Pass Username token in Web Service Client

I am totally new to Java....I work primarily with .Net. I am trying to send a Username token to a web service. I looked at the examples...can't get them to run.
My question is, without using config files, can I specify username token in the class. You can do this in .Net.
I am working with .NetBeans IDE 5.0.

I looked at this example....didn't get to far because I couldn't setup the samples.
http://java.sun.com/webservices/docs/1.6/tutorial/doc/XWS-SecuritySamples5.html#wp569635
Here is the guide I followed to setup the samples.
http://java.sun.com/webservices/docs/1.6/tutorial/doc/XWS-SecuritySamples2.html
I didn't do the part about the keystore. I got stuck on the "Setting Build Properties", and I don't know how to run the samples.
Are you saying there is no way of creating a java application, creating the web service client with JWSDP 2.0 and then modifying either the generated code or my main.class to set the username and token properties?
Thanks, Mike L.

Similar Messages

  • Attach WS Security (Username Token) to web service

    Dear All,
    I would like to attach WS security from Weblogic Side. Please can you suggest for me a good tutorial.
    Thanks

    You can refer this article
    web services security in weblogic

  • Add username token to SOAP Service in ESB

    I know how to add the username token to a partnerlink in a bpel process but how can I configure the same soap headers in a SOAP Service in ESB?
    Another question about the configuration of a bpel process when invoking a secure web service: I need to add 3 parameters to the partnerlink to be able to send the username/password credentials to the service but this isn't very flexible.
    How can you configure to use file authentication or ldap authentication when invoking the secure web service?

    Hi.
    I found some info related to passing username token in ESB.
    You go to ESB home page:
    http://www.oracle.com/technology/products/integration/esb/index.html
    and download esb samples:
    http://www.oracle.com/technology/products/integration/esb/files/esbsamples.zip
    There you'll find a SOAP Headers project (under OTN Samples) which has an example of how to pass WS-Security usename credentials.
    Here is a sample, in a XSLT:
    <xsl:variable name="setUsername"
    select="ehdr:setOutboundHeader('/wsse1:Security/wsse1:UsernameToken/wsse1:Username','oc4jadmin','wsse1=http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd;')"/>
    <xsl:variable name="setPassword"
    select="ehdr:setOutboundHeader('/wsse1:Security/wsse1:UsernameToken/wsse1:Password','welcome1','wsse1=http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd;')"/>
    <xsl:template match="/">
    <ns1:ReceiveCustElement>
    <ns1:customer>
    <xsl:value-of select="/inp1:InputElement/InputString"/>
    </ns1:customer>
    </ns1:ReceiveCustElement>
    </xsl:template>
    </xsl:stylesheet>
    Denis

  • JAX-WS web service client and Windows integrated Security authentication

    I am currently developing a JAX-WS web service client running on WebLogic 10.3.2.0. The client is connecting to exchange web service running on IIS.
    Everything works well when EWS is configured with Http basic authentication.
    The problems started when I changed the autentication method on EWS from Http basic authentication to Windows integrated Security authentication.
    The client is then unable to authenticate to the web service. Every request made to EWS returns with the message : Invalid HTTP server response [401] - Unauthorized.
    I tried using an authenticator like this one:
    static class RetrieveWSDLAuthenticator extends Authenticator
    private String username, password;
    public RetrieveWSDLAuthenticator(String user, String pass)
    username = user;
    password = pass;
    @Override
    protected PasswordAuthentication getPasswordAuthentication()
    return new PasswordAuthentication(username, password.toCharArray());
    and setting it as the default authenticator :
    Authenticator.setDefault(new MyAuthenticator("username", "password"));
    but the method getPasswordAuthentication() was not even called.
    Is there a way to make a JAX-WS client works with Windows integrated Security ?

    WIS is not suppported on WLS JAX-WS. You'll need to use other authentication mechanisms such as http basic (which you tried already), or message-level security such as UNT, or SAML.
    Regards,
    Pyounguk

  • How to prevent downloading wsdl in weblogic web service client

    Hi,
    I get a problem regarding weblogic web service client. My working environment:
    weblogic server 8.1
    Windows XP SP2
    JDK 1.4
    I use the weblogic tool to generate the client jar file from the wsdl file.
         <target name="generate-client">
              <clientgen wsdl="ACCESS.wsdl"
                   packageName="xxxxxx.client"
                   clientJar="${client}/${AccessClient_jar_file}"
                   keepGenerated="true"
                   saveWSDL="true"
              />
              <javac srcdir="${source}"
              destdir="${client}"
              includes="**/AccessClient.java">
              <classpath>
              <pathelement path="${client}/${AccessClient_jar_file}"/>
              </classpath>
              </javac>
         </target>
    After that, I create a client java file to invoke the service deploy in the server.
    public static void main(String[] argv)
    throws Exception
         int transactionId = 100;
         int id = 1000;
    // Setup the global JAXM message factory
    System.setProperty("javax.xml.soap.MessageFactory", "weblogic.webservice.core.soap.MessageFactoryImpl");
    // Setup the global JAX-RPC service factory
    System.setProperty( "javax.xml.rpc.ServiceFactory", "weblogic.webservice.core.rpc.ServiceFactoryImpl");
    AccessServicePorts ws = new AccessServicePorts_Impl(argv[0]);
    AccessService port = ws.getAccessService();
    // Resource - create
    Resource resource = new Resource();
    resource.setRES_CD("Create ResCo");
    resource.setCODE_CODE("code_cod");
    resource.setRES_TYPE("Resource typ");
    resource.setCOMMON_FIELD(common);
    AccessDefaultResult resultItems = port.createResource(resource);
    System.out.println("createResource : " + resultItems);
    I find that this web service client always issue 2 http requests to invoke an web service method deployed in server.
    1st http reqeust:
    GET /AccessEpol/EpolServiceSoap?WSDL HTTP/1.1
    User-Agent: Java/1.4.2_08
    Host: 127.0.0.1:8001
    Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
    Connection: keep-alive
    the return result is the wsdl downloaded from the server.
    2nd http request is the real web service request.
    The question is how could I eliminate the 1st http request because it's really unnecessary. I use other web service client like Axis 1.x, Axis client never has the http request to download the wsdl from the server.
    I read through weblogic web service document. It do mentions that put saveWSDL="true" in the clientgen ant task. the default value for saveWSDL is true already. I did try saveWSDL="false" also. None of them can eliminate the 1st http request.
    appreciate for any answer my question?

    Hi David,
    thanks for the reply.
    More or less I agree some points you mentioned above.
    I did use Axis 1.x to test the inter-operability. The web service was developed in Weblogic 8.1 and is a part of an existing web application. It will be merged to existing application deployed in weblogic 8.1.
    I also program the web service client to test the web service.
    The implementation of the server and client will be handed over the project team and training for supporting or continuous development have to be conducted by me. So I don't like to use two types of technologies which will make thing complex.
    I found this issue when I tried to protected the web service endpoint, eg http://localhost:7001/epol/service, using the web application Basic mechanism. The wsdl URL http://localhost:7001/epol/service?WSDL is also protected in this case. Unfortunately the username/password pair is not sent to the server when the weblogic client download the WSDL from the server. In this case, the client failed and throw exception.

  • Web service client ignores http proxy settings

    I have a web service client using Weblogic's web service client library. I'm trying to instruct it to use a http proxy. I've set all the following system properties:
    -Dhttp.proxyHost=127.0.0.1
    -Dhttp.proxyPort=8080 -Dweblogic.webservice.transport.http.proxy.host=127.0.0.1 -Dweblogic.webservice.transport.http.proxy.port=8080
    No traffic is passing through the proxy.
    When the proxy is down, the application works fine too. I suspect that the proxy settings are completely ignored for some reason.
    I'm using Weblogic 8.1 SP4 on a Windows XP box and JDK 1.4.2 (Sun's bundled JDK with Weblogic).

    Sorry about the delay,
    You just need to use the standard java http proxy properties, take a look at:
    http://download-west.oracle.com/docs/cd/A97329_03/web.902/a95453/useservices.htm
    Does this help?
    Gerard

  • Web service client needs to share data with a SOAP Message Handler

    I have a web service client that is built using WebLogic 10 clientgen. I also have a Soap Message Handler configured that will create the required Soap Headers for the web service call.
    Creating these Soap Headers works great as long as the header data is static but the problem comes up when I need to place some dynamic data in these headers. The web service client has this data and somehow needs to pass it to the Soap Message Handler. It looks like I need to somehow have the client place this data in the MessageContext before the call so the data can be accessed by the Soap Message Handler.
    How do I get access to the MessageContext from the client or is there a better way to do this?
    Thanks in advance for any help you can give.

    You may want to check the response to this previous post to see if it yields any ideas for you:
    Not able to Pass header info to Microsoft MapPoint WebService using WLS10

  • Standalone Web Service clients in NetBeans with WSIT security

    I'm having a problem create a secure app with NetBeans, any help would be appreciated, here's what I did:
    Following the WSIT tutorial (http://java.sun.com/webservices/reference/tutorials/wsit/doc/index.html) I was able to create a Web Service with (for example) Username Authentication with Symmetric Key. I select the keystore as being the either the default development settings (I installed V3 certificates previously) or what I imagine are the same as them: keystore from domain1, alias xws-server and a username and password that I've created in the glassfish admin console. All good so far.
    I then create a new web app servlet client, configuring the Web Service client with the corresponding cacerts keystore, alias xws-security-server from domain1 and the correct username and password. Deploy that and bingo, it works.
    Try that again with a standalone Java client configuring the client reference in exactly the same way and using:
            try { // Call Web Service Operation
                uk.ac.ox.sddag.glassfish.server.SecureWSService service = new uk.ac.ox.sddag.glassfish.server.SecureWSService();
                uk.ac.ox.sddag.glassfish.server.SecureWS port = service.getSecureWSPort();
                int x = 1200;
                int y = 36;
                int result = port.add(x, y);
                System.out.println("Result = "+result);
            } catch (Exception ex) {
                System.out.println("Exception:");
                ex.printStackTrace();
            }but this time, it doesn't work:
    Exception:
    javax.xml.ws.soap.SOAPFaultException: ERROR: No security header found in the message
            at com.sun.xml.ws.fault.SOAP11Fault.getProtocolException(SOAP11Fault.java:188)
            at com.sun.xml.ws.fault.SOAPFaultBuilder.createException(SOAPFaultBuilder.java:130)
            at com.sun.xml.ws.client.sei.SyncMethodHandler.invoke(SyncMethodHandler.java:119)
            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 $Proxy29.add(Unknown Source)
            at securestandaloneclient.Main.main(Main.java:26)
    Caused by: javax.xml.ws.soap.SOAPFaultException: ERROR: No security header found in the message
            at com.sun.xml.ws.security.opt.impl.util.SOAPUtil.getSOAPFaultException(SOAPUtil.java:171)
            at com.sun.xml.wss.provider.wsit.WSITServerAuthContext.validateRequest(WSITServerAuthContext.java:277)
            at com.sun.xml.wss.provider.wsit.WSITServerAuthContext.validateRequest(WSITServerAuthContext.java:179)
            at com.sun.enterprise.webservice.CommonServerSecurityPipe.processRequest(CommonServerSecurityPipe.java:168)
            at com.sun.enterprise.webservice.CommonServerSecurityPipe.process(CommonServerSecurityPipe.java:129)
            at com.sun.xml.ws.api.pipe.helper.PipeAdapter.processRequest(PipeAdapter.java:115)
            at com.sun.xml.ws.api.pipe.Fiber.__doRun(Fiber.java:595)
            at com.sun.xml.ws.api.pipe.Fiber._doRun(Fiber.java:554)
            at com.sun.xml.ws.api.pipe.Fiber.doRun(Fiber.java:539)
            at com.sun.xml.ws.api.pipe.Fiber.runSync(Fiber.java:436)
            at com.sun.xml.ws.server.WSEndpointImpl$2.process(WSEndpointImpl.java:243)
            at com.sun.xml.ws.transport.http.HttpAdapter$HttpToolkit.handle(HttpAdapter.java:444)
            at com.sun.xml.ws.transport.http.HttpAdapter.handle(HttpAdapter.java:244)
            at com.sun.xml.ws.transport.http.servlet.ServletAdapter.handle(ServletAdapter.java:135)
            at com.sun.enterprise.webservice.JAXWSServlet.doPost(JAXWSServlet.java:176)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:738)
            at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
            at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
            at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:290)
            at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
            at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
            at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
            at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
            at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
            at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
            at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
            at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
            at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:272)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
            at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:341)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:263)
            at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:214)
            at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
            at com.sun.enterprise.web.connector.grizzly.ssl.SSLWorkerThread.run(SSLWorkerThread.java:106)I'm assuming that it's something to do with the WSDL being used to create the request, here's what the source view for the web service reference says:
    <?xml version="1.0" encoding="UTF-8"?><!-- Published by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.3.1-hudson-417-SNAPSHOT. --><!-- Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.3.1-hudson-417-SNAPSHOT. --><definitions xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://server.glassfish.sddag.ox.ac.uk/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://server.glassfish.sddag.ox.ac.uk/" name="SecureWSService">
    <ns1:Policy xmlns:ns1="http://schemas.xmlsoap.org/ws/2004/09/policy" wsu:Id="SecureWSPortBindingPolicy">
    <ns1:ExactlyOne>
    <ns1:All>
    <ns4:SignedSupportingTokens xmlns:ns4="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns4:UsernameToken ns4:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/AlwaysToRecipient">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns4:WssUsernameToken10></ns4:WssUsernameToken10>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns4:UsernameToken>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns4:SignedSupportingTokens>
    <ns5:SymmetricBinding xmlns:ns5="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:AlgorithmSuite>
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:Basic128></ns5:Basic128>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:AlgorithmSuite>
    <ns5:IncludeTimestamp></ns5:IncludeTimestamp>
    <ns5:Layout>
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:Strict></ns5:Strict>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:Layout>
    <ns5:OnlySignEntireHeadersAndBody></ns5:OnlySignEntireHeadersAndBody>
    <ns5:ProtectionToken>
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:X509Token ns5:IncludeToken="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy/IncludeToken/Never">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns5:RequireIssuerSerialReference></ns5:RequireIssuerSerialReference>
    <ns5:WssX509V3Token10></ns5:WssX509V3Token10>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:X509Token>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:ProtectionToken>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns5:SymmetricBinding>
    <ns6:Wss11 xmlns:ns6="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns1:Policy>
    <ns1:ExactlyOne>
    <ns1:All>
    <ns6:MustSupportRefEncryptedKey></ns6:MustSupportRefEncryptedKey>
    <ns6:MustSupportRefIssuerSerial></ns6:MustSupportRefIssuerSerial>
    <ns6:MustSupportRefThumbprint></ns6:MustSupportRefThumbprint>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    </ns6:Wss11>
    <ns7:UsingAddressing xmlns:ns7="http://www.w3.org/2006/05/addressing/wsdl" ns1:Optional="true"></ns7:UsingAddressing>
    </ns1:All>
    </ns1:ExactlyOne>
    </ns1:Policy>
    <ns8:Policy xmlns:ns8="http://schemas.xmlsoap.org/ws/2004/09/policy" wsu:Id="SecureWSPortBinding_add_Input_Policy">
    <ns8:ExactlyOne>
    <ns8:All>
    <ns9:EncryptedParts xmlns:ns9="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns9:Body></ns9:Body>
    </ns9:EncryptedParts>
    <ns10:SignedParts xmlns:ns10="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns10:Body></ns10:Body>
    <ns10:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Namespace="http://www.w3.org/2005/08/addressing" Name="To"></ns10:Header>
    <ns10:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing"></ns10:Header>
    <ns10:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="AckRequested"></ns10:Header>
    <ns10:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="CreateSequence"></ns10:Header>
    <ns10:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="Sequence"></ns10:Header>
    <ns10:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="SequenceAcknowledgement"></ns10:Header>
    </ns10:SignedParts>
    </ns8:All>
    </ns8:ExactlyOne>
    </ns8:Policy>
    <ns11:Policy xmlns:ns11="http://schemas.xmlsoap.org/ws/2004/09/policy" wsu:Id="SecureWSPortBinding_add_Output_Policy">
    <ns11:ExactlyOne>
    <ns11:All>
    <ns12:EncryptedParts xmlns:ns12="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns12:Body></ns12:Body>
    </ns12:EncryptedParts>
    <ns13:SignedParts xmlns:ns13="http://schemas.xmlsoap.org/ws/2005/07/securitypolicy">
    <ns13:Body></ns13:Body>
    <ns13:Header Name="ReplyTo" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Namespace="http://www.w3.org/2005/08/addressing" Name="To"></ns13:Header>
    <ns13:Header Name="From" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Name="MessageID" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Name="FaultTo" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Name="Action" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Name="RelatesTo" Namespace="http://www.w3.org/2005/08/addressing"></ns13:Header>
    <ns13:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="AckRequested"></ns13:Header>
    <ns13:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="CreateSequence"></ns13:Header>
    <ns13:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="Sequence"></ns13:Header>
    <ns13:Header Namespace="http://schemas.xmlsoap.org/ws/2005/02/rm/policy" Name="SequenceAcknowledgement"></ns13:Header>
    </ns13:SignedParts>
    </ns11:All>
    </ns11:ExactlyOne>
    </ns11:Policy>
    <types>
    <xsd:schema>
    <xsd:import namespace="http://server.glassfish.sddag.ox.ac.uk/" schemaLocation="http://localhost:8080/SecureApplication/SecureWSService?xsd=1"></xsd:import>
    </xsd:schema>
    </types>
    <message name="add">
    <part name="parameters" element="tns:add"></part>
    </message>
    <message name="addResponse">
    <part name="parameters" element="tns:addResponse"></part>
    </message>
    <portType name="SecureWS">
    <operation name="add">
    <input message="tns:add"></input>
    <output message="tns:addResponse"></output>
    </operation>
    </portType>
    <binding name="SecureWSPortBinding" type="tns:SecureWS">
    <ns14:PolicyReference xmlns:ns14="http://schemas.xmlsoap.org/ws/2004/09/policy" URI="#SecureWSPortBindingPolicy"></ns14:PolicyReference>
    <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"></soap:binding>
    <operation name="add">
    <soap:operation soapAction="add"></soap:operation>
    <input>
    <ns15:PolicyReference xmlns:ns15="http://schemas.xmlsoap.org/ws/2004/09/policy" URI="#SecureWSPortBinding_add_Input_Policy"></ns15:PolicyReference>
    <soap:body use="literal"></soap:body>
    </input>
    <output>
    <ns16:PolicyReference xmlns:ns16="http://schemas.xmlsoap.org/ws/2004/09/policy" URI="#SecureWSPortBinding_add_Output_Policy"></ns16:PolicyReference>
    <soap:body use="literal"></soap:body>
    </output>
    </operation>
    </binding>
    <service name="SecureWSService">
    <port name="SecureWSPort" binding="tns:SecureWSPortBinding">
    <soap:address location="http://localhost:8080/SecureApplication/SecureWSService"></soap:address>
    </port>
    </service>
    </definitions>The contents of META-INF (The WSDL):
    <?xml version="1.0" encoding="UTF-8"?><!-- Published by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.3.1-hudson-417-SNAPSHOT. --><!-- Generated by JAX-WS RI at http://jax-ws.dev.java.net. RI's version is JAX-WS RI 2.1.3.1-hudson-417-SNAPSHOT. --><definitions xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:tns="http://server.glassfish.sddag.ox.ac.uk/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://schemas.xmlsoap.org/wsdl/" targetNamespace="http://server.glassfish.sddag.ox.ac.uk/" name="SecureWSService" xmlns:wsp="http://www.w3.org/ns/ws-policy" xmlns:sc="http://schemas.sun.com/2006/03/wss/client" xmlns:wspp="http://java.sun.com/xml/ns/wsit/policy">
    <types>
    <xsd:schema>
    <xsd:import namespace="http://server.glassfish.sddag.ox.ac.uk/" schemaLocation="http://localhost:8080/SecureApplication/SecureWSService?xsd=1"></xsd:import>
    </xsd:schema>
    </types>
    <message name="add">
    <part name="parameters" element="tns:add"></part>
    </message>
    <message name="addResponse">
    <part name="parameters" element="tns:addResponse"></part>
    </message>
    <portType name="SecureWS">
    <operation name="add">
    <input message="tns:add"></input>
    <output message="tns:addResponse"></output>
    </operation>
    </portType>
    <binding name="SecureWSPortBinding" type="tns:SecureWS">
        <wsp:PolicyReference URI="#SecureWSPortBindingPolicy"/>
        <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document"></soap:binding>
    <operation name="add">
    <soap:operation soapAction="add"></soap:operation>
    <input>
    <soap:body use="literal"></soap:body>
    </input>
    <output>
    <soap:body use="literal"></soap:body>
    </output>
    </operation>
    </binding>
    <service name="SecureWSService">
    <port name="SecureWSPort" binding="tns:SecureWSPortBinding">
    <soap:address location="http://localhost:8080/SecureApplication/SecureWSService"></soap:address>
    </port>
    </service>
        <wsp:Policy wsu:Id="SecureWSPortBindingPolicy">
            <wsp:ExactlyOne>
                <wsp:All>
                    <sc:CallbackHandlerConfiguration wspp:visibility="private">
                        <sc:CallbackHandler default="example1" name="usernameHandler"/>
                        <sc:CallbackHandler default="password1" name="passwordHandler"/>
                    </sc:CallbackHandlerConfiguration>
                    <sc:TrustStore wspp:visibility="private" type="JKS" storepass="changeit" location="/Applications/NetBeans/glassfish-v2ur2/domains/domain1/config/cacerts.jks" peeralias="xws-security-server"/>
                </wsp:All>
            </wsp:ExactlyOne>
        </wsp:Policy>
    </definitions>The wsit-client:
    <?xml version="1.0" encoding="UTF-8"?>
    <definitions
    xmlns="http://schemas.xmlsoap.org/wsdl/"
    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" name="mainclientconfig"
    >
        <import location="SecureWSService.xml" namespace="http://server.glassfish.sddag.ox.ac.uk/"/>
    </definitions>

    This bug still isn't fixed.
    Thank you, adding Glassfish's webservices-rt.jar does fix it.

  • Setting connect timeout and read timeout on a Web service Client

    How can I set timeout values for a SOAP Web service client?
    I don't want to set timeout values for the complete JVM, but on a call-by-call basis. I was looking for something like:
      SOAPConnection c = ....
      c.setTimeout(...);Anyone?

    Thanks again fsato4, but i still can not resolve my problem. I must use the java 1.2.2 and i think the package java.nio.charset is not supported. I have read documentation about the use of encodings but i can not understand clearly what is happening in my application. Let me explain what i am thinking and ask you some things.
    I send a message from the client in VB using soap toolkit, obviously in UTF-8 format. When the message is received in my Java Web service, Do i need to do something in order to my Java string understands the message?.
    What i am doing is to obtain the byte array with the following line:
    byte[] utf8Bytes = strXmlFile.getBytes("UTF8");
    And then i use the constructor of the string as follows:
    String ostr = new String (utf8Bytes,"UTF8"); I think that in this point i have my string in a valid representation for my server (Sun solaris) Rigth?. And finally i use my new string to pass that value to my function which expects a java.lang.String, but the result is that all the special characters are replaced.
    Just after of the new String line, i write my string to an Buffered Writer pointed to a FileOutputStream (just for Doublecheck) using the "ISO8859_1" encoding and for my surprise i can read very well that xml in my browser and the special characters are displayed in a correct way. Could you please explain me why?
    Thanks for your help.

  • Web service client invoke problem

    Hi all,I want to in sap studio to develop web service client to invoke a .net webservice,this webservice  need authen ,so I develop a standandalone proxy to write a consle to invoke my code.
    The follwoing is my invoke  code
    public class WebServiceTest {
         public static void main(String[] args) throws Exception {
              GetScaVersion parameter = new GetScaVersion();
              ManagementSoap port = new ManagementImpl().getLogicalPort(); 
                        port._setProperty(port.USERNAME_PROPERTY,"administrator");
                        port._setProperty(port.PASSWORD_PROPERTY,"administrator");
              GetUserList list=new GetUserList();
              GetScaVersionResponse response= port.getScaVersion(parameter);
              System.out.println(response.getGetScaVersionResult());
              System.out.println(response.getAErrorMsg());          
    But final I got the following errors,
    Warning ! Protocol Implementation [com.sap.engine.services.webservices.jaxrpc.wsdl2java.features.builtin.MessageIdProtocol] could not be loaded (NoClassDefFoundError) !
    Error Message is :com/sap/guid/GUIDGeneratorFactory
    null
    Invalid UserName and Password
    so I just want to ask ,if the webservice is need to authen,does the following tow senteces works for authenciation ?
      port._setProperty(port.USERNAME_PROPERTY,"administrator");
      port._setProperty(port.PASSWORD_PROPERTY,"administrator");

    Hi,
    You need to set the credentials of the .net user.
    Also, which type of proxy have you created? Are you able to open the wsdl in the browser?.
    Thanks,
    Vasu

  • Dynamic Logical Port for Web Service Client

    Hi *!
    We want to use the same Web Service Client code with different Web Service instances running on different systems. So I need to configure the logical port (especially the URL of the endpoint) dynamically at runtime.
    Please give me a hint, how this is done.
    (we are using WebAS 6.40 SP7)...
    Thanks in advance,
         Frank

    Hi Frank,
    I hope you were able to solve your issue on you own in the meantime.
    I was looking for the answer to this question today. This was the only thread I found on SDN. Unfortunately, it did not contain an answer yet. I was able to figure out a way to set the endpoint address dynamically after searching help.sap.com and after examining the interfaces offered by the Stub (logical port in this case) classes.
    Here's an extract from my code:
    // Connect to JNDI context
    InitialContext ic = new InitialContext();
    // Get reference to web service proxy from JNDI context
    Z_MSC_GET_SCHEDULE_WSDService service =
         (Z_MSC_GET_SCHEDULE_WSDService) ic.lookup("wsclients/proxies/iot-online.de/msc~srv_ejb~proxy/de.iot_online.msc.proxy.ScheduleReaderProxy");
    // Get reference to logical port from web service proxy
    Z_MSC_GET_SCHEDULE_WSD logicalPort = service.getLogicalPort();
    // Set URL of web service Endpoint
    logicalPort._setProperty(Stub.ENDPOINT_ADDRESS_PROPERTY, "http://<FQDN>:8010/sap/bc/srt/rfc/sap/Z_MSC_GET_SCHEDULE_WSD?sap-client=100");
    This is explained on
    http://help.sap.com/saphelp_nwce10/helpdata/en/45/113a1221337249e10000000a155369/frameset.htm
    You can also set the credentials (username / password) with the method _setProperty.
    Best regards
    Christian

  • Web Service Client Generation.

    <b>Hi
    I have deployed an EJB as a web service, now am trying to create a client using the web service client wizard in NWDS to test the web service. I pass the wsdl url to the wizard for the service definition, move the slider for Test client and change the web service runtime to SAP Netweaver and say Next. Then the wizard asks for the Output Folder and i use the default folder and say Next. Now at this point an error comes which says,</b>
    Publishing failed
      Error during deployment:
          com.sap.ide.eclipse.sdm.deploy.DeploymentException: DeploymentException.
          Reason: An error occurred while deploying the deployment item 'sap.com_SummitOrder_140207ClientEAR'.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.dc.gd.DeliveryException: An error occurred during deployment of sdu id: sap.com_SummitOrder_140207ClientEAR
          sdu file path: C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear
          version status: NEW
          deployment status: Admitted
          description:
          1. Error:
          Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          . Cannot deploy it.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          at com.sap.ide.eclipse.sdm.threading.DCDeployThread.run(DCDeployThread.java:145)
    Nested exception -
          com.sap.engine.services.dc.api.deploy.DeployException: DeploymentException.
          Reason: An error occurred while deploying the deployment item 'sap.com_SummitOrder_140207ClientEAR'.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.dc.gd.DeliveryException: An error occurred during deployment of sdu id: sap.com_SummitOrder_140207ClientEAR
          sdu file path: C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear
          version status: NEW
          deployment status: Admitted
          description:
          1. Error:
          Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          . Cannot deploy it.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          at com.sap.engine.services.dc.api.deploy.impl.DeployProcessorImpl.deployItems(DeployProcessorImpl.java:734)
          at com.sap.engine.services.dc.api.deploy.impl.DeployProcessorImpl.deploy(DeployProcessorImpl.java:220)
          at com.sap.ide.eclipse.deployer.dc.deploy.DeployProcessor70.deploy(DeployProcessor70.java:111)
          at com.sap.ide.eclipse.sdm.threading.DCDeployThread.run(DCDeployThread.java:119)
          Caused by: com.sap.engine.services.dc.cm.deploy.DeploymentException: An error occurred while deploying the deployment item 'sap.com_SummitOrder_140207ClientEAR'.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.dc.gd.DeliveryException: An error occurred during deployment of sdu id: sap.com_SummitOrder_140207ClientEAR
          sdu file path: C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear
          version status: NEW
          deployment status: Admitted
          description:
          1. Error:
          Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          . Cannot deploy it.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          at com.sap.engine.services.dc.cm.deploy.impl.OnlineDeployProcessor.performDelivery(OnlineDeployProcessor.java:186)
          at com.sap.engine.services.dc.cm.deploy.impl.BulkOnlineDeployProcessor.deploy(BulkOnlineDeployProcessor.java:47)
          at com.sap.engine.services.dc.cm.deploy.impl.AbstractDeployProcessor$DeployProcessorHelper.visit(AbstractDeployProcessor.java:177)
          at com.sap.engine.services.dc.cm.deploy.impl.DeploymentItemImpl.accept(DeploymentItemImpl.java:83)
          at com.sap.engine.services.dc.cm.deploy.impl.AbstractDeployProcessor.deploy(AbstractDeployProcessor.java:76)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.performDeploy(DeployerImpl.java:624)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doDeploy(DeployerImpl.java:483)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:206)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:153)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImplp4_Skel.dispatch(DeployerImplp4_Skel.java:807)
          at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:253)
          at com.sap.engine.services.rmi_p4.P4Message.execute(P4Message.java:109)
          at com.sap.engine.services.cross.fca.FCAConnectorImpl.executeRequest(FCAConnectorImpl.java:841)
          at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:125)
          at com.sap.engine.services.cross.fca.MessageReader.run(MessageReader.java:59)
          at com.sap.engine.core.thread.execution.Executable.run(Executable.java:108)
          at com.sap.engine.core.thread.execution.CentralExecutor$SingleThread.run(CentralExecutor.java:168)
          Caused by: java.rmi.RemoteException:  class com.sap.engine.services.dc.gd.DeliveryException: An error occurred during deployment of sdu id: sap.com_SummitOrder_140207ClientEAR
          sdu file path: C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear
          version status: NEW
          deployment status: Admitted
          description:
          1. Error:
          Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          . Cannot deploy it.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          at com.sap.engine.services.dc.gd.impl.ApplicationDeployer.performDeployment(ApplicationDeployer.java:162)
          at com.sap.engine.services.dc.gd.impl.GenericDeliveryImpl.deploy(GenericDeliveryImpl.java:54)
          at com.sap.engine.services.dc.cm.deploy.impl.OnlineDeployProcessor.performDelivery(OnlineDeployProcessor.java:157)
          ... 16 more
          Caused by: java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Error occurred while deploying ear file C:\SAP\DevStudio\eclipse\workspace\SummitOrder_140207ClientEAR\SummitOrder_140207ClientEAR.ear.
          Reason: Exception while validating application sap.com/SummitOrder_140207ClientEAR.
          No one of the [app_libraries_container, connector] containers, which processed it, returned deployed component names.
          The registered containers in this moment were [com.sap.security.ume, app_libraries_container, Cache Configuration Upload, servlet_jsp, dbcontentcontainer, connector, Cluster File System, JMSConnector, Monitoring Configurator, dbschemacontainer, appclient, orpersistence, JDBCConnector, EJBContainer, webservices_container, scheduler~container].
          Possible reasons :
          1.An AS Java service, which is providing a container, is stopped or not deployed.
          2.The containers, which processed it, are not implemented correct. They deployed or started initially the application, but didn't return deployed components in the application deployment info.
          at com.sap.engine.services.deploy.server.DeployServiceImpl.deploy(DeployServiceImpl.java:302)
          at com.sap.engine.services.dc.gd.impl.ApplicationDeployer.performDeployment(ApplicationDeployer.java:150)
          ... 18 more
    <b>Now what can be the reason for this failure, is there any configuration issues with the server which i have to take care of.
    Also is there any other way of testing a web service in NWDS. I tried using soap sonar as was specified in one article on SDN, but either you have to but that product or use a trial version, which expires after some days.
    Please help me on this.
    Thanks & Regards
    Bhupesh...</b>

    I tried with the project <i>type</i> as 'SAP Application Client Project', then this error comes,
    Publishing failed
      Error during deployment:
          com.sap.ide.eclipse.sdm.deploy.DeploymentException: DeploymentException.
          Reason: An error occurred while deploying the deployment item 'sap.com_DummyClientEAR'.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.dc.gd.DeliveryException: An error occurred during deployment of sdu id: sap.com_DummyClientEAR
          sdu file path: C:\SAP\DevStudio\eclipse\workspace\DummyClientEAR\DummyClientEAR.ear
          version status: NEW
          deployment status: Admitted
          description:
          1. Error:
          Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  com.sap.engine.services.library_container.deploy.LCDeploymentException: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.
          at com.sap.ide.eclipse.sdm.threading.DCDeployThread.run(DCDeployThread.java:145)
    Nested exception -
          com.sap.engine.services.dc.api.deploy.DeployException: DeploymentException.
          Reason: An error occurred while deploying the deployment item 'sap.com_DummyClientEAR'.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.dc.gd.DeliveryException: An error occurred during deployment of sdu id: sap.com_DummyClientEAR
          sdu file path: C:\SAP\DevStudio\eclipse\workspace\DummyClientEAR\DummyClientEAR.ear
          version status: NEW
          deployment status: Admitted
          description:
          1. Error:
          Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  com.sap.engine.services.library_container.deploy.LCDeploymentException: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.
          at com.sap.engine.services.dc.api.deploy.impl.DeployProcessorImpl.deployItems(DeployProcessorImpl.java:734)
          at com.sap.engine.services.dc.api.deploy.impl.DeployProcessorImpl.deploy(DeployProcessorImpl.java:220)
          at com.sap.ide.eclipse.deployer.dc.deploy.DeployProcessor70.deploy(DeployProcessor70.java:111)
          at com.sap.ide.eclipse.sdm.threading.DCDeployThread.run(DCDeployThread.java:119)
          Caused by: com.sap.engine.services.dc.cm.deploy.DeploymentException: An error occurred while deploying the deployment item 'sap.com_DummyClientEAR'.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.dc.gd.DeliveryException: An error occurred during deployment of sdu id: sap.com_DummyClientEAR
          sdu file path: C:\SAP\DevStudio\eclipse\workspace\DummyClientEAR\DummyClientEAR.ear
          version status: NEW
          deployment status: Admitted
          description:
          1. Error:
          Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  com.sap.engine.services.library_container.deploy.LCDeploymentException: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.
          at com.sap.engine.services.dc.cm.deploy.impl.OnlineDeployProcessor.performDelivery(OnlineDeployProcessor.java:186)
          at com.sap.engine.services.dc.cm.deploy.impl.BulkOnlineDeployProcessor.deploy(BulkOnlineDeployProcessor.java:47)
          at com.sap.engine.services.dc.cm.deploy.impl.AbstractDeployProcessor$DeployProcessorHelper.visit(AbstractDeployProcessor.java:177)
          at com.sap.engine.services.dc.cm.deploy.impl.DeploymentItemImpl.accept(DeploymentItemImpl.java:83)
          at com.sap.engine.services.dc.cm.deploy.impl.AbstractDeployProcessor.deploy(AbstractDeployProcessor.java:76)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.performDeploy(DeployerImpl.java:624)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.doDeploy(DeployerImpl.java:483)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:206)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImpl.deploy(DeployerImpl.java:153)
          at com.sap.engine.services.dc.cm.deploy.impl.DeployerImplp4_Skel.dispatch(DeployerImplp4_Skel.java:807)
          at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:253)
          at com.sap.engine.services.rmi_p4.P4Message.execute(P4Message.java:109)
          at com.sap.engine.services.cross.fca.FCAConnectorImpl.executeRequest(FCAConnectorImpl.java:841)
          at com.sap.engine.services.rmi_p4.P4Message.process(P4Message.java:125)
          at com.sap.engine.services.cross.fca.MessageReader.run(MessageReader.java:59)
          at com.sap.engine.core.thread.execution.Executable.run(Executable.java:108)
          at com.sap.engine.core.thread.execution.CentralExecutor$SingleThread.run(CentralExecutor.java:168)
          Caused by: java.rmi.RemoteException:  class com.sap.engine.services.dc.gd.DeliveryException: An error occurred during deployment of sdu id: sap.com_DummyClientEAR
          sdu file path: C:\SAP\DevStudio\eclipse\workspace\DummyClientEAR\DummyClientEAR.ear
          version status: NEW
          deployment status: Admitted
          description:
          1. Error:
          Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  com.sap.engine.services.library_container.deploy.LCDeploymentException: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.
          at com.sap.engine.services.dc.gd.impl.ApplicationDeployer.performDeployment(ApplicationDeployer.java:162)
          at com.sap.engine.services.dc.gd.impl.GenericDeliveryImpl.deploy(GenericDeliveryImpl.java:54)
          at com.sap.engine.services.dc.cm.deploy.impl.OnlineDeployProcessor.performDelivery(OnlineDeployProcessor.java:157)
          ... 16 more
          Caused by: java.rmi.RemoteException:  class com.sap.engine.services.deploy.server.utils.DSRemoteException: Cannot deploy application sap.com/DummyClientEAR. Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved...
          Reason: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.; nested exception is:
          java.rmi.RemoteException:  com.sap.engine.services.library_container.deploy.LCDeploymentException: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.
          at com.sap.engine.services.deploy.server.DeployServiceImpl.deploy(DeployServiceImpl.java:299)
          at com.sap.engine.services.dc.gd.impl.ApplicationDeployer.performDeployment(ApplicationDeployer.java:150)
          ... 18 more
          Caused by: java.rmi.RemoteException:  com.sap.engine.services.library_container.deploy.LCDeploymentException: Class-path entry jaxb-impl.jar specified in C:\SAP\JP1\JC00\j2ee\cluster\server0\temp\deploy\work\deploying\DummyClientEAR.ear1171514810109\jaxb-xjc.jar/META-INF/MANIFEST.MF file cannot be resolved.
          at com.sap.engine.services.library_container.deploy.LibraryContainer.addLibsFromClassPathElement(LibraryContainer.java:328)
          at com.sap.engine.services.library_container.deploy.LibraryContainer.addLibsFromClassPathElements(LibraryContainer.java:290)
          at com.sap.engine.services.library_container.deploy.LibraryContainer.getDeployableFiles(LibraryContainer.java:220)
          at com.sap.engine.services.library_container.deploy.LibraryContainer.deploy(LibraryContainer.java:148)
          at com.sap.engine.services.deploy.server.application.DeploymentTransaction.makeComponents(DeploymentTransaction.java:506)
          at com.sap.engine.services.deploy.server.application.DeployUtilTransaction.commonBegin(DeployUtilTransaction.java:248)
          at com.sap.engine.services.deploy.server.application.DeploymentTransaction.begin(DeploymentTransaction.java:215)
          at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhasesOnOneServer(ApplicationTransaction.java:371)
          at com.sap.engine.services.deploy.server.application.ApplicationTransaction.makeAllPhases(ApplicationTransaction.java:405)
          at com.sap.engine.services.deploy.server.DeployServiceImpl.makeGlobalTransaction(DeployServiceImpl.java:2298)
          at com.sap.engine.services.deploy.server.DeployServiceImpl.deploy(DeployServiceImpl.java:286)
          ... 19 more
    <b>What can be the reason for this?</b>

  • Creating Web Service Client to cater for autentication

    Hello everyone,
    I wonder if you can help me...
    I'm trying to connect a web service client; I have done so in the past with no issues.
    I use the wizard of Eclipse to create the clients, loading in the WSDL file and letting it generate all the classes for me.
    However, this time the WSDL I'm trying to access requires a username and password before you can actually view it in a web browser (it isn't a requirement of calling the methods of the web service, it's literally to access the web service).
    I've loaded the WSDL in okay to create the web service client, but when I try to call any of its methods, I get 401: Unauthorised error message.
    The closest I came to solving it was using this:
              Authenticator.setDefault(new MyAuthenticator(username, password));
    which does allow me to view the actual WSDL and write out the lines of the web page (the HTML), which previously wouldn't work. When I then try to call one of the web service's methods, I get the 401: Unauthorised message again.
    Can anyone give me any pointers? I'm really stuck, and just don't know where to turn. I've looked everywhere online, and just can't find any help.
    Thanks very much in advance.
    Robin

    the web service is the specification for whatever functionality you wish to provide
    there are a few artifacts you can auto-generate using the WSDL, but you still need to create a client and server application
    the web service is simply exposing the application remotely and the WSDL is the contract
    http://java.sun.com/webservices/docs/1.6/tutorial/doc/index.html

  • JDeveloper Web Service Client/Proxy Basic Authentication

    Hi I recently migrated a 10g Web Service to an 11g Web Service that uses basic authentication.
    I then generated the client/proxy using the WSDL for my consumer application in JDeveloper 11g. however I cannot find any functions that will allow me to set the username and password to access the web service.
    For instance, in 10g Client, I simply had to this:
    myPort = new SoapHttpPortClient();
    myPort.setUsername("username");
    myPort.setPassword("password");
    I am not sure how I do the same in the generated Web Service client in 11g.
    Thanks in advance.

    Thanks Frank. I was able to get it to work!
    I did google it but I always add "jdeveloper 11g" in my searches so that must be why this did not come up. :) Thanks again!

  • What is the steps to create the web service client

    I'm quite new to web service and currently need to work on a web application that will call web service by passing the request data. Then will handle the response data. Following are questions that I would like to get your advice.
    First, should I manually develop a schema? The request data will be passed as some element type (I thought a class should be generated and put in the class path), which will be some class with set/get(). Then I will use the schema to get a jar that contains the class file by using the xmlbean? Any example or suggestion on this?
    Secondly, how does the java code in web application send/get the request/response data to/from the web service. Your example will greatly help.
    I read article about WSDL and Schema and Soap. Get very confused on what really should be to follow step by step. Thanks in advance for your help!

    I propose that you start with some introductory tutorials. At seekda you will find two tutorials for newbies:
    1) [Finding and Testing Web Services|http://seekda.com/blog/write-your-first-web-services-client-%e2%80%93-part-1-finding-and-testing-services/]
    2) [Using Web Services|http://seekda.com/blog/write-your-first-web-services-client-part-2-using-services/]
    The second tutorial actually addresses most of your questions.
    Greetings,
    Michal

Maybe you are looking for

  • Trouble with iCloud Contacts & Calender / duplicates from system failure

    Duplicates do appear on iPad Contacts and even duplicate birthday entries. Even on iCloud.com the birthday entries are duplicate. The problem is when you delete a duplicate contact on iPad you lose both! Check on iCloud.com if the contact is really a

  • Server Side Includes like include of a file

    In my case, I have several static HTML files that rarely change. I want to bring these into APEX as a tab but I do not want to rebuild the files as true apex documents. I was wondering if there was a way to pull the existing files into apex and add t

  • Problem with Commit button When Backing bean is in Request Scope...

    HI Everybody, I have a Backing Bean in request scope having over 1000 lines of code, And in my JSPX page I have a table binding with a view object and At run time when user select the row in table and click the edit button so user will be able to edi

  • Can't find my published iCal calendar

    Hello, I published two iCal calendars from my Mac at home, but when I try to pull it up from my PC at work using the url format "http://ical.mac.com/username/calendar" I get "We're sorry but we cannot find the iCal you've requested. It's possible tha

  • NPS authentication against multipe DCs

    hi my work infrastructure contain as follow DC1.abc.local [primary and first root domain DC] DC2.abc.local [secondary DC] DC3.xyz.abc.local [primary DC in second domain] DC4.xyz.abc.local [secondary dc in second domain] NPS01.abc.local [network polic