Infrastructure prerequisites

Before setting up the Advancing Controller, ensure the following components are properly set up:

  • FlowX.AI Engine Deployment: The Advancing Controller depends on the FlowX Engine and must be deployed in the same environment. Refer to the FlowX Engine setup guide for more information on setting up the Engine.
  • Database Instance: The Advancing Controller uses a PostgreSQL or OracleDB instance as its database.

Dependencies

Ensure the following dependencies are met:

  • Database: Properly configured database instance.
  • Datasource: Configuration details for connecting to the database.
  • FlowX.AI Engine: Must be set up and running. Refer to the FlowX Engine setup guide.

Database compatibility

The Advancing Controller supports both PostgreSQL and OracleDB databases. However, the FlowX.AI Engine and the Advancing Controller must be configured to use the same type of database at any given time. The FlowX.AI Engine employs two databases: one shared with the FlowX.AI Admin microservice for process metadata and instances, and the other dedicated to advancement.

Mixing PostgreSQL and OracleDB is not supported; both databases must be of the same type.

Database configuration

PostgreSQL

A basic PostgreSQL configuration for Advancing:

postgresql:
  enabled: true
  postgresqlUsername: "postgres"
  postgresqlPassword: ""
  postgresqlDatabase: "advancing"
  existingSecret: "postgresql-generic"
  postgresqlMaxConnections: 200
  persistence:
    enabled: true
    storageClass: standard-rwo
    size: 20Gi
  resources:
    limits:
      cpu: 1000m
      memory: 1024Mi
    requests:
      memory: 256Mi
      cpu: 100m
  metrics:
    enabled: true
    serviceMonitor:
      enabled: false
    prometheusRule:
      enabled: false
  primary:
    nodeSelector:
      preemptible: "false"

If the parallel advancing configuration already exists, you must reset the ‘advancing’ database by executing the SQL command DROP DATABASE advancing;. Once the database has been dropped, the Liquibase script will automatically re-enable it.

Configuration

The Advancing Controller uses a PostgreSQL or an Oracle database as a dependency.

  • Ensure that the user, password, connection link, and database name are correctly configured. If these details are not configured correctly, errors will occur at startup.
  • The datasource is configured automatically via a Liquibase script inside the engine. All updates will include migration scripts.

Configuring datasource

If you need to change the datasource configuration detail, you can use the following environment variables:

  • SPRING_DATASOURCE_URL: Environment variable used to configure a data source URL for a Spring application. It typically contains the JDBC driver name, the server name, port number, and database name.
  • SPRING_DATASOURCE_USERNAME: Environment variable used to set the username for the database connection. This can be used to connect to a database instance.
  • SPRING_DATASOURCE_PASSWORD: Environment variable used to store the password for the database connection. This can be used to secure access to the database and ensure that only authorized users have access to the data.
  • SPRING_JPA_DATABASE: Specifies the type of database that the Spring application should connect to (accepted values: oracle or postgresql).
  • SPRING_JPA_PROPERTIES_HIBERNATE_DEFAULTSCHEMA (❗️only for Oracle DBs): Specifies the default schema to use for the database (default value: public).

It’s important to keep in mind that the Advancing Controller is tightly integrated with the FlowX.AI Engine. Therefore, it is crucial to ensure that both the Engine and the Advancing Controller are configured correctly and are in sync.