Could not compile the JMS client in maven with javax.jms-api-2.0.jar

Solution Verified - Updated -

Issue

SomeClass.java:[16,-1] cannot access javax.jms.QueueSender 
bad class file: .m2\repository\javax\jms\javax.jms-api\2.0\javax.jms-api-2.0.jar(javax/jms/QueueSender.class) 
class file has wrong version 51.0, should be 49.0

Environment

  • Red Hat JBoss Enterprise Application Platform (EAP)
    • 5.x

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content