You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by "Nelligan, Steven M" <sn...@illinois.edu> on 2019/12/09 00:57:43 UTC

Tomcat is throwing an error Invalid byte tag in constant pool:19

I am trying to rebuild my applications and all of a sudden, I am getting the following error:

Our backend application (from third party has been updated) It is using Java 11.

My tomcat servers are running version 7.34 of tomcat and version 1.7.0_45.

I have rebuilt and deploy a large number of our Apps; but there are about 4 with the following error:
SEVERE: Unable to process Jar entry [module-info.class] from Jar [jar:file:/G:/Tomcat7/temp/44-bannertools/WEB-INF/lib/jaxb-api-2.3.0.jar!/] for SEVERE: Unable to process Jar entry [module-info.class] from Jar [jar:file:/G:/Tomcat7/temp/44-bannertools/WEB-INF/lib/jaxb-api-2.3.0.jar!/] for annotations
org.apache.tomcat.util.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 19
	at org.apache.tomcat.util.bcel.classfile.Constant.readConstant(Constant.java:133)
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:60)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:209)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:119)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2104)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1980)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1946)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1931)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1325)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:878)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:369)
	at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5173)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)
	at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:977)
	at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1655)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:744)
s
org.apache.tomcat.util.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 19
	at org.apache.tomcat.util.bcel.classfile.Constant.readConstant(Constant.java:133)
	at org.apache.tomcat.util.bcel.classfile.ConstantPool.<init>(ConstantPool.java:60)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.readConstantPool(ClassParser.java:209)
	at org.apache.tomcat.util.bcel.classfile.ClassParser.parse(ClassParser.java:119)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsStream(ContextConfig.java:2104)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsJar(ContextConfig.java:1980)
	at org.apache.catalina.startup.ContextConfig.processAnnotationsUrl(ContextConfig.java:1946)
	at org.apache.catalina.startup.ContextConfig.processAnnotations(ContextConfig.java:1931)
	at org.apache.catalina.startup.ContextConfig.webConfig(ContextConfig.java:1325)
	at org.apache.catalina.startup.ContextConfig.configureStart(ContextConfig.java:878)
	at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:369)
	at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
	at org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
	at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5173)
	at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
	at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
	at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
	at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633)
	at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:977)
	at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1655)
	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471)
	at java.util.concurrent.FutureTask.run(FutureTask.java:262)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
	at java.lang.Thread.run(Thread.java:744)

When I first tried this a couple of weeks ago... I needed up trying to upgrade Tomcat to the latest release of 7.0_94
Everything started to fall apart, the javax modules were failing, etc.  I finally realized I was chasing my tail.
Every time I got one thing working, two more broke.

Restored everything back and went through the rebuild.

I tried to copy the annotation_api.jar file from Tomcat 7.0_94 into tomcat 7.0_45 but nothing would deploy...

I'm at a loss on what could be happening....

Any help would be appreciate any guidance.
 



Re: Tomcat is throwing an error Invalid byte tag in constant pool:19

Posted by Christopher Schultz <ch...@christopherschultz.net>.
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Steven,

On 12/9/19 06:45, Nelligan, Steven M wrote:
> 
> Thank you for your response...
> 
> We run multiple servers for our application.
> 
> We have a configuration as follows: 1. Portal ... running tomcat
> 7.0_45 and java 7... this is the outward facing running jetspeed.
> This is the server throwing the errors 2. Tomcat ... running tomcat
> 7.0_45 and java 7... this is our back-end business logic server 3.
> Mule .. enterprise service bus broker ... no tomcat running java 7 
> 4. AiM .. our ERP software from a third party  ... runing tomcat_9
> and java 11
> 
> We cannot upgrade Java at this point, because of an old third party
> application running on the portal.  It requires Java 7. We are
> currently exploring new packages to replace it, but this will take
> some time to finalize.
> 
> I've attached the catalina log showing the error.  The error
> appears on startup of Tomcat.
> 
> I tried to replace the annotation_api.jar with a newer version,
> somewhere on the web, it was posted that replacing this jar file
> with a new version solved his problem; which was simular to mine.

All you have to do is upgrade to Tomcat 7.0.latest and you should not
see this problem.

Now, since the vendor of your "Portal" application has moved to Java
11, it looks like they have also compiled the application with Java 11
as well, and the class files will likely not be compatible with Java 7.

So you will find that once Tomcat gets past this problem, you may have
a host of other problems caused by this version mismatch.

Thanks,
- -chris

> -----Original Message----- From: Mark Thomas <ma...@apache.org> 
> Sent: Monday, December 9, 2019 5:17 AM To: users@tomcat.apache.org 
> Subject: Re: Tomcat is throwing an error Invalid byte tag in
> constant pool:19
> 
> On 09/12/2019 00:57, Nelligan, Steven M wrote:
>> 
>> I am trying to rebuild my applications and all of a sudden, I am
>> getting the following error:
>> 
>> Our backend application (from third party has been updated) It is
>> using Java 11.
> 
> You'll need at least 7.0.88 for Java 11 support.
> 
>> When I first tried this a couple of weeks ago... I needed up
>> trying to upgrade Tomcat to the latest release of 7.0_94
> 
> That is what I would recommend (or latest 8.5.x / 9.0.x but that is
> probably changing too much in one go).
> 
>> Everything started to fall apart, the javax modules were failing,
>> etc.  I finally realized I was chasing my tail. Every time I got
>> one thing working, two more broke.
>> 
>> Restored everything back and went through the rebuild.
> 
> You are going to have to try this again. Can I suggest you post the
> first error you see here and we can try and talk you through fixing
> it.
> 
>> I tried to copy the annotation_api.jar file from Tomcat 7.0_94
>> into tomcat 7.0_45 but nothing would deploy...
> 
> Why do that?
> 
> Mark
> 
> ---------------------------------------------------------------------
>
> 
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
> 
> 
> 
> ---------------------------------------------------------------------
>
> 
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
> For additional commands, e-mail: users-help@tomcat.apache.org
> 
-----BEGIN PGP SIGNATURE-----
Comment: Using GnuPG with Thunderbird - https://www.enigmail.net/

iQIzBAEBCAAdFiEEMmKgYcQvxMe7tcJcHPApP6U8pFgFAl3ufdcACgkQHPApP6U8
pFhKiA/7BBK+AOtdAtTgJRoFQXUyUQoEACpD5YonFcUcYIsfl14lwMIhPUamjm+d
OmGMIZg+HKiZXaOCNp2mdWLrPbh/1fHWWxDSXL8E7R535CppJ9p8PUf2Jj5mD4Ex
6Vb34RQ3KGjNThepHG3jeSbE5OFt+E3hHqHLmHJ0pNaxJffI+uVtaI0zL+KLtb+8
Vv9VRZKGp49GjyLwzF/0AGRK6XsJaVLgzUSRALUdLlY+o6k1WdfF4rn/BhL3usiu
tun7vgHHJW36C5EAm/O19p+RJH0KjS4fmycCj3P8X6k3lDrYBnmnXCaJBLVI6Idw
xVDawgPccKKKrV/ZPsyjI0/IJLOpua7f1rRFxGSS1KOIzZo4b9YqDidmY/3YmX/r
hwOiIfVp0+Gng9TXjdyTua5aN0MBDiZH/bltkGb/F7dAMbVKz2mKWtt/TdcZDDGH
N/CBbLHcF+5A8Mvqy3nroFn4ji1kD2hgNhoQ5vDO90uDLBLcPa8/Ux8dfCdAJ82j
aLwZk0IfWmxhqQs1mTDsAQpGRVL3/r5M6I9iL5sHKN3Vmi8t8dSK8GB84rzt9eV1
MzoUVk2JGktOS6mnTNN3PkIjtJFc+G34vWgm9a4fTa1ttJ9ETtgufuo/Rouaa4vs
E5H3oczbcd8780y9YimA8WTjyvX71/xxKOPUK43WOnF1BIvjBSw=
=yYAV
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


RE: Tomcat is throwing an error Invalid byte tag in constant pool:19

Posted by "Nelligan, Steven M" <sn...@illinois.edu>.
Thank you for your response...

We run multiple servers for our application.

We have a configuration as follows:
	1. Portal ... running tomcat 7.0_45 and java 7... this is the outward facing running jetspeed.  This is the server throwing the errors
	2. Tomcat ... running tomcat 7.0_45 and java 7... this is our back-end business logic server
	3. Mule .. enterprise service bus broker ... no tomcat running java 7
	4. AiM .. our ERP software from a third party  ... runing tomcat_9 and java 11

We cannot upgrade Java at this point, because of an old third party application running on the portal.  It requires Java 7.  
We are currently exploring new packages to replace it, but this will take some time to finalize.

I've attached the catalina log showing the error.  The error appears on startup of Tomcat.

I tried to replace the annotation_api.jar with a newer version, somewhere on the web, it was posted that replacing this jar file with a new version solved his problem; which was simular to mine.

Steve

-----Original Message-----
From: Mark Thomas <ma...@apache.org> 
Sent: Monday, December 9, 2019 5:17 AM
To: users@tomcat.apache.org
Subject: Re: Tomcat is throwing an error Invalid byte tag in constant pool:19

On 09/12/2019 00:57, Nelligan, Steven M wrote:
> 
> I am trying to rebuild my applications and all of a sudden, I am getting the following error:
> 
> Our backend application (from third party has been updated) It is using Java 11.

You'll need at least 7.0.88 for Java 11 support.

> When I first tried this a couple of weeks ago... I needed up trying to 
> upgrade Tomcat to the latest release of 7.0_94

That is what I would recommend (or latest 8.5.x / 9.0.x but that is probably changing too much in one go).

> Everything started to fall apart, the javax modules were failing, etc.  I finally realized I was chasing my tail.
> Every time I got one thing working, two more broke.
> 
> Restored everything back and went through the rebuild.

You are going to have to try this again. Can I suggest you post the first error you see here and we can try and talk you through fixing it.

> I tried to copy the annotation_api.jar file from Tomcat 7.0_94 into tomcat 7.0_45 but nothing would deploy...

Why do that?

Mark

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Tomcat is throwing an error Invalid byte tag in constant pool:19

Posted by Mark Thomas <ma...@apache.org>.
On 09/12/2019 00:57, Nelligan, Steven M wrote:
> 
> I am trying to rebuild my applications and all of a sudden, I am getting the following error:
> 
> Our backend application (from third party has been updated) It is using Java 11.

You'll need at least 7.0.88 for Java 11 support.

> When I first tried this a couple of weeks ago... I needed up trying to upgrade Tomcat to the latest release of 7.0_94

That is what I would recommend (or latest 8.5.x / 9.0.x but that is
probably changing too much in one go).

> Everything started to fall apart, the javax modules were failing, etc.  I finally realized I was chasing my tail.
> Every time I got one thing working, two more broke.
> 
> Restored everything back and went through the rebuild.

You are going to have to try this again. Can I suggest you post the
first error you see here and we can try and talk you through fixing it.

> I tried to copy the annotation_api.jar file from Tomcat 7.0_94 into tomcat 7.0_45 but nothing would deploy...

Why do that?

Mark

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Re: Tomcat is throwing an error Invalid byte tag in constant pool:19

Posted by Konstantin Kolinko <kn...@gmail.com>.
пн, 9 дек. 2019 г. в 03:58, Nelligan, Steven M <sn...@illinois.edu>:
>
>
> I am trying to rebuild my applications and all of a sudden, I am getting the following error:
>
> Our backend application (from third party has been updated) It is using Java 11.
>
> My tomcat servers are running version 7.34 of tomcat and version 1.7.0_45.

1.7.0_45 is the version of Java? But you say that those web
applications need at least Java 11?

> I have rebuilt and deploy a large number of our Apps; but there are about 4 with the following error:
> SEVERE: Unable to process Jar entry [module-info.class] from Jar [jar:file:/G:/Tomcat7/temp/44-bannertools/WEB-INF/lib/jaxb-api-2.3.0.jar!/] for SEVERE: Unable to process Jar entry [module-info.class] from Jar [jar:file:/G:/Tomcat7/temp/44-bannertools/WEB-INF/lib/jaxb-api-2.3.0.jar!/] for annotations
> org.apache.tomcat.util.bcel.classfile.ClassFormatException: Invalid byte tag in constant pool: 19
>         at org.apache.tomcat.util.bcel.classfile.Constant.readConstant(Constant.java:133)

Sounds a lot like this issue that I answered a year ago:
https://stackoverflow.com/questions/52867430/invalid-byte-tag-in-constant-pool-19-error-message

>
> When I first tried this a couple of weeks ago... I needed up trying to upgrade Tomcat to the latest release of 7.0_94

The latest release of Tomcat 7 is 7.0.96, released in July.

> Everything started to fall apart, the javax modules were failing, etc.  I finally realized I was chasing my tail.
> Every time I got one thing working, two more broke.
>
> Restored everything back and went through the rebuild.
>
> I tried to copy the annotation_api.jar file from Tomcat 7.0_94 into tomcat 7.0_45 but nothing would deploy...
>
> I'm at a loss on what could be happening....
>
> Any help would be appreciate any guidance.
>
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org