igniterealtime/openfire-monitoring-plugin

Improve usage of 'resource' columns in the database

Closed this issue · 0 comments

In the first database upgrade scripts, a change was applied that causes various JIDs in ofMessageArchive to be stored in separate parts. Where initially the columns toJID and fromJID stored the entire JID, they now only store a bare JID. The resource parts, if any, are stored in new columns: toJIDResource respectively fromJIDResource.

Two issues remain:

  • Not all code was updated to reflect this change, causing some code to expect toJID and fromJID to contain full JIDs
  • No migration of existing database content was performed. This causes the database to continue to hold full JIDs in the old columns, for certain rows.