I have few jars related to some internal project which i am using in my project. These are being installed in the local maven repository using the maven install command as they are not available on any repository.
But, when i try to build the application, it fails with error:
error: error reading D:\proj\.m2\repository\com\affecto\bolib-web\0.1.6\bolib-web-0.1.6.jar
error in opening zip file
Error trace:
[ERROR] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Compilation failure
error: error reading D:\proj\.m2\repository\com\affecto\bolib-web\0.1.6\bolib-
web-0.1.6.jar; error in opening zip file
error: error reading D:\proj\.m2\repository\com\microsoft\sqljdbc\2005\sqljdbc
-2005.jar; error in opening zip file
[INFO] ------------------------------------------------------------------------
[DEBUG] Trace
org.apache.maven.BuildFailureException: Compilation failure
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
ultLifecycleExecutor.java:715)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLi
fecycle(DefaultLifecycleExecutor.java:556)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(Defau
ltLifecycleExecutor.java:535)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHan
dleFailures(DefaultLifecycleExecutor.java:387)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegmen
ts(DefaultLifecycleExecutor.java:348)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLi
fecycleExecutor.java:180)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:6
0)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.CompilationFailureException: Compilation fail
ure
at org.apache.maven.plugin.AbstractCompilerMojo.execute(AbstractCompiler
Mojo.java:516)
at org.apache.maven.plugin.CompilerMojo.execute(CompilerMojo.java:114)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPlugi
nManager.java:490)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(Defa
ultLifecycleExecutor.java:694)
... 17 more
https://gist.github.com/avchavan/01eb6e46e00dc86708d0
Dependency fragment:
<dependency>
<groupId>com.affecto</groupId>
<artifactId>bolib-web</artifactId>
<version>0.1.6</version>
</dependency>
I have tried deleting the entire .m2 but still the same. The jar file opens properly and i can see the contents of it. So that doesn't look like an issue to me. Also, there are no html pages inside the jar (java files only). When i open the jar i can see that the jar was made using maven as its carrying a pom file. What could be the problem here?
Thanks.