Announcement Announcement Module
No announcement yet.
One username per Service (Spring JAXRPC Remoting) Page Title Module
Move Remove Collapse
Conversation Detail Module
  • Filter
  • Time
  • Show
Clear All
new posts

  • One username per Service (Spring JAXRPC Remoting)

    We are using Axis 1.2.1 and Spring 2.0.x to invoke a remote webservice using a password callback defined in a client-deploy.wsdd file as follows:

    <deployment xmlns="" xmlns:java="">
          <transport name="http" pivot="java:org.apache.axis.transport.http.HTTPSender" />
                      <handler type="">
                            <parameter name="action" value="UsernameToken" />
                            <parameter name="user" value="USERNAME" />
                            <parameter name="passwordCallbackClass" value="package.PasswordCallback" />
                            <parameter name="passwordType" value="PasswordText" />
                            <parameter name="mustUnderstand" value="false" />
    This sends our username and password with *all* webservices invoked through the Axis (client). However, we would like to configure which username and password have to be used for each service individually.

    In our Spring configuration we define a webservice (client) as follows, extending a JaxRpcPortProxyFactoryBean by package.MyServiceJaxRpcPortProxy:

      <bean id="MyServiceBean" class="package.MyServiceJaxRpcPortProxy">
        <property name="serviceFactoryClass" value="org.apache.axis.client.ServiceFactory" />
        <property name="wsdlDocumentUrl" value="http://host/MyService.wsdl" />
        <property name="namespaceUri" value="http://host/myservice" />
        <property name="serviceName" value="MyService" />
        <property name="portName" value="MySOAPPort" />
        <property name="serviceInterface" value="package.MyService" />
    Do you know if and how it would be possible to configure Spring (by overriding the base class, maybe?) for a specific JaxRpcPortProxy in which we could define a custom username per service (for instance by changing the wsdd) ?

    Thanks in advance, best regards,


  • #2
    spring configuration of .wsdd

    I also have the same requirement in my project, and im stuck up with the initial stages itself. if you have already solved the issues, can you please tell me how and where you have configured the .wsdd file, where did u put this file and how the spring injections are done.