start of websocket transport support
WebSocket support and various improvements