Eclipelink plsql web services multiple operation
Hi,
In 11.1.2.2 jdev, I can generate a toplink/eclipse link plsql web services easily for one SQL (dbws).
Can I change the web services to support multiple operations, each for different select sql?
I've tried to changed the wsdl file to have multiple operations
and amend eclipse link-dbws.XML to include multiple query tags.
The web services can be run with multiple operation wsdl but the response of each operation
(using Jdev http analyzer) return only the result of the first operaton.
Can anyone help?
Regards,
Neln
Edited by: Nelson Ng on Nov 10, 2012 8:45 PM
Hi,
I think you are asking for multiple select statements processed by a single TopLink DB Service Provider configuration. As far as I know its exactly one per project and service. However, as this feature is coming from EclipseLink you may want to verify it there
Frank
Similar Messages
-
Problem with CLOB in PLSQL Web Service.
Hi-
I have Oracle Package that accepts CLOB as IN parameter and another CLOB as an OUT parameter. I went thru the tutorial in how to publish a database
PLSQL package as a web service with out any problem. I was able to publish and call successfully my PLSQL web service thru a browser and thru a simple C# application. It's been working fine until I receive an XML file which is bigger than 32766:
java.sql.SQLException: setString can only process strings of less than 32766 chararacters at oracle.jdbc.driver.DatabaseError.throwSqlException(DatabaseError.java:137)]
JDeveloper version: JDeveloper 10g (10.1.2.2.0) Build 1929
Oracle Application Server 10g
I'm newbie in JDeveloper so any help is greatly appreciated.
Thanks!well Shay,
i've used JDev's tools to developer and to deploy the web service: the war and ear files are automatically generates you to the end of the process.
I have included all the files java and the compiled classes, but I do not have files jar.
But don't works: if i create only one java class with all code inside then it works fine!!
Daniele -
9.0.3 plsql web service bug?
I've been building plsql web services for several days, and everything has been fine. I've been adding new functions on the database side, and editing my web services using the JDev wizard.
Now it's all stopped working, and I'm getting an "unexpected error" every time I try to generate the service. The "details" for the error looks like the stuff at the end of this message.
Before this happened, I did two potentially problematic things. I was (I thought) done with my testing, so I was cleaning up. So, I removed some functions on the plsql side. And I also did "remove from IDE" for my existing web service project, so I could start building a clean version that had just what I needed. It was when creating the fresh web service in the new project that things exploded.
As far as I can tell from the IDE, it generates the various serialization/deserialization files and the main web service class but fails before it can create the WSDL, web.xml, and deployment stuff.
-- jim
java.io.FileNotFoundException: /C:/Data/jdev9i/NEIEN1/Project1/src/__temp_java_wrappers/factlocal/Pk_web_service_test1.java (The system cannot find the file specified.
void java.io.FileInputStream.open(java.lang.String)
native code
void java.io.FileInputStream.<init>(java.lang.String)
FileInputStream.java:64
java.io.InputStream oracle.ide.net.FileURLFileSystemHelper.openInputStream.java.net.URL)
FileURLFileSystemHelper.java:415
java.io.InputStream oracle.ide.net.URLFileSystem.openInputStream(java.net.URL)
URLFileSystem.java:955
void oracle.jdevimpl.webservices.generator.WrapperClassGenerator$1.run()
WrapperClassGenerator.java:315
void oracle.jdevimpl.webservices.util.ThreadUtil$NonThrowingRunnable.run()
ThreadUtil.java:106
void java.awt.event.InvocationEvent.dispatch()
InvocationEvent.java:147
void java.awt.EventQueue.dispatchEvent(java.awt.AWTEvent)
EventQueue.java:337
boolean java.awt.EventDispatchThread.pumpOneEventForHierarchy(java.awt.Component)
EventDispatchThread.java:131
void java.awt.EventDispatchThread.pumpEventsForHierarchy(java.awt.Conditional, java.awt.Component)
EventDispatchThread.java:98
void java.awt.Dialog.show()
Dialog.java:380
void java.awt.Component.show(boolean)
Component.java:946
void java.awt.Component.setVisible(boolean)
Component.java:903
boolean oracle.bali.ewt.dialog.JEWTDialog.runDialog()
void oracle.ide.dialogs.ProgressBar.start(java.lang.String, java.lang.String)
ProgressBar.java:274
void oracle.jdevimpl.webservices.generator.SPWebServiceGenerator.generate(oracle.jdevimpl.webservices.wizard.publish.SPPublishModel, oracle.jdevimpl.webservices.util.JavaXSDTypeMap)
SPWebServiceGenerator.java:187
void oracle.jdevimpl.webservices.wizard.SPWebServicePublishWizard.wizardFinished(oracle.bali.ewt.wizard.WizardEvent)
SPWebServicePublishWizard.java:391
void oracle.bali.ewt.wizard.BaseWizard.processWizardEvent(oracle.bali.ewt.wizard.WizardEvent)
void oracle.bali.ewt.wizard.BaseWizard.processEventImpl(java.awt.AWTEvent)
void oracle.bali.ewt.LWComponent.processEvent(java.awt.AWTEvent)
void oracle.bali.ewt.wizard.BaseWizard.doFinish()
void oracle.bali.ewt.wizard.BaseWizard$Action.actionPerformed(java.awt.event.ActionEvent)
void javax.swing.AbstractButton.fireActionPerformed(java.awt.event.ActionEvent)
AbstractButton.java:1450
void javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(java.awt.event.ActionEvent)
AbstractButton.java:1504
void javax.swing.DefaultButtonModel.fireActionPerformed(java.awt.event.ActionEvent)
DefaultButtonModel.java:378
void javax.swing.DefaultButtonModel.setPressed(boolean)
DefaultButtonModel.java:250
void javax.swing.plaf.basic.BasicButtonListener.mouseReleased(java.awt.event.MouseEvent)
BasicButtonListener.java:216
void java.awt.Component.processMouseEvent(java.awt.event.MouseEvent)
Component.java:3715
void java.awt.Component.processEvent(java.awt.AWTEvent)
Component.java:3544
void java.awt.Container.processEvent(java.awt.AWTEvent)
Container.java:1164
void java.awt.Component.dispatchEventImpl(java.awt.AWTEvent)
Component.java:2593
void java.awt.Container.dispatchEventImpl(java.awt.AWTEvent)
Container.java:1213
void java.awt.Component.dispatchEvent(java.awt.AWTEvent)
Component.java:2497
void java.awt.LightweightDispatcher.retargetMouseEvent(java.awt.Component, int, java.awt.event.MouseEvent)
Container.java:2451
boolean java.awt.LightweightDispatcher.processMouseEvent(java.awt.event.MouseEvent)
Container.java:2216
boolean java.awt.LightweightDispatcher.dispatchEvent(java.awt.AWTEvent)
Container.java:2125
void java.awt.Container.dispatchEventImpl(java.awt.AWTEvent)
Container.java:1200
void java.awt.Window.dispatchEventImpl(java.awt.AWTEvent)
Window.java:922
void java.awt.Component.dispatchEvent(java.awt.AWTEvent)
Component.java:2497
void java.awt.EventQueue.dispatchEvent(java.awt.AWTEvent)
EventQueue.java:339
boolean java.awt.EventDispatchThread.pumpOneEventForHierarchy(java.awt.Component)
EventDispatchThread.java:131
void java.awt.EventDispatchThread.pumpEventsForHierarchy(java.awt.Conditional, java.awt.Component)
EventDispatchThread.java:98
void java.awt.Dialog.show()
Dialog.java:380
void java.awt.Component.show(boolean)
Component.java:946
void java.awt.Component.setVisible(boolean)
Component.java:903
boolean oracle.bali.ewt.wizard.WizardDialog.runDialog()
boolean oracle.ide.wizard.TitledWizardDialog.runDialog()
TitledWizardDialog.java:147
boolean oracle.jdevimpl.webservices.wizard.SPWebServicePublishWizard.runWizard()
SPWebServicePublishWizard.java:404
boolean oracle.jdevimpl.webservices.wizard.SPWebServicePublish.invoke(oracle.ide.addin.Context, java.lang.String[])
SPWebServicePublish.java:221
void oracle.ide.WizardManager$1.run()
WizardManager.java:450
void java.awt.event.InvocationEvent.dispatch()
InvocationEvent.java:154
void java.awt.EventQueue.dispatchEvent(java.awt.AWTEvent)
EventQueue.java:337
boolean java.awt.EventDispatchThread.pumpOneEventForHierarchy(java.awt.Component)
EventDispatchThread.java:131
void java.awt.EventDispatchThread.pumpEventsForHierarchy(java.awt.Conditional, java.awt.Component)
EventDispatchThread.java:98
void java.awt.EventDispatchThread.pumpEvents(java.awt.Conditional)
EventDispatchThread.java:93
void java.awt.EventDispatchThread.run()
EventDispatchThread.java:85Could be. Here's what the console has on it. Of course, contrary to the message, it is an Oracle database. Good luck!
Invoking JPublisher with command line:
-user=w19572/w19572
-driver=oracle.jdbc.driver.OracleDriver
-url=jdbc:oracle:thin:@localhost:1521:HUDSOJ
-numbertypes=objectjdbc
-lobtypes=jdbc
-usertypes=oracle
-builtintypes=jdbc
-case=mixed
-encoding=Cp1252
-methods=named
-plsqlmap=true
-transitive=true
-omit_schema_names
-dir=C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers
-package=factlocal
-input=C:\TEMP\input59112.jpub
C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
_test2.sqlj:43.5-44.17: Warning: You are using an Oracle JDBC driver, but connec
ting to an non-Oracle database. SQLJ will perform JDBC-generic SQL checking.
C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
test2.sqlj:43.5-44.17: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_NAME. Ther
e is no stored procedure or function of this name.
C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
test2.sqlj:53.5-54.17: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_SIC. There
is no stored procedure or function of this name.
C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
test2.sqlj:63.5-64.17: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_SICLIST. T
here is no stored procedure or function of this name.
C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
test2.sqlj:73.5-74.17: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_SIC_TABLE.
There is no stored procedure or function of this name.
C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
test2.sqlj:83.5-84.15: Error: Not found: PKWEB_SERVICE_TEST2.FID_TO_WHEREDATA.
There is no stored procedure or function of this name.
C:\Data\jdev9i\NEIEN1\Project1\src\__temp_java_wrappers\factlocal\Pk_web_service
test2.sqlj:94.5-96.21: Error: Not found: PKWEB_SERVICE_TEST2.UPDATE_NAME. Ther
e is no stored procedure or function of this name.
Total 6 errors and 1 warning. -
Develop PLSQL web services using JDeveloper.
Dear Sir,
1. Must we use OC4J to generate PLSQL webservices? or we can use any other J2EE compliant app server?
2. Does it mean in Oracle environment, we can only use JAVA and not other language to wrap PLSQL stored procedures to create PLSQL web services?
Please advise.
Thank you.You don't need OC4J - you can use JDeveloper to generate Web services from PL/SQL
You can manuall wrap PL/SQL into web services with any language - however JDeveloper uses Java to do this without the need for you to code anything. -
Can use PLSQL to develop PLSQL web services?
Hi,
I know we can use JDeveloper to create PLSQL web services.
How about if we want to develop plsql web services using PLSQL itself, is that possible?
Please advise.
Thank you.I found the article on how to call web services from within database.
http://www.oracle.com/technology/tech/webservices/htdocs/samples/dbwebservice/DBWebServices_PLSQL.html?_template=/ocom/technology/content/print
The example is for oracle9iR2.
It's looks like it's quite a bit of work compare to use java to call web services. I wonder with Oracle10g database, is there any improvement that will simply the steps? Would appreciate some advice as i don't have oracle10g environment in my place.
Thank you. -
PLSQL web service returning multiple records
Hello,
I am trying to create a web service using oracle 11g which should be able to return multiple records.
Based on hints and code samples found on the internet here is my code :
CREATE OR REPLACE TYPE test_rec is OBJECT (
s_nume_adre NUMBER ,
c_eta_civi VARCHAR2(4 BYTE),
l_nom1_comp VARCHAR2(40 BYTE),
l_nom2_comp VARCHAR2(40 BYTE),
l_nom3_comp VARCHAR2(40 BYTE),
l_pren_comp VARCHAR2(30 BYTE),
d_date_nais DATE);
CREATE OR REPLACE TYPE test_array AS TABLE OF test_rec;
CREATE OR REPLACE PACKAGE test_pkg AS
function get_rows(snume_adre in number) return test_array;
END;
CREATE OR REPLACE PACKAGE BODY test_pkg AS
function get_rows(snume_adre in number) return test_array is
v_rtn test_array := test_array(null);
v_first boolean := true;
cursor c_get_rows(snume_adre in number) is
SELECT a.s_nume_adre,
nvl(a.c_eta_civi, '') c_eta_civi,
nvl(a.l_nom1_comp, '') l_nom1_comp,
nvl(a.l_nom2_comp, '') l_nom2_comp,
nvl(a.l_nom3_comp, '') l_nom3_comp,
nvl(a.l_pren_comp, '') l_pren_comp,
nvl(a.d_date_nais, to_date('01.01.1900', 'dd.mm.yyyy')) d_date_nais
FROM bro.z45 a
where a.s_nume_adre = snume_adre or snume_adre is null;
begin
for rec in c_get_rows(snume_adre) loop
if v_first then
v_first := false;
else
v_rtn.extend;
end if;
v_rtn(v_rtn.last) := test_rec(rec.s_nume_adre, rec.c_eta_civi, rec.l_nom1_comp, rec.l_nom2_comp,
rec.l_nom3_comp, rec.l_pren_comp, rec.d_date_nais);
end loop;
return v_rtn;
end;
END;
--select * from table (test_pkg.get_rows(null));
I am able to retrieve the data using the select.
However when I try to access its wsdl I get an error :
<soap:Envelope>
<soap:Body>
<soap:Fault>
<faultcode>soap:Client</faultcode>
<faultstring>Error processing input</faultstring>
<detail>
<OracleErrors></OracleErrors>
</detail>
</soap:Fault>
</soap:Body>
</soap:Envelope>
If I comment the function call in the package declaration I get a "correct" wsdl :
<definitions name="GET_ROWS" targetNamespace="http://xmlns.oracle.com/orawsv/TEST/TEST_PKG/GET_ROWS" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://xmlns.oracle.com/orawsv/TEST/TEST_PKG/GET_ROWS" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
<types>
<xsd:schema targetNamespace="http://xmlns.oracle.com/orawsv/TEST/TEST_PKG/GET_ROWS" elementFormDefault="qualified">
<xsd:element name="GET_ROWSInput">
<xsd:complexType>
</xsd:complexType>
</xsd:element>
<xsd:element name="GET_ROWSOutput">
<xsd:complexType>
</xsd:complexType>
</xsd:element>
</xsd:schema>
</types>
<message name="GET_ROWSInputMessage">
<part name="parameters" element="tns:GET_ROWSInput"/>
</message>
<message name="GET_ROWSOutputMessage">
<part name="parameters" element="tns:GET_ROWSOutput"/>
</message>
<portType name="GET_ROWSPortType">
<operation name="GET_ROWS">
<input message="tns:GET_ROWSInputMessage"/>
<output message="tns:GET_ROWSOutputMessage"/>
</operation>
</portType>
<binding name="GET_ROWSBinding" type="tns:GET_ROWSPortType">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="GET_ROWS">
<soap:operation soapAction="GET_ROWS"/>
<input>
<soap:body parts="parameters" use="literal"/>
</input>
<output>
<soap:body parts="parameters" use="literal"/>
</output>
</operation>
</binding>
<service name="GET_ROWSService">
<documentation>Oracle Web Service</documentation>
<port name="GET_ROWSPort" binding="tns:GET_ROWSBinding">
<soap:address location="http://server.domain.ch:8080/orawsv/TEST/TEST_PKG/GET_ROWS"/>
</port>
</service>
</definitions>
Any hint as how to create and access pl sql web service returning multiple rows?
I don't use java and don't have access to tools like JDeveloper.
Thanks!The actual issue is that collection types are not supported for return parameters.
The solution is to wrap the collection into another object.
Here's a working example based on your settings :
CREATE OR REPLACE TYPE test_rec is OBJECT (
empno number(4)
, ename varchar2(10)
, hiredate date
CREATE OR REPLACE TYPE test_array AS TABLE OF test_rec;
CREATE OR REPLACE TYPE test_array_wrapper is OBJECT ( arr test_array );
CREATE OR REPLACE PACKAGE test_pkg AS
function get_rows(p_deptno in number) return test_array_wrapper;
END;
CREATE OR REPLACE PACKAGE BODY test_pkg AS
function get_rows(p_deptno in number) return test_array_wrapper is
results test_array;
begin
select test_rec(empno, ename, hiredate)
bulk collect into results
from scott.emp
where deptno = p_deptno;
return test_array_wrapper(results);
end;
END;
The wsdl is then generated correctly :
SQL> select httpuritype('http://DEV:dev@localhost:8080/orawsv/DEV/TEST_PKG/GET_ROWS?wsdl').getxml() from dual;
HTTPURITYPE('HTTP://DEV:DEV@LOCALHOST:8080/ORAWSV/DEV/TEST_PKG/GET_ROWS?WSDL').GETXML()
<definitions name="GET_ROWS" targetNamespace="http://xmlns.oracle.com/orawsv/DEV/TEST_PKG/GET_ROWS" xmlns="http://schemas.xmlsoap.org/wsdl/" xmlns:tns="http://xmlns.oracle.com/orawsv/DEV/TEST_PKG/GET_
ROWS" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
<types>
<xsd:schema targetNamespace="http://xmlns.oracle.com/orawsv/DEV/TEST_PKG/GET_ROWS" elementFormDefault="qualified">
<xsd:element name="CTEST_ARRAY_WRAPPER-GET_ROWSInput">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="P_DEPTNO-NUMBER-IN" type="xsd:double"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:element name="GET_ROWSOutput">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="RETURN" type="tns:TEST_ARRAY_WRAPPERType"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
<xsd:complexType name="TEST_ARRAY_WRAPPERType">
<xsd:sequence>
<xsd:element name="TEST_ARRAY_WRAPPER">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="ARR">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="TEST_REC" type="tns:TEST_REC_IntType" maxOccurs="unbounded" minOccurs="0"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
<xsd:complexType name="TEST_REC_IntType">
<xsd:sequence>
<xsd:element name="EMPNO" type="xsd:double"/>
<xsd:element name="ENAME">
<xsd:simpleType>
<xsd:restriction base="xsd:string">
<xsd:maxLength value="10"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
<xsd:element name="HIREDATE" type="xsd:date"/>
</xsd:sequence>
</xsd:complexType>
</xsd:schema>
</types>
<message name="GET_ROWSInputMessage">
<part name="parameters" element="tns:CTEST_ARRAY_WRAPPER-GET_ROWSInput"/>
</message>
<message name="GET_ROWSOutputMessage">
<part name="parameters" element="tns:GET_ROWSOutput"/>
</message>
<portType name="GET_ROWSPortType">
<operation name="GET_ROWS">
<input message="tns:GET_ROWSInputMessage"/>
<output message="tns:GET_ROWSOutputMessage"/>
</operation>
</portType>
<binding name="GET_ROWSBinding" type="tns:GET_ROWSPortType">
<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
<operation name="GET_ROWS">
<soap:operation soapAction="GET_ROWS"/>
<input>
<soap:body parts="parameters" use="literal"/>
</input>
<output>
<soap:body parts="parameters" use="literal"/>
</output>
</operation>
</binding>
<service name="GET_ROWSService">
<documentation>Oracle Web Service</documentation>
<port name="GET_ROWSPort" binding="tns:GET_ROWSBinding">
<soap:address location="http://localhost:8080/orawsv/DEV/TEST_PKG/GET_ROWS"/>
</port>
</service>
</definitions> -
Problem when invoking a web service multiple times
Hello,
I have a java client which invokes an apache axis web service (deployed on an Oracle Application Server on a remote machine) multiple times.
The client distributes the web service invokes among multiple threads, every thing goes well but after an average of 300 web service invokes (among all threads) ab exception is thrown from the client:
java.net.SocketException: Unable to establish connection
at org.apache.axis.AxisFault.makeFault(AxisFault.java:101)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:154)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:11
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at standardwebservice.StandardWebserviceSoapBindingStub.getStandardWebserviceData(StandardWebserviceSoapBindingStub.java:225)
at standardwebservice.StandardWebserviceProxy.getStandardWebserviceData(StandardWebserviceProxy.java:50)
at main.VericalThread.run(VericalThread.java:65)
Caused by: java.net.SocketException: Unable to establish connection
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSocketFactory.java:153)
at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSocketFactory.java:120)
at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:191)
at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:404)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:13
... 12 more
Thread No. 1 Start for calling 1210ZD106MAT2AAxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: java.net.SocketException: Unable to establish connection
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:java.net.SocketException: Unable to establish connection
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSocketFactory.java:153)
at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSocketFactory.java:120)
at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:191)
at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:404)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:13
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:11
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at standardwebservice.StandardWebserviceSoapBindingStub.getStandardWebserviceData(StandardWebserviceSoapBindingStub.java:225)
at standardwebservice.StandardWebserviceProxy.getStandardWebserviceData(StandardWebserviceProxy.java:50)
at main.VericalThread.run(VericalThread.java:65)
By the way, when I deploy the same web service on an oracle application server on a local machine (in same physical network), every thing goes well and this exception doesn't appear.
By the way, I also tried a JAX-RPC web service and the same exception is thrown.
So please can somebody give me a help.Hello,
I have a java client which invokes an apache axis web service (deployed on an Oracle Application Server on a remote machine) multiple times.
The client distributes the web service invokes among multiple threads, every thing goes well but after an average of 300 web service invokes (among all threads) ab exception is thrown from the client:
java.net.SocketException: Unable to establish connection
at org.apache.axis.AxisFault.makeFault(AxisFault.java:101)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:154)
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:11
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at standardwebservice.StandardWebserviceSoapBindingStub.getStandardWebserviceData(StandardWebserviceSoapBindingStub.java:225)
at standardwebservice.StandardWebserviceProxy.getStandardWebserviceData(StandardWebserviceProxy.java:50)
at main.VericalThread.run(VericalThread.java:65)
Caused by: java.net.SocketException: Unable to establish connection
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSocketFactory.java:153)
at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSocketFactory.java:120)
at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:191)
at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:404)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:13
... 12 more
Thread No. 1 Start for calling 1210ZD106MAT2AAxisFault
faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
faultSubcode:
faultString: java.net.SocketException: Unable to establish connection
faultActor:
faultNode:
faultDetail:
{http://xml.apache.org/axis/}stackTrace:java.net.SocketException: Unable to establish connection
at java.net.PlainSocketImpl.socketConnect(Native Method)
at java.net.PlainSocketImpl.doConnect(Unknown Source)
at java.net.PlainSocketImpl.connectToAddress(Unknown Source)
at java.net.PlainSocketImpl.connect(Unknown Source)
at java.net.SocksSocketImpl.connect(Unknown Source)
at java.net.Socket.connect(Unknown Source)
at sun.reflect.GeneratedMethodAccessor8.invoke(Unknown Source)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
at java.lang.reflect.Method.invoke(Unknown Source)
at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSocketFactory.java:153)
at org.apache.axis.components.net.DefaultSocketFactory.create(DefaultSocketFactory.java:120)
at org.apache.axis.transport.http.HTTPSender.getSocket(HTTPSender.java:191)
at org.apache.axis.transport.http.HTTPSender.writeToSocket(HTTPSender.java:404)
at org.apache.axis.transport.http.HTTPSender.invoke(HTTPSender.java:13
at org.apache.axis.strategies.InvocationStrategy.visit(InvocationStrategy.java:32)
at org.apache.axis.SimpleChain.doVisiting(SimpleChain.java:11
at org.apache.axis.SimpleChain.invoke(SimpleChain.java:83)
at org.apache.axis.client.AxisClient.invoke(AxisClient.java:165)
at org.apache.axis.client.Call.invokeEngine(Call.java:2784)
at org.apache.axis.client.Call.invoke(Call.java:2767)
at org.apache.axis.client.Call.invoke(Call.java:2443)
at org.apache.axis.client.Call.invoke(Call.java:2366)
at org.apache.axis.client.Call.invoke(Call.java:1812)
at standardwebservice.StandardWebserviceSoapBindingStub.getStandardWebserviceData(StandardWebserviceSoapBindingStub.java:225)
at standardwebservice.StandardWebserviceProxy.getStandardWebserviceData(StandardWebserviceProxy.java:50)
at main.VericalThread.run(VericalThread.java:65)
By the way, when I deploy the same web service on an oracle application server on a local machine (in same physical network), every thing goes well and this exception doesn't appear.
By the way, I also tried a JAX-RPC web service and the same exception is thrown.
So please can somebody give me a help. -
Web-Service generator : operation arguments
Hello.
I've built a very simple web service to test the JSR 172 API. The server side is built using AXIS. The service is exposed in document/literal style as required by the JSR.
An operation of the service takes as argument a simple structure bean with a string and an integer. The wsdl declares the corresponding complex type, and describes the operation with an argument of this type.
Now, the WTK stub generator generates as expected the stub and the bean classes, but the operation is translated with two arguments instead of the original two members structure. The MIDlet code can obviously call the service passing the two arguments. At runtime, it all works, since both the wsdl and consequent soap body don't make difference about the structure representation.
But what should occur with a more complex structure with many members ? I suppose it should work the same, but not with the preferred interface and usage...
Is it a legal behaviour, according to the JSR or WS-I specifications. Does the WTK only support this 'unwrapped' mode, or is there any way to change it ?
Thanks for your help.
Ephemeris LappisIs this for sure? I am having the same problem, and it seems odd that I am going to have to tell all of the people using my services what the parameters mean instead of them just being able to read the WSDL. Is there any way at all to rename the parameters?
-
Invoking web service multiple times
Hello,
in CAF I have modeled a business object Order which contains a number of OrderLines.
In VC I have modeled a form which is used to collect the metadata of the Order as well as a table containing the OrderLines of the regarded Order.
For storing the Order I have specified a web service in CAF, which basically inkoves the create operation of the Order.
For storing the OrderLines I have specified a web service which adds an OrderLine to a given Order (i.e., invoking the add operation on the association).
Is it possible to invoke this web service for each row in the table? When I connect the table to the web service and choose "all rows" only the last row seems to be processed.
Best regards
AlexanderHi Alexander,
Consumption of complex structure is possible when calling a web service.
Please refer to the below links:
http://help.sap.com/saphelp_nwce10/helpdata/en/32/07c93f26903a1ce10000000a114084/frameset.htm
http://help.sap.com/saphelp_nwce10/helpdata/en/43/733b956d596fcee10000000a1553f6/frameset.htm ( here click on Supported web service struct and facets link)
Let me know if its useful
Regards,
Vani -
People Picker field and Web service -- multiple round trips to get Display Name value
Using Sharepoint 2010 and Infopath 2010, I have created a form that validates fields entered within the form by connecting to a .Net web service created by someone else. One of the fields that I need to validate is a People Picker field
for the Project Manager.
The connection to the Web Service runs correctly except that the People Picker goes through the validation process 3-4 times. I know this because I have a MessageBox showing the value for the InnerXML that pops up 3 times. The
first time the MessageBox shows no value for the XML, the next time it shows a name, and the 3rd time it shows no value.
Here is the code I'm using in the Infopath form (without the Messagebox):
Dim wsConnection As WebServiceConnection = DirectCast(Me.DataConnections("Validate"), WebServiceConnection)
Dim formNavigatorProjectManager As XPathNavigator = MainDataSource.CreateNavigator()
Dim wsNavigatorProjectManager As XPathNavigator = Me.DataSources("Validate").CreateNavigator()
strformNavProjectManager = formNavigatorProjectManager.SelectSingleNode("/pr:properties/p:properties/documentManagement/ns3:ProjectManager/ns3:UserInfo/ns3:DisplayName", NamespaceManager).InnerXml
wsNavigatorProjectManager.SelectSingleNode("/dfs:myFields/dfs:queryFields/ns7:Validate/ns7:projectManager", NamespaceManager).SetValue(strformNavProjectManager)
wsConnection.Execute()
The line in BOLD above used to have just /pr:properties/p:properties/documentManagement/ns3:ProjectManager
but I thought my problem might be because People Picker fields are made up of 3 elements -- DisplayName, AccountID and Account Type. So I changed the XML. Sadly, that didn't make any difference.
I am using the CHANGED event which a colleague of mine thought would have taken care of the multiple round trips. But it didn't.
Hopefully someone out there can tell me what I need to do so that this People Picker field only get validated once (The form also has Managed Metadata fields that have very similar problems so I'm hoping that the solution for the People Picker field
takes care of the MMD fields too.) Thanks in advance. Carol.Hi Carol,
It is the behavior for setting People/Group field if you just select the node "/dfs:myFields/dfs:queryFields/ns7:Validate/ns7:projectManager".
Also you can try to only set the AccountID value of the People/Group field:
Dim wsConnection As WebServiceConnection = DirectCast(Me.DataConnections("Validate"), WebServiceConnection)
Dim formNavigatorProjectManager As XPathNavigator = MainDataSource.CreateNavigator()
Dim wsNavigatorProjectManager As XPathNavigator = Me.DataSources("Validate").CreateNavigator()
strformNavProjectManagerID = formNavigatorProjectManager.SelectSingleNode("/pr:properties/p:properties/documentManagement/ns3:ProjectManager/ns3:UserInfo/ns3:AccountID", NamespaceManager).InnerXml
wsNavigatorProjectManager.SelectSingleNode("/dfs:myFields/dfs:queryFields/ns7:Validate/ns7:projectManager/ns7:userinfo/ns7:AccountID", NamespaceManager).SetValue(strformNavProjectManagerID)
wsConnection.Execute()
Thanks,
Eric
Forum Support
Please remember to mark the replies as answers
if they help and unmark them if they provide no help. If you have feedback for TechNet Subscriber Support, contact [email protected]
Eric Tao
TechNet Community Support -
Call Same Web Service Multiple Times
Hello All,
Just wondering if there are any issues calling the same web service more than once within a single form?
Basically what I'm trying to do is use an LDAP web service that returns a user name at different status levels. (i.e. user1 who starts the form process, and then again at user2 who is reviewing the form - pre-populating their names)
Since the web service is already bound to the first set of fields at level 1, I created a new data connection to the same web service to run at the next level. Problem is, I'm not getting any errors OR any results.
Do I need to just re-create the web service with another name?
Thanks.Multiple calls work fine for me.
Just create a new data connection and that's it. -
hi ...
I've just read on the internet, that in oracle database 10g, it'll be
posible to expose plsql packages/procedures as web-services, directly
from the database, and without any help from the applicacion server.
Is that true?
When is gonna be available oracle database 10g???
Is there gonna be a linux version, free of charge for
development-purposes? (just as with 9i)
Do u know anything about oracle's xforms implementation? ... I mean,
when are gonna be released the "real" products ...I hope that besides
the IE plugin, there'll be other options from oracle. And I suppose that
oracle xforms implementation is gonna be compatible with oracle plsql
exposed as database web services , don't they?
Thanks in advance.
salu2
dario estepario ...For questions about Oracle Database 10g, please visit the Database forums here:
Forums Home � Oracle Technology Network (OTN) � Products � Database
With the Wireless Client (i.e. the "IE plugin"), you will be able to call any web service. We are currently preparing an OTN sample to demonstrate this capability.
Oracle also has developed server-side support for XForms in the latest version of Oracle Application Server Wireless. You can find more information in the documentation here:
http://download-west.oracle.com/docs/cd/B10464_01/wireless.904/b10948/nuxhtml.htm#1032529
Regards,
Phil -
ANM web services - Get operational state of an SfRserver
Is there any way to obtain the operational state of a serverfarm realserver via the ANM (4.1) web services API? The SfRserver data type includes the admin state (i.e. IS, ISS, or OOS) but I dont see a field for the operational state. The ANM web GUI displays both an admin state and an operational state for a serverfarm realserver -- with the operational state indicating the latest probe status for the real server (e.g. "Up" or "Probe Failed") and I would like to obtain the same information but using the ANM web services interface.
Hello Andrew,
The API for ANM is purely for configuration, it does not return anything other than configuration. The state of "inservice" or "out of service" relates to the command under the rserver:
rserver host Server05
ip address 172.16.35.14
inservice <======= **Here**
The probe states don't relate to the configuration, so the API doesn't have a plugin to that information.
However - You could use SNMP seperately to gathter that probe state directly from the ACE and intigrate that into the page you are executing the API for.
Regards,
Chris Higgins -
Deploy PLSQL web services on weblogic for 11g-URI not working
Dear all,
Scenario:
Using JDeveloper I deployed a web service from a PLSQL package to a war file. After that I deployed that war file on a weblogic (10.3.5) server manually not by using JDeveloper.
The deployment of the admin on the admin server is successfully done. While testing the application on the server itself again successful.
Problem:
But having an issue while trying to do the same using the URL giving in the application server.
404 -Not Found error is coming up.
Solutions tried so far:
Tried putting a html file to the created application in order to get the job done- Did not work out
Please I have no idea how to proceed. Quick responses are much appreciated.
Thank youHi. The [Service]-mapping.xml file is a standard "JAX-RPC mapping file" according the JSR-109 spec and WebLogic 9.2 doc ([1],[2]). That's the file that references the class. Here's a fragment:
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<java-wsdl-mapping xmlns="http://java.sun.com/xml/ns/j2ee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" version="1.1" xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://www.ibm.com/webservices/xsd/j2ee_jaxrpc_mapping_1_1.xsd">
<package-mapping>
<package-type>co.com.acme.services</package-type>
<namespaceURI>urn:Service/types</namespaceURI>
</package-mapping>
<package-mapping>
<package-type>co.com.acme.services</package-type>
<namespaceURI>urn:Services/wsdl</namespaceURI>
</package-mapping>
<java-xml-type-mapping>
<java-type>co.com.acme.services.ServiceSEI_serviceOperation_RequestStruct</java-type>
<root-type-qname xmlns:typeNS="urn:Service/types">typeNS:serviceOperation</root-type-qname>
<qname-scope>complexType</qname-scope>
<variable-mapping>
<java-variable-name>String_1</java-variable-name>
<xml-element-name>String_1</xml-element-name>
</variable-mapping>
</java-xml-type-mapping>
I'll take a look at the ant task.
Thank you very much.
[1]http://download.oracle.com/otndocs/jcp/websvcs-1.0-fr-spec-oth-JSpec/
[2]http://otndnld.oracle.co.jp/document/products/wls/docs92/webserv/jsr109.html -
PL/SQL Web Service element, operation, part names etc all in lowecase
I have generated web services from pl/sql packages on a 11.2.0.1.0 database using JDev 11.1.1.5.0. In the generated wsdl all the names are in lowercase. Is there anyway of getting these names to match the case the objects are stored in the database?
Eg. CREATE OR REPLACE TYPE sampleEntity AS OBJECT (entityNumber INTEGER
,entityType VARCHAR2(1)
,displayName VARCHAR2(400))
But in the wsdl they are all lowercase:-
Eg.
<xsd:complexType name="sampleentity">
<xsd:sequence>
<xsd:element name="entitynumber" type="int" nillable="true"/>
<xsd:element name="entitytype" type="string" nillable="true"/>
<xsd:element name="displayname" type="string" nillable="true"/>
Thanks.
Steve.Ok, this sounds like a known bug ( Bug 5908689 ) in 10.1.3.1, but this was specific to non-Windows platforms. Are you on Linux/Solaris or any other platform? It might or might not be the same problem you are hitting but it does seem quite close (can't say for sure without a close investigation, I am afraid!)
In any case, this bug is fixed in the 10.1.3.4 patchset (besides quite a few other fixes and enhancements) - so would recommend you to first apply the 10.1.3.4 patchset and retest. The patchset is available on My Oracle Support (formerly Metalink) under Patch 7272722. Or you could go a step ahead, and apply the 10.1.3.5 patchset (Patch 8626084) instead which is the latest patchset for OracleAS 10.1.3.x.
HTH,
Yogesh
Maybe you are looking for
-
SAP NetWeaver 04s SP9 for JAVA Installation problem on Windows Vista
Hi Guys, Firstly, anyone installed WAS on Windows Vista home version? I have gone thru couple of postings in the SDN and disabled firewall but no use. here is link : Port 21212 error : Couldn't install 2004s When I am trying to install, getting
-
Open items missing in F-44 compared to FBL1N
Hello all My user is attempting to do a routine clearing of a vendor account using the f-44 transaction. However, when they run the transaction it does not display all open items on the vendor account (as seen in fbl1n run for open items). there are
-
How to set missing language information in iTunes books?
Some of the ebooks I imported into iTunes are missing language information in their metadata. I can't find a means of setting the proper language in the information dialog, something which can easily done i.e. using Calibre or Sigil. Is iTunes really
-
I'm sitting here with my new Macbook Pro and next to it my older Macbook. Both are connected to the same wireless base station but the Pro's signal strength fluctuates from zero to half strength while the Macbook signs in on near full strength and is
-
Privacy violation bug in firefox 7
I have found a bug in fire fox 7 this is a bug that sends information about me over the internet to a server. This is a violation of the privacy act and i will sue. Then there is a problem wit logging in on portals if i do it with firefox 7 i get ban