Chat
Created by Emmanuelle Raffenne, last modified by Gustaf Neumann 24 Nov 2023, at 06:41 PM
Package Specification Summary for Package: chat
Summary: | Server based chat with an html and ajax client. |
Description: | Adapted by Peter Alberer 2006/03/25 to allow java and ajax to coexist. Adapted by Tekne 2006/03/01 to replace JAVA server with AJAX; make use of generalized chat class from xotcl-core. Adapted by Antonio Pisano circa 2016-2019 to reduce bloating and exploit xotcl ORM and server push capabilities. Java server was discontinued in the process. Adapted by Hector Romojaro Gomez 2018-2019 to give a modern look and feel, customizable skins and avatar picture. |
Documentation: | Package Documentation |
Maturity: | Mature |
This package depends on: | acs-kernel acs-tcl acs-templating xowiki |
Packages that depend on chat: | chat-includelet chat-portlet dotlrn-chat |
Package parameters: |
|
Bug Tracker Summary for Package: chat
Open Bugs: | 1 |
All Tracked Issues: | 5 |
Latest Bug Opened: | 2006-04-05 Ajax chat English language catalog incomplete |
Latest Bug Fixed: | 2015-07-25 Russian localization for package chat(HEAD). |
Top Bug Submitters: | Ryan Gallimore (3) Joel Aufrecht (1) Vlad V (1) |
Top Bug Fixers: | Gustaf Neumann (4) |
Code Metrics Summary for Package: chat
# Tcl Procs | 26 |
# Tcl Lines | 1079 |
# Tcl Blank Lines | 127 |
# Tcl Comment Lines | 67 |
# Automated Tests | 0 |
# Stored Procedures | PG: 0 ORA: 0 |
# SQL Lines | PG: 65 (blank 12 comments 12) ORA: 69 (blank 12 comments 12) |
# ADP pages | 17 |
# ADP lines | 340 |
# Include pages (chat/lib/) | 3 |
# Documentation pages | 0 (Package Documentation) |
# Documentation lines | 0 |
Browse Source | API-browser |
Github Repository: | https://github.com/openacs/chat/tree/oacs-5-10 |
The chat package is currently using two different chat engines:
- The Java applet and the Java chat server, or
- the Ajax based chat class from xotcl-core
If no xotcl-core is installed, one can only use the version with Java applet. If xotcl-core is installed, one has to option to choose between both engines via parameter.
In essence, the Ajax based variant is the chat implementation from xowiki plus chat room management and a list of the currently connected users. Originally, the AJAX-based chat class (::xo::Chat) was developed for xowiki, but later moved to xotcl-core such that the chat package does not need a dependency on xotcl-core and xowiki.
Actually, the chat support in xowiki contains a different variety of AJAX based communication strategies:
- Polling mode (the web browser queries via AJAX in definable intervals the server, and checks, if there is some new information available), and
- Streaming mode (the client opens a connection to the server, the server pushes the information back to the client. xowiki chat supports two different sub-modes:
- streaming of JSON objects via asynchronous AJAX sockets, or
- scripted streaming, where the browser loads HTML with embedded script tags in the background from a hidden iframe
Both (2a) and (2b) require libthread installed and NaviServer. However, the advantage of the streaming approaches is that they are much faster in the look and feel and that they are better scalable on sites with a high load. 2a works only on Firefox (not in current versions of IE or Safari) and has the advantage over 2b that the browser does not show the background activity (no spinning wheel in Firefox). 2b is more robust and works with Safari, IE and Firefox (the information about the browser support is from 2006, and most probably different today). Both streaming modes implement, what is sometimes called COMET.
When the chat package uses the ::xo::Chat, it uses it only in currently only polling mode, which has the least requirements. This has been as well tested with (Firefox, IE and Safari).