forked from petersen-rex/nodechat
timcubb/nodechat
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Folders and files
Name | Name | Last commit message | Last commit date | |
---|---|---|---|---|
Repository files navigation
I found some overly complicated examples of chat servers using NodeJs so I set out to create a simple example. The client connects and waits for a response. The server preserves a list of connected clients in the responses[] array. Once the server has satisfied one request, the response element is deleted for that client. So the server's only state information is a list of clients who are currently expecting a response and that list is completely destructed every time a message is broadcast. Subsequently the client receives the message and reconnects. So, from the clients perspective there is always one outstanding ajax request. If a client drops, his connection will be automatically purged from the list on the next iteration. -Rex To Run: from the install directory: node nodechatserver.js then browse to: localhost:8080/nodechat.html
About
Simple Chat client and server using NodeJS and JQuery
Resources
Stars
Watchers
Forks
Releases
No releases published
Packages 0
No packages published