Uploaded image for project: 'CXF'
  1. CXF
  2. CXF-8183

JDK 9+ Illegal reflective access caused in AutomaticWorkQueueImpl

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Duplicate
    • 3.3.4
    • None
    • Core
    • None
    • OpenJDK 11 inside docker container fabric8/java-centos-openjdk11-jre

    • Unknown

    Description

      We use CXF for SOAP with cxf-rt-transports-http-hc-3.3.4.jar  (Async HTTP) and do get the following warning: 

      WARNING: Illegal reflective access by org.apache.cxf.common.util.ReflectionUtil$11 (file:/Users/peterschulz/.m2/repository/org/apache/cxf/cxf-core/3.3.4/cxf-core-3.3.4.jar) to field java.util.concurrent.ThreadPoolExecutor.mainLock
      WARNING: Please consider reporting this to the maintainers of org.apache.cxf.common.util.ReflectionUtil$11
      WARNING: Use --illegal-access=warn to enable warnings of further illegal reflective access operations
      WARNING: All illegal access operations will be denied in a future release

       
      org.apache.cxf.workqueue.AutomaticWorkQueueImpl line 206 and/or 439 

      Field f = ThreadPoolExecutor.class.getDeclaredField("mainLock");
      ReflectionUtil.setAccessible(f);
      l = (ReentrantLock)f.get(executor);
      
      /*...*/
      
      ReflectionUtil.setAccessible(addWorkerMethod).invoke(executor, addWorkerArgs);

      Attachments

        Issue Links

          Activity

            People

              ffang Freeman Yue Fang
              schulzp Peter Schulz
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: