Jax-ws ws-addressings non-anonymous replyto header asynchronous client

Hi All,
I have an asynchronous jax-ws client with addressingfeature enabled.
This will add the replyto header as anonymous and open a client listening port for the reply message when I execute the asynchronous method to the server.
The client is then waiting for asynchronous reply from the server.
Although I don't know the listening "replyto" address, I can see with netstat that it is listening to a random opened port (TCP).
How can I make the client send the non-anonymous random generated replyto header with the port so that the server can reply to?
Kind Regards,
Tuno

Hi,
there is a bug in 11.1.1.3 which is fixed in 11.1.1.4. but I found a simple workaround.
I changed the web service annotation from the callback function for "@Adressing" from "true" to "false". e.g.
@WebService(targetNamespace="http://xmlns.oracle.com/SOAHelloApp/SOAHelloAsync/SOAHelloAsyncProcess", name="SOAHelloAsyncProcessCallback")
@XmlSeeAlso(
{ ObjectFactory.class })
@SOAPBinding(style=Style.DOCUMENT)
@Addressing(enabled=false, required=false)
so I still have the wrong wsa:Action, but nobody cares.
HTH

Similar Messages

  • Jax-ws 2.2.8 and ws-addressing: Client throwing java.lang.NullPointerException on receipt of HTTP 202 when using non-anonymous ReplyTo address

    Server: JBoss EAP 6.2.0
    Client: JDK 1.7.0_51 x64
    JAX-WS: RI 2.2.8 ( via -Djava.endorsed.dirs )
    I am getting a java.lang.NullPointerException when calling the operation on the WS endpoint from the client when using non-anonymous replyTo address.
    I have simplified the scenario into a small test case that hopefully others can replicate. Since the exception is happening on the client instead of the server, I would think that the container used is irrelevant, but I have specified it nonetheless.
    1) WebService:
    package test.webservice;
    import java.util.Random;
    import javax.jws.WebMethod;
    import javax.jws.WebParam;
    import javax.jws.WebService;
    import javax.jws.soap.SOAPBinding;
    import javax.xml.ws.soap.Addressing;
    @WebService(targetNamespace="http://services.nowhere.org/")
    @Addressing(required=true)
    @SOAPBinding(style = SOAPBinding.Style.DOCUMENT)
    public class RandomTest {
        @WebMethod
        public long nextRandom(@WebParam boolean forceException) throws Exception {
            if( forceException ) {
                throw new Exception("Some exception");
            Random rand = new Random();
            return rand.nextLong();
    2) Generated WSDL by JBossEAP 6.2.2:
    <?xml version='1.0' encoding='UTF-8'?><wsdl:definitions xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:wsp="http://www.w3.org/ns/ws-policy" xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:wsaw="http://www.w3.org/2006/05/addressing/wsdl" xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata" xmlns:tns="http://webservice.test/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:ns1="http://schemas.xmlsoap.org/soap/http" name="RandomTestService" targetNamespace="http://webservice.test/">
      <wsdl:types>
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:tns="http://webservice.test/" elementFormDefault="unqualified" targetNamespace="http://webservice.test/" version="1.0">
      <xs:element name="nextRandom" type="tns:nextRandom"/>
      <xs:element name="nextRandomResponse" type="tns:nextRandomResponse"/>
      <xs:complexType name="nextRandom">
        <xs:sequence/>
      </xs:complexType>
      <xs:complexType name="nextRandomResponse">
        <xs:sequence>
          <xs:element name="return" type="xs:long"/>
        </xs:sequence>
      </xs:complexType>
    </xs:schema>
      </wsdl:types>
      <wsdl:message name="nextRandom">
        <wsdl:part element="tns:nextRandom" name="parameters">
        </wsdl:part>
      </wsdl:message>
      <wsdl:message name="nextRandomResponse">
        <wsdl:part element="tns:nextRandomResponse" name="parameters">
        </wsdl:part>
      </wsdl:message>
      <wsdl:portType name="RandomTest">
        <wsdl:operation name="nextRandom">
          <wsdl:input message="tns:nextRandom" name="nextRandom" wsam:Action="http://webservice.test/RandomTest/nextRandomRequest" wsaw:Action="http://webservice.test/RandomTest/nextRandomRequest">
        </wsdl:input>
          <wsdl:output message="tns:nextRandomResponse" name="nextRandomResponse" wsam:Action="http://webservice.test/RandomTest/nextRandomResponse" wsaw:Action="http://webservice.test/RandomTest/nextRandomResponse">
        </wsdl:output>
        </wsdl:operation>
      </wsdl:portType>
      <wsdl:binding name="RandomTestServiceSoapBinding" type="tns:RandomTest">
        <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
        <wsaw:UsingAddressing wsdl:required="true"/>
        <wsp:PolicyReference URI="#RandomTestServiceSoapBinding_WSAM_Addressing_Policy"/>
        <wsdl:operation name="nextRandom">
          <soap:operation soapAction="" style="document"/>
          <wsdl:input name="nextRandom">
            <soap:body use="literal"/>
          </wsdl:input>
          <wsdl:output name="nextRandomResponse">
            <soap:body use="literal"/>
          </wsdl:output>
        </wsdl:operation>
      </wsdl:binding>
      <wsdl:service name="RandomTestService">
        <wsdl:port binding="tns:RandomTestServiceSoapBinding" name="RandomTestPort">
          <soap:address location="http://localhost:8080/servertest/RandomTest"/>
        </wsdl:port>
      </wsdl:service>
        <wsp:Policy xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" wsu:Id="RandomTestServiceSoapBinding_WSAM_Addressing_Policy"><wsam:Addressing><wsp:Policy/></wsam:Addressing></wsp:Policy>
    </wsdl:definitions>
    3) ant build.xml to generate the client code from WSDL
    <?xml version="1.0" encoding="UTF-8"?>
    <project default="build" basedir="..">
        <property name="jaxws.classpath" location="C://jaxws-2.2.8/jaxws-ri/lib/*.jar"/>
        <taskdef name="wsimport" classname="com.sun.tools.ws.ant.WsImport">
               <classpath path="${jaxws.classpath}"/>
        </taskdef>
        <target name="build" >
            <!-- For these to work, the JAR files in tools/jaxws-ri must be included in Ant's classpath -->
            <wsimport wsdl="http://localhost:8080/servertest/RandomTest?wsdl"
                   verbose="true"
                   sourcedestdir="src"
                   destdir="bin"
                   keep="true">
                   <xjcarg value="-enableIntrospection"/>
            </wsimport>
        </target>
    </project>
    4) Client code
    4a) ClientTest.java - Actual client run from client
    package test.wsclient;
    import java.util.ArrayList;
    import java.util.List;
    import javax.xml.ws.BindingProvider;
    import javax.xml.ws.Endpoint;
    import javax.xml.ws.handler.Handler;
    import javax.xml.ws.soap.AddressingFeature;
    import org.nowhere.services.RandomTest;
    import org.nowhere.services.RandomTestService;
    public class ClientTest {
        public static void main(String args[]) throws Exception {
            ClientTest app = new ClientTest();
            app.testAddressing();
        public void testAddressing() throws Exception {
            String REPLY_TO_ADDRESS = "http://localhost:8082/servertest/RandomCallback";
            String FAULT_TO_ADDRESS = "http://localhost:8082/servertest/RandomCallbackFault";
            RandomTestService service = new RandomTestService();
            RandomTest port = service.getRandomTestPort(new AddressingFeature());
            BindingProvider provider = (BindingProvider) port;
            // pass the replyTo address to the handler
            provider.getRequestContext().put("ReplyTo", REPLY_TO_ADDRESS);
            provider.getRequestContext().put("FaultTo", FAULT_TO_ADDRESS);
            // Register handlers to set the ReplyTo and FaultTo on the SOAP request sent to the WS endpoint
            List<Handler> handlerChain = new ArrayList<Handler>();
            handlerChain.add(new ClientHandler());
            provider.getBinding().setHandlerChain(handlerChain);
            // Start endpoint to receive callbacks from WS
            Endpoint endpoint = Endpoint.publish(REPLY_TO_ADDRESS, new CallbackSEI());
            try {
                port.nextRandom(false);
            } catch( Exception ex ) {
                ex.printStackTrace();
            } finally {
                Thread.sleep(10000);
            endpoint.stop();
            System.exit(0);
    4b) ClientHandler.java - Used to set the wsa ReplyTo address and FaultTo address when sending SOAP request from client to server
    package test.wsclient;
    import java.util.Set;
    import javax.xml.namespace.QName;
    import javax.xml.soap.SOAPEnvelope;
    import javax.xml.soap.SOAPHeader;
    import javax.xml.ws.handler.MessageContext;
    import javax.xml.ws.handler.MessageContext.Scope;
    import javax.xml.ws.handler.soap.SOAPHandler;
    import javax.xml.ws.handler.soap.SOAPMessageContext;
    import org.w3c.dom.Node;
    import org.w3c.dom.NodeList;
    public class ClientHandler implements SOAPHandler<SOAPMessageContext> {
        public ClientHandler() {};
        @Override
        public Set<QName> getHeaders() {
            return null;
        @Override
        public void close(MessageContext arg0) {
        @Override
        public boolean handleFault(SOAPMessageContext context) {
            return true;
        protected void setAnAddress(SOAPHeader header, String tagName, String address) {
            NodeList nodeListReplyTo = header.getElementsByTagName(tagName);
            NodeList nodeListAddress = nodeListReplyTo.item(0).getChildNodes();
            for (int i = 0; i < nodeListAddress.getLength(); i++) {
                Node node = nodeListAddress.item(i);
                if ("Address".equals(node.getLocalName())) {
                    node.setTextContent(address);
                    break;
        protected String getMessageID(SOAPHeader header) {
            NodeList nodeListMessageId = header.getElementsByTagName("MessageID");
            return nodeListMessageId.item(0).getTextContent();
        @Override
        public boolean handleMessage(SOAPMessageContext context) {
            Boolean isOutbound = (Boolean) context.get(SOAPMessageContext.MESSAGE_OUTBOUND_PROPERTY);
            if (isOutbound) {
                try {
                    SOAPEnvelope envelope = context.getMessage().getSOAPPart().getEnvelope();
                    SOAPHeader header = envelope.getHeader();
                    /* extract the generated MessageID */
                    String messageID = getMessageID(header);
                    context.put("MessageID", messageID);
                    context.setScope("MessageID", Scope.APPLICATION);
                    /* change ReplyTo address */
                    setAnAddress(header, "ReplyTo", (String) context.get("ReplyTo"));
                    setAnAddress(header, "FaultTo", (String) context.get("FaultTo"));
                } catch (Exception ex) {
                    throw new RuntimeException(ex);
            return true;
    4c) CallbackSEI.java - endpoint on the client for server to send the SOAP response back to the client
    package test.wsclient;
    import javax.annotation.Resource;
    import javax.jws.Oneway;
    import javax.jws.WebParam;
    import javax.jws.WebService;
    import javax.xml.ws.Action;
    import javax.xml.ws.RequestWrapper;
    import javax.xml.ws.WebServiceContext;
    import javax.xml.ws.soap.Addressing;
    @WebService
    @Addressing
    //@HandlerChain(file = "/handler-chain.xml")
    public class CallbackSEI {
        @Resource
        private WebServiceContext context;
         * If there is no namespace specified in the method below, then the CallbackSEI needs to be in the same package as the
         * WS endpoint.
        @Oneway
        @Action(input="http://services.nowhere.org/RandomTest/nextRandomResponse")
        @RequestWrapper(localName="nextRandomResponse", targetNamespace="http://services.nowhere.org/")
        public void handleNotification(@WebParam(name="return")long random) {
            System.out.println("Asynch response received");
            System.out.println( random );
            //System.out.println("This response relates to the message ID: "+ getMessageID());
    In summary:
    Server is listening on port 8080
    Client will listen in port 8082 for the callback from the server for the SOAP response
    Now when I run the client, I see that the proper behaviour as far as ws-addressing is concerned. That is:
    client  -- SOAP request ( on port 8080 ) --> server
    client <-- HTTP 202 ( empty HTTP body )  --- server
    client <-- SOAP response ( on port 8082 )  --- server
    All well and good, except that I am getting a NullPointerException on the client side when I call the operation.
    With debugging of the SOAP request and responses, I get the following output:
    ---[HTTP request - http://localhost:8080/servertest/RandomTest]---
    Accept: text/xml, multipart/related
    Content-Type: text/xml; charset=utf-8
    SOAPAction: "http://services.nowhere.org/RandomTest/nextRandomRequest"
    User-Agent: JAX-WS RI 2.2.8 svn-revision#13980
    <?xml version='1.0' encoding='UTF-8'?><S:Envelope xmlns:S="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/"><S:Header><To xmlns="http://www.w3.org/2005/08/addressing">http://localhost:8080/servertest/RandomTest</To><Action xmlns="http://www.w3.org/2005/08/addressing">http://services.nowhere.org/RandomTest/nextRandomRequest</Action><ReplyTo xmlns="http://www.w3.org/2005/08/addressing">
        <Address>http://localhost:8082/servertest/RandomCallback</Address>
    </ReplyTo><FaultTo xmlns="http://www.w3.org/2005/08/addressing">
        <Address>http://localhost:8082/servertest/RandomCallbackFault</Address>
    </FaultTo><MessageID xmlns="http://www.w3.org/2005/08/addressing">uuid:bcd2f6ef-3034-49e8-b837-dbd6a772fb93</MessageID></S:Header><S:Body><ns2:nextRandom xmlns:ns2="http://services.nowhere.org/"><arg0>false</arg0></ns2:nextRandom></S:Body></S:Envelope>--------------------
    ---[HTTP response - http://localhost:8080/servertest/RandomTest - 202]---
    null: HTTP/1.1 202 Accepted
    Content-Length: 0
    Content-Type: text/xml;charset=UTF-8
    Date: Fri, 18 Jul 2014 08:34:36 GMT
    Server: Apache-Coyote/1.1
    java.lang.NullPointerException
        at com.sun.proxy.$Proxy38.nextRandom(Unknown Source)
        at test.wsclient.ClientTest.testAddressing(ClientTest.java:43)
        at test.wsclient.ClientTest.main(ClientTest.java:18)
    ---[HTTP request]---
    Cache-control: no-cache
    Host: localhost:8082
    Content-type: text/xml; charset=UTF-8
    Content-length: 704
    Connection: keep-alive
    Pragma: no-cache
    User-agent: Apache CXF 2.7.7.redhat-1
    Accept: */*
    <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"><soap:Header><Action xmlns="http://www.w3.org/2005/08/addressing">http://services.nowhere.org/RandomTest/nextRandomResponse</Action><MessageID xmlns="http://www.w3.org/2005/08/addressing">urn:uuid:65d8d7fc-09e4-494a-a9c5-0a01faf4d7e6</MessageID><To xmlns="http://www.w3.org/2005/08/addressing">http://localhost:8082/servertest/RandomCallback</To><RelatesTo xmlns="http://www.w3.org/2005/08/addressing">uuid:bcd2f6ef-3034-49e8-b837-dbd6a772fb93</RelatesTo></soap:Header><soap:Body><ns2:nextRandomResponse xmlns:ns2="http://services.nowhere.org/"><return>2870062781194370669</return></ns2:nextRandomResponse></soap:Body></soap:Envelope>--------------------
    Asynch response received
    2870062781194370669
    As you can see from the output above, the proxy is throwing an Exception when it receives the HTTP 202 response.
    Any ideas ?

    I think I have found when I get this error and probably I have found a bug. I will appreciate if someone can confirm this.
    In my BPEL project setup, my BPEL process's wsdl file imports another wsdl from different namespace. Here is sample snippet -
    <wsdl:definitions targetNamespace="http://namespace/1">
    <wsdl:import namespace="http://namespace/2" location="resources/another.wsdl"/>
    <plnk:partnerLinkType....../>
    </wsdl:definitions>
    Please let me know. I checked the bundled samples with Oracle BPEL PM and did not find any similar case where process wsdl imports another wsdl.
    Thank you.
    Meghana

  • Log file non-mac-based version of client? And CGBitmapContextGetData:invali

    I'm not sure if this is a security problem. I had to completely reset my airport yesterday and today re installed my remote back-up. My keychain is messing up. I don't know if these logs are normal or if something is amiss. My IP address before resetting it yesterday started with a 169 which means something ... please if someone can let me know if there is something i should do or if there are any questions i can answer. thank you.
    Jul 24 17:12:20 Macintosh com.apple.coreservicesd[47]: NOTE: Using non-mach-based version of client -> server communication, via direct function calls.
    Jul 24 17:12:20 Macintosh com.apple.coreservicesd[47]: NOTE: Using non-mach-based version of client -> server communication, via direct function calls.
    Jul 24 17:17:12 Macintosh com.apple.launchd[110] ([0x0-0x68068].com.apple.systempreferences[538]): Exited: Terminated
    Jul 24 17:17:12 Macintosh com.apple.coreservicesd[47]: NOTE: Using non-mach-based version of client -> server communication, via direct function calls.
    Jul 24 17:25:45: --- last message repeated 1 time ---
    Jul 24 17:25:45 Macintosh com.apple.coreservicesd[47]: NOTE: Using non-mach-based version of client -> server communication, via direct function calls.
    Jul 24 17:28:45: --- last message repeated 1 time ---
    Jul 24 17:28:45 Macintosh /usr/sbin/ocspd[676]: starting
    Jul 24 17:29:33 Macintosh com.apple.coreservicesd[47]: NOTE: Using non-mach-based version of client -> server communication, via direct function calls.
    Jul 24 17:29:37: --- last message repeated 1 time ---
    Jul 24 17:29:37 Macintosh Microsoft Word[679]: CGBitmapContextGetData: invalid context
    Jul 24 17:29:59: --- last message repeated 189 times ---
    Jul 24 17:29:59 Macintosh com.apple.coreservicesd[47]: NOTE: Using non-mach-based version of client -> server communication, via direct function calls.
    Jul 24 17:29:59: --- last message repeated 1 time ---
    Jul 24 17:29:59 Macintosh Microsoft Word[679]: CGBitmapContextGetData: invalid context
    Jul 24 17:30:02: --- last message repeated 204 times ---
    Jul 24 17:30:02 Macintosh com.apple.coreservicesd[47]: NOTE: Using non-mach-based version of client -> server communication, via direct function calls.
    Jul 24 17:30:02: --- last message repeated 1 time ---
    Jul 24 17:30:02 Macintosh Microsoft Word[679]: CGBitmapContextGetData: invalid context
    Jul 24 17:30:31: --- last message repeated 2355 times ---
    Jul 24 17:30:31 Macintosh Microsoft Word[679]: doClip: empty path.
    Jul 24 17:30:31 Macintosh Microsoft Word[679]: CGBitmapContextGetData: invalid context
    Jul 24 17:30:32: --- last message repeated 70 times ---
    Jul 24 17:30:31 Macintosh [0x0-0x84084].com.microsoft.Word[679]: Thu Jul 24 17:30:31 Macintosh.local Microsoft Word[679] <Error>: doClip: empty path.
    Jul 24 17:30:32 Macintosh Microsoft Word[679]: CGBitmapContextGetData: invalid context
    Jul 24 17:30:49: --- last message repeated 1066 times ---

    BAM! I had tried to disable my scheduled task, and it didn't seem to make a difference. I saw your reply and decided to just delete the scheduled task. My "6/29/09 10:46:39 AM com.apple.coreservicesd[74] NOTE: Using non-mach-based version of client -> server communication, via direct function calls." seem to be gone now.
    2 things: 1) My scheduled task was a "When the drive is connected" type
    2) I had originally "unchecked" this task, but when I went back in at a later date, it was checked. So either my user error, or somehow CCC re-enabled it.
    I was really getting sick of my log getting pummeled.

  • How to get and put data in HTTP header in Client Side

    One JSP's function is to display data records page by page. Client users could click "First page" or "Previous Page" or "Next Page" or "Last Page" button to let the JSP to show the corresponding page. So the JSP must remember the current page number. Due to there are a number of client users maybe access the JSP at the same time, keep the current page number in session, there will be a lot of session is created at the same time, this will impact system's performance. So using session to keep data method is not used. I plan to use request header and response header to pass the current page number. I know use the response.addHeader to put data in response header and also know use request.getHeader to get data in request header in server side, but I donot know how to put data in request header and how to get data in response header in client side. Could you please give me a help? If donot use these method, are there any other method? Thanks a lot.

    Why not pass it as a parameter with the URL?
    at the beginning of the page..
    <%
    int pageNumber = Integer.parseInt(request.getParameter("page"));
    %>
    then when defining your links
    <a href="thisPage.jsp?page=<%= (pageNumber-1)%>">Previous</a>
    <a href="thisPage.jsp?page=<%= (pageNumber+1)%>">Next</a>

  • JAX-RPC - dynamic wsdl - non-built-in data types

    I thought my recent exp with developing a JAX-RPC client using a dynamic wsdl to communicate to a non-weblogic Web Service might help somebody out there. :-)
    JAX-RPC Mechanism in Weblogic for dynamic_wsdl seems to work only with built-in data types. Weblogic also supports non-built-in data types, but you need to do some extra work! For the user-defined objects, you need to generate their types and register them.
    Note: The samples given in Weblogic 8.1 do not use non-built-in data types!
    Make sure you use the ant task "autotype" in your build.xml to generate the appropriate types (objects to support java-xml and xml-java converstion), types.xml from the wsdl. Register the types.xml file in your calling client code.
    If you do not use register the types for the user-defined classes used in the web services method signatures, then you are likely to get the foll. exception.
    javax.xml.soap.SOAPException: failed to serialize interface javax.xml.soap.SOAPElementw
    eblogic.xml.schema.binding.SerializationException: mapping lookup failure. class=interface javax.xml
    .soap.SOAPElement class context=TypedClassContext{schemaType=['http://svcVodafonePooled.wsdlgen.jipi
    lot.vodafone.com']:getStock}
    C:\Tutorial\WS\dynamic_wsdl>ant run
    Buildfile: build.xml
    run:
    [java] Creating the service...
    [java] Creating the call...
    [java] invoking the call....
    [java] javax.xml.rpc.JAXRPCException: failed to invoke operation 'getStock' due to an error in
    the soap layer (SAAJ); nested exception is: Message[ failed to serialize interface javax.xml.soap.SO
    APElementweblogic.xml.schema.binding.SerializationException: mapping lookup failure. class=interface
    javax.xml.soap.SOAPElement class context=TypedClassContext{schemaType=['http://svcVodafonePooled.ws
    dlgen.jipilot.vodafone.com']:getStock}]StackTrace[
    [java] javax.xml.soap.SOAPException: failed to serialize interface javax.xml.soap.SOAPElementw
    eblogic.xml.schema.binding.SerializationException: mapping lookup failure. class=interface javax.xml
    .soap.SOAPElement class context=TypedClassContext{schemaType=['http://svcVodafonePooled.wsdlgen.jipi
    lot.vodafone.com']:getStock}
    [java] at weblogic.webservice.core.DefaultPart.invokeSerializer(DefaultPart.java:328)
    [java] at weblogic.webservice.core.DefaultPart.toXML(DefaultPart.java:297)
    [java] at weblogic.webservice.core.DefaultMessage.toXML(DefaultMessage.java:645)
    [java] at weblogic.webservice.core.ClientDispatcher.send(ClientDispatcher.java:206)
    [java] at weblogic.webservice.core.ClientDispatcher.dispatch(ClientDispatcher.java:143)
    [java] at weblogic.webservice.core.DefaultOperation.invoke(DefaultOperation.java:457)
    [java] at weblogic.webservice.core.DefaultOperation.invoke(DefaultOperation.java:443)
    [java] at weblogic.webservice.core.rpc.CallImpl.invoke(CallImpl.java:558)
    [java] at weblogic.webservice.core.rpc.CallImpl.invoke(CallImpl.java:411)
    [java] at Main.main(Main.java:61)
    [java] Caused by: weblogic.xml.schema.binding.SerializationException: mapping lookup failure. c
    lass=interface javax.xml.soap.SOAPElement class context=TypedClassContext{schemaType=['http://svcVod
    afonePooled.wsdlgen.jipilot.vodafone.com']:getStock}
    [java] at weblogic.xml.schema.binding.RuntimeUtils.lookup_serializer(RuntimeUtils.java:151)
    [java] at weblogic.xml.schema.binding.RuntimeUtils.invoke_serializer(RuntimeUtils.java:187)
    [java] at weblogic.xml.schema.binding.RuntimeUtils.invoke_serializer(RuntimeUtils.java:174)
    [java] at weblogic.webservice.core.DefaultPart.invokeSerializer(DefaultPart.java:324)
    [java] ... 9 more
    [java] ]
    [java] at weblogic.webservice.core.rpc.CallImpl.invoke(CallImpl.java:578)
    [java] at weblogic.webservice.core.rpc.CallImpl.invoke(CallImpl.java:411)
    [java] at Main.main(Main.java:61)
    [java] Exception in thread "main"
    [java] Java Result: 1

    The foll. code worked fine for me in Weblogic 8.1 SP3, on Windows 2000.
    Note: the 2 important lines of code:
    TypeMappingRegistry registry service.getTypeMappingRegistry();
    registry.registerDefault(new DefaultTypeMapping("types.xml"));
    package auth;
    import java.net.URL;
    import javax.xml.rpc.ServiceFactory;
    import javax.xml.rpc.Service;
    import javax.xml.rpc.Call;
    import javax.xml.rpc.ParameterMode;
    import javax.xml.namespace.QName;
    import javax.xml.rpc.encoding.TypeMapping;
    import javax.xml.rpc.encoding.TypeMappingRegistry;
    import weblogic.webservice.core.encoding.stream.SOAPElementCodec;
    import javax.xml.rpc.encoding.*;
    import weblogic.webservice.encoding.DefaultTypeMapping;
    public class DClient1 {
    static private void print(String msg) {
         System.out.println("DClient1: " + msg);
    public static void main(String[] argv) throws Exception {
    System.setProperty("javax.xml.soap.MessageFactory", "weblogic.webservice.core.soap.MessageFactoryImpl");
    System.setProperty( "javax.xml.rpc.ServiceFactory", "weblogic.webservice.core.rpc.ServiceFactoryImpl");
    ServiceFactory factory = ServiceFactory.newInstance();
    String targetNamespace = "http://www.vishwa.com/amazingworld";
    QName serviceName = new QName(targetNamespace, "GeminiPasswordService");
    QName portName = new QName(targetNamespace, "GeminiPasswordServicePort");
    QName operationName = new QName("", "checkPassword");
    URL wsdlLocation = new URL("http://localhost:7001/GeminiPasswordService/GeminiPasswordService?WSDL");
         print("Creating the service...");
    Service service = factory.createService(wsdlLocation, serviceName);
         print("Creating the call...");
    Call call = service.createCall(portName, operationName);
         TypeMappingRegistry registry = service.getTypeMappingRegistry();
         registry.registerDefault(new DefaultTypeMapping("types.xml"));
         print("invoking the call....");
    Object[] inParams = new Object[2];
    inParams[0] = "clark1";
    inParams[1] = "kent1";
    Object result = call.invoke(inParams);
    print("Client return value: = " + result.toString());
    QName operationName1 = new QName("", "getBook");
    print("Creating the call...");
    Call call1 = service.createCall(portName, operationName1);
    print("invoking the call....");
    Name n = new Name();
         n.setFirstname("Walker");
         n.setAge(50);
         Object[] inParams1 = new Object[1];
         inParams1[0] = n;
    Book b = (Book) call1.invoke(inParams1);
    print("author: " + b.getAuthor());
    print("money: " + b.getMoney());
    }

  • Adding to JAX-WS 2.1 response object's header

    Hello
    We are using JAX-WS 2.1. We have a requirement to have few fields such as userId to be part of SOAP response's header. How to have these added in the header. Using @WebResult(header=true) gets the whole result object into the header which I don't want

    Any suggestions

  • Vsftpd: chown non-anonymous uploads?

    Hello,
    I'm having a problem with the permissions on files uploaded to a server via vsftpd. I haven't used permissions in a very fine-grained way before, but over the last couple days I've done quite a bit of searching and experimenting but I'm still stuck.
    At my work we have an FTP server that our clients use to upload files to us which we later retrieve. This role is currently filled by a Windows machine running locally in our office, but recently I've set up a Linode VPS to take over. We have "business" DSL that doesn't exactly come with an SLA, so the server being unavailable whenever our local connection was down was becoming a problem.
    I need to make is so that uploaded files can be read, moved, and deleted by a separate (non-super) user. Once they've been uploaded, we basically just want to download them and move them to an archive on the VPS.
    I've tried a number of combinations of directory ownership, group membership, umask, etc, but I always end up with root and the user who uploaded the file being the only two users who can perform these operations. vsftpd supports chown-ing files at upload, but it only works if the uploads are anonymous, which these are not.
    Any help with this will be greatly appreciated.
    Thanks,
    jbm

    Hi,
    This is the configuration file of a vsftpd server I setup on a friend's company a few years ago. Bare in mind that the OS was Debian, vsftpd was configured with virtual users, and the permissions were setup in a way that would allow samba users to have full rights over the whole FTP directory. As long as I can remember, fine tuning the permissions took me some time too. Ftp users have full rights on an upload directory and read only access on a download directory. Both directories are inside the user's root ftp folder. Maybe this can give you some clues (but the virtual users setup changes some things).
    listen=YES
    anonymous_enable=NO
    local_enable=YES
    write_enable=YES
    local_umask=000
    file_open_mode=0777
    anon_upload_enable=YES
    anon_umask=0000
    anon_mkdir_write_enable=YES
    dirmessage_enable=YES
    xferlog_enable=YES
    connect_from_port_20=YES
    chroot_local_user=YES
    chroot_list_enable=YES
    chroot_list_file=/etc/vsftpd_login.db
    virtual_use_local_privs=YES
    pam_service_name=vsftpd
    guest_enable=YES
    guest_username=virtual
    user_sub_token=$USER
    local_root=/mnt/FTP/$USER

  • EA4500 and Non-Anonymous Disk Access

    Purchased an EA4500 this weekend and overall it's working well. Running into what seems like a bug however with the NAS settings in firmware 2.0.37. If I enable "anonymous disk access" I can use the attached USB hard drive no problem, as soon as I turn off that setting and try to setup a user it's a no-go. Windows 7 reports that the device can not be found, and in fact the icon for it will immediately disappear from the list of network devices within a few seconds of changing the radio button and clicking "save".
    It's behaving as if it's in a different workgroup than the PC's. I just have the workgroup set to the Windows 7 default of "WORKGROUP" and have the EA4500 set to the same.
    Is this a known bug with this device and firmware combination, or am I missing something obvious?

    Jake_2.0 wrote:
    By default, Anonymous Disk Access specify whether users have read-and-write or read-only access to the folder. How about if you try to map the netework drive after disabling that feature and see if the harddrive will be detected.
    That's incorrect. When it is enabled, users on the LAN can access the drive without having to enter in the credentials of one of the accounts set up in the router. 
    When it's disabled, then users have to enter in the correct credentials of one of the registered accounts to be able to access the drive. 
    The read/write access in parentheses which you are referring to is meant to make users aware what privileges an anonymous user will have. 
    I don't work for Cisco. I'm just here to help.

  • Non anonymous class

    I have a doubt in the following piece of code, Here JPanel class is getting two extra methods, how does this works and what do we call this kind of class in programming language terms. Where can i use it.
    public class XYX {
    // constructor goes here.....
    public void displayXYZ(){
      JPanel panel = new JPanel(){
           public String getPanelID(){
                return "SOMEID";
           public void delete(){
              // do delete operation .
      // some more logic here
    }TIA
    Zoha

    i got it....
    I have one more doubt..
    Consider this example.
    public class XYX {
    // constructor goes here.....
    public JPanel displayXYZ(){ 
    JPanel panel = new JPanel(){
          public String getPanelID(){   
            return "SOMEID";
          public void repaint(){ 
            // repaint in my way operation . 
       // some more logic here
    return panel;
    }I have overwritten repaint() method of JPanel now if i issue a repaint() method it should repaint in the new way. IS that right.
    The second doubt is, I create this panel and i am returning it in this method is that possible to do that, will i still have a reference to this new JPanel, what are the effects of doing so.
    How to use reflection to access anonymous classes.
    TIA
    Zoha

  • Non-anonymous FTP setup on Solaris 8

    I'd like to set up FTP access on my Solaris 8 (Sparc) box. However, I don't want people to use real system accounts on the server to log in. Is it possible?
    For example, on Widnows platform, I can install WS_FTP Server from IPSwitch, which maintains its own list of FTP users (thus no users are set up at the OS level). Can the default FTP Server on Solaris 8 do such thing? What about WU FTPD?
    Any helps are very much appreciated!

    Thanks Jeffrey!
    Can you also shed some lights on this:
    The default FTP server setup on Solaris seems to allow a system user to go anywhere(if he has permissions to) once he ftps in. For example, once I ftp in as myself, I am in my home directory. I can cd to, say, /etc and do a get on the passwd file and read it on my local machine. Being able to read the passwd file does not do much harm, but just wondering if there is a way to restrict the valid system user to his home directory and its subdirectories once logged in.
    Thanks again!

  • ReplyTo header field from Java JMS read by C JMS API causes core dump...

    Hi,

    First step is to add the option -Xcheck:jni to your java command line. It will flag common JNI errors.
    If that doesn't identify the problem, then compile your jni code with debugging symbols (-g) and add the following option to the java command line when you run your test: -XX:+ShowMessageBoxOnError. When you hit the problem again, the VM will keep the process alive instead of calling abort(). Then you can use dbx to attach to the live process and should be able to get a better idea of what went wrong.

  • HTTP Header in Client Application

    Hi All,
    I have developed a small web app (client), running under tomcat. I have configured access manager with ldap repository. my client webapp has been configured with tomcat policy agent to communicate with Access manager. This client app will be a SSO login page for manu apps. I would like to know how to set up header values for the logged in user using policy agent configuration / by some other means.
    I will pass this header value to other application, so that it can obtain authentication info's from the header.
    Thanks
    Bharat

    Hi,
    Try to find the configuration file of the policy agent, its name should be "AMAgent.properties".
    Put HTTP_HEADER in the following property: com.sun.am.policy.agents.config.profile.attribute.fetch.mode
    Then in the property com.sun.am.policy.agents.config.profile.attribute.map list the user attributes you want to retrieve in the application side, for example (cn|common-name,mail|email).
    Restart tomcat and that should be ok
    Best regards.

  • Downloading/uploading external (non-jar) files to/from client

    We are searching for a solution to upload and download non-jar files to or from the JWS-client. We've only found information to upload jar-files to a JWS-client, but we couldn't find anything about uploading non-jar files. Is there a standard solution or tool to do this with webstart?

    Hi there,
    We found a solution to upload the non-jar files, in our requirement we are trying to load the resources in the zip files. I have written the extension installer to extract the zip file from the URL to the JNLP client.
    But for this user has to click on the install pop up to allow the JWS to install the non jar files.
    Thanks,
    TSR

  • Enable anonymous access for Javascript Client Object Model

    In SharePoint 2010 it was possible to use the Javascript Client Object Model with anonymous access enabled by removing "GetItems" from the ClientCallableSettings.AnonymousRestrictedTypes.
    In SharePoint 2013 however, it seems that an extra security barrier has been implemented. Trying to use the Javascript Client Object Model results in the following message: "Access denied. You do not have permission to perform this action or access this
    resource."
    After this I went on to do a little research, and it appears that Javascript Client Object Model actually relies on the REST API (please correct me if I'm mistaken), and the REST API also doesn't seem to work as an anonymous user.
    So I'm in the dark here. I can't imagine that SharePoint 2013 (so heavily relying on the client object model) can't be used with anonymous access. I've also found very little documentation on anonymous access in combination with SharePoint 2013.
    So, how do I enable the Javascript Client Object Model to be used with anonymous access enabled?
    P.S. Needless to say, my web application is enabled for anonymous access and so is my site collection.

    There are really 4 things you need to do to enable anonymous access:
    1. In web application level, enable anonymous.
    2. In site collection level, make sure anonymous access Entire Website.
    3. In Web level, set Full Permission Masks, till here, you're able to anonymously access REST APIs.
    # Enable Anonymous access
    $web = Get-SPWeb $url
    if($web -ne $null)
        Write-Host
        Write-Host -ForegroundColor Yellow "Enabling Anonymous access on:" $web.Url
        Write-Host
        $web.AnonymousState = "On"
        Write-Host -ForegroundColor Yellow "AnonymousState set to:" $web.AnonymousState
        $web.AnonymousPermMask64 = "FullMask"
        Write-Host -ForegroundColor Yellow "AnonymousPermMask64 set to:" $web.AnonymousPermMask64
        $web.Update()
        Write-Host
    Below are the things to enable anonymous client object model APIs:
    4. In web application level, Require Use Remote Interfaces Permission - uncheck it.
    5. In web application level, Anonymous Restricted Types, remove all of them:
    $app.ClientCallableSettings.AnonymousRestrictedTypes.RemoveAll()

  • Oracle 10 g non-global zones with asynchronous I/O

    Hi,
    I note that using direct I/O (by setting the forcedirectio while
    mounting the database file systems) and bypassing the file system
    cache may improve database performance significantly, but this should
    be done only for file systems in which database files and redo log
    files exist. If direct I/O is used and there is not enough database
    buffer cache, it may even decrease the performance by moving the
    problem from double buffering to a lack of database buffer cache. So,
    this performance tuning must be planned carefully, and the database
    buffer cache should be sized properly. The direct I/O option should
    not be used for other file systems used by other applications because
    they still need the UFS buffer cache.
    Now, I have Oracle database installed inside a non-global zone and I
    see a lot of Asynchronous I/O wait warnings in the Oracle Alert log
    file. Storage mount points with UFS filesystem contain the Oracle
    datafiles and redo log files. In addition, two Oracle datafiles of 10
    GB each reside on the local disks. The Oracle init.ora parameter to
    set asynchronous I/O for Oracle database files is
    FILESYSTEMIO_OPTIONS= SETALL.
    Although the above parameter was set during the database installation,
    the aiowait warnings don't seem to disappear.
    Can I use the "forcedirectio" option at the Operating System /etc/
    vfstab file for Oracle datafiles and redo log files?
    Or, should I just move the Oracle database files residing on the local
    disks to the external storage? Will this take care of aiowait warnings
    and if yes, how? The storage is a DAS.
    Regards
    Sandeep

    I presume you compiled php on the Sun server, was this done using gcc or the Sun One C compiler.
    If the latter then you can also use the flag: --enable-nonportable-atomics when you run configure                                                                                                                                                                                                                                                                                                                                                                                                   

Maybe you are looking for

  • In app purchase not appearing in game

    I have made an in app purchase of gold in Jewel Mania but although the money has been taken from my iTunes credit twice the gold has not appeared in the game after nearly 24 hours,any suggestions anyone?

  • Standard cost item in foreign currency

    Dear Experts, The item valuation method is standard and it require us to fill in the item cost field. Question is - can we maintain standard cost item in foreign currency? Is there any documentation regarding this? I tried entering the item cost in f

  • LV listbox size limitation

    Is there a limitation to the number of entries a listbox will display? My attached program indicates there is. If you run it, I can only scroll through to 32767 items. Ultimately, I want a program I can list a directory of files(80000+) and allow the

  • Enhanced  and conditional interface determination, :

    Experts ,            can you giv me some link/ examples  of Conditional interface determination and Enhanced  Interface determination.   Pls dont send me teh below link! http://help.sap.com/saphelp_nw04s/helpdata/en/42/ed364cf8593eebe10000000a1553f7/

  • Mobile Field Service Laptop setup login

    I have Oracle Lite 10.3.0.2.0 and Oracle Business 12.1.1 I used for implementation note 846572.1 from support.oracle.com Problem is: When I try to install the laptop client application I received the error "Invalid the user name/password: my.user". I