Uploaded image for project: 'JGroups'
  1. JGroups
  2. JGRP-2048

ClassConfigurator: use constructors rather than Classes in map

    Details

    • Type: Enhancement
    • Status: Resolved (View Workflow)
    • Priority: Minor
    • Resolution: Duplicate Issue
    • Affects Version/s: None
    • Fix Version/s: 4.0
    • Labels:
      None

      Description

      Investigate whether use of Constructor as values in the maps rather than Class<?> improves performance. Class.newInstance() does cache the constructor, but there's a security check that's executed once, so using the constructor may improve perf.
      Also, if a class doesn't have an empty constructor, using Class.newInstance() would throw an exception, whereas using constructors would detect this at load time.

        Gliffy Diagrams

          Attachments

            Issue Links

              Activity

                People

                • Assignee:
                  belaban Bela Ban
                  Reporter:
                  belaban Bela Ban
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  1 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved: