Uploaded image for project: 'Openfire'
  1. Openfire
  2. OF-607

When serializing JID instances in a cluster, do not use the (expensive) JID constructor

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.8.0
    • Component/s: None
    • Labels:
      None

      Description

      Constructing a JID class via the regular constructors is a resource intensive task (the stringprepping that occurs requires a lot of CPU-cycles). This should be avoided when needed.

      When a JID instance is moved between cluster nodes, it is safe to assume that the original instance got node-prepped. The marshalling/unmarshalling (between cluster nodes) does not need to repeat this process. Currently, a String representation is serialized/deserialized and fed to the (resource intensive) JID constructors. As the JID class is Serializable itself, there is a lot to be gained here.

        Attachments

          Activity

            People

            • Assignee:
              guus Guus der Kinderen
              Reporter:
              guus Guus der Kinderen
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: