title: javax.xml.parsers.SAXParserFactory cannot be created
body: <p>In my code I use multiple threads to parse multiple xml responses at the same time. My code is basically like this</p>
  
  <pre><code>private static final JAXBContext JAXB_CONTEXT = JAXBContext.newInstance(JAXB_CONTEXT_PATH);
  
  executorService = newFixedThreadPool(5);
  
  builder.executeAsync(executorService).whenComplete((result, ex) -&gt; {
      _parseResponse(result);
  });
  
  private void _parseResponse(@Nonnull final byte[] response) {
      final ByteArrayInputStream stream = new ByteArrayInputStream(response);
      Object responseObj = JAXB_CONTEXT.createUnmarshaller().unmarshal(stream);
  }
  </code></pre>
  
  <p>But I got a lot of such errors when executing the above code. Anyone has idea of what could be the cause? Or how to get more detailed info about the failure? Thanks!!</p>
  
  <pre><code>Exception when parsing a response  &lt;Executors.newThreadPoolExecutor-8-0&gt;
  javax.xml.parsers.FactoryConfigurationError: Provider for class javax.xml.parsers.SAXParserFactory cannot be created
      at java.xml/javax.xml.parsers.FactoryFinder.findServiceProvider(FactoryFinder.java:305)
      at java.xml/javax.xml.parsers.FactoryFinder.find(FactoryFinder.java:261)
      at java.xml/javax.xml.parsers.SAXParserFactory.newInstance(SAXParserFactory.java:147)
      at javax.xml.bind.helpers.AbstractUnmarshallerImpl.getXMLReader(AbstractUnmarshallerImpl.java:113)
      at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:170)
      at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(AbstractUnmarshallerImpl.java:209)
      at _parseResponse
      at MarketingApiCaller.lambda$execute$0
      at java.base/java.util.concurrent.CompletableFuture.uniWhenComplete(CompletableFuture.java:859)
      at java.base/java.util.concurrent.CompletableFuture$UniWhenComplete.tryFire(CompletableFuture.java:837)
      at java.base/java.util.concurrent.CompletableFuture.postComplete(CompletableFuture.java:506)
      at java.base/java.util.concurrent.CompletableFuture.complete(CompletableFuture.java:2073)
      at com.tripadvisor.core.rpc.ServiceCallBuilderImpl.lambda$executeAsyncRaw$5(ServiceCallBuilderImpl.java:989)
      at java.base/java.util.concurrent.CompletableFuture.uniHandle(CompletableFuture.java:930)
      at java.base/java.util.concurrent.CompletableFuture$UniHandle.tryFire(CompletableFuture.java:907)
      at java.base/java.util.concurrent.CompletableFuture$Completion.run(CompletableFuture.java:478)
      at com.TripResearch.util.concurrent.SelfAwareRunnable._run(SelfAwareRunnable.java:43)
      at com.TripResearch.object.RequestContext.with(RequestContext.java:315)
      at com.TripResearch.util.concurrent.SelfAwareRunnable.run(SelfAwareRunnable.java:30)
      at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128)
      at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
      at java.base/java.lang.Thread.run(Thread.java:834)
  Caused by: java.lang.RuntimeException: Provider for class javax.xml.parsers.SAXParserFactory cannot be created
      at java.xml/javax.xml.parsers.FactoryFinder.findServiceProvider(FactoryFinder.java:302)
      ... 21 more
  Caused by: java.util.ServiceConfigurationError: javax.xml.parsers.SAXParserFactory: Provider org.apache.xerces.jaxp.SAXParserFactoryImpl not found
      at java.base/java.util.ServiceLoader.fail(ServiceLoader.java:588)
      at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.nextProviderClass(ServiceLoader.java:1211)
      at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNextService(ServiceLoader.java:1220)
      at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator$1.run(ServiceLoader.java:1267)
      at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator$1.run(ServiceLoader.java:1266)
      at java.base/java.security.AccessController.doPrivileged(Native Method)
      at java.base/java.util.ServiceLoader$LazyClassPathLookupIterator.hasNext(ServiceLoader.java:1269)
      at java.base/java.util.ServiceLoader$2.hasNext(ServiceLoader.java:1299)
      at java.base/java.util.ServiceLoader$3.hasNext(ServiceLoader.java:1384)
      at java.xml/javax.xml.parsers.FactoryFinder$1.run(FactoryFinder.java:287)
      at java.base/java.security.AccessController.doPrivileged(Native Method)
      at java.xml/javax.xml.parsers.FactoryFinder.findServiceProvider(FactoryFinder.java:283)
      ... 21 more
  </code></pre>