Getting Started
This is the manual for older MicroStream versions (Version < 5.0).
The new documentation (Version >= 5.0) is located at:
Prerequisites
Hello World
1) Get the default CachingProvider
implementation from the application’s classpath. This method will work if and only if there is only one JCache implementation available in the classpath. If there are multiple providers then use the fully qualified name
Caching.getCachingProvider("one.microstream.cache.CachingProvider")
instead.
2) Get the default CacheManager
instance using the provider.
3) Create a cache configuration using MutableConfiguration
4) with key type and value type as Integer
and String
respectively
5) configured to store the cache entries by reference (not by value)
6) and with an expiry time of one minute defined for entries from the moment they are created.
7) Using the cache manager, create a cache named jCache
with the configuration created in step 3.
8) Put some data into the cache
9) And retrieve it.
The same can be done using MicroSteam's CacheConfiguration
API. This time we use a EmbeddedStorageManager
as a backing store for the cache.
Last updated