Skip to content

Getting Started

The release of Valkey GLIDE was tested on the following platforms:

Linux:

  • Ubuntu 20 (x86_64/amd64 and arm64/aarch64)
  • Amazon Linux 2 (AL2) and 2023 (AL2023) (x86_64)

macOS:

  • macOS 14.7 (Apple silicon/aarch_64)
  • macOS 13.7 (x86_64/amd64)

The Java client contains the following parts:

  1. src: Rust dynamic library FFI to integrate with GLIDE core library.
  2. client: A Java-wrapper around the GLIDE core rust library and unit tests for it.
  3. benchmark: A dedicated benchmarking tool designed to evaluate and compare the performance of Valkey GLIDE and other Java clients.
  4. integTest: An integration test sub-project for API and E2E testing.

An example app (called glide.examples.ExamplesApp) is also available under examples app, to sanity check the project.

Valkey GLIDE is API-compatible with the following engine versions:

Engine Type6.27.07.17.28.08.19.0
Valkey---VVVV
RedisVVVV---

Java Requirements

Minimum requirements: JDK 11 or later. Ensure that you have a minimum Java version of JDK 11 installed on your system:

Terminal window
echo $JAVA_HOME
java -version

Refer to https://central.sonatype.com/artifact/io.valkey/valkey-glide. Once set up, you can run the basic examples.

Additionally, consider installing the Gradle plugin, OS Detector to help you determine what classifier to use.

There are 4 types of classifiers for Valkey GLIDE which are

osx-aarch_64
osx-x86_64
linux-aarch_64
linux-x86_64
// osx-aarch_64
dependencies {
implementation group: 'io.valkey', name: 'valkey-glide', version: '2.+', classifier: 'osx-aarch_64'
}
// osx-x86_64
dependencies {
implementation group: 'io.valkey', name: 'valkey-glide', version: '2.+', classifier: 'osx-x86_64'
}
// linux-aarch_64
dependencies {
implementation group: 'io.valkey', name: 'valkey-glide', version: '2.+', classifier: 'linux-aarch_64'
}
// linux-x86_64
dependencies {
implementation group: 'io.valkey', name: 'valkey-glide', version: '2.+', classifier: 'linux-x86_64'
}
// with osdetector
plugins {
id "com.google.osdetector" version "1.7.3"
}
dependencies {
implementation group: 'io.valkey', name: 'valkey-glide', version: '2.+', classifier: osdetector.classifier
}

To use Valkey GLIDE in a Java project with modules, include a module-info.java in your project.

For example, if your program is called App, you can follow this path

app/src/main/java/module-info.java

and inside the module it will specifically require the line requires glide.api;

For example, if your project has a module called playground, it would look like this

module playground {
requires glide.api;
}