This folder contains a samples in form of stand-alone snippets that demonstrate useful scenarios.
Ensure the following setup is in place.
You must have java installed locally on your machinee. Run java --version to check if this is available.
A working instance of Memorystore for Valkey must be available. You can run the Valkey CLI for a local instance, or create an instance through the GCP Platform.
To setup a live instance, create a new Memorystore instance through the GCloud CLI using the following
gcloud redis instances create myinstance --size=2 --region=LOCATION --redis-version=redis_6_xAltrernativley, run a local instance through the Valkey CLI
valkey-cliEach example contains instructions on any prerequisite configuration.
mvn compilemvn exec:java -Dexec.mainClass=MemorystoreTtlItem #Replace the main class as needed