Home » Developer & Programmer » Forms » Unable to initialize Java VM (Forms 6i, java 1.4.2_04, Linux)
Unable to initialize Java VM [message #386691] Mon, 16 February 2009 12:20 Go to next message
asito
Messages: 6
Registered: February 2009
Junior Member
Hi,
I'm new in developing Web calls from within Forms 6i (I'm using it to develop custom forms for Oracle e-Business Suite 11.5.10.2).

I have a WHEN-BUTTON-PRESED trigger which code is the following:

DECLARE
  jo ora_java.jobject;
  ex ora_java.jobject;
BEGIN
  --
  IF :main_block.conversion_type = 1 THEN
    :main_block.to_farenheit := 
       TempConvertStub.CelsiusToFahrenheit(jo,:main_block.celsius);
  ELSE
    :main_blockto_celsius := 
       TempConvertStub.FahrenheitToCelsius(jo,:main_block.farenheit);
  END IF;
  --
EXCEPTION
 WHEN ORA_JAVA.JAVA_ERROR then 
  fnd_message.set_string('ORA_JAVA.JAVA_ERROR: '
            ||ORA_JAVA.LAST_ERROR);
  fnd_message.error;
 WHEN ORA_JAVA.EXCEPTION_THROWN then 
  ex := ORA_JAVA.LAST_EXCEPTION;
  fnd_message.set_string('ORA_JAVA.EXCEPTION_THROWN: '
            ||Exception_.ToString(ex));
  fnd_message.error;
END;


No matter the call is (TempConvertStub.FahrenheitToCelsius or TempConvertStub.FahrenheitToCelsius) the form raise the exception ORA_JAVA.JAVA_ERROR. The message is like this:

Quote:
ORA_JAVA.JAVA_ERROR: Unable to initialize Java VM


I can add to this post a few data that may be usefull:

Quote:
Linux oriondesa.capgemini.es 2.6.9-67.ELsmp #1 SMP Wed Nov 7 13:58:04 EST 2007 i686 i686 i386 GNU/Linux

Oracle HTTP Server Powered by Apache/1.3.19

java version 1.4.2_04

Forms 6.0 (Forms Runtime) Version 6.0.8.27.0 (Production)


I followed all the instructions from this URL:
http://www.oracle.com/technology/products/forms/htdocs/Forms_WebService_How_To.htm

(Nevertheless the document has been written for Forms 9i, it would work the same for Forms 6i)

I've put the needed classes into a file named Orion.jar, and I've put it on the web server in an accesible path. I've restarted the Application server so the new CLASSPATH environmet variable is now visible.

Quote:
echo $CLASSPATH
/u01/orion/orioncomn/util/java/1.4/j2sdk1.4.2_04/lib/dt.jar:/u01/orion/orioncomn/util/java/1.4/j2sdk1.4.2_04/lib/tools.jar:/u01/orion /orioncomn/util/java/1.4/j2sdk1.4.2_04/jre/lib/rt.jar:/u01/orion/orioncomn/util/java/1.4/j2sdk1.4.2_04/jre/lib/charsets.jar:/u01/orio n/orioncomn/java/appsborg2.zip:/u01/orion/orioncomn/java/apps.zip:/u01/orion/orionora/8.0.6/forms60/java:/u01/orion/orioncomn/java:/u 01/orion/orioncomn/html/Orion.jar


No matter the Web Service I've tried to use, the problem is the same. Although, I'm giving you the URL of the WSDL file and the end points that I'm using for test purposes:

WSDL File:
http://www.w3schools.com/webservices/tempconvert.asmx?WSDL

End Points:
http://www.w3schools.com/webservices/tempconvert.asmx?op=CelsiusToFahrenheit
http://www.w3schools.com/webservices/tempconvert.asmx?op=FahrenheitToCelsius

Please, I need help to solve this problem.

Thanks all in advance,
Alejandro.
Re: Unable to initialize Java VM [message #387108 is a reply to message #386691] Tue, 17 February 2009 23:35 Go to previous messageGo to next message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
I have no immediately useful ideas for you.

Have you tried the 'CurrencyExchangeServiceStub' that is mentioned in the document you have referenced?

Have you searched this forum for 'web service' and 'webservice'. There may be someone there who is working with Forms 6.

David
Re: Unable to initialize Java VM [message #387236 is a reply to message #387108] Wed, 18 February 2009 06:55 Go to previous messageGo to next message
asito
Messages: 6
Registered: February 2009
Junior Member
Yes David, but I have to use others Web Services because the one used in the Oracle article is no more available (as it is said in the article itself). In the example that I've posted I point one of them.

All the things related to generate the jar file using the Web Service stub template with JDeveloper are working well.

Also, the "Import Java Classes" option in Forms 6i Builder is running well.

Before I posted my issue I researched a lot in the Web, including OraFaq serchig for things like Web Service Webservice, ORA_JAVA, and many more). I can't find anything usefull.

But, I've found one topic in OraFaq which mentioned things using this capability of integrating Forms 6i with Web Service. In that post you have helped to solve the problem:
http://www.orafaq.com/forum/m/192156/137848

I hope thet you can help me too.

Thanks a lot,
Alejandro.
Re: Unable to initialize Java VM [message #387344 is a reply to message #387236] Wed, 18 February 2009 22:57 Go to previous message
djmartin
Messages: 10181
Registered: March 2005
Location: Surges Bay TAS Australia
Senior Member
Account Moderator
Sorry. I don't have a platform on which to do this sort of testing.

David
Previous Topic: Application( Forms 6i Run Time) should be expired when application( Forms 6i ) is idle for 30 mins
Next Topic: How to store pdf file in oracle 10G
Goto Forum:
  


Current Time: Fri Apr 26 02:48:24 CDT 2024