Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Websockets echo demo over Brubeck #98

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

fleephub
Copy link

In connections.py

  • Removed many unneccessary imports (ujson should also be removed
  • From connection class removed lots of stuff that was left hanging
    there after wsgi support was added. Seems that there are only
    two shared methods in current implementation and all the rest of
    the code was just complicating code and creating confusion
  • Did some cleanup in Mongrel2Connection but there is probably
    more room to make it consisten and nice to use
  • Removed hardcoding for only http responses from process_message
    so now it can be used also for websocket responses

In request_handling.py

  • Removed some unneccessary imports
  • Removed uncommented and unneccessary function render() from module level.
    All calls to this replaced with appropriate http_response calls
    Also cleaned up ungly cross importing between modules that was in the way
    for websockets

In m2reader.py

  • Set connect string to match mongrel2 conf in demos dir.

In demo_websocket.py

  • Quite simplistic impleetation of websockets echo server.
    I plan to write decent support but i would like to get the
    fixed common code first incorporated into brubeck

… that

can be used to start building your own websocekt handler.

In connections.py
- Removed many unneccessary imports (ujson should also be removed
- From connection class removed lots of stuff that was left hanging
  there after wsgi support was added. Seems that there are only
  two shared methods in current implementation and all the rest of
  the code was just complicating code and creating confusion
- Did some cleanup in Mongrel2Connection but there is probably
  more room to make it consisten and nice to use
- Removed hardcoding for only http responses from process_message
  so now it can be used also for websocket responses

In request_handling.py
- Removed some unneccessary imports
- Removed uncommented and unneccessary function render() from module level.
  All calls to this replaced with appropriate http_response calls
  Also cleaned up ungly cross importing between modules that was in the way
  for websockets

In m2reader.py
- Set connect string to match mongrel2 conf in demos dir.

In demo_websocket.py
- Quite simplistic impleetation of websockets echo server.
  I plan to write decent support but i would like to get the
  fixed common code first incorporated into brubeck
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants