Search code examples
oraclewso2wso2-api-manager

How can deploy Wso2 in Oracle?


when I want to change wso2'DB to Oracle I got this error. what shall I do? here are my tables and my settings please help me. Thank you so much

enter image description here enter image description here enter image description here


Solution

  • The error is thrown when you dont configure the shared db properly. Run the oracle scripts under APIM_HOME/dbcripts/oracle.sql into a separate user schema and point it as follows.

    [database.shared_db]
    type = "oracle"
    url = "jdbc:oracle:thin:@localhost:1521/orcl1"
    username = "sharedadmin"
    password = "sharedadmin"
    driver = "oracle.jdbc.driver.OracleDriver"
    validationQuery = "SELECT 1 FROM DUAL"
    

    then run the script under APIM-HOME/dbscripts/apimgt/oracle.sql and point it as follows.

    [database.apim_db]
    type = "oracle"
    url = "jdbc:oracle:thin:@localhost:1521/orcl2"
    username = "apimadmin"
    password = "apimadmin"
    driver = "oracle.jdbc.driver.OracleDriver"
    validationQuery = "SELECT 1 FROM DUAL"
    

    It is not mandatory to configure local db to oracle if you do not have a special need. You can remove the [database.local] config to keep it in h2 itself.