Hi Sergey,

It happens when the proxy initilises invocations because then after it succeeds 
calling the actual service.

Piotr

> From: [email protected]
> To: [email protected]
> Subject: Re: "Already Connected" message when try to route to cxf rest service
> Date: Mon, 22 Jun 2009 12:29:09 +0100
> 
> Hi Piotr
> 
> Can you please provide some more info ?
> 
> Does it happen after the initial invocation succeeds (you said responses were 
> ok), when using the same proxy to perform subsequent 
> invocations ? Or when you use a proxy inside some server code which attempts 
> to route ?
> 
> thanks, Sergey
> 
> ----- Original Message ----- 
> From: "Piotr Skawinski" <[email protected]>
> To: "cxf users mailing list" <[email protected]>
> Sent: Sunday, June 21, 2009 11:21 AM
> Subject: "Already Connected" message when try to route to cxf rest service
> 
> 
> 
> Hi,
> 
> I get an "Already connected" error message from the cxf client when a message 
> is send to the cxf rest service. The service seems to 
> work fine. The requests are consumed fine as well as the responses returned 
> to the client but the client throw the below error 
> message. The cxf client is initilized in the following way:
> 
> SecurityServiceInvocation client = 
> JAXRSClientFactory.create(securityServiceUrl, 
> SecurityServiceInvocation.class);
> 
> The error message from the client:
> 
> java.lang.IllegalStateException: Already connected
>         at 
> java.net.HttpURLConnection.setFixedLengthStreamingMode(HttpURLConnect
> ion.java:103)
>         at 
> org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.thresho
> ldNotReached(HTTPConduit.java:1841)
>         at 
> org.apache.cxf.io.AbstractThresholdOutputStream.close(AbstractThresho
> ldOutputStream.java:99)
>         at 
> org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.close(H
> TTPConduit.java:1929)
>         at 
> org.apache.cxf.transport.AbstractConduit.close(AbstractConduit.java:6
> 6)
>         at 
> org.apache.cxf.transport.http.HTTPConduit.close(HTTPConduit.java:626)
> 
>         at 
> org.apache.cxf.interceptor.MessageSenderInterceptor$MessageSenderEndi
> ngInterceptor.handleMessage(MessageSenderInterceptor.java:62)
>         at 
> org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseIntercept
> orChain.java:226)
>         at 
> org.apache.cxf.jaxrs.client.ClientProxyImpl.doChainedInvocation(Clien
> tProxyImpl.java:412)
>         at 
> org.apache.cxf.jaxrs.client.ClientProxyImpl.invoke(ClientProxyImpl.ja
> va:166)
>         at $Proxy18.addPermission(Unknown Source)
>         at 
> com.axiell.arena.services.security.service.connectors.SecurityService
> Connector.addPermission(SecurityServiceConnector.java:58)
>         at 
> com.axiell.arena.services.security.functional.SecurityFunctionalTest.
> testPermissions(SecurityFunctionalTest.java:45)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> java:39)
>         at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> 
> 
> 
> Thx in advance, Piotr
> 
> _________________________________________________________________
> Show them the way! Add maps and directions to your party invites.
> http://www.microsoft.com/windows/windowslive/products/events.aspx 
> 

_________________________________________________________________
More than messages–check out the rest of the Windows Live™.
http://www.microsoft.com/windows/windowslive/

Reply via email to