Uploaded image for project: 'EJBCA'
  1. EJBCA
  2. ECA-2119

Optimize DNFieldsUtil

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: EJBCA 3.9.9, EJBCA 3.10.6, EJBCA 3.11.0, EJBCA 4.0.0
    • Fix Version/s: EJBCA 4.0.2
    • Component/s: PKI core
    • Labels:
      None

      Description

      org.ejbca.util.dn.DNFieldsUtil created to solve ECA-1841 generates a lot of new org.ejbca.util.dn.DNFields and org.ejbca.util.dn.DNFields.Field instances.

      Running memory profiling on org.ejbca.* and org.cesecore.* with EJBCA 4.0.2alpha while running "ant test:runlotsperuser" gives the following:

      1. DNFields.Field is responsible for 16.1% of all object instantiations and 10.2% of all allocated memory. (Live instances 0-5%, using 0-3% of memory)
      ...
      6. DNFields is responsible for 5.4% of all object instantiations and 2.2% of all allocated memory. (Live instances 0-2%, using 0-1% of memory)

      So these objects are short lived, but perhaps there is a way to perform this String manipulation that is more efficient and generates less work for the garbage collector?

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              johan Johan Eklund
              Reporter:
              johan Johan Eklund
              Verified by:
              Mike Agrenius Kushner
              Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: