Search code examples
eclipsedependency-injectionwebsphere-liberty

Liberty CWWKZ0002E and ZipError when deploying webapps from Eclipse


We are deploying 3 webapps in a liberty server (16.0.0.4) and frequently get ziperrors and messages like below (this is fairly easy to reproduce):

[ERROR ] CWWKZ0002E: An exception occurred while starting the application XYZ. The exception message was: com.ibm.ws.container.service.state.StateChangeException: java.util.zip.ZipError: jzentry == 0, jzfile = 693877616, total = 1148, name = C:\opt\IBM\wlp\usr\servers\XYZ\workarea\org.eclipse.osgi\220\data\cache\com.ibm.ws.classloading.sharedlibrary_84.cache\lib\db2jcc.jar, i = 329, message = null

It seems to be erratic but easier to reproduce on slower machines so I suspect a race condition, but it may be as simple as the cache clearing during a server Clean is non-blocking?

Deploying the webapps as war files rather than linked via xml files back to projects does not experience this problem.

I've used the beans.xml with bean-discovery-mode="all" with no effect. We are using injection of different classes in two of the three web applications.

Note the directory number in the path to the cache differs from run to run.

This has been present since at least version 16.0.0.2 of Liberty. Is there a workaround for this problem or does anyone know if will be fixed in the December release?


Solution

  • The problem has gone away with migrating projects to newer releases of Eclipse, so closing.