Configuring WebSphere Application Server for MySQL manually

IBM Worklight V5.0.5. automatically configures your databases. However, if you are using an older version of IBM Worklight, or if you are experiencing problems with the automatic configuration process for the WebSphere Application Server, you must manually set up and configure your MySQL database and then the WebSphere Application Server for MySQL. Complete the MySQL database setup procedure before continuing.

  1. Set up the JDBC provider:

    1. In the WebSphere Application Server console, click Resources > JDBC > JDBC Providers.

    2. Create a JDBC provider named MySQL.

    3. Set Database type to User defined.

    4. Set Scope to Cell.

    5. Set Implementation class to com.mysql.jdbc.jdbc2.optional.MysqlConnectionPoolDataSource.

    6. Set Database classpath to the location of the MySQL JDBC connector .jar file.

    7. Save your changes.

  2. If you are using JNDI configuration, rather than URI configuration, create a data source for the IBM Worklight database:

    1. Click Resources > JDBC > Data sources.

    2. Click New to create a data source.

    3. Type any name (for example, Worklight Database).

    4. Set JNDI Name to jdbc/WorklightDS.

    5. Use the existing JDBC Provider MySQL, defined in the previous step.

    6. Set Scope to New.

    7. On the Configuration tab, select the Non-transactional data source check box.

    8. Click Next a number of times, leaving all other settings as defaults.

    9. Save your changes.

  3. If you are using JNDI configuration, rather than URI configuration, create a data source for the IBM Worklight reports database:

    1. Click New to create a data source.

    2. Type any name (for example, Worklight Report Database).

    3. Set JNDI Name to jdbc/WorklightReportsDS or any other name defined in the worklight.properties file to refer to the IBM Worklight report database.

    4. Use the existing JDBC Provider MySQL, defined in the previous step.

    5. Set Scope to New.

    6. On the Configuration tab, select the Non-transactional data source check box. New.

    7. Click Next a number of times, leaving all other settings as defaults.

    8. Save your changes.

  4. Set the custom properties of each new data source.

    1. Select the new data source.

    2. Click Custom properties.

    3. Set the following properties:
      port = 3306
      relaxAutoCommit=true
      databaseName = the name of the MySQL database
      serverName = the host name of the MySQL server
      user = the user name of the MySQL server
      password = the password associated with the user name
      


Parent topic Troubleshooting