Uploaded image for project: 'Log4j 2'
  1. Log4j 2
  2. LOG4J2-769

Startup takes a long time if you have empty packages attribute

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.1
    • Fix Version/s: 2.0.2
    • Component/s: None
    • Labels:
      None

      Description

      If you specify packages="" in your configuration, the PluginManager searches through all classes in the CLASSPATH at startup, because split() on an empty string actually returns an array containing one empty string.

        Activity

        Hide
        seh4nc Scott Harrington added a comment -

        My patch for LOG4J2-745 contains a fix for this issue.

        Show
        seh4nc Scott Harrington added a comment - My patch for LOG4J2-745 contains a fix for this issue.
        Hide
        remkop@yahoo.com Remko Popma added a comment -

        Prevented registration of empty package strings in revision 1617053.
        Please verify and close.

        Show
        remkop@yahoo.com Remko Popma added a comment - Prevented registration of empty package strings in revision 1617053. Please verify and close.
        Hide
        remkop@yahoo.com Remko Popma added a comment -

        Re-opening for regression in revision 1617171:
        PluginManager.addPackages(Collection<String> packages) checks that the collection is not empty but does not check if it contains empty strings.

        Show
        remkop@yahoo.com Remko Popma added a comment - Re-opening for regression in revision 1617171: PluginManager.addPackages(Collection<String> packages) checks that the collection is not empty but does not check if it contains empty strings.
        Hide
        remkop@yahoo.com Remko Popma added a comment -

        Now also ignoring empty package names in the specified collection in method addPackages(Collection).
        Committed in revision 1617295.
        Please verify and close.

        Show
        remkop@yahoo.com Remko Popma added a comment - Now also ignoring empty package names in the specified collection in method addPackages(Collection) . Committed in revision 1617295. Please verify and close.

          People

          • Assignee:
            remkop@yahoo.com Remko Popma
            Reporter:
            seh4nc Scott Harrington
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development