Redis Connector for CData Sync

Build 23.0.8839
  • Redis
    • Establishing a Connection
    • Data Model
      • Modeling Redis Hashes as Tables
      • Freeform Querying of Redis Keys
      • Redis Data Types
      • Tables
        • Keys
    • Connection String Options
      • Authentication
        • AuthScheme
        • Server
        • Port
        • LogicalDatabase
        • User
        • Password
        • EnableCluster
        • UseSSL
        • ReplicaSet
      • Connection
        • DefineTables
        • PatternSeparator
        • ReaderEndpoints
        • TablePattern
      • SSL
        • SSLClientCert
        • SSLClientCertType
        • SSLClientCertPassword
        • SSLClientCertSubject
        • SSLStartMode
        • SSLServerCert
      • SSH
        • SSHAuthMode
        • SSHClientCert
        • SSHClientCertPassword
        • SSHClientCertSubject
        • SSHClientCertType
        • SSHServer
        • SSHPort
        • SSHUser
        • SSHPassword
        • SSHServerFingerprint
        • UseSSH
      • Firewall
        • FirewallType
        • FirewallServer
        • FirewallPort
        • FirewallUser
        • FirewallPassword
      • Logging
        • LogModules
      • Schema
        • Location
        • BrowsableSchemas
        • Tables
        • Views
      • Miscellaneous
        • IgnoreTypeErrors
        • MaxRows
        • Other
        • ParallelMode
        • PseudoColumns
        • QueryTimeout
        • RowScanDepth
        • TableScanDepth
        • Timeout
        • UserDefinedViews

Redis Connector for CData Sync

Overview

The CData Sync App provides a straightforward way to continuously pipeline your Redis data to any database, data lake, or data warehouse, making it easily available for Analytics, Reporting, AI, and Machine Learning.

The Redis connector can be used from the CData Sync application to pull data from Redis and move it to any of the supported destinations.

Redis Version Support

The Sync App models Redis instances as relational databases. The Sync App leverages the Redis commands to enable bidirectional access to Redis and Redis Enterprise data through SQL. Redis versions 2.8.0 and above are supported.

Redis Connector for CData Sync

Establishing a Connection

Adding a Connection to Redis

To add a connection to Redis:

  1. In the application console, navigate to the Connections page.
  2. At the Add Connections panel, select the icon for the connection you want to add.
  3. If the Redis icon is not available, click the Add More icon to download and install the Redis connector from the CData site.

For required properties, see the Settings tab.

For connection properties that are not typically required, see the Advanced tab.

Connecting to Redis

Set the Server connection property to the name or address of the server your Redis instance is running on.

If your Redis server is running on a port other than the default (6379), you can specify your port in the Port property.

Authenticating to Redis

The Sync App supports Password and ACL authentication. Connections to Redis instances that aren't password protected are supported as well.

No Authentication

Set the AuthScheme property to None. This indicates the Redis instance is not password protected (using the requirepass directive in the configuration file).

Password

Set the AuthScheme property to Password and set the Password property to the password used to authenticate with a password protected Redis instance using the Redis AUTH command.

ACL (Access Control List)

Set the following to connect:

  • AuthScheme: Set this to ACL.
  • User: Set this to the username you use to authenticate with Redis ACL.
  • Password: Set this to the password you use to authenticate with Redis ACL.

Securing Redis Connections

You can set UseSSL to negotiate SSL/TLS encryption when you connect.

Redis Connector for CData Sync

Data Model

The Sync App enables you to model Redis key-value pairs as tables.

Tables

The Sync App enables two major paradigms for modeling Redis key-value pairs as tables.

Modeling Redis Hashes as Tables

Redis key patterns can be modeled as tables. See Freeform Querying of Redis Keys for a breakdown of the different configuration options.

Freeform Querying of Redis Keys

It is also possible to query keys directly as if they are tables.

If you would like to query specific keys as tables, see Modeling Redis Hashes as Tables.

If you would like to query all keys in the Redis keystore from a single table, see the Keys table.

Redis Data Types

See Redis Data Types for a list of the Redis data types supported by the Sync App.

Stored Procedures

Use the available Stored Procedures to submit commands (in native redis-cli syntax) to the Redis server for direct execution.

Redis Connector for CData Sync

Modeling Redis Hashes as Tables

The Sync App can be configured to shape the discovered metadata.

Use the DefineTables, TablePattern, and PatternSeparator connection properties to customize how tables and columns are inferred from the Redis key store.

Presume the following hashes have been created in the Redis server (either with redis-cli or the RunCommand storec procedure).

> hmset user:1000 name "John Smith" email "[email protected]" password "s3cret"
OK
> hmset user:1001 name "Mary Jones" email "[email protected]" password "hidden" 
OK
> hmset user:1002 name "Sally Brown" email "[email protected]" password "p4ssw0rd"
OK
> hmset customer:200 name "John Smith" account "123456" balance "543.21"
OK
> hmset customer:201 name "Mary Jones" account "123457" balance "654.32" 
OK
> hmset customer:202 name "Sally Brown" account "123458" balance "765.43"
OK

When these properties are used to define the Sync App's behavior, the Redis keys will be pivoted, so that each Redis key that matches the pattern in the definition is represented as a single row in the table. Each value associated with that Redis key becomes a column for the table.

DefineTables Property

The DefineTables connection property allows you to explicitly define the names of the tables that will appear. To do so, set the property to a comma-separated string of name-value pairs, where the name is the name of the table and the value is the pattern used to assign Redis keys to that table.

The Sync App aggregates all of the Redis keys that match the specified patterns.

DefineTables=Users=user:*,Customers=customer:*;

With the property set as above, the Users and Customers tables will be exposed. If you were to query the tables, you would see the following results:

SELECT * FROM Users

RedisKey name email password
user:1000 John Smith [email protected] s3cret
user:1001 Mary Jones [email protected] hidden
user:1002 Sally Brown sally.b@example p4ssw0rd

SELECT * FROM Customers

RedisKey name account balance
customer:200 John Smith 123456 543.21
customer:201 Mary Jones 123456 654.32
customer:202 Sally Brown 123456 765.43

TablePattern Property

The TablePattern connection property allows you to define the separator(s) that determine how the Sync App defines tables. For the Redis keys described above, "user" and "customer" would be defined as tables if the separator is set to ":" since the unique piece of each Redis key appears after the ":". If you have a need to structure the tables differently, to drill down further, you can include multiple instances of the separator. Set the property to a pattern that includes the separator(s) needed to define your table structure. (Below is the default value.)

You can also manually specify the pattern separator indepently from the TablePattern using the PatternSeparator property.

TablePattern=*:*;

With the property set as above, the user and customer tables will be exposed. If you were to query the tables, you would see the following results:

SELECT * FROM user

RedisKey name email password
user:1000 John Smith [email protected] s3cret
user:1001 Mary Jones [email protected] hidden
user:1002 Sally Brown sally.b@example p4ssw0rd

SELECT * FROM customer

RedisKey name account balance
customer:200 John Smith 123456 543.21
customer:201 Mary Jones 123456 654.32
customer:202 Sally Brown 123456 765.43

Redis Connector for CData Sync

Freeform Querying of Redis Keys

The most direct way to work with Redis data with the Sync App is to use a Redis key as a table name. Below you will find sample data, queries, and results based on Redis data types.

Note: This page contains redis-cli syntax. Use either your own instance of redis-cli or the RunCommand procedure to send queries from the Sync App to the Redis server for direct execution.

Redis Strings

Create a string in Redis:

> set mykey somevalue
OK
If you perform a SELECT query on mykey the Sync App will return the following:

SELECT * FROM mykey

RedisKey ValueIndex Value RedisType ValueScore
mykey 1 somevalue String NULL

Redis Lists

Create a list in Redis:

> rpush mylist A B C
(integer) 3
If you perform a SELECT query on mylist the Sync App will return the following:

SELECT * FROM mylist

RedisKey ValueIndex Value RedisType ValueScore
mylist 1 A List NULL
mylist 2 B List NULL
mylist 3 C List NULL

Deleting Redis Lists

List type records can also be removed using DELETE statements, though they must be performed by specifying the Value column in the WHERE clause:

DELETE FROM Keys WHERE Value = 'myvalue' AND RedisKey = 'mylist'

Note that using ValueIndex in the WHERE clause of the DELETE statement is not supported.

Redis Sets

Create a set in Redis:

> sadd myset 1 2 3
(integer) 3
If you perform a SELECT query on myset the Sync App will return the following (note that Redis can return the elements of a set in any order):

SELECT * FROM myset

RedisKey ValueIndex Value RedisType ValueScore
myset 1 2 Set NULL
myset 2 1 Set NULL
myset 3 3 Set NULL

Redis Sorted Sets

Create a ZSet (sorted set) in Redis:

> zadd hackers 1940 "Alan Kay" 1957 "Sophie Wilson" 1953 "Richard Stallman" 1949 "Anita Borg"
(integer) 9
If you perform a SELECT query on hackers the Sync App will return the following:

SELECT * FROM hackers

RedisKey ValueIndex Value RedisType ValueScore
hackers 1 Alan Kay ZSet 1940
hackers 2 Anita Borg ZSet 1949
hackers 3 Richard Stallman ZSet 1953
hackers 4 Sophie Wilson ZSet 1957

Redis Hashes

Create a hash in Redis:

> hmset user:1000 username antirez birthyear 1977 verified 1
OK
If you perform a SELECT query on user:1000 the Sync App will return the following:

SELECT * FROM user:1000

RedisKey ValueIndex Value RedisType ValueScore
user:1000 username antirez Hash NULL
user:1000 birthyear 1977 Hash NULL
user:1000 verified 1 Hash NULL

Querying Key Patterns as Tables

You can retrieve multiple Redis keys at once by using a pattern (e.g., "user:*") as a table name. For example, start by adding several keys to Redis that match a pattern:

> hmset user:1000 name "John Smith" email "[email protected]" password "s3cret"
OK
> hmset user:1001 name "Mary Jones" password "hidden" email "[email protected]"
OK

If you use user:* as the table name, the Sync App will retrieve all Redis key-value pairs whose keys match the pattern. You can see the expected results below:

SELECT * FROM [user:*]

RedisKey ValueIndex Value RedisType ValueScore
user:1000 name John Smith Hash NULL
user:1000 email [email protected] Hash NULL
user:1000 password s3cret Hash NULL
user:1001 name Mary Jones Hash NULL
user:1001 email [email protected] Hash NULL
user:1001 password hidden Hash NULL

Redis Connector for CData Sync

Redis Data Types

Redis Data Types Supported by the Data Provider

  • Binary-safe Strings.
  • Lists: collections of string elements sorted according to the order of insertion. They are basically linked lists.
  • Sets: collections of unique, unsorted string elements.
  • Sorted Sets (ZSets): similar to sets but where every string element is associated to a floating number value, called score. The elements are always taken sorted by their score, so unlike sets it is possible to retrieve a range of elements (for example you may ask: give me the top 10, or the bottom 10).
  • Hashes: maps composed of fields associated with values. Both the field and the value are strings. This is very similar to Ruby or Python hashes.

Redis Connector for CData Sync

Tables

The Sync App models the data in Redis as a list of tables in a relational database that can be queried using standard SQL statements.

Redis Connector for CData Sync Tables

Name Description
Keys Returns keys present in the Redis store.

Redis Connector for CData Sync

Keys

Returns keys present in the Redis store.

This table allows you to query all Redis keys in one place. It models Redis key metadata in exactly the same way as described in Freeform Querying of Redis Keys.

Columns

Name Type ReadOnly Description
RedisKey [KEY] String True

The name of the Redis key.

ValueIndex String True

Varies by type: 1 for strings; the one-based index for sets, lists, and sorted sets; or the associated field name for hashes.

Value String True

The value associated with the Redis key.

RedisType String True

The type associated with the Redis key.

ValueScore Double True

NULL for strings, lists, sets, and hashes. Returns the associated score for sorted sets.

Redis Connector for CData Sync

Connection String Options

The connection string properties are the various options that can be used to establish a connection. This section provides a complete list of the options you can configure in the connection string for this provider. Click the links for further details.

For more information on establishing a connection, see Establishing a Connection.

Authentication


PropertyDescription
AuthSchemeThe authentication mechanism that the provider will use to authenticate with Redis.
ServerThe host name or IP address of the server hosting the Redis instance.
PortThe port for the Redis database.
LogicalDatabaseThe index of the Redis Logical Database.
UserThe username provided for authentication with Redis ACL.
PasswordThe password used to authenticate with Redis.
EnableClusterThis field sets whether the Redis Cluster Mode is enabled.
UseSSLThis field sets whether SSL is enabled.
ReplicaSetThis property allows you to specify multiple servers in addition to the one configured in Server and Port . Specify both a server name and port; separate servers with a comma.

Connection


PropertyDescription
DefineTablesDefine the tables exposed by the provider using table names and Redis key patterns.
PatternSeparatorDefine the table pattern's delimiter.
ReaderEndpointsThe slave hosts and port array, which indicates the Redis Master/Slave cluster's slave instances, are split by a comma.
TablePatternDefine the tables exposed by the provider using Redis key patterns.

SSL


PropertyDescription
SSLClientCertThe TLS/SSL client certificate store for SSL Client Authentication (2-way SSL).
SSLClientCertTypeThe type of key store containing the TLS/SSL client certificate.
SSLClientCertPasswordThe password for the TLS/SSL client certificate.
SSLClientCertSubjectThe subject of the TLS/SSL client certificate.
SSLStartModeThis property determines how the provider starts the SSL negotiation.
SSLServerCertThe certificate to be accepted from the server when connecting using TLS/SSL.

SSH


PropertyDescription
SSHAuthModeThe authentication method used when establishing an SSH Tunnel to the service.
SSHClientCertA certificate to be used for authenticating the SSHUser.
SSHClientCertPasswordThe password of the SSHClientCert key if it has one.
SSHClientCertSubjectThe subject of the SSH client certificate.
SSHClientCertTypeThe type of SSHClientCert private key.
SSHServerThe SSH server.
SSHPortThe SSH port.
SSHUserThe SSH user.
SSHPasswordThe SSH password.
SSHServerFingerprintThe SSH server fingerprint.
UseSSHWhether to tunnel the Redis connection over SSH. Use SSH.

Firewall


PropertyDescription
FirewallTypeThe protocol used by a proxy-based firewall.
FirewallServerThe name or IP address of a proxy-based firewall.
FirewallPortThe TCP port for a proxy-based firewall.
FirewallUserThe user name to use to authenticate with a proxy-based firewall.
FirewallPasswordA password used to authenticate to a proxy-based firewall.

Logging


PropertyDescription
LogModulesCore modules to be included in the log file.

Schema


PropertyDescription
LocationA path to the directory that contains the schema files defining tables, views, and stored procedures.
BrowsableSchemasThis property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC.
TablesThis property restricts the tables reported to a subset of the available tables. For example, Tables=TableA,TableB,TableC.
ViewsRestricts the views reported to a subset of the available tables. For example, Views=ViewA,ViewB,ViewC.

Miscellaneous


PropertyDescription
IgnoreTypeErrorsRemoves support for the specified data types and ignores casting exceptions for those types.
MaxRowsLimits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses.
OtherThese hidden properties are used only in specific use cases.
ParallelModeThis option sets whether the provider should use multiple connections when connecting to Redis.
PseudoColumnsThis property indicates whether or not to include pseudo columns as columns to the table.
QueryTimeoutThe timeout in seconds for which the provider will wait for the query response. The default value is -1, which indicates the provider should never time out.
RowScanDepthThe maximum number of rows to scan to look for the columns available in a table.
TableScanDepthThe maximum number of keys to scan when looking for tables available in your Redis database.
TimeoutThe value in seconds until the timeout error is thrown, canceling the operation.
UserDefinedViewsA filepath pointing to the JSON configuration file containing your custom views.
Redis Connector for CData Sync

Authentication

This section provides a complete list of the Authentication properties you can configure in the connection string for this provider.


PropertyDescription
AuthSchemeThe authentication mechanism that the provider will use to authenticate with Redis.
ServerThe host name or IP address of the server hosting the Redis instance.
PortThe port for the Redis database.
LogicalDatabaseThe index of the Redis Logical Database.
UserThe username provided for authentication with Redis ACL.
PasswordThe password used to authenticate with Redis.
EnableClusterThis field sets whether the Redis Cluster Mode is enabled.
UseSSLThis field sets whether SSL is enabled.
ReplicaSetThis property allows you to specify multiple servers in addition to the one configured in Server and Port . Specify both a server name and port; separate servers with a comma.
Redis Connector for CData Sync

AuthScheme

The authentication mechanism that the provider will use to authenticate with Redis.

Remarks

Choose one of the following:

  • None: Indicates that the Redis instance is not password protected (using the requirepass directive in the configuration file).
  • Password: The Sync App attempts to connect using the AUTH Redis command, using Password.
  • ACL: The Sync App authenticates using ACL credentials.

Redis Connector for CData Sync

Server

The host name or IP address of the server hosting the Redis instance.

Remarks

The host name or IP address of the server hosting the Redis instance.

Redis Connector for CData Sync

Port

The port for the Redis database.

Remarks

The port for the Redis database.

Redis Connector for CData Sync

LogicalDatabase

The index of the Redis Logical Database.

Remarks

The index of the Redis Logical Database. The default value is 0.

Redis Connector for CData Sync

User

The username provided for authentication with Redis ACL.

Remarks

The username provided for authentication with Redis ACL.

Redis Connector for CData Sync

Password

The password used to authenticate with Redis.

Remarks

The password used to authenticate with Redis.

Redis Connector for CData Sync

EnableCluster

This field sets whether the Redis Cluster Mode is enabled.

Remarks

This field sets whether the Redis Cluster Mode is enabled.

Redis Connector for CData Sync

UseSSL

This field sets whether SSL is enabled.

Remarks

This field sets whether the Sync App will attempt to negotiate TLS/SSL connections to the server. By default, the Sync App checks the server's certificate against the system's trusted certificate store. To specify another certificate, set SSLServerCert.

Redis Connector for CData Sync

ReplicaSet

This property allows you to specify multiple servers in addition to the one configured in Server and Port . Specify both a server name and port; separate servers with a comma.

Remarks

This property only works when EnableCluster is True. This property allows you to specify the other servers in the replica set in addition to the one configured in Server and Port. You must specify all servers in the replica set using ReplicaSet, Server, and Port.

Specify both a server name and port in ReplicaSet; separate servers with a comma. For example:

Server=localhost;Port=6379;ReplicaSet=localhost:6380,localhost:6381;

To find the primary server, the Sync App queries the servers in ReplicaSet and the server specified by Server and Port.

Redis Connector for CData Sync

Connection

This section provides a complete list of the Connection properties you can configure in the connection string for this provider.


PropertyDescription
DefineTablesDefine the tables exposed by the provider using table names and Redis key patterns.
PatternSeparatorDefine the table pattern's delimiter.
ReaderEndpointsThe slave hosts and port array, which indicates the Redis Master/Slave cluster's slave instances, are split by a comma.
TablePatternDefine the tables exposed by the provider using Redis key patterns.
Redis Connector for CData Sync

DefineTables

Define the tables exposed by the provider using table names and Redis key patterns.

Remarks

This property is used to define the key pattern within Redis that will appear as tables. The value is a comma-separated list of name-value pairs in the form [Table Name]=[Redis key pattern]. Table Name is the name of the table you want to use for the data and will be used when issuing queries. The Redis key pattern is the pattern to be used to group and pivot corresponding keys into the named table.

For example:

DefineTables="DefinedTable1=table1:*,DefinedTable2=table2:*"

Given this value, all of the keys that begin with "table1:" will be found in DefinedTable1, while all keys that begin with "table2:" will be found in DefinedTable2.

If there is any conflict between tables defined with this property and those defined by the TablePattern, these statically defined tables will take precedence.

Redis Connector for CData Sync

PatternSeparator

Define the table pattern's delimiter.

Remarks

This property is used in tandem with TablePattern to define the delimiter character for the pattern, which determines where the table names derived from the key pattern will end.

This is especially useful when there is more than one delimiter in your TablePattern.

For example, if TablePattern is set to *@*:* and there is a key called "first@second:1", a pattern separator of "@" produces the table name "first" and a PatternSeparator of ":" produces the table name "first@second".

Note that the behavior of the pattern separator is greedy, meaning the last instance of the separator character is used to specify the end of the table name.

For example, if there is a key called "first:second:1", a pattern separator of ":" produces the table name "first:second".

Redis Connector for CData Sync

ReaderEndpoints

The slave hosts and port array, which indicates the Redis Master/Slave cluster's slave instances, are split by a comma.

Remarks

The slave hosts and port array indicate the Redis Master/Slave cluster's slave instances. For example: 'ReaderEndpoints=app:6381,app:6382;'

Redis Connector for CData Sync

TablePattern

Define the tables exposed by the provider using Redis key patterns.

Remarks

This property is used to define the key patterns within Redis that will appear as tables. The value is a Redis key pattern. The Redis key pattern is a string pattern containing a separator to determine a hierarchical structure for the key-values stored in the Redis data store. Any other string patterns in the value will limit which keys will be pivoted and returned as tables.

For example, TablePattern="*:*" causes the ":" character to be used as the separator. Given the following keys,


user:1001, user:1002, user:1003, admin:001, admin:002, admin:003

two tables would be exposed, user and admin, with the related keys corresponding to individual rows in each table.

Redis Connector for CData Sync

SSL

This section provides a complete list of the SSL properties you can configure in the connection string for this provider.


PropertyDescription
SSLClientCertThe TLS/SSL client certificate store for SSL Client Authentication (2-way SSL).
SSLClientCertTypeThe type of key store containing the TLS/SSL client certificate.
SSLClientCertPasswordThe password for the TLS/SSL client certificate.
SSLClientCertSubjectThe subject of the TLS/SSL client certificate.
SSLStartModeThis property determines how the provider starts the SSL negotiation.
SSLServerCertThe certificate to be accepted from the server when connecting using TLS/SSL.
Redis Connector for CData Sync

SSLClientCert

The TLS/SSL client certificate store for SSL Client Authentication (2-way SSL).

Remarks

The name of the certificate store for the client certificate.

The SSLClientCertType field specifies the type of the certificate store specified by SSLClientCert. If the store is password protected, specify the password in SSLClientCertPassword.

SSLClientCert is used in conjunction with the SSLClientCertSubject field in order to specify client certificates. If SSLClientCert has a value, and SSLClientCertSubject is set, a search for a certificate is initiated. See SSLClientCertSubject for more information.

Designations of certificate stores are platform-dependent.

The following are designations of the most common User and Machine certificate stores in Windows:

MYA certificate store holding personal certificates with their associated private keys.
CACertifying authority certificates.
ROOTRoot certificates.
SPCSoftware publisher certificates.

In Java, the certificate store normally is a file containing certificates and optional private keys.

When the certificate store type is PFXFile, this property must be set to the name of the file. When the type is PFXBlob, the property must be set to the binary contents of a PFX file (for example, PKCS12 certificate store).

Redis Connector for CData Sync

SSLClientCertType

The type of key store containing the TLS/SSL client certificate.

Remarks

This property can take one of the following values:

USER - defaultFor Windows, this specifies that the certificate store is a certificate store owned by the current user. Note that this store type is not available in Java.
MACHINEFor Windows, this specifies that the certificate store is a machine store. Note that this store type is not available in Java.
PFXFILEThe certificate store is the name of a PFX (PKCS12) file containing certificates.
PFXBLOBThe certificate store is a string (base-64-encoded) representing a certificate store in PFX (PKCS12) format.
JKSFILEThe certificate store is the name of a Java key store (JKS) file containing certificates. Note that this store type is only available in Java.
JKSBLOBThe certificate store is a string (base-64-encoded) representing a certificate store in JKS format. Note that this store type is only available in Java.
PEMKEY_FILEThe certificate store is the name of a PEM-encoded file that contains a private key and an optional certificate.
PEMKEY_BLOBThe certificate store is a string (base64-encoded) that contains a private key and an optional certificate.
PUBLIC_KEY_FILEThe certificate store is the name of a file that contains a PEM- or DER-encoded public key certificate.
PUBLIC_KEY_BLOBThe certificate store is a string (base-64-encoded) that contains a PEM- or DER-encoded public key certificate.
SSHPUBLIC_KEY_FILEThe certificate store is the name of a file that contains an SSH-style public key.
SSHPUBLIC_KEY_BLOBThe certificate store is a string (base-64-encoded) that contains an SSH-style public key.
P7BFILEThe certificate store is the name of a PKCS7 file containing certificates.
PPKFILEThe certificate store is the name of a file that contains a PuTTY Private Key (PPK).
XMLFILEThe certificate store is the name of a file that contains a certificate in XML format.
XMLBLOBThe certificate store is a string that contains a certificate in XML format.

Redis Connector for CData Sync

SSLClientCertPassword

The password for the TLS/SSL client certificate.

Remarks

If the certificate store is of a type that requires a password, this property is used to specify that password to open the certificate store.

Redis Connector for CData Sync

SSLClientCertSubject

The subject of the TLS/SSL client certificate.

Remarks

When loading a certificate the subject is used to locate the certificate in the store.

If an exact match is not found, the store is searched for subjects containing the value of the property. If a match is still not found, the property is set to an empty string, and no certificate is selected.

The special value "*" picks the first certificate in the certificate store.

The certificate subject is a comma separated list of distinguished name fields and values. For example, "CN=www.server.com, OU=test, C=US, [email protected]". The common fields and their meanings are shown below.

FieldMeaning
CNCommon Name. This is commonly a host name like www.server.com.
OOrganization
OUOrganizational Unit
LLocality
SState
CCountry
EEmail Address

If a field value contains a comma, it must be quoted.

Redis Connector for CData Sync

SSLStartMode

This property determines how the provider starts the SSL negotiation.

Remarks

The SSLStartMode property may have one of the following values:

AutomaticIf the remote port is set to the standard plain text port of the protocol (where applicable), the Sync App will behave the same as if SSLStartMode is set to Explicit. In all other cases, SSL negotiation will be implicit.
ImplicitThe SSL negotiation will start immediately after the connection is established.
ExplicitThe Sync App will first connect in plaintext, and then explicitly start SSL negotiation through a protocol command such as STARTTLS.
NoneNo SSL negotiation, no SSL security. All communication will be in plain text mode.

Redis Connector for CData Sync

SSLServerCert

The certificate to be accepted from the server when connecting using TLS/SSL.

Remarks

If using a TLS/SSL connection, this property can be used to specify the TLS/SSL certificate to be accepted from the server. Any other certificate that is not trusted by the machine is rejected.

This property can take the following forms:

Description Example
A full PEM Certificate (example shortened for brevity) -----BEGIN CERTIFICATE----- MIIChTCCAe4CAQAwDQYJKoZIhv......Qw== -----END CERTIFICATE-----
A path to a local file containing the certificate C:\cert.cer
The public key (example shortened for brevity) -----BEGIN RSA PUBLIC KEY----- MIGfMA0GCSq......AQAB -----END RSA PUBLIC KEY-----
The MD5 Thumbprint (hex values can also be either space or colon separated) ecadbdda5a1529c58a1e9e09828d70e4
The SHA1 Thumbprint (hex values can also be either space or colon separated) 34a929226ae0819f2ec14b4a3d904f801cbb150d

If not specified, any certificate trusted by the machine is accepted.

Use '*' to signify to accept all certificates. Note that this is not recommended due to security concerns.

Redis Connector for CData Sync

SSH

This section provides a complete list of the SSH properties you can configure in the connection string for this provider.


PropertyDescription
SSHAuthModeThe authentication method used when establishing an SSH Tunnel to the service.
SSHClientCertA certificate to be used for authenticating the SSHUser.
SSHClientCertPasswordThe password of the SSHClientCert key if it has one.
SSHClientCertSubjectThe subject of the SSH client certificate.
SSHClientCertTypeThe type of SSHClientCert private key.
SSHServerThe SSH server.
SSHPortThe SSH port.
SSHUserThe SSH user.
SSHPasswordThe SSH password.
SSHServerFingerprintThe SSH server fingerprint.
UseSSHWhether to tunnel the Redis connection over SSH. Use SSH.
Redis Connector for CData Sync

SSHAuthMode

The authentication method used when establishing an SSH Tunnel to the service.

Remarks

  • None: No authentication is performed. The current User value is ignored, and the connection is logged in as anonymous.
  • Password: The Sync App uses the values of User and Password to authenticate the user.
  • Public_Key: The Sync App uses the values of User and SSHClientCert to authenticate the user. SSHClientCert must have a private key available for this authentication method to succeed.

Redis Connector for CData Sync

SSHClientCert

A certificate to be used for authenticating the SSHUser.

Remarks

SSHClientCert must contain a valid private key in order to use public key authentication. A public key is optional, if one is not included then the Sync App generates it from the private key. The Sync App sends the public key to the server and the connection is allowed if the user has authorized the public key.

The SSHClientCertType field specifies the type of the key store specified by SSHClientCert. If the store is password protected, specify the password in SSHClientCertPassword.

Some types of key stores are containers which may include multiple keys. By default the Sync App will select the first key in the store, but you can specify a specific key using SSHClientCertSubject.

Redis Connector for CData Sync

SSHClientCertPassword

The password of the SSHClientCert key if it has one.

Remarks

This property is only used when authenticating to SFTP servers with SSHAuthMode set to PublicKey and SSHClientCert set to a private key.

Redis Connector for CData Sync

SSHClientCertSubject

The subject of the SSH client certificate.

Remarks

When loading a certificate the subject is used to locate the certificate in the store.

If an exact match is not found, the store is searched for subjects containing the value of the property.

If a match is still not found, the property is set to an empty string, and no certificate is selected.

The special value "*" picks the first certificate in the certificate store.

The certificate subject is a comma separated list of distinguished name fields and values. For instance "CN=www.server.com, OU=test, C=US, [email protected]". Common fields and their meanings are displayed below.

FieldMeaning
CNCommon Name. This is commonly a host name like www.server.com.
OOrganization
OUOrganizational Unit
LLocality
SState
CCountry
EEmail Address

If a field value contains a comma it must be quoted.

Redis Connector for CData Sync

SSHClientCertType

The type of SSHClientCert private key.

Remarks

This property can take one of the following values:

TypesDescriptionAllowed Blob Values
MACHINE/USER Blob values are not supported.
JKSFILE/JKSBLOB base64-only
PFXFILE/PFXBLOBA PKCS12-format (.pfx) file. Must contain both a certificate and a private key.base64-only
PEMKEY_FILE/PEMKEY_BLOBA PEM-format file. Must contain an RSA, DSA, or OPENSSH private key. Can optionally contain a certificate matching the private key.base64 or plain text. Newlines may be replaced with spaces when providing the blob as text.
PPKFILE/PPKBLOBA PuTTY-format private key created using the puttygen tool.base64-only
XMLFILE/XMLBLOBAn XML key in the format generated by the .NET RSA class: RSA.ToXmlString(true).base64 or plain text.

Redis Connector for CData Sync

SSHServer

The SSH server.

Remarks

The SSH server.

Redis Connector for CData Sync

SSHPort

The SSH port.

Remarks

The SSH port.

Redis Connector for CData Sync

SSHUser

The SSH user.

Remarks

The SSH user.

Redis Connector for CData Sync

SSHPassword

The SSH password.

Remarks

The SSH password.

Redis Connector for CData Sync

SSHServerFingerprint

The SSH server fingerprint.

Remarks

The SSH server fingerprint.

Redis Connector for CData Sync

UseSSH

Whether to tunnel the Redis connection over SSH. Use SSH.

Remarks

By default the Sync App will attempt to connect directly to Redis. When this option is enabled, the Sync App will instead establish an SSH connection with the SSHServer and tunnel the connection to Redis through it.

Redis Connector for CData Sync

Firewall

This section provides a complete list of the Firewall properties you can configure in the connection string for this provider.


PropertyDescription
FirewallTypeThe protocol used by a proxy-based firewall.
FirewallServerThe name or IP address of a proxy-based firewall.
FirewallPortThe TCP port for a proxy-based firewall.
FirewallUserThe user name to use to authenticate with a proxy-based firewall.
FirewallPasswordA password used to authenticate to a proxy-based firewall.
Redis Connector for CData Sync

FirewallType

The protocol used by a proxy-based firewall.

Remarks

This property specifies the protocol that the Sync App will use to tunnel traffic through the FirewallServer proxy.

Type Default Port Description
TUNNEL 80 When this is set, the Sync App opens a connection to Redis and traffic flows back and forth through the proxy.
SOCKS4 1080 When this is set, the Sync App sends data through the SOCKS 4 proxy specified by FirewallServer and FirewallPort and passes the FirewallUser value to the proxy, which determines if the connection request should be granted.
SOCKS5 1080 When this is set, the Sync App sends data through the SOCKS 5 proxy specified by FirewallServer and FirewallPort. If your proxy requires authentication, set FirewallUser and FirewallPassword to credentials the proxy recognizes.

Redis Connector for CData Sync

FirewallServer

The name or IP address of a proxy-based firewall.

Remarks

This property specifies the IP address, DNS name, or host name of a proxy allowing traversal of a firewall. The protocol is specified by FirewallType: Use FirewallServer with this property to connect through SOCKS or do tunneling.

Redis Connector for CData Sync

FirewallPort

The TCP port for a proxy-based firewall.

Remarks

This specifies the TCP port for a proxy allowing traversal of a firewall. Use FirewallServer to specify the name or IP address. Specify the protocol with FirewallType.

Redis Connector for CData Sync

FirewallUser

The user name to use to authenticate with a proxy-based firewall.

Remarks

The FirewallUser and FirewallPassword properties are used to authenticate against the proxy specified in FirewallServer and FirewallPort, following the authentication method specified in FirewallType.

Redis Connector for CData Sync

FirewallPassword

A password used to authenticate to a proxy-based firewall.

Remarks

This property is passed to the proxy specified by FirewallServer and FirewallPort, following the authentication method specified by FirewallType.

Redis Connector for CData Sync

Logging

This section provides a complete list of the Logging properties you can configure in the connection string for this provider.


PropertyDescription
LogModulesCore modules to be included in the log file.
Redis Connector for CData Sync

LogModules

Core modules to be included in the log file.

Remarks

Only the modules specified (separated by ';') will be included in the log file. By default all modules are included.

See the Logging page for an overview.

Redis Connector for CData Sync

Schema

This section provides a complete list of the Schema properties you can configure in the connection string for this provider.


PropertyDescription
LocationA path to the directory that contains the schema files defining tables, views, and stored procedures.
BrowsableSchemasThis property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC.
TablesThis property restricts the tables reported to a subset of the available tables. For example, Tables=TableA,TableB,TableC.
ViewsRestricts the views reported to a subset of the available tables. For example, Views=ViewA,ViewB,ViewC.
Redis Connector for CData Sync

Location

A path to the directory that contains the schema files defining tables, views, and stored procedures.

Remarks

The path to a directory which contains the schema files for the Sync App (.rsd files for tables and views, .rsb files for stored procedures). The folder location can be a relative path from the location of the executable. The Location property is only needed if you want to customize definitions (for example, change a column name, ignore a column, and so on) or extend the data model with new tables, views, or stored procedures.

If left unspecified, the default location is "%APPDATA%\\CData\\Redis Data Provider\\Schema" with %APPDATA% being set to the user's configuration directory:

Platform %APPDATA%
Windows The value of the APPDATA environment variable
Linux ~/.config

Redis Connector for CData Sync

BrowsableSchemas

This property restricts the schemas reported to a subset of the available schemas. For example, BrowsableSchemas=SchemaA,SchemaB,SchemaC.

Remarks

Listing the schemas from databases can be expensive. Providing a list of schemas in the connection string improves the performance.

Redis Connector for CData Sync

Tables

This property restricts the tables reported to a subset of the available tables. For example, Tables=TableA,TableB,TableC.

Remarks

Listing the tables from some databases can be expensive. Providing a list of tables in the connection string improves the performance of the Sync App.

This property can also be used as an alternative to automatically listing views if you already know which ones you want to work with and there would otherwise be too many to work with.

Specify the tables you want in a comma-separated list. Each table should be a valid SQL identifier with any special characters escaped using square brackets, double-quotes or backticks. For example, Tables=TableA,[TableB/WithSlash],WithCatalog.WithSchema.`TableC With Space`.

Note that when connecting to a data source with multiple schemas or catalogs, you will need to provide the fully qualified name of the table in this property, as in the last example here, to avoid ambiguity between tables that exist in multiple catalogs or schemas.

Redis Connector for CData Sync

Views

Restricts the views reported to a subset of the available tables. For example, Views=ViewA,ViewB,ViewC.

Remarks

Listing the views from some databases can be expensive. Providing a list of views in the connection string improves the performance of the Sync App.

This property can also be used as an alternative to automatically listing views if you already know which ones you want to work with and there would otherwise be too many to work with.

Specify the views you want in a comma-separated list. Each view should be a valid SQL identifier with any special characters escaped using square brackets, double-quotes or backticks. For example, Views=ViewA,[ViewB/WithSlash],WithCatalog.WithSchema.`ViewC With Space`.

Note that when connecting to a data source with multiple schemas or catalogs, you will need to provide the fully qualified name of the table in this property, as in the last example here, to avoid ambiguity between tables that exist in multiple catalogs or schemas.

Redis Connector for CData Sync

Miscellaneous

This section provides a complete list of the Miscellaneous properties you can configure in the connection string for this provider.


PropertyDescription
IgnoreTypeErrorsRemoves support for the specified data types and ignores casting exceptions for those types.
MaxRowsLimits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses.
OtherThese hidden properties are used only in specific use cases.
ParallelModeThis option sets whether the provider should use multiple connections when connecting to Redis.
PseudoColumnsThis property indicates whether or not to include pseudo columns as columns to the table.
QueryTimeoutThe timeout in seconds for which the provider will wait for the query response. The default value is -1, which indicates the provider should never time out.
RowScanDepthThe maximum number of rows to scan to look for the columns available in a table.
TableScanDepthThe maximum number of keys to scan when looking for tables available in your Redis database.
TimeoutThe value in seconds until the timeout error is thrown, canceling the operation.
UserDefinedViewsA filepath pointing to the JSON configuration file containing your custom views.
Redis Connector for CData Sync

IgnoreTypeErrors

Removes support for the specified data types and ignores casting exceptions for those types.

Remarks

A comma-separated list of data types for which to ignore casting exceptions and treat as strings. For example, IgnoreTypeErrors=Date,Time.

If the value can be parsed as the specified type, it is returned as a string; otherwise, the value is returned as NULL instead.

Redis Connector for CData Sync

MaxRows

Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses.

Remarks

Limits the number of rows returned when no aggregation or GROUP BY is used in the query. This takes precedence over LIMIT clauses.

Redis Connector for CData Sync

Other

These hidden properties are used only in specific use cases.

Remarks

The properties listed below are available for specific use cases. Normal driver use cases and functionality should not require these properties.

Specify multiple properties in a semicolon-separated list.

Integration and Formatting

DefaultColumnSizeSets the default length of string fields when the data source does not provide column length in the metadata. The default value is 2000.
ConvertDateTimeToGMTDetermines whether to convert date-time values to GMT, instead of the local time of the machine.
RecordToFile=filenameRecords the underlying socket data transfer to the specified file.

Redis Connector for CData Sync

ParallelMode

This option sets whether the provider should use multiple connections when connecting to Redis.

Remarks

The default is that parallel mode is disabled, which means that the Sync App will use only one connection when communicating with Redis. This works well for smaller databases, but can cause performance and memory usage issues on larger databases.

If parallel mode is enabled, the Sync App will open different connections to Redis for discovering keys and reading data. This makes interacting with larger databases more efficient but can add overhead for smaller databases.

If parallel mode is enabled, you can tune how much memory is used by the Sync App by using the hidden MaxPageSize property (see Other). The default value is 5, but you can increase it to make the Sync App faster or decrease it to make the Sync App use less memory.

Redis Connector for CData Sync

PseudoColumns

This property indicates whether or not to include pseudo columns as columns to the table.

Remarks

This setting is particularly helpful in Entity Framework, which does not allow you to set a value for a pseudo column unless it is a table column. The value of this connection setting is of the format "Table1=Column1, Table1=Column2, Table2=Column3". You can use the "*" character to include all tables and all columns; for example, "*=*".

Redis Connector for CData Sync

QueryTimeout

The timeout in seconds for which the provider will wait for the query response. The default value is -1, which indicates the provider should never time out.

Remarks

The timeout in seconds for which the Sync App will wait for the query response. The default value is -1, which indicates the Sync App should never time out.

Redis Connector for CData Sync

RowScanDepth

The maximum number of rows to scan to look for the columns available in a table.

Remarks

The columns in a table must be determined by scanning table rows. This value determines the maximum number of rows that will be scanned.

Setting a high value may decrease performance. Setting a low value may prevent the data type from being determined properly, especially when there is null data.

Redis Connector for CData Sync

TableScanDepth

The maximum number of keys to scan when looking for tables available in your Redis database.

Remarks

Since Redis is schemaless, the Sync App determines tables by finding keys that match the TablePattern. This value determines the maximum number of keys that will be scanned for each entry in TablePattern.

To disable this limit and always scan all keys, set the value of this property to "-1". Otherwise, set this property to a positive integer to limit the keys scanned to that amount.

Redis Connector for CData Sync

Timeout

The value in seconds until the timeout error is thrown, canceling the operation.

Remarks

If Timeout = 0, operations do not time out. The operations run until they complete successfully or until they encounter an error condition.

If Timeout expires and the operation is not yet complete, the Sync App throws an exception.

Redis Connector for CData Sync

UserDefinedViews

A filepath pointing to the JSON configuration file containing your custom views.

Remarks

User Defined Views are defined in a JSON-formatted configuration file called UserDefinedViews.json. The Sync App automatically detects the views specified in this file.

You can also have multiple view definitions and control them using the UserDefinedViews connection property. When you use this property, only the specified views are seen by the Sync App.

This User Defined View configuration file is formatted as follows:

  • Each root element defines the name of a view.
  • Each root element contains a child element, called query, which contains the custom SQL query for the view.

For example:

{
	"MyView": {
		"query": "SELECT * FROM Customers WHERE MyColumn = 'value'"
	},
	"MyView2": {
		"query": "SELECT * FROM MyTable WHERE Id IN (1,2,3)"
	}
}
Use the UserDefinedViews connection property to specify the location of your JSON configuration file. For example:
"UserDefinedViews", C:\Users\yourusername\Desktop\tmp\UserDefinedViews.json
Note that the specified path is not embedded in quotation marks.

Copyright (c) 2024 CData Software, Inc. - All rights reserved.
Build 23.0.8839