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

FastStringUtils does not work in an OSGi environment

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 4.0.9
    • JSON
    • None

    Description

      Using the FastStringUtils does not work in an OSGi environment. The FastStringUtils will be called by the classloader of another bundle, making the code at https://github.com/apache/groovy/blob/master/subprojects/groovy-json/src/main/java/org/apache/groovy/json/internal/FastStringUtils.java#L39 not find the default service loader.

      To counter this, I'd like to propose to at least fall back to the DefaultFastStringService when no FastStringServiceFactory is found

       

      Attachments

        1. Screenshot 2023-02-01 at 11.53.16.png
          14 kB
          Roy Teeuwen
        2. Screenshot 2023-01-25 at 15.41.16.png
          34 kB
          Roy Teeuwen
        3. groovy-json-example.zip
          17 kB
          Roy Teeuwen

        Issue Links

          Activity

            People

              paulk Paul King
              royteeuwen Roy Teeuwen
              Votes:
              0 Vote for this issue
              Watchers:
              6 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: