JAX-WS Client hangs thread

Hello
I have a web application which consumes a remote web service, it has been in live use for more than a year.
The web service consumed is part of an off the shelf application which fails approx 6 times a year. When it fails, the GlassFish server hosting my web application is also liable to fail. Thus a failure of the purchased application results in the failure of a whole set of other applications.
The Web Service client was written using JAX-WS. When the web service fails, calls to the client are liable to hang and never return. There is no timeout and no error, just a hung thread in GlassFish. In GlassFish the default maximum for request processing threads is 5, if all of them hang Glassfish is dead.
jstack output shows JAX-WS gets stuck, it does a read without a timeout and never regains control. I have seen threads stuck for in excess of 1 hour 45 minutes, they remain stuck until the application server is re-started.
To work around this issue I have written a class to predict if a connection is likely to be healthy or not, if not it attempts to replace the connection with a new one. I am reasonably confident this will reduce the likelihood of failures but I believe there must be a better way to avoid the overhead of getting a new connection every time.
1) Has anybody else suffered this same issue, if so how did you get round it ?
2) Does anybody agree with me that the reads done by JAX-WS should timeout if necessary and failure to do so is a weakness/bug in the JAX-WS client ?
What follows is an example of jstack output showing a hung thread.
----------------- t@162 -----------------
0xff2cc360     _read + 0x8
0xfead8e18     JVM_Read + 0xe4
0xfadbc154     Java_java_net_SocketInputStream_socketRead0 + 0x1fc
0xf8c0c280     * java.net.SocketInputStream.socketRead0(java.io.FileDescriptor, byte[], int, int, int) bci:-1830175952 (Interpreted frame)
0xf8c0c224     * java.net.SocketInputStream.socketRead0(java.io.FileDescriptor, byte[], int, int, int) bci:0 (Interpreted frame)
0xf8c058b8     * java.net.SocketInputStream.read(byte[], int, int) bci:84 line:129 (Interpreted frame)
0xf8c50588     <C2IAdapter>
0xf949c8fc     0xf949c8fc     * java.io.BufferedInputStream.fill() bci:175 line:218 (Compiled frame)
0xf8fbac24     0xf8fbac24     * java.io.BufferedInputStream.read1(byte[], int, int) bci:44 line:256 (Compiled frame)
0xfa889c6c     0xfa889c6c     * sun.net.www.http.HttpClient.parseHTTPHeader(sun.net.www.MessageHeader, sun.net.ProgressSource, sun.net.www.protocol.http.HttpURLConnection) bci:51 line:681 (Compiled frame)
0xf8cbfc44     <I2CAdapter>
0xf8c057a8     * sun.net.www.http.HttpClient.parseHTTP(sun.net.www.MessageHeader, sun.net.ProgressSource, sun.net.www.protocol.http.HttpURLConnection) bci:30 line:626 (Interpreted frame)
0xf8c057a8     * sun.net.www.protocol.http.HttpURLConnection.getInputStream() bci:246 line:983 (Interpreted frame)
0xf8c05874     * java.net.HttpURLConnection.getResponseCode() bci:16 line:367 (Interpreted frame)
0xf8c058b8     * com.sun.xml.ws.transport.http.client.HttpClientTransport.checkResponseCode() bci:5 line:201 (Interpreted frame)
0xf8c05764     * com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(com.sun.xml.ws.api.message.Packet) bci:345 line:149 (Interpreted frame)
0xf8c05d3c     * com.sun.xml.xwss.XWSSClientPipe.process(com.sun.xml.ws.api.message.Packet) bci:76 line:118 (Interpreted frame)
0xf8c05d3c     * com.sun.xml.ws.api.pipe.helper.PipeAdapter.processRequest(com.sun.xml.ws.api.message.Packet) bci:6 line:115 (Interpreted frame)
0xf8c52980     <C2IAdapter>
0xfab36e58     0xfab36e58     * com.sun.xml.ws.api.pipe.Fiber.__doRun(com.sun.xml.ws.api.pipe.Tube) bci:206 line:595 (Compiled frame)
0xf8c547bc     <I2CAdapter>
0xf8c05874     * com.sun.xml.ws.api.pipe.Fiber._doRun(com.sun.xml.ws.api.pipe.Tube) bci:31 line:554 (Interpreted frame)
0xf8c05874     * com.sun.xml.ws.api.pipe.Fiber.doRun(com.sun.xml.ws.api.pipe.Tube) bci:84 line:539 (Interpreted frame)
0xf8c05874     * com.sun.xml.ws.api.pipe.Fiber.runSync(com.sun.xml.ws.api.pipe.Tube, com.sun.xml.ws.api.message.Packet) bci:48 line:436 (Interpreted frame)
0xf8c05874     * com.sun.xml.ws.client.Stub.process(com.sun.xml.ws.api.message.Packet, com.sun.xml.ws.client.RequestContext, com.sun.xml.ws.client.ResponseContextReceiver) bci:155 line:248 (Interpreted frame)
0xf8c05874     * com.sun.xml.ws.client.sei.SEIStub.doProcess(com.sun.xml.ws.api.message.Packet, com.sun.xml.ws.client.RequestContext, com.sun.xml.ws.client.ResponseContextReceiver) bci:4 line:135 (Interpreted frame)
0xf8c05874     * com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(java.lang.Object, java.lang.Object[], com.sun.xml.ws.client.RequestContext, com.sun.xml.ws.client.ResponseContextReceiver) bci:64 line:109 (Interpreted frame)
0xf8c05874     * com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(java.lang.Object, java.lang.Object[]) bci:14 line:89 (Interpreted frame)
0xf8c05874     * com.sun.xml.ws.client.sei.SEIStub.invoke(java.lang.Object, java.lang.reflect.Method, java.lang.Object[]) bci:24 line:118 (Interpreted frame)
0xf8c05d3c     * $Proxy64.updateProblem(com.peregrine.servicecenter.pws.pm.UpdateProblemRequest) bci:16 (Interpreted frame)
0xf8c05d3c     * com.reuters.gsm.sf.consumePeregWs.PeregPm.addUpdate(java.lang.String, int, int, java.lang.String, java.lang.String, java.util.Date) bci:341 line:129 (Interpreted frame)
Regards, Vince

[http://stackoverflow.com/questions/2592303/how-do-i-set-the-jax-ws-client-request-timeout-programatically-on-jboss]

Similar Messages

  • Jax-WS Client - Change Endpoint Address "https" to "http" - Cause HTTP 302

    Hi,
    I don't know it is a bug or not, but i couldn't find any answer for this.
    I try to write a client for an SSL Secured and Basic Authenticated web service. To access the WSDL url, i have a VPN connection to that network. Also i registered their certificate to the JVM that i used to run the Client.
    To create Jax-WS Client codes, i used "......\jaxws-ri\bin\wsimport.bat -s src -d bin -p model https://xxxx.com/xxxxxx.asmx?WSDL" as explained.
    After successfully generated sources, i added my "SecurityEnvironmentHandler.java" to catch Username and Password callbacks, and also added "SecurityHandler.java" to register my handler and surrund with necessary SOAP Header Security tags. I register them as explained too.
    Everything looks fine, but when i try to run Client test which basically call one of the services, i get
    com.sun.xml.ws.client.ClientTransportException: The server sent HTTP status code 302: Found
         at com.sun.xml.ws.transport.http.client.HttpTransportPipe.checkStatusCode(HttpTransportPipe.java:203)
         at com.sun.xml.ws.transport.http.client.HttpTransportPipe.process(HttpTransportPipe.java:177)
         at com.sun.xml.ws.transport.http.client.HttpTransportPipe.processRequest(HttpTransportPipe.java:93)
         at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:598)
         at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:557)
         at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:542)
         at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:439)
         at com.sun.xml.ws.client.Stub.process(Stub.java:222)
         at com.sun.xml.ws.client.sei.SEIStub.doProcess(SEIStub.java:135)
         at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:109)
         at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:89)
         at com.sun.xml.ws.client.sei.SEIStub.invoke(SEIStub.java:118)
         at $Proxy36.xxxxxxxxxxx(Unknown Source)
         at xxxxxxxxServisImpl.xxxxxxxxxxxxx(xxxxServisImpl.java:69)
         at xxxxxxxxxServisTest.testxxxxxxx(xxxxxxServisTest.java:57)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:585)
         at junit.framework.TestCase.runTest(TestCase.java:154)
         at junit.framework.TestCase.runBare(TestCase.java:127)
         at org.springframework.test.ConditionalTestCase.runBare(ConditionalTestCase.java:69)
         at junit.framework.TestResult$1.protect(TestResult.java:106)
         at junit.framework.TestResult.runProtected(TestResult.java:124)
         at junit.framework.TestResult.run(TestResult.java:109)
         at junit.framework.TestCase.run(TestCase.java:118)
         at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
         at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
         at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)( i have changed some unnecessary parts with "xxxxxx" )
    The basic of it i get an "*HTTP 302*" which means it tries to redirect the request.
    Also i had an working copy of a sample Client which was written with Jax-RPC. I looked the generated SOAP Messages for both of clients, they was almostly the same.
    After lots of tries, i found the problem, somehow after the client application starts, it changes the Endpoint Address "https://xxxxxxxx.com/xxxx.asmx" to "http://xxxxxxxxx.com/xxx.asmx", ( it drops the "s" wich means it changes the protocol HTTPS to HTTP ).
    If i set the Endpoint Address to "https://xxxxxxxx.com/xxxx.asmx" before calling any service on port, it works as it should be.
    On the "generated" main WebServiceClient class the WSDL address and also Endpoint Address were set correctly ( with https ).
    Also do i missing any logical part of it? Because i didnt changed it, it generated from WSDL by using "wsimport", it couldnt be a mistake, of if it would be, somebody could see that.
    Thanks for any advice.
    Umut KUNDUKAN

    Welcome to the forum. Please don't post in threads that are long dead. When you have a question, start your own topic. Feel free to provide a link to an old post that may be relevant to your problem.
    I'm locking this thread now.

  • Session Bean Client Hangs when one Server in Cluster Fails

    We are testing several failure scenarios and one has come up that concerns us.
    Some background: Were running a WLS6.1 cluster on two separate machines. We
    start a test client consisting of 50 active threads and let them start calling
    into a session bean. After a couple minutes we pull the network plug out of one
    of the machines to simulate an uncontrolled crash of the machine. Once the plug
    is pulled the clients hang and of more concern any new clients that we startup
    also hang. Has anyone successfully solved this problem?

    When we kill one of Weblogic instances in the cluster none of the clients fail.
    All of our clients fail-over to the remaining servers. It's pulling the network
    plug to our of the server that causes everything to hang. Not just or test client,
    but the other servers in the cluster hang. The control panel doesn't respond
    at all either. We currently have a support case open with BEA #348184 about this.
    We've gotten a prompt response in which we were asked to modify our configuration
    by deploying our beans to each individual server rather than the cluster. We
    did this, but the results so far have not changed.
    Thanks for the feedback,
    Howard.
    "Ade Barkah" <[email protected]> wrote:
    We haven't encountered something like that, so it could be a setup problem.
    Can you verify that the t3 url hostname the client threads use resolves
    to the
    ip addresses of each machine in the cluster? Are all machines in the
    cluster
    listening at the same port number? Also, does it matter if you kill one
    of the
    weblogic processes instead of pulling the plug? (i.e., if you leave the
    network
    layer up?)
    Check also that your threads aren't simply blocking each other when the
    server
    goes down? E.g. start multiple test client processes with one thread
    each just
    to test.
    What we notice is (with round-robin cluster policy), as we bring down
    one of
    the servers, the clients will continue to work on the second server,
    but will slow
    down between method invocations as they still attempt to connect to the
    downed
    server.
    After a short period of time (~30 seconds) the clients will fully switch
    to the
    second machine and processing continues at full speed again, until the
    downed
    machine is brought back up, at which point work is distributed evenly
    again.
    Also, when the first server is brought down, some of the clients may
    terminate
    with a PeerGoneException (or something similar to that.) So unless your
    threads
    are catching exceptions, they might terminate as well.
    regards,
    -Ade
    "howard spector" <[email protected]> wrote in message news:[email protected]...
    We are testing several failure scenarios and one has come up that concernsus.
    Some background: Were running a WLS6.1 cluster on two separate machines.We
    start a test client consisting of 50 active threads and let them startcalling
    into a session bean. After a couple minutes we pull the network plugout of one
    of the machines to simulate an uncontrolled crash of the machine. Once the plug
    is pulled the clients hang and of more concern any new clients thatwe startup
    also hang. Has anyone successfully solved this problem?

  • JAX-WS client error when calling web method

    My JAX-WS client is getting the following error when calling a web method:
    Exception in thread "main" javax.xml.ws.WebServiceException:
    No Content-type in the header!
    I'm using Eclipse as my development environment. I use the CXF facet to generate a WSDL from Java code. I then use the New -> Web Service Client to generate client side code from the WSDL.
    The following fully describes my environment:
    Windows XP
    JDK 1.6.0_22
    Java EE 6
    Eclipse Helios
    Apache CXF 2.3.0 (runtime)
    Tomcat 6.0
    I have found several post on the net that describe this problem and a solution for JBoss, but I have been unable to find anything that addresses this error on Tomcat.
    I can provide source code if needed. The app is a simple Hello World web service. I'm using it to try and get familiar with developing web services with all the components listed above.
    Thanks

    Hi Anders,
    The resolution of the crossdomain problem is not to store an cross-domain-policy file at the [SAP] webservice side; but instead it needs to be done at the (every...) webservice client. In case the client is an IIS based webapplication (and thus the ultimate end-users are accessing it via their browser), this is not such an issue. It there is sufficient to put an crossdomain.xml policy file in the IIS main virtual root of your 'client' .net webapplication (c:\inetpub\wwwroot). It also can be required or at least helpful to put a clientaccesspolicy.xml file; both at the main virtual root and in the virtual root of the specific webapplication
    In case of SharePoint application, the crossdomain.xml file must be stored in the WSS virtual root of that site; c:\inetpub\wwwroot\wss\virtualdirectories\<your SharePoint webapp>
    Best regards, William.

  • ActiveMQ-CPP client hangs when connect ActiveMQ-CPP client & OpenMQ broker

    I am trying to connect an ActiveMQ-CPP client with an Oracle OpenMQ broker via STOMP. Both manufacturers claim this will work, and I have been able to get an ActiveMQ-CPP client to connect to an ActiveMQ broker via STOMP, an OpenMQ client with an OpenMQ broker via STOMP, and an OpenMQ client with an ActiveMQ broker via STOMP without problems, but the only one missing is what I need- ActiveMQ-CPP client to connect with OpenMQ broker.
    I am using Fedora Linux and am using the provided "example" script for ActiveMQ-CPP, changing the brokerURL to be "tcp://localhost:61613?wireFormat=stomp" instead, where the OpenMQ STOMP bridge is located at localhost:61613.
    On the OpenMQ end, I receive the request to connect by the client and I start a connection:
    INFO: Create JMS connection for user admin with client id ID:csa-nexus-57767-1281630228652-1:0
    Aug 12, 2010 8:23:48 AM
    INFO: Started JMS connection 8950669406784000768[ID:csa-nexus-57767-1281630228652-1:0] for user admin
    This is where the ActiveMQ-CPP client hangs at "connection->start", or if this is removed, "connection->createSession".
    Any help would be appreciated. Thanks!

    I need to use ActiveMQ-CPP because I need a C++ messaging client which supports failover, which OpenMQ's C client does not. I thought it was unlikely that it wouldn't be able to connect as well. I can't find a good way to debug the ActiveMQ-CPP client enough to know whether the problem is on the ActiveMQ-CPP client's end or the OpenMQ broker's end.
    Here is the source code for installing ActiveMQ-CPP, that is how you install it: http://activemq.apache.org/cms/activemq-cpp-322-release.html.
    The example comes bundled with ActiveMQ-CPP installation, but I'll show you parts of the main.cpp file that does all of the work:
    class HelloWorldConsumer : public ExceptionListener,
    public MessageListener,
    public Runnable {
    private:
    this->brokerURI = brokerURI;
    virtual ~HelloWorldConsumer(){
    cleanup();
    void close() {
    this->cleanup();
    void waitUntilReady() {
    latch.await();
    virtual void run() {
    try {
    auto_ptr<ConnectionFactory> connectionFactory( ConnectionFactory::createCMSConnectionFactory( brokerURI ) );
    // Create a Connection
    connection = connectionFactory->createConnection("admin", "admin");
    connection->start();
    connection->setExceptionListener(this);
    // Create a Session
    if( this->sessionTransacted == true ) {
    session = connection->createSession( Session::SESSION_TRANSACTED );
    } else {
    session = connection->createSession( Session::AUTO_ACKNOWLEDGE );
    // Create the destination (Topic or Queue)
    if( useTopic ) {
    destination = session->createTopic( "TEST.FOO" );
    } else {
    destination = session->createQueue( "TEST.FOO" );
    // Create a MessageConsumer from the Session to the Topic or Queue
    consumer = session->createConsumer( destination );
    consumer->setMessageListener( this );
    std::cout.flush();
    std::cerr.flush();
    // Indicate we are ready for messages.
    latch.countDown();
    // Wait while asynchronous messages come in.
    doneLatch.await( waitMillis );
    } catch( CMSException& e ) {
    // Indicate we are ready for messages.
    latch.countDown();
    e.printStackTrace();
    // Called from the consumer since this class is a registered MessageListener.
    virtual void onMessage( const Message* message ){
    static int count = 0;
    try
    count++;
    const TextMessage* textMessage =
    dynamic_cast< const TextMessage* >( message );
    string text = "";
    if( textMessage != NULL ) {
    text = textMessage->getText();
    } else {
    text = "NOT A TEXTMESSAGE!";
    printf( "Message #%d Received: %s\n", count, text.c_str() );
    } catch (CMSException& e) {
    e.printStackTrace();
    // Commit all messages.
    if( this->sessionTransacted ) {
    session->commit();
    // No matter what, tag the count down latch until done.
    doneLatch.countDown();
    // If something bad happens you see it here as this class is also been
    // registered as an ExceptionListener with the connection.
    virtual void onException( const CMSException& ex AMQCPP_UNUSED) {
    printf("CMS Exception occurred. Shutting down client.\n");
    ex.printStackTrace();
    exit(1);
    int main(int argc AMQCPP_UNUSED, char* argv[] AMQCPP_UNUSED) {
    activemq::library::ActiveMQCPP::initializeLibrary();
    std::cout << "=====================================================\n";
    std::cout << "Starting the example:" << std::endl;
    std::cout << "-----------------------------------------------------\n";
    std::string brokerURI =
    "tcp://localhost:61613"
    "?wireFormat=stomp"
    // "&soConnectTimeout=5"
    // "&connection.sendTimeout=5"
    // "&connection.useAsyncSend=true"
    // "&transport.useInactivityMonitor=false"
    // "&connection.alwaysSyncSend=true"
    // "&connection.useAsyncSend=true"
    // "&transport.commandTracingEnabled=true"
    // "&transport.tcpTracingEnabled=true"
    // "&wireFormat.tightEncodingEnabled=true"
    //============================================================
    // set to true to use topics instead of queues
    // Note in the code above that this causes createTopic or
    // createQueue to be used in both consumer an producer.
    //============================================================
    bool useTopics = true;
    bool sessionTransacted = false;
    int numMessages = 2000;
    long long startTime = System::currentTimeMillis();
    HelloWorldProducer producer( brokerURI, numMessages, useTopics );
    HelloWorldConsumer consumer( brokerURI, numMessages, useTopics, sessionTransacted );
    // Start the consumer thread.
    Thread consumerThread( &consumer );
    consumerThread.start();
    // Wait for the consumer to indicate that its ready to go.
    consumer.waitUntilReady();
    // Start the producer thread.
    Thread producerThread( &producer );
    producerThread.start();
    // Wait for the threads to complete.
    producerThread.join();
    consumerThread.join();
    long long endTime = System::currentTimeMillis();
    double totalTime = (double)(endTime - startTime) / 1000.0;
    consumer.close();
    producer.close();
    std::cout << "Time to completion = " << totalTime << " seconds." << std::endl;
    std::cout << "-----------------------------------------------------\n";
    std::cout << "Finished with the example." << std::endl;
    std::cout << "=====================================================\n";
    activemq::library::ActiveMQCPP::shutdownLibrary();
    // END SNIPPET: demo The places where the code will hang upon connection are "connection->start() and connection->createSession()". Again, this happens with any ActiveMQ client, no matter the language, and via Stomp, both should be supported. But using an OpenMQ client with ActiveMQ broker works perfectly. And using this code with its own ActiveMQ broker still via Stomp works perfectly as well.
    Thanks!

  • Swing client hangs for ever

    The swing client is hanging for ever with the following trace. Kindly provide me any information you may be having related to this issue. Thanks much.
    java.lang.Object.wait(Native Method)
    java.lang.Object.wait(Unknown Source)
    javax.swing.text.AbstractDocument.readLock(Unknown Source)
    javax.swing.plaf.basic.BasicTextUI.getPreferredSize(Unknown Source)
    javax.swing.JComponent.getPreferredSize(Unknown Source)
    javax.swing.JEditorPane.getPreferredSize(Unknown Source)
    java.awt.GridBagLayout.GetLayoutInfo(Unknown Source)
    java.awt.GridBagLayout.getLayoutInfo(Unknown Source)
    java.awt.GridBagLayout.preferredLayoutSize(Unknown Source)
    java.awt.Container.preferredSize(Unknown Source)
    java.awt.Container.getPreferredSize(Unknown Source)
    javax.swing.JComponent.getPreferredSize(Unknown Source)
    java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
    java.awt.Container.preferredSize(Unknown Source)
    java.awt.Container.getPreferredSize(Unknown Source)
    javax.swing.JComponent.getPreferredSize(Unknown Source)
    javax.swing.JRootPane$RootLayout.preferredLayoutSize(Unknown Source)
    java.awt.Container.preferredSize(Unknown Source)
    java.awt.Container.getPreferredSize(Unknown Source)
    javax.swing.JComponent.getPreferredSize(Unknown Source)
    java.awt.BorderLayout.preferredLayoutSize(Unknown Source)
    java.awt.Container.preferredSize(Unknown Source)
    java.awt.Container.getPreferredSize(Unknown Source)
    java.awt.Window.pack(Unknown Source)

    Hi,
    pack() is not getting called from event dispatch thread. This is getting called from a modal dialog which tries to display itself from the constructor of it.
    At this time the EventQueue thread is having the following trace,
    Thread::: Thread[AWT-EventQueue-2,6,javawsApplicationThreadGroup]
    java.awt.Component.invalidate(Unknown Source)
    java.awt.Container.invalidate(Unknown Source)
    javax.swing.JComponent.revalidate(Unknown Source)
    javax.swing.plaf.basic.BasicTextUI$RootView.preferenceChanged(Unknown Source)
    javax.swing.text.View.preferenceChanged(Unknown Source)
    javax.swing.text.BoxView.preferenceChanged(Unknown Source)
    javax.swing.text.View.preferenceChanged(Unknown Source)
    javax.swing.text.BoxView.preferenceChanged(Unknown Source)
    javax.swing.text.View.preferenceChanged(Unknown Source)
    javax.swing.text.BoxView.preferenceChanged(Unknown Source)
    javax.swing.text.View.preferenceChanged(Unknown Source)
    javax.swing.text.View.preferenceChanged(Unknown Source)
    javax.swing.text.GlyphView.changedUpdate(Unknown Source)
    javax.swing.text.LabelView.changedUpdate(Unknown Source)
    javax.swing.text.html.InlineView.changedUpdate(Unknown Source)
    javax.swing.text.View.forwardUpdateToView(Unknown Source)
    javax.swing.text.FlowView$LogicalView.forwardUpdateToView(Unknown Source)
    javax.swing.text.View.forwardUpdate(Unknown Source)
    javax.swing.text.View.changedUpdate(Unknown Source)
    javax.swing.text.FlowView.changedUpdate(Unknown Source)
    javax.swing.text.ParagraphView.changedUpdate(Unknown Source)
    javax.swing.text.View.forwardUpdateToView(Unknown Source)
    javax.swing.text.View.forwardUpdate(Unknown Source)
    javax.swing.text.BoxView.forwardUpdate(Unknown Source)
    javax.swing.text.View.changedUpdate(Unknown Source)
    javax.swing.text.html.BlockView.changedUpdate(Unknown Source)
    javax.swing.text.View.forwardUpdateToView(Unknown Source)
    javax.swing.text.View.forwardUpdate(Unknown Source)
    javax.swing.text.BoxView.forwardUpdate(Unknown Source)
    javax.swing.text.View.changedUpdate(Unknown Source)
    javax.swing.text.html.BlockView.changedUpdate(Unknown Source)
    javax.swing.plaf.basic.BasicTextUI$RootView.changedUpdate(Unknown Source)
    javax.swing.plaf.basic.BasicTextUI$UpdateHandler.changedUpdate(Unknown Source)
    javax.swing.text.AbstractDocument.fireChangedUpdate(Unknown Source)
    javax.swing.text.html.HTMLDocument.fireChangedUpdate(Unknown Source)
    javax.swing.text.DefaultStyledDocument$ChangeUpdateRunnable.run(Unknown Source)
    java.awt.event.InvocationEvent.dispatch(Unknown Source)
    java.awt.EventQueue.dispatchEvent(Unknown Source)
    And, whenever a client hang happens I am seeing both the stack traces in the thread dump.

  • JAX-WS Client throws NULL Pointer Exception in NW 7.1 SP3 and higher

    All,
    My JAX-WS client is throwing an exception when attempting to create a client to connect to the calculation service. The exception is coming out of the core JAX-WS classes that are part of NetWeaver. (see exception below)
    Caused by: java.lang.NullPointerException
         at com.sap.engine.services.webservices.espbase.client.jaxws.core.SAPServiceDelegate.createDispatchContextExistingPort(SAPServiceDelegate.java:440)
         at com.sap.engine.services.webservices.espbase.client.jaxws.core.SAPServiceDelegate.createDispatchContext(SAPServiceDelegate.java:475)
         at com.sap.engine.services.webservices.espbase.client.jaxws.core.SAPServiceDelegate.createDispatch(SAPServiceDelegate.java:492)
         at com.sap.engine.services.webservices.espbase.client.jaxws.core.SAPServiceDelegate.createDispatch(SAPServiceDelegate.java:484)
         at javax.xml.ws.Service.createDispatch(Service.java:166)
    I have done some research and it appears that as of NetWeaver 7.1 SP3 SAP stopped using the SUN JAX-WS runtime and implemented their own SAP JAX-WS runtime. I also took the time to decompile the jar file that contained the SAPServiceDelegate class which is throwing the null pointer exception. (see method from SAPServiceDelegate below)
        private ClientConfigurationContext createDispatchContextExistingPort(QName portName, JAXBContext jaxbContext)
            BindingData bindingData;
            InterfaceMapping interfaceMap;
            InterfaceData interfaceData;
            bindingData = clientServiceCtx.getServiceData().getBindingData(portName);
            if(bindingData == null)
                throw new WebServiceException((new StringBuilder()).append("Binding data '").append(portName.toString()).append("' is missing!").toString());
            QName bindingQName = new QName(bindingData.getBindingNamespace(), bindingData.getBindingName());
            interfaceMap = getInterfaceMapping(bindingQName, clientServiceCtx);
            interfaceData = getInterfaceData(interfaceMap.getPortType());
            ClientConfigurationContext result = DynamicServiceImpl.createClientConfiguration(bindingData, interfaceData, interfaceMap, null, jaxbContext, getClass().getClassLoader(), clientServiceCtx, new SOAPTransportBinding(), false, 1);
            return result;
            WebserviceClientException x;
            x;
            throw new WebServiceException(x);
    The exception is being throw on the line where the interfaceMap.getPortType() is being passed into the getInterfaceData method. I checked the getInterfaceMapping method which returns the interfaceMap (line above the line throwing the exception). This method returns NULL if an interface cannot be found. (see getInterfaceMapping method  below)
       public static InterfaceMapping getInterfaceMapping(QName bindingQName, ClientServiceContext context)
            InterfaceMapping interfaces[] = context.getMappingRules().getInterface();
            for(int i = 0; i < interfaces.length; i++)
                if(bindingQName.equals(interfaces<i>.getBindingQName()))
                    return interfaces<i>;
            return null;
    What appears to be happening is that the getInterfaceMapping method returns NULL then the next line in the createDispatchContextExistingPort method attempts to call the getPortType() method on a NULL and throws the Null Pointer Exception.
    I have included the code we use to create a client below. It works fine on all the platforms we support with the exception of NetWeaver 7.1 SP3 and higher (I already checked SP5 as well)
          //Create URL for service WSDL
          URL serviceURL = new URL(null, wsEndpointWSDL);
          //create service qname
          QName serviceQName = new QName(targetNamespace, "WSService");
          //create port qname
          QName portQName = new QName(targetNamespace, "WSPortName");
          //create service
          Service service = Service.create(serviceURL, serviceQName);
          //create dispatch on port
          serviceDispatch = service.createDispatch(portQName, Source.class, Service.Mode.PAYLOAD);
    What do I need to change in order to create a JAX-WS dispatch client on top of the SAP JAX-WS runtime?

    Hi Guys,
    I am getting the same error. Any resolution or updates on this.
    Were you able to fix this error.
    Thanks,
    Yomesh

  • JAX-RPC client access a JAX-WS services

    Hello all,
    There is a little problem I had with webservices and googling for a solution has not help so far.
    I am accessing a JAX-WS webservice from a J2SE 1.4.2 JAX-RPC client application and getting a NoSuchMethodError error from one of the stubs at runtime. The method call is rather a HelloWorld concept but it has not been possible.
    This are the step I took (I am using netbeans 6.0).
    1. I downloaded the JAX-RPC plugin on netbeans
    2. Download the stubs using the wsdl url. I am using the netbeans wizard for this process.
    3. Write my code for get a handle to the endpoint. Using the ServiceFactory.loadClass().
    4. Call the method on the
    Can anyone please help me.

    To make things a little more clearer, this is a post of the error gotten at runtime...
            java.lang.NoSuchMethodError: java.util.Collections.emptyList()Ljava/util/List;
            at com.sun.xml.messaging.saaj.soap.MessageImpl.<clinit>(MessageImpl.java:755)
            at com.sun.xml.messaging.saaj.soap.ver1_1.SOAPMessageFactory1_1Impl.createMessage(SOAPMessageFactory1_1Impl.java:47)
            at com.sun.xml.rpc.soap.message.SOAPMessageContext.createMessage(SOAPMessageContext.java:137)
            at com.sun.xml.rpc.client.StreamingSenderState.<init>(StreamingSenderState.java:30)
            at com.sun.xml.rpc.client.StubBase._start(StubBase.java:92)
            at mck.practise.oracle.plsql.PlsqlService_Stub.sayHello(PlsqlService_Stub.java:54)
            at mck.practise.oracle.plsql.HelloWorld.sayRPCHello(HelloWorld.java:34)
            at mck.practise.oracle.plsql.HelloWorld.main(HelloWorld.java:22)The suprising thing is that if I change the application's java platform from JDK 1.4 to Java 5 using the netbeans projects property window, everything works fine.
    Can anyone still suggest on this.
    Regards,

  • EJB client spawning threads

    We've got problems with respect to the number of EJB client threads (ExecuteThread) spawned by WebLogic in a client JVM. As the number of threads increase (~1700 in a JVM with 512Mb of memory and 2 hours of uptime), the JVM performance degrades substantially - although almost all these threads are waiting for requests, as one can see in the thread dump attached bellow.
    This problem happens in an integration scenario involving both WebLogic (8.1 and 6.1 as service providers) and webMethods Integration Server (version 6.0.1); the webMethods EJB adapter (version 1.2) acts like EJB client from the WebLogic instances, and the "EJB client spawning threads" can be detected by thread dumps extracted from the Integration Server JVM. The URL property from the wm EJB adapter has been setup as t3://server:port. The Integration Server runs with Java HotSpot(TM) Server VM (build 1.4.2 1.4.2.02-040225-19:18-PA_RISC2.0 PA2.0 (aCC_AP), mixed mode) JRE in HP-UX (11.11) environment.
    Although we couldn't reproduce this problem in a prod like environemnt, we'd identified that initially, WebLogic (weblogic.jar from WebLogic 6.1) spawns 5 ExecuteThreads plus 3 additional threads (TimeEventGenerator, SpinnerRandomSource and HighPriority TimeEventGenerator) in the first access of an EJB not matter the instance used, as well as two new threads (ExecuteThread) for each access to new WebLogic instances (different from previously accessed WebLogic instances). With weblogic.jar from the WebLogic 8.1 SP4 the behavior is slightly different: from the second instance access toward, only two new Threads (ExecuteThread in weblogic.JavaSocketReaders queue) are created.
    We have also noticed that this problem should not be reflect of context classloaders because the counter of the ExecuteThread for the default pool only increases; in case of a pool cached in separate context classloaders, we should see "duplicate" threads with the same counter (starting with 0), which is not the case.
    The questions are 1) why weblogic is spawning so much threads; 2) is there any setup/config to limit the number of WebLogic threads in the client context ?
    Excerpt from the thread dump:
    Full thread dump Java HotSpot(TM) Server VM (1.4.2 1.4.2.02-040225-19:18-PA_RISC2.0 PA2.0 (aCC_AP) mixed mode):
    "ExecuteThread: '1749' for queue: 'default'" daemon prio=10 tid=05734140 nid=4813 lwp_id=583942 in Object.wait() [0x0dfbe000..0x0dfbe4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4a5ef9f0> (a weblogic.common.internal.DynaQueue)
         at weblogic.common.internal.DynaQueue.getW(DynaQueue.java:228)
         - locked <4a5ef9f0> (a weblogic.common.internal.DynaQueue)
         at weblogic.socket.JavaSocketMuxer.processSockets2(JavaSocketMuxer.java:252)
         at weblogic.socket.JavaSocketMuxer.processSockets(JavaSocketMuxer.java:233)
         at weblogic.socket.SocketReaderRequest.execute(SocketReaderRequest.java:24)
         at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
    "ExecuteThread: '1742' for queue: 'default'" daemon prio=10 tid=04c263f0 nid=4812 lwp_id=583845 runnable [0x06449000..0x064494f0]
         at java.net.SocketInputStream.socketRead0(Native Method)
         at java.net.SocketInputStream.read(SocketInputStream.java:129)
         at weblogic.socket.JavaSocketMuxer.processSockets2(JavaSocketMuxer.java:281)
         - locked <4a5ee690> (a java.net.Socket)
         at weblogic.socket.JavaSocketMuxer.processSockets(JavaSocketMuxer.java:233)
         at weblogic.socket.SocketReaderRequest.execute(SocketReaderRequest.java:24)
         at weblogic.kernel.ExecuteThread.execute(ExecuteThread.java:139)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:120)
    "ExecuteThread: '1735' for queue: 'default'" daemon prio=10 tid=05733fd8 nid=4811 lwp_id=583784 in Object.wait() [0x064ca000..0x064ca4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4c40a6b8> (a weblogic.kernel.ExecuteThread)
         at java.lang.Object.wait(Object.java:429)
         at weblogic.kernel.ExecuteThread.waitForRequest(ExecuteThread.java:94)
         - locked <4c40a6b8> (a weblogic.kernel.ExecuteThread)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:118)
    "ExecuteThread: '1734' for queue: 'default'" daemon prio=10 tid=01ecd940 nid=4810 lwp_id=583783 in Object.wait() [0x0654b000..0x0654b4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4c40a728> (a weblogic.kernel.ExecuteThread)
         at java.lang.Object.wait(Object.java:429)
         at weblogic.kernel.ExecuteThread.waitForRequest(ExecuteThread.java:94)
         - locked <4c40a728> (a weblogic.kernel.ExecuteThread)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:118)
    "ExecuteThread: '1733' for queue: 'default'" daemon prio=10 tid=05733e70 nid=4806 lwp_id=583777 in Object.wait() [0x066ce000..0x066ce4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4c40a798> (a weblogic.kernel.ExecuteThread)
         at java.lang.Object.wait(Object.java:429)
         at weblogic.kernel.ExecuteThread.waitForRequest(ExecuteThread.java:94)
         - locked <4c40a798> (a weblogic.kernel.ExecuteThread)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:118)
    "ExecuteThread: '1732' for queue: 'default'" daemon prio=10 tid=01ecd7d8 nid=4801 lwp_id=583771 in Object.wait() [0x065cc000..0x065cc4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4c40a808> (a weblogic.kernel.ExecuteThread)
         at java.lang.Object.wait(Object.java:429)
         at weblogic.kernel.ExecuteThread.waitForRequest(ExecuteThread.java:94)
         - locked <4c40a808> (a weblogic.kernel.ExecuteThread)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:118)
    "ExecuteThread: '1731' for queue: 'default'" daemon prio=10 tid=05733d08 nid=4798 lwp_id=583766 in Object.wait() [0x067d0000..0x067d04f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4c40a878> (a weblogic.kernel.ExecuteThread)
         at java.lang.Object.wait(Object.java:429)
         at weblogic.kernel.ExecuteThread.waitForRequest(ExecuteThread.java:94)
         - locked <4c40a878> (a weblogic.kernel.ExecuteThread)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:118)
    ... (cut for brevity)
    "ExecuteThread: '2' for queue: 'default'" daemon prio=10 tid=009251b8 nid=172 lwp_id=569500 in Object.wait() [0x3d61f000..0x3d61f4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4a5b4498> (a weblogic.kernel.ExecuteThread)
         at java.lang.Object.wait(Object.java:429)
         at weblogic.kernel.ExecuteThread.waitForRequest(ExecuteThread.java:94)
         - locked <4a5b4498> (a weblogic.kernel.ExecuteThread)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:118)
    "ExecuteThread: '1' for queue: 'default'" daemon prio=10 tid=00924ee8 nid=171 lwp_id=569499 in Object.wait() [0x3d6a0000..0x3d6a04f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4a5b40f0> (a weblogic.kernel.ExecuteThread)
         at java.lang.Object.wait(Object.java:429)
         at weblogic.kernel.ExecuteThread.waitForRequest(ExecuteThread.java:94)
         - locked <4a5b40f0> (a weblogic.kernel.ExecuteThread)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:118)
    "ExecuteThread: '0' for queue: 'default'" daemon prio=10 tid=00925050 nid=170 lwp_id=569498 in Object.wait() [0x3d7a2000..0x3d7a24f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <4a5b3d48> (a weblogic.kernel.ExecuteThread)
         at java.lang.Object.wait(Object.java:429)
         at weblogic.kernel.ExecuteThread.waitForRequest(ExecuteThread.java:94)
         - locked <4a5b3d48> (a weblogic.kernel.ExecuteThread)
         at weblogic.kernel.ExecuteThread.run(ExecuteThread.java:118)
    "Thread-2" daemon prio=10 tid=00bec5f0 nid=18 lwp_id=569246 in Object.wait() [0x41e2e000..0x41e2e4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c14ff0> (a com.wm.app.repov4.server.RepoServer$RepoLockTimeoutMgr)
         at com.wm.app.repov4.server.RepoServer$RepoLockTimeoutMgr.run(RepoServer.java:1533)
         - locked <46c14ff0> (a com.wm.app.repov4.server.RepoServer$RepoLockTimeoutMgr)
    "Thread-1" daemon prio=10 tid=00bec488 nid=17 lwp_id=569244 in Object.wait() [0x41eaf000..0x41eaf4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c150a8> (a com.wm.driver.queue.data.DataQueue)
         at java.lang.Object.wait(Object.java:429)
         at com.wm.driver.queue.data.DataQueue.dequeue(DataQueue.java:310)
         - locked <46c150a8> (a com.wm.driver.queue.data.DataQueue)
         at com.wm.driver.queue.data.DataQueue.dequeueCommit(DataQueue.java:260)
         - locked <46c150a8> (a com.wm.driver.queue.data.DataQueue)
         at com.wm.driver.queue.data.DataQueue.dequeueCommit(DataQueue.java:254)
         - locked <46c150a8> (a com.wm.driver.queue.data.DataQueue)
         at com.wm.app.repov4.server.RepoServerBase$RepoEventManager.run(RepoServerBase.java:224)
    "Log Thread" prio=10 tid=00bec320 nid=16 lwp_id=569243 in Object.wait() [0x41f30000..0x41f304f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c15120> (a com.wm.util.sync.SimpleQueue)
         at com.wm.util.sync.SimpleQueue.deq(SimpleQueue.java:171)
         - locked <46c15120> (a com.wm.util.sync.SimpleQueue)
         at com.wm.util.sync.SimpleQueue.deq(SimpleQueue.java:126)
         - locked <46c15120> (a com.wm.util.sync.SimpleQueue)
         at com.wm.app.b2b.server.ServerLogHandler$LogThread.run(ServerLogHandler.java:268)
    "Cron Daemon" prio=10 tid=00bec1b8 nid=15 lwp_id=569241 in Object.wait() [0x41fb1000..0x41fb14f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c15190> (a java.util.Vector)
         at com.wm.util.Cron.run(Cron.java:424)
         - locked <46c15190> (a java.util.Vector)
         at java.lang.Thread.run(Thread.java:534)
    "Cron Daemon Pool2" prio=10 tid=00bec050 nid=14 lwp_id=569240 in Object.wait() [0x42032000..0x420324f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c15268> (a com.wm.util.pool.PooledThread)
         at java.lang.Object.wait(Object.java:429)
         at com.wm.util.pool.PooledThread.run(PooledThread.java:103)
         - locked <46c15268> (a com.wm.util.pool.PooledThread)
         at java.lang.Thread.run(Thread.java:534)
    "Cron Daemon Pool1" prio=10 tid=00bebee8 nid=13 lwp_id=569239 in Object.wait() [0x420b3000..0x420b34f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c152d0> (a com.wm.util.pool.PooledThread)
         at java.lang.Object.wait(Object.java:429)
         at com.wm.util.pool.PooledThread.run(PooledThread.java:103)
         - locked <46c152d0> (a com.wm.util.pool.PooledThread)
         at java.lang.Thread.run(Thread.java:534)
    "webMethods Integration Server" prio=10 tid=000870e0 nid=12 lwp_id=569238 in Object.wait() [0x42134000..0x421344f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c152f0> (a com.wm.app.b2b.server.Server)
         at java.lang.Object.wait(Object.java:429)
         at com.wm.app.b2b.server.Server.run(Server.java:353)
         - locked <46c152f0> (a com.wm.app.b2b.server.Server)
    "Signal Dispatcher" daemon prio=10 tid=00086f78 nid=7 lwp_id=569231 waiting on condition [0x00000000..0xffffffff]
    "Finalizer" daemon prio=10 tid=00086e10 nid=5 lwp_id=569229 in Object.wait() [0x4293b000..0x4293b4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c15668> (a java.lang.ref.ReferenceQueue$Lock)
         at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:127)
         - locked <46c15668> (a java.lang.ref.ReferenceQueue$Lock)
         at java.lang.ref.ReferenceQueue.remove(ReferenceQueue.java:143)
         at java.lang.ref.Finalizer$FinalizerThread.run(Finalizer.java:188)
    "Reference Handler" daemon prio=10 tid=00086ca8 nid=4 lwp_id=569228 in Object.wait() [0x429bc000..0x429bc4f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c15340> (a java.lang.ref.Reference$Lock)
         at java.lang.Object.wait(Object.java:429)
         at java.lang.ref.Reference$ReferenceHandler.run(Reference.java:120)
         - locked <46c15340> (a java.lang.ref.Reference$Lock)
    "main" prio=10 tid=00086b40 nid=1 lwp_id=569222 in Object.wait() [0x68ff3000..0x68ff24f0]
         at java.lang.Object.wait(Native Method)
         - waiting on <46c152f0> (a com.wm.app.b2b.server.Server)
         at java.lang.Thread.join(Thread.java:1001)
         - locked <46c152f0> (a com.wm.app.b2b.server.Server)
         at java.lang.Thread.join(Thread.java:1054)
         at com.wm.app.b2b.server.Server.start(Server.java:141)
         at com.wm.app.b2b.server.Main.main(Main.java:40)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at com.wm.proxy.Proxy.invokeStaticMethod(Proxy.java:166)
         at com.wm.app.server.ServerProxy.ServerMain_main(ServerProxy.java:77)
         at com.wm.app.server.ServerApp.start(ServerApp.java:105)
         at com.wm.app.Application.launch(Application.java:490)
         at com.wm.app.server.Main.main(Main.java:50)
    "VM Thread" prio=7 tid=000167f8 nid=3 lwp_id=569227 runnable
    "VM Periodic Task Thread" prio=8 tid=00016908 nid=11 lwp_id=569235 waiting on condition
    "Suspend Checker Thread" prio=10 tid=00016880 nid=6 lwp_id=569230 runnable

    We already opened a case. Actually, we did reproduce the problem: it happens because there is a hardware load balancing between the client and the WebLogic Server.
    As far as I know, EJB load balancing can be done only with WebLogic clusters. Could you confirm that ?

  • JAX-RPC client with JDeveloper 12c

    Hello,
    It's the first time I use jax-rpc (I'm used to jax-ws) and looking for help.
    I need to create a client for a JAX-RPC web service using JDeveloper 12c.
    The customer provided to me a WSDL file (I don't have access to the webservice yet). In JDeveloper I created as usual a "Web Service Client and Proxy" providing that wsdl file, but I think the generated code is for a JAX-WS (since there are @WebMethod, @WebServiceClient and @WebService notations that I understood should not be present in JAX-RPC clients.
    Can anyone point me to some documentation about JAX-RPC client developing in JDeveloper 12?
    Thank you,
    Marco

    To make things a little more clearer, this is a post of the error gotten at runtime...
            java.lang.NoSuchMethodError: java.util.Collections.emptyList()Ljava/util/List;
            at com.sun.xml.messaging.saaj.soap.MessageImpl.<clinit>(MessageImpl.java:755)
            at com.sun.xml.messaging.saaj.soap.ver1_1.SOAPMessageFactory1_1Impl.createMessage(SOAPMessageFactory1_1Impl.java:47)
            at com.sun.xml.rpc.soap.message.SOAPMessageContext.createMessage(SOAPMessageContext.java:137)
            at com.sun.xml.rpc.client.StreamingSenderState.<init>(StreamingSenderState.java:30)
            at com.sun.xml.rpc.client.StubBase._start(StubBase.java:92)
            at mck.practise.oracle.plsql.PlsqlService_Stub.sayHello(PlsqlService_Stub.java:54)
            at mck.practise.oracle.plsql.HelloWorld.sayRPCHello(HelloWorld.java:34)
            at mck.practise.oracle.plsql.HelloWorld.main(HelloWorld.java:22)The suprising thing is that if I change the application's java platform from JDK 1.4 to Java 5 using the netbeans projects property window, everything works fine.
    Can anyone still suggest on this.
    Regards,

  • Deploying JAX-RPC Client for client-side application

    I have a java Swing client side application that I am attempting to integrate web services capabilities into. The web services were already written (new to web services myself), I am just calling them. Using Oracle's JDeveloper I managed to create proxies for the web services and to call them just fine, once I added the JAX-RPC Client library to my project.
    My only issue is how to deploy. Again within the development environment all works perfectly. I tried references to all the jar files identified by the Oracle JAX-RPC Client library to know luck. I've referenced other jar files I use for deployment with no issues.
    Anyone created standalone applciations before that call web services? How did you deploy the web service related libraries.
    I'm using JDeveloper 10.1.3.3.0 with Java 1.5.0_06.
    I appreciate any guidance provided.

    I found a solution, but it shouldn't have been that difficult. JDeveloper provides a view of what JARs are part of a library. I used that as a starting point of what JARs might be required for my instance. I switched to linking to the individual JARs within their JDeveloper installed locations directly instead of the single library. I then systematically starting removing them one-by-one from my list to determine which were actually being used in my implementation. I did this because there were way too many to deploy. Once that was done I created a separate directory for holding the required JARs files local to my application.
    Lastly, I had to take care of any internal references within the JARs that may link to other JAR files. So I opened each JAR and looked at its manifest and copied those files over. Then I repeated the steps of deternmining if they were really necessary and copying over other internal references until I had the complete list.
    In the end I ended up with a considerable smaller list of JARs then if I had just assumed all JARs within the library and their references. However, it was much more difficult then it needed to be.

  • JAX-RPC Client for VB-SoapToolkit3.0 WebService

    I need to develop a JAX-RPC client for a VB6.0 WebService (the WebService being generated through MS SoapToolkit3.0).
    I'm using JWSDP 1.0_01. The WSDL that the JWSDP is using to generate the stubs is the one generated by the MS SoapToolkit. My WebService
    has only one method (Public Test(xpto As String)As String) that receives and returns a string.
    So what's the problem:
    - JAX-RPC client sends a SOAP packet different than what the WebService expects, especially in the namespaces. JAX-RPC generates some strange namespaces, like xmlns:ns0="xpto" (xpto is the name of the argument of the WebService) or xmlns:ns1="Result xpto"
    - Looking at the JAX-RPC generated WebService interface, I see that instead of String, the method test receives a StringHolder (???). What's a string holder, and why isn't a String?
    The resumed message returned by the WebService:
    <mserror:description>WSDLReader:None of the matching operations for soapAction http://tempuri.org/Test/action/WS.Test could successfully load the incoming request. Potential typemapper problem HRESULT=0x80070057: The parameter is incorrect.
    - Server:One of the parameters supplied is invalid. HRESULT=0x80070057: The parameter is incorrect.
    </mserror:description>
    Any help would be apreciated.
    Thanks

    Can you send the WSDL that you used to generate the JAXRPC client?
    Thanks

  • Exception when running a JAX-WS client against a JAX-RPC service

    I have a JAX-WS client invoking a JAX-RPC web service on Weblogic 10.3. The service was originally built for Weblogic 9.2, it's been rebuilt and runs fine on 10.3.
    Some operations work fine, but invoking one operation results in the following exception:
    at secsvc.client.GetRolesForUserInApplicationResponse$JaxbAccessorF_role.get(Unknown Source)
         at com.sun.xml.internal.bind.v2.runtime.reflect.NullSafeAccessor.get(Unknown Source)
         at com.sun.xml.internal.bind.v2.runtime.reflect.Accessor.getUnadapted(Unknown Source)
         at com.sun.xml.internal.bind.v2.runtime.JAXBContextImpl$7.get(Unknown Source)
         at com.sun.xml.internal.ws.client.sei.ResponseBuilder$DocLit$PartBuilder.readResponse(Unknown Source)
         at com.sun.xml.internal.ws.client.sei.ResponseBuilder$DocLit.readResponse(Unknown Source)
         at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(Unknown Source)
         at com.sun.xml.internal.ws.client.sei.SyncMethodHandler.invoke(Unknown Source)
         at com.sun.xml.internal.ws.client.sei.SEIStub.invoke(Unknown Source)
         at $Proxy29.getRolesForUserInApplication(Unknown Source)
    This operation works fine if invoked by an RPC client.
    Any idea what's going on?
    Mikey

    Hi Jitu,
    I changed the wsdl. And so I don�t get the warning anymore. My Webservice also runs well, now. Thanks anyway for the reply.
    There is a nice tech article on the sun network, which solved my problem. The basic idea is to split the wsdl into 2 wsdl documents. one containing all the porttypes messages and so on. And the other wsdl contains the binding and service elements.
    If you are interested check out this link:
    http://java.sun.com/developer/technicalArticles/xml/jaxrpcpatterns/index2.html
    thanks,
    footman

  • Hanging threads in J2EE/Portal 7.0

    Hi,
    How to check/know the hanging threads in Portal 7.0 system
    what is the cause and avoid
    Thanks in advance

    Hi,
    Do you have Wily Intro-scope in your landscape?If yes then you can refer to this doc :
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/50973df5-e1d1-2c10-cf89-c177fbfd7e65?QuickLink=index&overridelayout=true
    Otherwise, you can goto NWA->Availability and Performance management-->Java system report or LogViewer and explore options there.
    Normally,i refer to Java system reports.
    Thanks,
    Ashutosh

  • How can I change namespace prefix for JAX-RPC client request?

    I'm creating a JAX-RPC client to invoke a RPC/encoded web service. The service was generated from a ColdFusion program and for some reason when the SOAP namespace prefix is anything but "soapenv" it returns text/html instead of text/xml. Currently the client is sending requests with the prefix "env" and I'd like to change it to "soapenv".
    I created a type of javax.xml.rpc.handler.GenericHandler and attempted to do the follow:
    @Override public boolean handleRequest(MessageContext p1) {
         SOAPMessage msg = ((SOAPMessageContext) p1).getMessage(); 
         try {
              SOAPPart part = msg.getSOAPPart();
              SOAPEnvelope envelope = part.getEnvelope(); 
              envelope.setPrefix("soapenv"); 
              msg.saveChanges(); 
         } catch(SOAPException ex) {
              // TODO
              return false;
         return true;
    However I get the following exception:
    java.rmi.RemoteException: SOAPFaultException - FaultCode [{http://schemas.xmlsoap.org/soap/envelope/}Server] FaultString [UNIMPLEMENTED ] FaultActor [null] Detail [<detail><bea_fault:stacktrace xmlns:bea_fault="http://www.bea.com/servers/wls70/webservice/fault/1.0.0">java.lang.AssertionError: UNIMPLEMENTED
    at weblogic.xml.domimpl.NodeImpl.setPrefix(NodeImpl.java:173)
    at test.MyHandler.handleRequest(MyHandler.java:33)
    at weblogic.wsee.handler.JaxrpcHandlerChain.handleRequest(JaxrpcHandlerChain.java:58)
    at weblogic.wsee.ws.dispatch.server.JaxrpcChainHandler.handleRequest(JaxrpcChainHandler.java:102)
    at weblogic.wsee.handler.HandlerIterator.handleRequest(HandlerIterator.java:141)
    at weblogic.wsee.handler.HandlerIterator.handleRequest(HandlerIterator.java:107)
    at weblogic.wsee.ws.dispatch.client.ClientDispatcher.dispatch(ClientDispatcher.java:132)
    at weblogic.wsee.ws.WsStub.invoke(WsStub.java:87)
    at weblogic.wsee.jaxrpc.StubImpl._invoke(StubImpl.java:341)
    at test.Approvedsuppliers_Wrap_Stub.echo(Approvedsuppliers_Wrap_Stub.java:31)
    at test.Approvedsuppliers_WrapPortClient.echo(Approvedsuppliers_WrapPortClient.java:130)
    at test.Approvedsuppliers_WrapPortClient.main(Approvedsuppliers_WrapPortClient.java:43)
    Is there any workaround? I appreciate any feedback.
    Thanks, Bill

    What I ended up doing is converting the SOAP message to a string, replacing the namespace prefix and converting it back to a SOAP message.
    @Override
       public boolean handleRequest(MessageContext messageContext) {
          SOAPMessageContext soapMessageContext = (SOAPMessageContext) messageContext;
          SOAPMessage soapMessage = soapMessageContext.getMessage();
          String soapString = convertSOAPToString(soapMessage);
          soapString = soapString.replaceAll("env:", "soapenv:");
          soapString = soapString.replaceAll("xmlns:env", "xmlns:soapenv");
          SOAPMessage newSoapMessage = convertStringToSOAP(soapString);
          MimeHeaders mimeHeader = newSoapMessage.getMimeHeaders();
          mimeHeader.setHeader("SOAPAction", "");
          soapMessageContext.setMessage(newSoapMessage);
          return true;
       private String convertSOAPToString(SOAPMessage soapMessage) {
          StringWriter stringWriter = null;
          try {
             stringWriter = new StringWriter();
             StreamResult streamResult = new StreamResult(stringWriter);
             TransformerFactory transformFactory = TransformerFactory.newInstance();
             Transformer transformer = transformFactory.newTransformer();
             transformer.transform(new DOMSource(soapMessage.getSOAPPart()), streamResult);
          } catch (TransformerException e) {
             throw new RuntimeException(e);
          } finally {
             close(stringWriter);
          return stringWriter.toString();   
       private SOAPMessage convertStringToSOAP(String soapString) {
          SOAPMessage soapMessage = null;
          ByteArrayInputStream byteInputStream = null;
          try {
             MessageFactory msgFactory = MessageFactory.newInstance();
             soapMessage = msgFactory.createMessage();
             SOAPPart soapPart = soapMessage.getSOAPPart();
             // Load the SOAP text into a stream source
             byte[] buffer = soapString.getBytes();
             byteInputStream = new ByteArrayInputStream(buffer);
             StreamSource source = new StreamSource(byteInputStream);
             // Set contents of message
             soapPart.setContent(source);       
          } catch (SOAPException e) {
             throw new RuntimeException(e);
          } finally {
             close(byteInputStream);
          return soapMessage;
       private void close(Closeable closeable) {
          if(closeable != null) {
             try {
                closeable.close();
             } catch (IOException e) {
                // TODO

Maybe you are looking for

  • Unable to create repository owner

    Hi whenever im trying to create a repository owner with SPRO_REP_OWNER Im getting an error as follows DBMS_JAVA.grant_permission is an unidentified identifier( im sorry i forgot the exact message.) I checked in the Database i found a synonym but i di

  • Big PDF files

    Why are the PDF files that come with some installed programs so big? For example, the "iMovie Getting Started" file is 23.3 megs while the exact same file downloaded off the support website is 1.2 megs. There's no obvious differences between them. Wh

  • Editable text scan

    using  hp officejet 8500  with window xp I was able to edit my scans.  Now using window 8.1 that menu is not available. The only download  was HP scan & capture.  Though it will scan photos and docs (only in pdf).  Is there a way to scan to editable

  • Create multiple single unit wip jobs for total sales order line qty

    Hi all, I want to know if there's a standard way to create multiple single unit wip jobs from a sales order line which has 2 or more units, i mean... I have a sales order line with item A with 3 units. If I progress the sales order, a single job is a

  • FRM-40501 Error and HeadStart 3.4.2W

    I'm migrating and old application made with Designer 1.3.2 and HeadStart 3.4.2W to Oracle 8i Release 8.1.6 and in many forms screens at commit time i'm receiving the message FRM-40501 "Unable to reserve records to update or delete". Any Clue, Anyone.