Connections to Amazon OpenSearch Service are made in QuerySurge using the AWS JDBC driver. Users can take advantage of the power and connectivity options of AWS OpenSearch by setting up a regular JDBC connection to your OpenSearch domain in QuerySurge. While it is referred to as AWS OpenSearch Service, AWS is using a fork from the last ALv2 version of Elasticsearch and Kibana. You can download the OpenSearch JDBC driver here. Be sure to download the JDBC driver that corresponds to your version of OpenSearch or Elasticsearch.
Create a Connection
To create a AWS OpenSearch connection in QuerySurge, we use the Connection Extensibility feature of the Connection Wizard. Key pieces of information that you'll need for your connection include:
- The Elasticsearch user credentials (username and password)
- The AWS OpenSearch JDBC driver class:
com.amazon.opendistroforelasticsearch.jdbc.Driver - Your AWS OpenSearch Domain Endpoint
- Your AWS OpenSearch port , default is 443
- The AWS OpenSearch JDBC Connection URL (using the domain endpoint and port):
jdbc:elasticsearch://<your-domain-endpoint>:<port>Note: AWS OpenSearch requires the Master username and Master password on a connection, that was set up when you created your domain. It also requires that you set up the domain's access policy with fine-grained access control.
Setting up a Connection with the AWS OpenSearch JDBC Driver
- Download the AWS OpenSearch JDBC driver. The driver download can be found here.
- Deploy the driver jar to your QuerySurge Agent(s). The procedure for deploying a driver to a QuerySurge Agent is here (for Agents on Windows) and here (for Agents on Linux).
- Log into QuerySurge as a QuerySurge Admin user, and navigate to the Admin view. Launch the Connection Wizard, give your Connection a name, and for the Data Source, choose the Connection Extensibility option. (Steps for using the Connection Extensibility feature can be found here.). Click Next.
- Enter the AWS OpenSearch driver class (com.amazon.opendistroforelasticsearch.jdbc.Driver). Click Next.
- Enter your AWS JDBC URL (see above). Enter the Master Username and Master Password for the domain in the Authentication Info section. Click Next. When you've entered your URL, the Connection Wizard will look like the following. After checking your entries, click Next.
Note: A test query (optional) need only return a single row/column.
- If you have entered a test Query, you can use it to verify that your Connection parameters are correct by clicking the Test Connection button.
- The Connection test gives a popup showing whether the Connection was successfully completed.
- Once you have verified your Connection information, click the Save button to save the Connection. You are now ready to use the Connection in a QueryPair.
.