These instructions will help you connect Bamboo to a MySQL 5.x database. MySQL 4.1 is no longer a supported database for use with Bamboo.
Please note, the JDBC driver for MySQL 5.x (JDBC Connector/J 5.1) is bundled with Bamboo. You do not have to download and install the driver.
1. Configuring MySQL
Configuring MySQL to use 'UTF8' character encoding
Before you connect Bamboo to MySQL, you need configure it to use 'utf8' character encoding, instead of 'latin1' character encoding. Please read the following MySQL documentation for instructions:
Creating an external MySQL database
You need to manually create an external MySQL database (referenced below as the "bamboo" database) before Bamboo can connect to it. Please read the following documentation for instructions:
2. Connecting Bamboo to MySQL
Bamboo provides two ways to connect to a MySQL database — via JDBC or via a datasource. JDBC is generally simpler and is the recommended method.
Connecting via JDBC
To connect Bamboo to a MySQL database, via JDBC,
- Run the Setup Wizard and choose the 'Custom Installation' method.
- At the 'Choose a Database Configuration' step, choose 'External Database' and select 'MySQL 5.x' from the list.
- The 'Select Database Connection' screen will appear. Select 'Direct JDBC connection'.
- The 'Setup JDBC Connection' screen will appear as shown in the screenshot below.
- 'Driver Class Name' — Type the following:
com.mysql.jdbc.Driver
- 'Database URL' — Type the URL where Bamboo will access your database. Ensure that your URL includes the
autoReconnect=true flag, the useUnicode=true flag and the characterEncoding=utf8 flag, e.g.
If the autoReconnect flag is not set, the MySQL JDBC driver will eventually time out and Bamboo will no longer be able to communicate with the database.
For more information on the URL syntax, please see the MySQL documentation.
- 'User Name' — Type the username that Bamboo will use to access your database.
- 'Password' — Type the password (if required) that Bamboo will use to access your database.
- Select the 'Overwrite existing data' checkbox if you wish Bamboo to overwrite any tables that already exist in the database.
- Click 'Continue' to finish specifying your connection settings.
Screenshot 1: 'Setup JDBC Connection (MySQL)'

Connecting via a datasource
To connect Bamboo to a MySQL database, via a datasource,
- Configure a datasource in your application server (consult your application server documentation for details). Ensure that the JDBC URL that you configure in your application server includes the
autoReconnect=true flag, the useUnicode=true flag and the characterEncoding=utf8 flag, e.g.
jdbc:mysql://localhost/bamboo?autoReconnect=true&useUnicode=true&characterEncoding=utf8
If the autoReconnect flag is not set, the MySQL JDBC driver will eventually time out and Bamboo will no longer be able to communicate with the database.
For more information on the URL syntax, please see the MySQL documentation.
- Run the Setup Wizard and choose the 'Custom Installation' method.
- At the 'Choose a Database Configuration' step, choose 'External Database' and select 'MySQL 5.x' from the list.
- The 'Select Database Connection' screen will appear. Select 'Connect via a datasource (configured in the application server)'.
- The 'Setup Datasource Connection' screen will appear as shown in the screenshot below. In the 'JNDI name' field, type the JNDI name of your datasource, as configured in your application server.
If java:comp/env/jdbc/DataSourceName doesn't work, try jdbc/DataSourceName (and vice versa).
- Select the 'Overwrite existing data' checkbox if you wish Bamboo to overwrite any tables that already exist in the database.
- Click 'Continue' to finish specifying your connection settings.
Screenshot 2: 'Setup Datasource Connection'
