Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Steps to switch Database used by PF

  1. Add jdbc driver to classpath of application.
  2. Create policy_user user in database.
  3. Create policy_admin database.
  4. Edit the defaultConfig that is sent to start up your application and switch out the driver for the new database driver.

    Code Block
    titleExample DB Config
    "databaseProviderParameters": {
            "name": "PolicyProviderParameterGroup",
            "implementation": "org.onap.policy.models.provider.impl.DatabasePolicyModelsProviderImpl",
            "databaseDriver": "org.postgresql.jdbc.Driver",
            "databaseUrl": "jdbc:postgresql://localhost:5432/policyadmin",
            "databaseUser": "policy_user",
            "databasePassword": "cG9saWN5X3VzZXI=",
            "persistenceUnit": "PolicyMariaDb"
        },


  5. Run PAP application and you should see the tables created correctly in the database.

Proven Compatibility with Postgres

ServiceStatus
PAPStability Tests all pass
APIStability Tests all pass
APEX

Stability Tests all pass

Drools-PDPNot compatible
XACMLNot compatible

It would useful to enable a level of abstraction on the database so that PF is more flexible when it comes to which database is used.

...