• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Works through Jdeveloper not through Console

 
Aftab Mahmood
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,

I have created a proxy to a webservice using Jdeveloper. All Works fine when I run the java application that calls the webservice through Jdeveloper. When I try running the application from a console window (eg java webservicecleint) I get the PrivilegedActionException.

Any ideas as to why it does that. I am running the colsole version from the same machine where Jdeveloper is running

Confused.....
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
 
Markus Koegel
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

I am new one in Java. Was just digging into jdeveloper and soap. But I have exactlty the same problem.

Start it outside the jdeveloper with
java -jar archive1.jar

All webproxys are in the jar.
But I get the error:
Exception in thread "main" java.lang.NoClassDefFoundError: javax/xml/rpc/ServiceFactory

Thank you for help!

Markus
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The proxy classes don't contain the JAX-RPC classes. You need to add those to your classpath.
 
Markus Koegel
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

a short report of my progress:
All the hints that I have to add to the classpath the needed jar files were right. I figured out that running a jar file with "java -jar" ignores the -cp option.
I finally found out how to add the Class-Path tag to the mainifest file in JDeveloper Deployment-Profile.

Now my program runs from a DOS-Box (java -jar archive1.jar arg1 arg2) with no error message. But unfortunately also with no reply. It just ends very shortly.

So I will keep hanging on to the problem.

Regards

Markus
 
Markus Koegel
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,

finally I gave up the path to create a jar file.
Java didn't react as I expected from the documentation.

I continued using all class files. And finally I got it run outside the JDeveloper.

It still needs a little tuning but I have a base I can work on.

Thanks to all,

Markus
 
Brian Rhees
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Are there any solutions to this?
I am having the same problem.

I have a web service proxy within JDeveloper (created from a wsdl file). I created a .java file to call the web service. It runs fine within JDeveloper. When I deploy it to a .jar file I get the exception: "Exception in thread "main" java.long.NoClassDefFoundError: javax/xml/rpc/ServiceFactory"

Any ideas?

Thanks
 
Ulf Dittmer
Rancher
Posts: 42968
73
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Is that class contained in the jar file, or otherwise in the classpath, when the WS client is run?
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic