Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-1946

getting the value of groovy.source.encoding from system property in default constractor of CompilerConfiguration.

    XMLWordPrintableJSON

Details

    • Wish
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • 1.0
    • 1.1-beta-2
    • None
    • None
    • Patch

    Description

      In case of writing groovlet scripts in UTF8 on Tomcat.
      It's needed to specify "-Dfile.encoding=UTF8" in JAVA_OPTS.
      Then messages in Japanese on Tomcat console are
      garbling because of changing default file encoding.

      On the other, there is the code getting the value of property
      groovy.source.encoding in org.codehaus.groovy.control.CompilerConfiguration
      but it is in constractor, "CompilerConfiguration(Properties configuration)."
      It's seemed that default constractor of CompilerConfiguration
      is used in all most cases. Hence setting of groovy.source.encoding
      is ignored.

      I wisth that default constractor of CompilerConfiguration would get the value of
      groovy.source.encoding from system property.

      Attachments

        1. patch.txt
          1 kB
          Hiroki Taira

        Activity

          People

            blackdrag Jochen Theodorou
            hrktir Hiroki Taira
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: