]> source.dussan.org Git - poi.git/commitdiff
#61350 - Use unsynchronized xmlbeans
authorAndreas Beeker <kiwiwings@apache.org>
Wed, 26 Jul 2017 22:15:27 +0000 (22:15 +0000)
committerAndreas Beeker <kiwiwings@apache.org>
Wed, 26 Jul 2017 22:15:27 +0000 (22:15 +0000)
git-svn-id: https://svn.apache.org/repos/asf/poi/trunk@1803120 13f79535-47bb-0310-9956-ffa450edef68

src/ooxml/java/org/apache/poi/POIXMLTypeLoader.java

index ec829ce44e4a37cb76e798dfb36e498f26c71e45..b5189090881461cd4f577497b7a83db7960755ca 100644 (file)
@@ -69,6 +69,9 @@ public class POIXMLTypeLoader {
         // so only user code using XmlObject/XmlToken.Factory.parse
         // directly can bypass the entity check, which is probably unlikely (... and not within our responsibility :)) 
         // DEFAULT_XML_OPTIONS.setLoadEntityBytesLimit(4096);
+        
+        // POI is not thread-safe - so we can switch to unsynchronized xmlbeans mode - see #61350
+        DEFAULT_XML_OPTIONS.setUnsynchronized();
 
         Map<String, String> map = new HashMap<String, String>();
         map.put("http://schemas.openxmlformats.org/drawingml/2006/main", "a");