This Confluence has been LDAP enabled, if you are an ASF Committer, please use your LDAP Credentials to login. Any problems file an INFRA jira ticket please.

Child pages
  • Atmosphere-Websocket
Skip to end of metadata
Go to start of metadata

Atmosphere Websocket Servlet Component

Available as of Camel 2.14

The atmosphere-websocket: component provides Websocket based endpoints for a servlet communicating with external clients over Websocket (as a servlet accepting websocket connections from external clients).
The component uses the SERVLET component and uses the Atmosphere library to support the Websocket transport in various Servlet containers (e..g., Jetty, Tomcat, ...).

Unlike the Websocket component that starts the embedded Jetty server, this component uses the servlet provider of the container.

Maven users will need to add the following dependency to their pom.xml for this component:

    <!-- use the same version as your Camel core version -->

URI Format

atmosphere-websocket:///relative path[?options]

Reading and Writing Data over Websocket

An atmopshere-websocket endpoint can either write data to the socket or read from the socket, depending on whether the endpoint is configured as the producer or the consumer, respectively.

Configuring URI to Read or Write Data

In the route below, Camel will read from the specified websocket connection.


And the equivalent Spring sample:

<camelContext xmlns="">
    <from uri="atmosphere-websocket:///servicepath"/>
    <to uri="direct:next"/>

In the route below, Camel will read from the specified websocket connection.


And the equivalent Spring sample:

<camelContext xmlns="">
    <from uri="direct:next"/>
    <to uri="atmosphere-websocket:///servicepath"/>


  • No labels