Giter Club home page Giter Club logo

chatserver's People

Contributors

andrewriehm avatar

chatserver's Issues

Deployment

Figure out how to deploy this to an Amazon EC2 instance (or some equivalent).

Need central way of getting a room or user name

Something like ChatManager::GetRoomName(string name) that returns the actual name if it exists, or "" if it doesn't.

Same thing for user names. And these functions should be able to deal with case differences gracefully.

Read all the waiting bytes

Right now I'm only reading into a fixed-size buffer. Need to read all available data (might be more than what fits in the buffer).

Don't run as root

In Server.cpp::main(), need to check and see if we're root, and if so, drop down.

Thread safety!

Need to add mutex / locks around all sensitive stuff in ChatManager.

Wordtionary!

Make a word guessing game. The one giving hints is the SUPREME COMMANDER OMEGA. SCO gets to see the word at the beginning of a round, he can give hints. Everyone else tries to guess the word. First person to guess the word becomes the new SCO, and a new round begins.

Non-blocking IO in ClientHandler

Need to make the main handle loop nonblocking, so the chat server can send stuff to the client without having to wait for the client to send something first...

Get listPeeps working

If no args are specified, should list all users on the server (perhaps showing what room they're in?)
If an arg is given, list all users in the room specified by 'arg'

Unfork and threadify

Need to spawn new threads to handle clients, so they can more easily access the shared ChatManager object.

Unit tests!

Figure out best way to implement unit tests for ClientHandler and ChatManager classes.
Also need to integrate the tests into the build system.

Make a ChatManager class

Needs to have methods for adding/removing a user, creating rooms, join/unjoin a user and a room, post new messages to rooms, send a message to a user, list who is in a room

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.