Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8245241

Incorrect locale provider preference is not logged

    Details

    • Type: Bug
    • Status: Closed
    • Priority: P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 15
    • Component/s: core-libs
    • Labels:
    • Subcomponent:
    • Resolved In Build:
      b25
    • CPU:
      generic
    • OS:
      generic
    • Verification:
      Verified

      Description

      If an incorrect system property for locale providers is set, it should be logged and presetned to the user, but it's not in reality. There's such code in LocaleProvderAdapter static initializer:
      ---
                      } catch (IllegalArgumentException | UnsupportedOperationException e) {
                          // could be caused by the user specifying wrong
                          // provider name or format in the system property
                          LocaleServiceProviderPool.config(LocaleProviderAdapter.class, e.toString());
                      }
      ---
      However, this ends up in jdk.internal.logger.SurrogateLogger which only logs JUL_DEFAULT_LEVEL( = PlatformLogger.Level.INFO) or more severe ones, ie., the message, which is CONFIG, will never be logged.

        Attachments

          Activity

            People

            • Assignee:
              naoto Naoto Sato
              Reporter:
              naoto Naoto Sato
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: