Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » ServerTools (WTP) » java.lang.NoClassDefFoundError
java.lang.NoClassDefFoundError [message #159718] Wed, 08 February 2006 22:16 Go to next message
Ben Sisson is currently offline Ben SissonFriend
Messages: 202
Registered: July 2009
Senior Member
I'm working with:
Eclipse 3.1
Tomcat 5.5.15
Axis 1_2_1
Java JDK 1.5

I just recently changed from older versions:
Tomcat 5.0.25
Axis 1_1
Java SDK 1.4

I wanted to upgrade to JDK 1.5 to work with "enums" that required that I
upgrade to Axis 1_2_1 or 1_3. I originally upgraded to 1_3 but backed up
to 1_2 because I noticed that within the Eclipse plugins there was a
org.apache.axis_1.2.1 and I thought it best to be consistent.

Since making these changes I have noticed a few errors that I had not seen
with the previous versions:

I have a new Web Service that I generated. I run a quick test and it
returns the result that I expected. I then add code to the project that
references another project within my work area. To accomplish this I go
to Java Build Path->Projects folder and select the project that I want to
reference. I then go to Project References and select the same project.

Within my project the references are placed in the import statement and
all the code looks good. No errors!

I then start the same Web Client that I used before to get the expected
result and I get the following error message in the client result area:

exception: java.lang.NoClassDefFoundError:
org/bass/processing/SessionSupportServices; nested exception is:
java.lang.NoClassDefFoundError: org/bass/processing/SessionSupportServices

SessionSupportServices is the name of the project that I am referencing.

Any thoughts?

Thanks,
Ben
Re: java.lang.NoClassDefFoundError [message #159859 is a reply to message #159718] Thu, 09 February 2006 14:56 Go to previous messageGo to next message
Ben Sisson is currently offline Ben SissonFriend
Messages: 202
Registered: July 2009
Senior Member
I was comparing my old project that I created with Eclipse 3.1, Tomcat
5.0.23, SDK 1.4, and Axis 1_1 with the new project created with Eclipse
3.1, Tomcat 5.5.15, JDK 1.5, and Axis 1_2_1. I compared the .deployables
folders in both projects and found some differences that I cannot explain.

The WEB-INF\lib folder for the older project contained the jar files for
the referenced projects. However, the WEB-INF\lib folder for the new
project does not contain the jar files for the referenced projects.

I cannot explain the differences. I compared the project properties of
the old and new projects and they are setup almost identically. The only
differences beeing that versions of JDK and Axis that are referenced.
Both projects have the same reference projects selected in the Java Build
Path->Projects tab. The Order and Export are the exact same.

In the Properties->Project References they each have the same projects
selected.

One of the more interesting comparisions that I did discover was that the
new project Properties->Java JAR dependencies has a list of some of my
other projects in it (none that I reference) but the older version does
not contain anything within the list.

I'm sure that I have missed something simple but can someone please
explain why the new project is not generating the jar files to the
deployables WEB\lib directory for the referenced projects while the old
projecd did.

Thanks,
Ben
Re: java.lang.NoClassDefFoundError [message #172398 is a reply to message #159859] Mon, 26 June 2006 09:35 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: pbarry.prosys.fr

I got exactly the same problem.
I think I can bypass it by creating a .jar from the referenced project and
put it in the lib directory of my web project, but that would be slightly
heavier to develop, if I want to modify my referenced project often.
Still, if you found the solution since, I'd greatly apreciate it

Regards,
Paul Barry Delongchamps.

"Ben Sisson" <bsisson@simventions.com> a
Re: java.lang.NoClassDefFoundError [message #172787 is a reply to message #172398] Fri, 30 June 2006 13:31 Go to previous message
Chuck Bridgham is currently offline Chuck BridghamFriend
Messages: 35
Registered: July 2009
Member
Paul Barry Delongchamps wrote:

> I got exactly the same problem.
> I think I can bypass it by creating a .jar from the referenced project and
> put it in the lib directory of my web project, but that would be slightly
> heavier to develop, if I want to modify my referenced project often.
> Still, if you found the solution since, I'd greatly apreciate it

> Regards,
> Paul Barry Delongchamps.

> "Ben Sisson" <bsisson@simventions.com> a écrit dans le message de news:
> 900b59d34767eb2c3c7b08e9308728bd$1@www.eclipse.org...
>>I was comparing my old project that I created with Eclipse 3.1, Tomcat
>>5.0.23, SDK 1.4, and Axis 1_1 with the new project created with Eclipse
>>3.1, Tomcat 5.5.15, JDK 1.5, and Axis 1_2_1. I compared the .deployables
>>folders in both projects and found some differences that I cannot explain.
>>
>> The WEB-INFlib folder for the older project contained the jar files for
>> the referenced projects. However, the WEB-INFlib folder for the new
>> project does not contain the jar files for the referenced projects.
>> I cannot explain the differences. I compared the project properties of
>> the old and new projects and they are setup almost identically. The only
>> differences beeing that versions of JDK and Axis that are referenced.
>> Both projects have the same reference projects selected in the Java Build
>> Path->Projects tab. The Order and Export are the exact same.
>>...


It sounds like you have been working with R0.7 workspaces that contained
the ".deployables" folder. And possibly have upgraded to R1.0?

The .deployables folder was used to "assemble" the referenced
projects/libraries under a single folder root, and we pointed the server
adapter to this location. In R1.0, we abandoned this idea of constantly
"copying" the relevant files, but still rely on the dependencies created
with the "J2EE Module Dependencies" property sheet.

I recommend moving up to the callisto release today, as there are many
options for setting up project/archive dependencies. The classpath entries
are added to you project, and in the case of tomcat, are assembled in the
proper directory at publish time.

Thanks - Chuck
Previous Topic:DeploymentDescriptorLoadException???
Next Topic:Simple Webservices server
Goto Forum:
  


Current Time: Fri Mar 29 08:59:25 GMT 2024

Powered by FUDForum. Page generated in 0.02278 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top