0

I have a requirment, of invoking a Java file from Oracle database. In my project, whole of my business logic is in database, but there is a requirement of invoking a third party system (SOAP / RMI call) from my application.

Now for this i need to invoke atleast a Java Code or a batch script file (depending on Windows(.bat) Or Linux(.sh)).

Thanks

M.J.
  • 16,266
  • 28
  • 75
  • 97

2 Answers2

3

Try this page: http://www.cs.umbc.edu/portal/help/oracle8/java.815/a64686/04_call2.htm

You can can Java-Code from your PL/SQL.

Christian Kuetbach
  • 15,850
  • 5
  • 43
  • 79
1

Web-service call outs can be done from the Oracle Database. I'm not sure why you need to use Java for this as PL/SQL also allows for outbound calls using UTL_DBWS.

If you do not intend to use JPublisher, or you have a very simple web-service to consume, then you can use UTL_HTTP itself, or the appropriate class in Java - HttpURLConnection. However, I've never seen any case where a JAX-RPC library or any other web-service library was loaded into the database using loadjava, and used to make web-service calls; it ought to be possible do so, as long as the library is very light (in not depending on other libraries that cannot be loaded or used in the database), and requires permissions only to connect out from the database.

Related question

Community
  • 1
  • 1
Vineet Reynolds
  • 76,006
  • 17
  • 150
  • 174