Book Image

Oracle ADF Faces Cookbook

By : Amr Gawish, Amr Ismail Gawish
Book Image

Oracle ADF Faces Cookbook

By: Amr Gawish, Amr Ismail Gawish

Overview of this book

Table of Contents (18 chapters)
Oracle ADF Faces Cookbook
Credits
About the Author
Acknowledgments
About the Reviewers
www.PacktPub.com
Preface
Index

Using WebSockets for more interactive applications


WebSocket is a new protocol that was standardized in 2011 and provides two-way communication channels over a single TCP connection. It is designed to work with web browsers and web servers, and it has native JavaScript APIs in all modern browsers. The WebSocket protocol is totally independent from the HTTP protocol, and it can have a secured and unsecured layer just like the HTTP protocol. Starting with Weblogic 12c, it supports the WebSocket APIs fully, and we are going to use it in this recipe to create a small, anonymous chat client.

There is no model for this project, and this is a separate application from previous recipes. So, you should grab the ADFFacesWebSockets application from the Git repository directly.

How to do it…

To learn how to use ADF Faces with WebSockets, we first need to include the weblogic library inside our application. Follow the ensuing steps to do this:

  1. Open the ADFFacesWebSockets application.

  2. Right-click on ViewController...