public static class DriverInfo.Builder extends Object
DriverInfo instances.| Modifier and Type | Method and Description |
|---|---|
DriverInfo.Builder |
addUpstreamDriver(String driverName,
String driverVersion)
Adds an upstream driver to the driver information.
|
DriverInfo |
build()
Builds and returns a new immutable
DriverInfo instance. |
DriverInfo.Builder |
name(String name)
Sets the base library name.
|
public DriverInfo.Builder name(String name)
This overrides the default name ("Lettuce"). Use this when you want to completely customise the library identification.
name - the library name, must not be nullIllegalArgumentException - if name is nullpublic DriverInfo.Builder addUpstreamDriver(String driverName, String driverVersion)
Upstream drivers are prepended to the list, so the most recently added driver appears first in the formatted output.
The driver name must follow Maven artifactId naming conventions: lowercase letters, digits, hyphens, and underscores only, starting with a lowercase letter.
Both values must not contain spaces, newlines, non-printable characters, or brace characters as these would violate the format of the Redis CLIENT LIST reply.
driverName - the name of the upstream driver (e.g., "spring-data-redis"), must not be nulldriverVersion - the version of the upstream driver (e.g., "3.2.0"), must not be nullIllegalArgumentException - if the driver name or version is null or has invalid formatpublic DriverInfo build()
DriverInfo instance.Copyright © 2026 lettuce.io. All rights reserved.