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

Make some JDK system properties read only

XMLWordPrintable

    • b20

        I've run into issues in the past where bad user code (app server) has set the java.home system property to a value other than the default. This has consequences for apps/code that depend heavily on java.home returning the correct location. The case I saw was a JDK 7 runtime attempting to load JDK 6 config files (since java.home was pointing to JDK 6)

        It leads me to question on whether we should change this behaviour. There are a whole bunch of properties that make no sense to change.
        Those like : java.version, java.vendor, java.home, java.vm.specification.version, java.vm.specification.vendor, java.vm.specification.name, java.vm.version, java.vm.vendor, java.vm.name, java.specification.version, java.specification.vendor,java.specification.name.

        Should we consider making them read only for JDK 9 and later ?

              rriggs Roger Riggs
              coffeys Sean Coffey
              Votes:
              0 Vote for this issue
              Watchers:
              8 Start watching this issue

                Created:
                Updated:
                Resolved: