In This Article


Redshift Database Connection Steps 

Step 1 - Create a JDBC Config File

For GenRocket to connect to a Redshift database via JDBC, you must create a JDBC Config or config.properties file. Any application can connect to a Redshift database via JDBC using the information included in this file. Click here to learn more.


A template is provided below:

driver=com.amazon.redshift.jdbc42.Driver
user=USER
password=PASSWORD
url=jdbc:redshift://HOST:PORT/DATABASE_NAME
batchCount=1000
Text

Example Configuration File

GenRocket will read this config file and connect to the employee database on localhost using username root and password root.

driver=com.amazon.redshift.jdbc42.Driver
user=root
password=root
url=jdbc:redshift:@localhost:1521/employee
batchCount=1000


Tex

Step 2 - (Optional) Encrypt the JDBC Config file

You can encrypt this file for additional security. Click here to learn more. 

Step 3 - Update Your JDBC Organization Resource Value in GenRocket We P

The resource.jdbc.config Organization Resource specifies the location of the JDBC Config file on the logged in user's local machine. This resource value should contain the full directory path (e.g., /home/user/dev). Click here for more information.



Step 4 - Update your Profile in the .genrocket Folder

Each user has a profile stored in the .genrocket folder on their local machine. You must download and replace your profile (in ~/.genrocket folder). GenRocket will read this resource value from your profile on your system to make a connection with the database. Click here for more information.


Step 5 - Download and place the JDBC connector Jar file in the $GENROCKET_HOME/lib/ folder

  • Download and place a Redshift JDBC Connector in your genrocket/lib folder
  • For more information on the Redshift JDBC Connector and download instructions, click here.


Step 6 - Test the JDBC Connection

You can test the JDBC connection before referencing the resource in GenRocket. Click here to learn more. 


Step 7 - Reference the JDBC Resource as Needed

When you create a Scenario containing a Generator or Receiver that references your jdbc.config resource, it will connect directly to your database. GenRocket feature that uses a database connection will also need to reference this file. 


Troubleshooting 

If you cannot connect to your Redshift database via JDBC, please contact us at support@genrocket.com.