For up-to-date product documentation, see the IBM MobileFirst Foundation Developer Center.


Configure WebSphere Application Server for Derby manually for Application Center

We can set up and configure your Apache Derby database manually for Application Center with WebSphere® Application Server.


Overview

Complete the Apache Derby database setup procedure before continuing.


Procedure

  1. Determine a suitable directory for the JDBC driver JAR file in the WebSphere Application Server installation directory.

    If this directory does not exist, create it.

    • For a standalone server, we can use a directory such as was_install_dir/optionalLibraries/IBM/Worklight/derby.
    • For deployment to a WebSphere Application Server ND cell, use was_install_dir/profiles/profile-name/config/cells/cell-name/Worklight/derby.
    • For deployment to a WebSphere Application Server ND cluster, use was_install_dir/profiles/profile-name/config/cells/cell-name/clusters/cluster-name/Worklight/derby.
    • For deployment to a WebSphere Application Server ND node, use was_install_dir/profiles/profile-name/config/cells/cell-name/nodes/node-name/Worklight/derby.
    • For deployment to a WebSphere Application Server ND server, use was_install_dir/profiles/profile-name/config/cells/cell-name/nodes/node-name/servers/server-name/Worklight/derby.
  2. Add the Derby JAR file from product_install_dir/ApplicationCenter/tools/lib/derby.jar to the directory determined in step 1.
  3. Set up the JDBC provider.
    1. In the WebSphere Application Server console, click Resources > JDBC > JDBC Providers.
    2. Select the appropriate scope from the Scope combination box.
    3. Click New.
    4. Set Database Type to User-defined.
    5. Set class Implementation name to org.apache.derby.jdbc.EmbeddedConnectionPoolDataSource40.
    6. Set Name to Worklight - Derby JDBC Provider.
    7. Set Description to Derby JDBC provider for Worklight.
    8. Click Next.
    9. Set the Class path to the JAR file in the directory determined in step 1, replacing was_install_dir/profiles/profile-name with the WebSphere Application Server variable reference ${USER_INSTALL_ROOT}.
    10. Click Finish.
  4. Create the data source for the Worklight database.
    1. In the WebSphere Application Server console, click Resources > JDBC > Data sources.
    2. Select the appropriate scope from the Scope combination box.
    3. Click New.
    4. Set Data source Name to Application Center Database.
    5. Set JNDI name to jdbc/AppCenterDS.
    6. Click Next.
    7. Select the existing JDBC Provider that is named Worklight - Derby JDBC Provider.
    8. Click Next.
    9. Click Next.
    10. Click Finish.
    11. Click Save.
    12. In the table, click the Application Center Database data source created.
    13. Under Additional Properties, click Custom properties.
    14. Click databaseName.
    15. Set Value to the path to the APPCNTR database that is created in Setting up your Apache Derby database manually for Application Center.
    16. Click OK.
    17. Click Save.
    18. At the top of the page, click Application Center Database.
    19. Under Additional Properties, click WebSphere Application Server data source properties.
    20. Select Non-transactional datasource.
    21. Click OK.
    22. Click Save.
    23. In the table, select the Application Center Database data source created.
    24. Optional: Only if you are not on the console of a WebSphere Application Server Deployment Manager, click test connection.

Parent topic: Configuring the Apache Derby database manually for Application Center