An exception occurred while creating an affiliation

Hi

Version: Openfire 5.0.2

Server > Server Manager > Logs:

2025.11.26 11:34:11.239 ERROR [TaskEngine-pool-21693]: org.jivesoftware.openfire.pubsub.DefaultPubSubPersistenceProvider - An exception occurred while creating an affiliation (org.jivesoftware.openfire.pubsub.NodeAffiliate@312b599d - JID: kz@testspark.com - Affiliation: none) to a node (UniqueIdentifier{serviceId=‘dz@testspark.com’, nodeId=‘dz@testspark.com’}) in the database.
java.sql.SQLIntegrityConstraintViolationException: integrity constraint violation: unique constraint or index violation ; OFPUBSUBAFFILIATION_PK table: OFPUBSUBAFFILIATION
at org.hsqldb.jdbc.JDBCUtil.sqlException(Unknown Source) ~[hsqldb-2.7.1.jar:2.7.1]
at org.hsqldb.jdbc.JDBCUtil.sqlException(Unknown Source) ~[hsqldb-2.7.1.jar:2.7.1]

I’m getting spammed with a similar error in my logs. How do I fix it? I had trouble creating a user in AD. I deleted the account and created a new one, but something must have gone wrong with Openfire.

The same message occurs when debugging locally, it looks like a minor issue will be fixed later

1 Like

I appreciate it.