[ 
https://issues.apache.org/jira/browse/CXF-5646?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ankush updated CXF-5646:
------------------------

    Description: 
Hello team,

I am workign on CXF and want to have my response of my TestConnection like 
below :

<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema";><soap:Body><TestConnectionResponse 
xmlns="http://tempuri.org/";><TestConnectionResult>Hello 
World</TestConnectionResult></TestConnectionResponse></soap:Body></soap:Envelope>


But I am getting like below,

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";>
<soap:Body>
<ns1:TestConnectionResponse xmlns:ns1="http://tempuri.org";>
<TestConnectionResult>Hello World</TestConnectionResult>
</ns1:TestConnectionResponse>
</soap:Body>
</soap:Envelope>

So how to add  <?xml version="1.0" encoding="utf-8"?>   in my response and Is 
it possible to remove ns1 from TestConnectionRespopnse element?

I am using CXF without Spring. 

My Interface looks like : 
@WebService(targetNamespace="http://tempuri.org";)

public interface EFIRedirectConfig extends Remote
{

        @WebResult(partName="TestConnectionResult")
    public String TestConnection() throws RemoteException;
}

And My server code : 

                JaxWsServerFactoryBean  svrFactory = new JaxWsServerFactoryBean 
();
                svrFactory.setServiceClass(EFIRedirectConfig.class);
                svrFactory.setAddress("/EFIRedirectConfig");
                svrFactory.setServiceBean(new 
DefaultEFIRedirectConfig(m_webAppURLCreator,m_objectModel));
                svrFactory.getServiceFactory().setDataBinding(new 
XmlBeansDataBinding());
                svrFactory.create();


  was:
Hello team,

I am workign on CXF and want to have my response of my TestConnection like 
below :

<?xml version="1.0" encoding="utf-8"?><soap:Envelope 
xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"; 
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
xmlns:xsd="http://www.w3.org/2001/XMLSchema";><soap:Body><TestConnectionResponse 
xmlns="http://tempuri.org/";><TestConnectionResult>Hello 
World</TestConnectionResult></TestConnectionResponse></soap:Body></soap:Envelope>


But I am getting like below,

<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";>
<soap:Body>
<ns1:TestConnectionResponse xmlns:ns1="http://tempuri.org";>
<TestConnectionResult>Hello World</TestConnectionResult>
</ns1:TestConnectionResponse>
</soap:Body>
</soap:Envelope>

So is it possible to remove ns1 from TestConnectionRespopnse element?

I am using CXF without Spring. 

My Interface looks like : 
@WebService(targetNamespace="http://tempuri.org";)

public interface EFIRedirectConfig extends Remote
{

        @WebResult(partName="TestConnectionResult")
    public String TestConnection() throws RemoteException;
}



> Need to remove ns1 from  soapbody
> ---------------------------------
>
>                 Key: CXF-5646
>                 URL: https://issues.apache.org/jira/browse/CXF-5646
>             Project: CXF
>          Issue Type: Bug
>            Reporter: ankush
>
> Hello team,
> I am workign on CXF and want to have my response of my TestConnection like 
> below :
> <?xml version="1.0" encoding="utf-8"?>
> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"; 
> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
> xmlns:xsd="http://www.w3.org/2001/XMLSchema";><soap:Body><TestConnectionResponse
>  xmlns="http://tempuri.org/";><TestConnectionResult>Hello 
> World</TestConnectionResult></TestConnectionResponse></soap:Body></soap:Envelope>
> But I am getting like below,
> <soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/";>
> <soap:Body>
> <ns1:TestConnectionResponse xmlns:ns1="http://tempuri.org";>
> <TestConnectionResult>Hello World</TestConnectionResult>
> </ns1:TestConnectionResponse>
> </soap:Body>
> </soap:Envelope>
> So how to add  <?xml version="1.0" encoding="utf-8"?>   in my response and Is 
> it possible to remove ns1 from TestConnectionRespopnse element?
> I am using CXF without Spring. 
> My Interface looks like : 
> @WebService(targetNamespace="http://tempuri.org";)
> public interface EFIRedirectConfig extends Remote
> {
>       @WebResult(partName="TestConnectionResult")
>     public String TestConnection() throws RemoteException;
> }
> And My server code : 
>                 JaxWsServerFactoryBean  svrFactory = new 
> JaxWsServerFactoryBean ();
>               svrFactory.setServiceClass(EFIRedirectConfig.class);
>               svrFactory.setAddress("/EFIRedirectConfig");
>               svrFactory.setServiceBean(new 
> DefaultEFIRedirectConfig(m_webAppURLCreator,m_objectModel));
>               svrFactory.getServiceFactory().setDataBinding(new 
> XmlBeansDataBinding());
>               svrFactory.create();



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to