Skip to content

Getting Started with the samples

jfarcand edited this page May 14, 2012 · 29 revisions

The table below describes every Atmosphere's sample by defining the server and client API used to build it. You can download the sample by clicking on its name.

<
Sample Name Description Server Components Client Components Language
[all-api-pubsub](http://search.maven.org/#artifactdetails%7Corg.atmosphere.samples%7Catmosphere-all-api-pubsub%7C0.9.4%7Cwar) This sample implements a pubsub example that demonstrates all Atmosphere's API and extension. The use of AtmosphereResource, Meteor, Annotation like @Suspend and @Broadcast are demonstrated [AtmosphereHandler](https://github.com/Atmosphere/atmosphere/blob/master/samples/all-api-pubsub/src/main/scala/org/atmosphere/samples/pubsub/websocket/AtmosphereHandler.scala) [Jersey Resource](https://github.com/Atmosphere/atmosphere/blob/master/samples/all-api-pubsub/src/main/scala/org/atmosphere/samples/pubsub/websocket/Resource.scala) [Meteor](https://github.com/Atmosphere/atmosphere/blob/master/samples/all-api-pubsub/src/main/scala/org/atmosphere/samples/pubsub/websocket/Meteor.scala) [WebSocketProtocol](https://github.com/Atmosphere/atmosphere/blob/master/samples/all-api-pubsub/src/main/scala/org/atmosphere/samples/pubsub/websocket/DevoxxWebSocketProtocol.scala) Single [Callback](https://github.com/Atmosphere/atmosphere/blob/master/samples/all-api-pubsub/src/main/webapp/index.html) supporting WebSocket, Long-Polling, JSONP, Http-Streaming Javascript, Scala
[async-annotation-pubsub](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-async-channel%22) This sample demonstrates the use of the @Asynchronous annotation combined with the Callable> API, showing how an application can be fully asynchronous in its execution. The sample implements the pubsub concepts. [Jersey Resource](https://github.com/Atmosphere/atmosphere/blob/master/samples/async-annotation-pubsub/src/main/java/org/atmosphere/samples/pubsub/AsynchronousAnnotation.java) Single [Callback](https://github.com/Atmosphere/atmosphere/blob/master/samples/async-annotation-pubsub/src/main/webapp/index.html#L36) supporting WebSocket, Long-Polling, JSONP, Http-Streaming Javascript, Java
[atmosphere-ee6](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-ee6%22) This sample demonstrates the use of @Suspend with Java EE's 6 annotation like @Resource and EJB Timer [Jersey Resource](https://github.com/Atmosphere/atmosphere/blob/master/samples/atmosphere-ee6/src/main/java/org/jersey/devoxx/samples/ee6/atmosphere/TimerResource.java) Http-Streaming Java
[channel](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-channel%22) This sample demonstrate the use of @Subscribe and @Publish annotation using a pub sub application. If you are migrating from CometD, this sample is for you. [Jersey Resource](https://github.com/Atmosphere/atmosphere/blob/master/samples/channel/src/main/java/org/atmosphere/samples/pubsub/TypedChannel.java) Java
[chat-guice](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-guice-chat%22) This sample demonstrate the use of Google Guice with Atmosphere. The Chat application is implemented using @Suspend and @Broadcast annotation [Guice](https://github.com/Atmosphere/atmosphere/blob/master/samples/chat-guice/src/main/java/org/atmosphere/samples/guice/GuiceChatModule.java) [Jersey Resource](https://github.com/Atmosphere/atmosphere/blob/master/samples/chat-guice/src/main/java/org/atmosphere/samples/guice/ResourceChat.java) Javascript Functions demonstrating [WebSocket, falling back to Long-Polling](https://github.com/Atmosphere/atmosphere/blob/master/samples/chat-guice/src/main/webapp/jquery/application.js) Javascript, Java
[chat](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-chat%22) This sample demonstrates the use of WebSocket (falling back to Long-Polling) using a simple AtmosphereHandler. The sample also demonstrates how to detect which transport are supported by the client and server by negotiating with the server. [AtmosphereHandler](https://github.com/Atmosphere/atmosphere/blob/master/samples/chat/src/main/java/org/atmosphere/samples/chat/ChatAtmosphereHandler.java) Javascript Functions demonstrating [WebSocket, falling back to Long-Polling](https://github.com/Atmosphere/atmosphere/blob/master/samples/chat/src/main/webapp/jquery/application.js). Code demonstrating how to negotiate with the server demonstrated as well Javascript, Java
[di-guice-sample](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-di-guice-sample%22) The sample demonstrates the use of Atmosphere's Dependencies Injection using Guice [Jersey Resource](https://github.com/Atmosphere/atmosphere/blob/master/samples/di-guice-sample/src/main/java/org/atmosphere/samples/di/guice/MessageResource.java) [Guice](https://github.com/Atmosphere/atmosphere/blob/master/samples/di-guice-sample/src/main/java/org/atmosphere/samples/di/guice/GuiceContextListener.java) [Javascript Callback](https://github.com/Atmosphere/atmosphere/blob/master/samples/di-guice-sample/src/main/webapp/index.html#L46) Javascript, Java
[gwt-demo](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-gwt-demo%22) This samples demonstrates the use of the Atmosphere GWT extension. [GWT](https://github.com/Atmosphere/atmosphere/blob/master/samples/gwt-demo/src/main/java/org/atmosphere/samples/server/AtmosphereHandler.java) [GWT](https://github.com/Atmosphere/atmosphere/blob/master/samples/gwt-demo/src/main/java/org/atmosphere/samples/client/GWTDemo.java) Java
[gwt-jsdemo](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-gwt-jsdemo%22) This sample demonstrates the use of the GWT Javascript client [GWT](https://github.com/Atmosphere/atmosphere/blob/master/samples/gwt-jsdemo/src/main/webapp/index.html) [GWT Javascript Library](https://github.com/Atmosphere/atmosphere/blob/master/samples/gwt-jsdemo/src/main/webapp/index.html) Language
[jaxrs2-chat](http://search.maven.org/#search%7Cga%7C1%7Ca%3A%22atmosphere-jaxrs2-chat%22) This samples demonstrates the use of JAX RS Specification 2 using the @Context, ExecutionContext and @Suspend annotation [Jersey Resource](https://github.com/Atmosphere/atmosphere/blob/master/samples/jaxrs2-chat/src/main/java/org/atmosphere/samples/chat/jersey/Jaxrs2Chat.java)Javascript Functions demonstrating [WebSocket, falling back to Long-Polling](https://github.com/Atmosphere/atmosphere/blob/master/samples/jaxrs2-chat/src/main/webapp/jquery/application.js) Java
[jquery-atmospherehandler-pubsub](http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22org.atmosphere.samples%22%20AND%20a%3A%22atmosphere-atmospherehandler-pubsub%22) This sample demosntrates the use of AtmosphereHandler for implementing a pub sub application. The sample supports Long-Polling, Http Streaming and WebSocket [AtmosphereHandler](https://github.com/Atmosphere/atmosphere/blob/master/samples/jquery-atmospherehandler-pubsub/src/main/java/org/atmosphere/samples/pubsub/AtmosphereHandlerPubSub.java#L39) [Javascript Function](https://github.com/Atmosphere/atmosphere/blob/master/samples/jquery-atmospherehandler-pubsub/src/main/webapp/index.html) Language

Step by Step Tutorials

Concepts & Architecture

15 Minutes Tutorial

Advanced Topics

API

Known WebServer Issues

References

External Documentations

githalytics.com alpha

Clone this wiki locally