Chat House
Introduction
Chat programs are very popular at present time. You can
find chat ability almost at any portal type web site. But, when I decided to
setup one on my web server and did a search at jars.com, then I have
found only three(!) servlet based chats. Other search engine gave me even worse
result. No one has satisfied my needs, so I have decided
to write my own. My implementation is not sophisticated and quite restricted,
but since it's open source it can be interesting for some people.
Got started
I made the following goals, when started the design:
- No applet. I like applets much, but we could expect
that big players on market of browsers can drop Java soon. Another reason was
that some firewalls filter any Java appearance for a security purpose. And
finally, I have already implemented an applet based chat in the past.
- An attempt to implement a server push model. It should
make chat smooth as it's going on an applet versions.
- Provide good internationalization support lacked in many applet based
chats.
- Gives possibility to do file exchange. It should be a
killing feature of my chat.
- No JavaScript and HTML 4.0 or to keep it minimal.
- Make it customizable as possible and even to provide WAP/WML support.
Features
All goaled features were accomplished. Just summarize them:
- Multiroom chat capabilities with possibilities as using
predefined rooms in specified char set as a user created rooms in default char
set.
- Easy navigation between rooms with displaying
room visitors.
- Locking predefined rooms by chat participants request for new visitors and
unlocking them when all left.
- Automatically dispose a user created room when number
of visitors reached 0.
- Using push server capabilities offered by Microsoft and
Netscape browsers with manual and automatic refresh features. Netscape 6.x
browsers are not supported, shame on Netscape first proposed a server push model.
- A fully customizable L&F with a template based page
design.
- An ability to upload a file to a chat message with
following possibility to download the uploaded file by all chat participants
(GonnaSee® technology).
- Switching to a private conversation with a selected chat participant.
- All chat parameters are configurable without any code
change.
- E-mail notification about a chat house activity including instant
e-mailing of an invitation.
- Message board capability to publish news and other message right at front
of the Chat House entrance.
- All in one instant installation, when you can start immediately after download
without touching anything (Download&Play® technology). Preinstalled JDK 1.3
or above is
required.
Implementation Notices
The implementation is pretty simple and cool (see
sources), thanks a simple and powerful DemRog
class library. GonnaSee® technology is based on an implementation of
multipart-form-data has been done for UploadServlet.
About MIME types allow server push model, see multi part content
types.
Installation
Make sure that you have JDK 1.3 or better installed on your server machine. Unzip
distributed zip file to your hard disk and type java -jar chathouse.jar or
just double click the jar if you are using Windows and File Explorer.
Start your browser and try to reach http://localhost:81.
If you need modify some setting, just look in to other files provided with the
jar. You can try already
running version.
Competitors again
When I almost finish my chat program (it took less than 3 days), I have found
more servlet based chats much better quality, then I saw initially at jars.com.
To my surprise, my implementation was not so bad in comparison to the best
competitor's product, as jzChat. I would
recommend jzChat to everyone, who seriously consider using servlet based
chat program on a web site. (Never use free stuff, unless you steal it.)
Licensing
The version is free as long you use copyright notice below in source or
binary from distribution.
Copyright
All sources and binaries are copyright © by Dmitriy Rogatkin 1999-2006. The
instant running
version is based on some sources of Acme Java Web Server copyrighted by its author.
Go back