cancel
Showing results for 
Search instead for 
Did you mean: 

java.lang.UnsupportedClassVersionError ... bad major version at offset=6

Former Member
0 Kudos

Hi,

java.lang.UnsupportedClassVersionError: (com/bms/bpr/wd/homepage/wdp/InternalHomePageDC3) bad major version at offset=6

at java.lang.ClassLoader.defineClassImpl(Native Method)

at java.lang.ClassLoader.defineClass(ClassLoader.java:254)

at com.sap.engine.services.deploy.server.ApplicationLoader.defineClassWithInterception(ApplicationLoader.java:168)

I'm encountering this error when I'm trying to run the application deployed thru NWDI.

I'm using NWDS 7.0.11, dk version is j2sdk1.4.2_09

I think my runtime system is also in same jdk version because I can run the application I directly deployed using SDM (I have J2EE engine setup on my NWDS)

NWDI is in 7.2. Do you think this is the reason why we're encountering this error? I've read somewhere that NWDS, Runtime System and CBS should have the same jdk version.

Please help.

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Jan,

Thanks for that information. I've read this from the pdf file you sent:

Change CBS Service Properties to be able to use JDK 1.5: Log on to the Visual Administrator tool of the SAP NetWeaver 7.0 AS Java server on which NWDI is running. Go to Services u2013> Component Build Service.

Change the two properties - BUILD_TOOL_JDK_HOME (point to the JDK 1.5 directory) - JDK_HOME_PATH (define and add a new variable for JDK 1.5, for example JDK1.5.0_HOME) as shown in the example on the right.

My concern is other group is using the NWDI, I think they're using NWDS 7.2. Would that be a problem if we set the BUILD_TOOL_JDK_HOME to point to jdk 1.4?

Former Member
0 Kudos

Hi there,

your concern is not without reason. But there is a way to configure NWDI to use both JDKs as required.

In the CBS-Settings

BUILD_TOOL_JDK_HOME - has to point to the JDK with the highest version. This should be the JDK 6 of your CE 7.2 I guess.

JDK_HOME_PATHS - contains aliases for the JDKs and the PATH to them. This aliases will be used in the build variant.

For example: JDK1.4_HOME=/usr/lib64/jvm/java;JDK1.5.0_HOME=/nwdi/sap_build_vm/sapjvm_5;default=/nwdi/sap_build_vm/sapjvm_5

This example tells CBS that there are 2 JDKs 1.4 and 1.5 and that the 1.5 JDK will be used by default.

When you create a track you have to set a build variant to use , in my case JDK 1.4, instead od the JDK1.5 by default.

The build variant will be:

com.sap.jdk.home_path_key = JDK1.4_HOME

This tells CBS to use the JDK1.4 as defined in JDK_HOME_PATHS for building in this track. other tracks will use the default JDK as long as the build variant is not adjusted.

So its not problem to build with different JDKs in NWD if required.

Have a good time

Jan

Former Member
0 Kudos

Hi,

if your NWDI is based on NW7.2 default for CBS is to build with the same JDK the J2EE is running on. This is SAP JDK version 6.

You have to configure/enable your CBS to build with JDK 1.4 and you have to set a build variant in your tracks build option so the track is build with JDK1.4.

The general steps ob how to to this can be foaund in this howto

http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/7014086d-3fd9-2910-80bd-be3417810...

But its for a 7.0 NWDI running a 7.1x track so you have to adapt the steps for your scenario.

Have a good time

Jan