-
Improvement
-
Resolution: Fixed
-
Critical
-
-
2.266
Related to JENKINS-13154, we are still seeing lots of congestion with Jenkins 1.517 and our builds may still stay tens of minutes in "Waiting for Jenkins to finish collecting data" -phase.
The place has changed though, now thread dumps show lots of these:
java.lang.Thread.State: BLOCKED (on object monitor)
at java.util.Collections$SynchronizedMap.get(Collections.java:2031)
waiting to lock <0x000000070c6dcfa8> (a java.util.Collections$SynchronizedMap)
at com.thoughtworks.xstream.core.DefaultConverterLookup.lookupConverterForType(DefaultConverterLookup.java:49)
- is blocking
-
JENKINS-46460 Performance issue in AsyncResourceDisposer.persist
-
- Resolved
-
- is related to
-
JENKINS-13154 Heavy thread congestion with FingerPrint.save
-
- Resolved
-
-
JENKINS-18775 [XStream] ConcurrentModificationException from DefaultConverterLookup
-
- Resolved
-
-
JENKINS-23514 Deadlock in Xstream at Jenkins startup
-
- Resolved
-
- relates to
-
JENKINS-41037 Unable to serialize lists because of ConcurrentModificationException
-
- In Progress
-
- links to
Access to converters apparently needs to be synchronized per
JENKINS-18775but the execution path to the cached converters should be as free of synchronization as possible.typeToConverterMap has changed for more synchronization in two steps:
(1)
from ConcurrentHashMap to Collections.synchronizedMap(new WeakHashMap());
https://github.com/jenkinsci/xstream/blob/3ee1dba0e7a0ae2a12759c87bea9cbb6578e19f7/xstream/src/java/com/thoughtworks/xstream/core/DefaultConverterLookup.java
(2) from just having synchronized access to the map to total synchronization in
JENKINS-18775I assume the WeakHashMap is needed in XStream in the general case, but if CI uses XStream for a fixed set of classes we could maybe do without that so that ConcurrentHashMap would do the trick?