[Bug 64628] New: tomcat6/7/8/9 processorCache is no remove from the processors of RequestGroupInfo in concurrent release

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

[Bug 64628] New: tomcat6/7/8/9 processorCache is no remove from the processors of RequestGroupInfo in concurrent release

Bugzilla from bugzilla@apache.org
https://bz.apache.org/bugzilla/show_bug.cgi?id=64628

            Bug ID: 64628
           Summary: tomcat6/7/8/9 processorCache is no remove from the
                    processors of RequestGroupInfo in concurrent release
           Product: Tomcat 9
           Version: 9.0.5
          Hardware: All
                OS: All
            Status: NEW
          Severity: critical
          Priority: P2
         Component: Catalina
          Assignee: [hidden email]
          Reporter: [hidden email]
  Target Milestone: -----

Created attachment 37374
  --> https://bz.apache.org/bugzilla/attachment.cgi?id=37374&action=edit
too many processor in processors of RequestGroupInfo

httpnio processor release exist processor no unregister from jmx bean at
concurrent invoke push method of RecycledProcessors

@SuppressWarnings("sync-override") // Size may exceed cache size a bit
 @Override
 public boolean push(Processor processor) {
            int cacheSize = handler.getProtocol().getProcessorCache();
            boolean offer = cacheSize == -1 ? true : size.get() < cacheSize;
            //avoid over growing our cache or add after we have stopped
            boolean result = false;
            if (offer) {
                result = super.push(processor);
                if (result) {
                    size.incrementAndGet();
                }
            }
            if (!result) handler.unregister(processor);
            return result;
 }



cacheSize default is 200,if current size is 199 is lower 200 and two thread
push processor at the same time ,all offer is true,so result also is true.
so processor cache is more than 200 ,so no do unregister with processor,

so the processor don't remove from the processors of RequestGroupInfo

and running time too long,the processor cache is too many,because new create
processor is do register to jmx and add to the processors of RequestGroupInfo

so the sync-override is need add

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]

Reply | Threaded
Open this post in threaded view
|

[Bug 64628] tomcat6/7/8/9 processorCache is no remove from the processors of RequestGroupInfo in concurrent release

Bugzilla from bugzilla@apache.org
https://bz.apache.org/bugzilla/show_bug.cgi?id=64628

--- Comment #1 from Gavin.peng <[hidden email]> ---
now we use the processorCache params resolve the problem,by set
processorCache=0
but can't use cache,create byte[] for every request

please help me thanks

--
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]