[GLASSFISH-446] When using Mustang, verifier gets ZipException trying to read JRE optional package Created: 20/Mar/06  Updated: 06/Mar/12

Status: Open
Project: glassfish
Component/s: verifier
Affects Version/s: 9.0pe
Fix Version/s: not determined

Type: Bug Priority: Minor
Reporter: Sanjeeb Sahoo Assignee: Bhavanishankar
Resolution: Unresolved Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified
Environment:

Operating System: All
Platform: All


Attachments: Zip Archive Archive.java.zip    
Issuezilla Id: 446

 Description   

java version "1.6.0-beta2"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.6.0-beta2-b72)
Java HotSpot(TM) Client VM (build 1.6.0-beta2-b72, mixed mode, sharing)

I tried running verifier using above JDK. When I tried verifying any application
in '-p' mode, verifier console output reports about a ZipException as shown below:

WARNING: DPL5400:Exception occurred : error in opening zip file.
INFO: Verifying: [ build/jpa_acc_option1.ear ]
INFO: Verifying: [ appclient_jar ]
INFO: Ignoring optional pkg
/space/ss141213/software/jdk1.6.0/jre/../jre/lib/ext/meta-index
java.util.zip.ZipException: error in opening zip file
at java.util.zip.ZipFile.open(Native Method)
at java.util.zip.ZipFile.<init>(ZipFile.java:113)
at java.util.jar.JarFile.<init>(JarFile.java:132)
at java.util.jar.JarFile.<init>(JarFile.java:97)
at
com.sun.enterprise.tools.verifier.apiscan.packaging.Archive$1.accept(Archive.java:77)
at java.io.File.listFiles(File.java:1129)
at
com.sun.enterprise.tools.verifier.apiscan.packaging.Archive.getAllOptPkgsInstalledInJRE(Archive.java:73)
at
com.sun.enterprise.tools.verifier.apiscan.packaging.ClassPathBuilder.buildClassPathForEar(ClassPathBuilder.java:244)
at
com.sun.enterprise.tools.verifier.apiscan.packaging.ClassPathBuilder.buildClassPathForEar(ClassPathBuilder.java:235)
at
com.sun.enterprise.tools.verifier.appclient.AppClientVerifier.getClassPath(AppClientVerifier.java:109)
at
com.sun.enterprise.tools.verifier.BaseVerifier.preVerification(BaseVerifier.java:123)
at
com.sun.enterprise.tools.verifier.appclient.AppClientVerifier.verify(AppClientVerifier.java:66)
at
com.sun.enterprise.tools.verifier.VerificationHandler.runVerifier(VerificationHandler.java:223)
at
com.sun.enterprise.tools.verifier.VerificationHandler.verifyArchive(VerificationHandler.java:142)
at com.sun.enterprise.tools.verifier.Verifier.verify(Verifier.java:131)
at com.sun.enterprise.tools.verifier.Verifier.main(Verifier.java:101)
INFO:

  1. of Failures : 0
  2. of Warnings : 0
  3. of Errors : 0

Needs further investigation as to why the ZipException is coming. More over, the
first WARNING is coming from DOL. Let's ignore that for the moment. We will
files a separate bug against deployment for that WARNING.

– Sahoo



 Comments   
Comment by Sanjeeb Sahoo [ 20/Mar/06 ]

When I looked at the source code, I see that verifier is assuming every file
installed in jre/lib/ext is a jar file. This assumption is not valid in Mustang
as there is a file called jre/lib/ext/meta-index there, which seem to be
containing index information about jars in that folder. So, in our code, we
should try to filter only *.jar files from ext dirs.

Sahoo

Comment by deepasobhana [ 06/Jun/08 ]

Created an attachment (id=1542)
Attaching the patch for this issue

Comment by Sanjeeb Sahoo [ 06/Jun/08 ]
      • Issue 5113 has been marked as a duplicate of this issue. ***
Comment by Tom Mueller [ 06/Mar/12 ]

Bulk update to change fix version to "not determined" for all issues still open but with a fix version for a released version.

Generated at Mon Aug 29 14:49:48 UTC 2016 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.