JDBC connector
This page describes how to enable provisioning to a database table with JDBC
OpenIAM can provision to a database table by means of several solutions. The JDBC connector integrates with a database through the Java Database Connectivity programming interface — it is used to integrate with existing relational database systems for user provisioning and identity data synchronization.
Create / update user (Save)
✅
Delete user
✅
Suspend / resume user
✅
Reset password
✅
Search / synchronize users
✅
Search groups
✅
Test connection
✅
Login
❌ Not implemented in the current connector
Group create/delete
❌ Not implemented in the current connector
Use cases
Provisioning users into an application's own database tables (a custom app whose users live in a
userstable).Importing users from a legacy database into OpenIAM via synchronization.
Working with any RDBMS with a JDBC driver — DB2, MySQL, MariaDB, PostgreSQL, SQL Server, Oracle.
Versions and compatibility
JDBC is a programming interface rather than a product, so there is no target version to match. What matters is the driver, and the connector loads the driver class named by the JDBC_DRIVER attribute at run time.
The JDBC Driver selection stores the driver class name (managed-system attribute JDBC_DRIVER), which the connector loads before connecting:
DB2
com.ibm.db2.jcc.DB2Driver
MySQL
com.mysql.cj.jdbc.Driver
MariaDB
org.mariadb.jdbc.Driver
PostgreSQL
org.postgresql.Driver
Microsoft SQL Server
com.microsoft.sqlserver.jdbc.SQLServerDriver
Oracle
oracle.jdbc.driver.OracleDriver
Prerequisites
A database account with rights on the target tables.
The matching JDBC driver JAR on the connector's classpath (see Supported drivers below).
Network access from the connector host to the database.
Verify JDBC connector availability in your OpenIAM environment before proceeding.
Installing the connector
Deploy the connector for your deployment type (the Kubernetes deployment configuration, or the RPM connector service openiam-connector@jdbc-connector-rabbitmq) — see Connectors via RPM. Ensure the JDBC driver JAR for your database is on the connector's classpath.
Starting, stopping, and restarting
RPM (systemd)
systemctl start|stop|restart openiam-connector@jdbc-connector-rabbitmq
Kubernetes
kubectl rollout restart the connector deployment.
Command-line parameters and properties
The connector is a Spring Boot application and takes no connector-specific command-line flags. Everything adjustable is a property, settable in the override file or in the usual Spring Boot forms (--name=value, or -Dname=value as a JVM argument).
confpath must point at the OpenIAM configuration directory. The connector reads its overrides from:
org.openiam.connector.queue
JDBC_Connector_1_Request
The queue the connector takes requests from. Must match the managed system
org.openiam.connector.queueResponseName
JDBC_Connector_1_Response
The queue it publishes responses to
org.openiam.connector.name
JDBC
The connector's registered name
org.openiam.connector.type
JDBC Connector
The connector type shown in the Webconsole
Change the queue names only when running more than one JDBC connector, and change them in both places.
Verifying the connector is running
In the Webconsole, open the managed system — the Running connector status indicator must be green.
Click Test Connection — it must return success.
In the RabbitMQ management console, confirm the JDBC_Connector_1_Request queue exists and has a consumer, and that JDBC_Connector_1_Response exists alongside it.
Provision a test user and confirm the row appears in the database.
Troubleshooting
JDBC_DRIVER_NOT_FOUND / "Unable to load the class"
Wrong driver class, or a database outside the six bundled ones with no JAR on the classpath
Re-check the JDBC Driver value against the table above. For MySQL in particular the class is com.mysql.cj.jdbc.Driver — the older com.mysql.jdbc.Driver was removed from Connector/J at 8.0.
SQL_ERROR on operations
The SQL fails against the target schema or the account lacks privileges
Check the query/table mapping and the database account's rights.
Test connection fails
Wrong connection string or credentials
Verify the JDBC URL format for your database type.
Group create/delete does nothing
Not implemented in this connector
Expected — see the operations table above.
See also: general connector troubleshooting and the connector error-code reference.
After completing this setup, your JDBC connector is ready to connect to your existing database system for seamless user provisioning and identity data synchronization with OpenIAM.
Registering the connector in OpenIAM
If registering manually under Provisioning → Connectors, the queue name must match exactly:
org.openiam.connector.queue
JDBC_Connector_1_Request
org.openiam.connector.name
JDBC
Configuring the managed system
Log in to the Webconsole, go to Provisioning → Managed system, click Create managed system, and configure it with the following parameters:
Type
JDBC Connector
System Name
A descriptive name for your environment
Description
Brief description of the database system
Status
Active
Connection String
Complete JDBC URL (e.g., jdbc:mariadb://your-host:3306/your-database)
Login Id
Database username
Password
Database password
JDBC Driver
Select your database type (see below)

Managed system attributes
The connector reads these from the managed system's Attributes panel, which appears once the managed system has been saved.

Three are required — without them every operation fails with `INVALID_CONFIGURATION` and a message naming the attribute.
JDBC_DRIVER
Yes
The driver class to load before connecting. Set by the JDBC Driver field
USER_TABLE_NAME
Yes
The table holding the user rows
USER_ID_COLUMN_NAME
Yes
The primary key column of that table
LOGIN_COLUMN_NAME
Yes
The column the identity's login is matched on
SCHEMA_NAME
No
Prefixed to every table name as schema.table. Needed on DB2
INSERTION_SEQUENCE
No
Dependent tables to write after the user row, separated by >
USER_ID_COLUMN_NAME_IN_OTHER_TABLES
No
The column those dependent tables use to refer back to the user
PASSWORD_ATTRIBUTE_NAME
No
Which attribute carries the password, in table.column form
PASSWORD_GROOVY
No
A Groovy script the password is passed through before it is written. Applied on reset password only
STATUS_ATTRIBUTE_NAME
No
Which attribute carries the account status, in table.column form. Suspend and resume write it
GROUP_TABLE_NAME
No
The table holding groups
GROUP_TABLE_ID_COLUMN_NAME
No
Its primary key column
GROUP_TABLE_NAME_COLUMN_NAME
No
The column holding the group name
GROUP_TABLE_MEMBERSHIP_NAME
No
The membership table joining users to groups
GROUP_MEMBERSHIP_USER_COLUMN_NAME
No
Its user column
GROUP_MEMBERSHIP_GROUP_COLUMN_NAME
No
Its group column
GROUP_MEMBERSHIP_ID_COLUMN_NAME
No
Its primary key column
GROUP_ATTRIBUTE_NAME
No
Which attribute carries group membership
Attribute mapping and policy map
The policy map decides which OpenIAM attributes reach the database and what each one carries. Name every mapped attribute <table>.<column> — the table being the one named in USER_TABLE_NAME, or any table listed in INSERTION_SEQUENCE.
Where the tables and key columns themselves are declared is a separate matter, covered in Managed system attributes.

Provision a user, then confirm the write reached the database.
In the Webconsole the audit entry for the request reports User has been successfully modified and names the target managed system. Its Request Body lists each mapped column with the value sent and the operation applied, for example USERS.USER_NAME with REPLACE. The password column is masked in that view.
Then check the row itself. Select the columns you mapped rather than SELECT *, so the password column does not end up on screen:
Reconciliation and synchronization
How synchronization and reconciliation work in general is covered in the Administration guide — see Synchronize and import data and Configure reconciliation. This section covers only what is specific to this connector.
Log in to the Webconsole, go to Provisioning → Synchronization, and click Create Synchronization.
Use the following settings for JDBC synchronization:
Name: JDBC User Example
Managed System: JDBC Managed System
Sync Type: Complete
Source Attribute Name: UID
SQL Query:
SELECT * FROM USERS

Click Save, then Sync now.
Synchronization runs in the background, so the screen that follows reports that the run has started, not that it has finished. It gives you three things worth reading:
The query the connector actually ran. Check it against what you typed — this is where a filter that silently returned nothing shows itself.
A summary row per object type, with the number of threads, the minimum, average and maximum transformation time, and a count of objects as success, failure or orphan, and total.
A row per object, carrying its name, whether it was treated as an orphan, the result, the request body that was sent, and any error.
The details block also states the batch size the objects will be processed in, which is the Records per Batch value from the form above.
Past runs are kept under Synchronization History, in the left menu beside Edit Synchronization.
Confirm the rows the synchronization read:
Last updated
Was this helpful?