Pular para o conteúdo principal

Postagens

Mostrando postagens de outubro, 2018

Debugging error "Could not import XML from stream: invalid LOC header (bad signature)" when building a Thorntail application

Tl;DR: Check if there's corrupted JARs in your maven repository When building a Thorntail 2.2.0.Final application I faced the error  Could not import XML from stream: invalid LOC header (bad signature) when trying to build the JAR using mvn clean install . I could not find what is wrong, I just downloaded the application using Thorntail generator but I was not able to run it, so frustrating. When I used the -X flag I could see the error stack trace. The part that was causing the error was: Caused by: java.util.zip.ZipException: invalid LOC header (bad signature)     at java.util.zip.ZipFile.read (Native Method)     at java.util.zip.ZipFile.access$1400 (ZipFile.java:60) (...)     at com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderImpl.parse (DocumentBuilderImpl.java:339)     at javax.xml.parsers.DocumentBuilder.parse (DocumentBuilder.java:121)     at org.jboss.shrinkwrap.descriptor.spi.node.dom.XmlDom...