block for socket-connections and websocket serfver