public final class DriverUtil extends Object
| Modifier and Type | Field and Description |
|---|---|
static String |
CASSANDRA_4
Cassandra version 4.0.
|
static String |
CASSANDRA_5
Cassandra version 5.0.
|
static String |
JDBC_DRIVER_PROPERTIES_FILE
Properties file name containing some properties relative to this JDBC wrapper (such as JDBC driver version,
name, etc.).
|
static String |
JSSE_KEYSTORE_PASSWORD_PROPERTY
The JSSE property used to retrieve the key store password when SSL is enabled on the database connection using
JSSE properties.
|
static String |
JSSE_KEYSTORE_PROPERTY
The JSSE property used to retrieve the key store when SSL is enabled on the database connection using
JSSE properties.
|
static String |
JSSE_TRUSTSTORE_PASSWORD_PROPERTY
The JSSE property used to retrieve the trust store password when SSL is enabled on the database connection using
JSSE properties.
|
static String |
JSSE_TRUSTSTORE_PROPERTY
The JSSE property used to retrieve the trust store when SSL is enabled on the database connection using
JSSE properties.
|
static String |
NULL_KEYWORD
NULL CQL keyword. |
| Modifier and Type | Method and Description |
|---|---|
static String |
buildMetadataList(List<VersionedMetadata> metadataList,
String dbVersion)
Builds an alphabetically sorted and comma-separated list of metadata (such as built-in functions or CQL
keywords) existing in the specified Cassandra version.
|
static DriverPropertyInfo |
buildPropertyInfo(String propertyName,
Object value)
Builds an instance of
DriverPropertyInfo for the given driver property and value. |
static boolean |
existsInDatabaseVersion(String dbVersion,
VersionedMetadata versionedMetadata)
Checks whether the database metadata (CQL type or built-in function) exists in the current database version.
|
static String |
getDriverProperty(String name)
Gets a property value from the Cassandra JDBC driver properties file.
|
static org.semver4j.Semver |
safeParseVersion(String version)
Gets the
Semver representation of a version string. |
public static final String JDBC_DRIVER_PROPERTIES_FILE
public static final String JSSE_TRUSTSTORE_PROPERTY
public static final String JSSE_TRUSTSTORE_PASSWORD_PROPERTY
public static final String JSSE_KEYSTORE_PROPERTY
public static final String JSSE_KEYSTORE_PASSWORD_PROPERTY
public static final String NULL_KEYWORD
NULL CQL keyword.public static final String CASSANDRA_5
public static final String CASSANDRA_4
public static String getDriverProperty(String name)
name - The name of the property.public static org.semver4j.Semver safeParseVersion(String version)
Semver representation of a version string.
It uses the dot character as separator to parse the different parts of a version (major, minor, patch).
version - The version string (for example X.Y.Z).Semver.ZERO if the string cannot be parsed correctly.public static boolean existsInDatabaseVersion(String dbVersion, VersionedMetadata versionedMetadata)
dbVersion - The version of the Cassandra database the driver is currently connected to.versionedMetadata - The database metadata to check.true if the database metadata exists in the current database version, false otherwise.public static String buildMetadataList(List<VersionedMetadata> metadataList, String dbVersion)
metadataList - The list of possible metadata to format.dbVersion - The version of the Cassandra database the driver is currently connected to.public static DriverPropertyInfo buildPropertyInfo(String propertyName, Object value)
DriverPropertyInfo for the given driver property and value.propertyName - The property name.value - The current value of the property.Copyright © 2020–2024 ING Bank. All rights reserved.