During deployment of an EAR file on JBoss 6.0 I received this error (the sample is not really what I read on log file)
<code>java.lang.UnsupportedClassVersionError: test_hello_world : Unsupported major.minor version 51.0 at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClassCond(Unknown Source)</code>
Looking for a solution I’ve found the answer on StackOverflow.
Note to self:
The version number shown describe which version if Java was used to compile the code.
The reported major numbes are:
<code>J2SE 7 = 51, J2SE 6.0 = 50, J2SE 5.0 = 49, JDK 1.4 = 48, JDK 1.3 = 47, JDK 1.2 = 46, JDK 1.1 = 45 </code>
(source: http://en.wikipedia.org/wiki/Java_class_file )