![]() Note: The port number can also be specified via -host. This can be the address of any node in the cluster. The server host and port number to connect to. To convert a connection URL to the syntax that works with your client driver, run cockroach convert-url. FlagĪ connection URL to use instead of the other arguments. Variable is used when the command-line flag is not specified. In replacement) to -url which specifies all parameters as aįor each command-line flag that directs a connection parameter,ĬockroachDB also recognizes an environment variable. Parameters as separate, discrete command-line flags, in addition (or Most cockroach commands accept connection Use for secure specifies a connection for the root user to an insecure cluster listening for a socket connection (e.g., a cluster started with the -socket-dir flag) at /path/to/client, and on port 26257. An error occurs if the secure connection cannot be established.įorce a secure connection and verify that the server certificate is signed by a known CA.įorce a secure connection, verify that the server certificate is signed by a known CA, and verify that the server address matches that specified in the certificate. Try to establish a secure connection, but accept an insecure connection if the server does not support secure connections.įorce a secure connection. Parameterĭo not use an encrypted, secure connection at all.Įnable a secure connection only if the server requires it. The following values are supported for sslmode, although only the first and the last are recommended for use. For example, spaces in a JDBC connection string must specified as %20. Note that some drivers require certain characters to be properly encoded in URL connection strings. Sets a session variable for the SQL session. The host in the connection string now includes the tenant information. Identifies your tenant cluster on a multi-tenant host. After the first options parameter is specified, any additional parameters in the same connection string must be separated by a space. Note that passwords with special characters must be passed as query string parameters (e.g., and not as a component in the connection URL (e.g., stringĪdditional options to be passed to the server.ĬockroachDB supports the following options parameters. It is not recommended to pass the password in the URL directly. Path to the client private key, when sslmode is not disable. Path to the client certificate, when sslmode is not disable. Path to the CA certificate, when sslmode is not disable. See Secure Connections With URLs for details. Which type of secure connection to use: disable, allow, prefer, require, verify-ca or verify-full. Note: For Java JDBC, use ApplicationName. ParameterĪn initial value for the application_name session variable. After the first parameter is specified, any additional parameters must be separated by an ampersand ( &). The following additional parameters can be passed after the ? character in the URL. Is currently printed if it is mistakenly specified, andįuture versions of CockroachDB may return an error in that case. Required when specifying a Unix domain socket URI.Īdditional connection parameters, including SSL/TLS certificate settings. The directory path to the client listening for a socket connection. Use this value when in doubt.Ī database name to use as current database. The default port number for CockroachDB is 26257. The port number of the SQL interface of the CockroachDB node or load balancer. The host name or address of a CockroachDB node or load balancer. Note that passwords with special characters must be passed as query string parameters (e.g., and not as a component in the connection URL (e.g., more detail about how CockroachDB handles passwords. ![]() Connect using a URLĪ connection URL has the following SQL user that will own the client session. Start, other cockroach commands, GUI database visualizer,ĭiscrete parameters may be more convenient in automation, where theĬomponents of the configuration are filled in separately fromĭifferent variables in a script or a service manager. Parameters (the URL) between different tools: the output of cockroach Specifying client parameters using a URL may be more convenient duringĮxperimentation, as it facilitates copy-pasting the connection When to use a URL and when to use discrete parameters Specify the connection parameters separately from a URL. In addition, all cockroach client commands also accept discrete Which CockroachDB server to connect to using a PostgreSQL connection Most client apps, including cockroach client commands, determine The client connection parametersĭetermine which CockroachDB cluster they connect to, and how toĮstablish this network connection. Client applications, including cockroach clientĬonnection to a CockroachDB cluster.
0 Comments
Leave a Reply. |
Details
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |