You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@camel.apache.org by "Claus Ibsen (Jira)" <ji...@apache.org> on 2022/09/02 17:35:00 UTC

[jira] [Resolved] (CAMEL-16046) camel-ahc-ws client serving as both a producer and consumer

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

Claus Ibsen resolved CAMEL-16046.
---------------------------------
    Resolution: Won't Fix

> camel-ahc-ws client serving as both a producer and consumer
> -----------------------------------------------------------
>
>                 Key: CAMEL-16046
>                 URL: https://issues.apache.org/jira/browse/CAMEL-16046
>             Project: Camel
>          Issue Type: New Feature
>          Components: camel-vertx-websocket
>    Affects Versions: 2.23.4
>         Environment: N/A 
>            Reporter: Josh West
>            Priority: Major
>             Fix For: 3.x
>
>
> While subscribing to a websocket using camel-ahc-ws the connection and session is sometimes bidirectional.  A session may be initiated to subscribe to specific data points by sending a message over the same session as the producer (incoming) exchange. 
>   
>  from("ahc-wss://ws-feed.example.com").routeId("incoming")
>     .log("received message: ${body}");
>   
>  from("timer:wssfeedInitaitor?delay=10&repeatCount=1").routeId("feed-initiator")
>     .setBody().constant(WSS_SUBSCRIBE)
>     .to("ahc-wss://ws-feed.example.com")
>     .log("received message on initiator: ${body}");
>   
>  The current behavior is that the "incoming" route connects but doesn't receive any data. 
>  The "feed-initiator" router successfully sends the subscribe message to the remote endpoint and starts receiving data. The websocket data received is only showing up in WsListener DEBUG logging messages "[cHttpClient-3-1] o.a.camel.component.ahc.ws.WsEndpoint : Received message --> ..." without the data on the exchange. The logging is coming from the "feed-initator" route, which is not logging messages using the route given the initiator is in wrong mode.
>   
>  Is there a way to share the same session? 
>   
>  Otherwise can the component be enhanced to serve as both a producer and consumer at the same time? 
>   
>   



--
This message was sent by Atlassian Jira
(v8.20.10#820010)