How to resolve "UnsupportedClassVersionError: com/example/Class : Unsupported major.minor version xx"

Solution Unverified - Updated -

Issue

  • In Red Hat JBoss Enterprise Application Platform (EAP) 6, we are having issues getting our jvm to start in the crash environment after updating the Microsoft SQL Server driver from version 4.0 to version 4.2. We found errors like this in server.log:

    13:23:57,931 ERROR [org.jboss.as.controller.management-operation] (ServerService Thread Pool -- 50) JBAS014612: Operation ("add") failed - address: ([
    ("subsystem" => "datasources"),
    ("jdbc-driver" => "MicrosoftType4")
    ]): java.lang.UnsupportedClassVersionError: com/microsoft/sqlserver/jdbc/SQLServerDriver : Unsupported major.minor version 52.0
    
  • When I try to install a custom module for JBoss EAP 6, I got similar error:

    java.lang.UnsupportedClassVersionError: com/example/Class : Unsupported major.minor version 51.0
    

Environment

all Red Hat JBoss Middleware products

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase of over 48,000 articles and solutions.

Current Customers and Partners

Log in for full access

Log In
Close

Welcome! Check out the Getting Started with Red Hat page for quick tours and guides for common tasks.