Questions tagged [websocket]

WebSocket is an API and a protocol for bi-directional, full-duplex communication that is closely associated with HTML5 and implemented in recent versions of most web browsers.

Filter by
Sorted by
Tagged with
1
vote
1answer
29 views

Updating state with React and Websockets

I'm working on a React app with websocket. In this app there is a socket event listener which returns 3 types: add, change, and <...
3
votes
0answers
93 views

Middleware which lets developer maintain dynamic context

Problem Statement: Users can chat while the replies of the chatbot are based on past messages. So the chatbot needs to have the context of the previous messages and reply accordingly. Here is ...
5
votes
1answer
158 views

Node websockets

I have this code I use it for two things connect to lxd instances and emits any operation events it recieves over socket.io to the client Bridge between client and lxd for terminals Its pretty ...
4
votes
0answers
96 views

Python server that performs sentiment analysis on Twitter data

I have a fully working Python server that utilizes Tornado, asyncio, websockets and tweepy(Twitter's Streaming api). The main point of this server is to receive a query from the user, call upon tweepy ...
1
vote
0answers
121 views

Angular Websocket service with wait for response sending

I am writing an Angular Websocket service that can send messages to a server and then can subscribe to the response. I am grateful for every suggestion to improve this. ...
7
votes
0answers
1k views

Sending notifications with Django channels

I have project on Django wich use Django Channels. I use Django Channel for sending notifications to users who are subscribed to articles changes (adding/editing/deleting comments on article). So I'...
4
votes
1answer
405 views

Spring Boot Websocket STOMP Crud

I have a personal project that runs the backend under spring boot that implements websocket for real-time functionality and I apply it to a crud operations. Although the code is working and work as ...
4
votes
0answers
207 views

An in-memory copy of the GDAX order book for an arbitrary cryptocurrency, updated in real time

GDAX is the cryptocurrency exchange owned and operated by Coinbase. This code is intended to be the basis for an order-book-strategy trading bot. I'd love feedback on my use of data structures, my ...
2
votes
0answers
32 views

Websocket 'onmessage' logger to MongoDB

I'm learning websockets and wanted to make a websocket onmessage logger which writes the received data in a mongodb. I'm starting my script with ...
10
votes
1answer
114 views

Cardshifter chat lobby using vanilla JS

This is part 2 of my re-writing of a Angular client to vanilla JS. Part 1 is here: Cardshifter login page using vanilla JavaScript This animated GIF illustrates the basic functionality of the lobby. ...
1
vote
0answers
833 views

WebSocket example with akka-http

Akka-http supports WS connections like that: ...
9
votes
1answer
272 views

Cardshifter login page using vanilla JavaScript

I'm working on rewriting the Cardshifter HTML Client with vanilla JavaScript, the original HTML Client is written with Angular but I really wanted to stay away from anything npm and just go back to ...
1
vote
0answers
100 views

Update WebApp Time with GoRoutine + Websocket

I have created a Golang WebApp that shows the time. I am new to the Golang programming language so thought this little app would allow me to use golang as a webserver, learn about goroutines and ...
1
vote
0answers
175 views

WebSocket based API library in Julia

I made a very bare-bones API "library" in Julia which should abstract the interaction with the API. The API is fairly complex - it's based around 2 core layers an HTTPS/REST API for general ...
2
votes
1answer
267 views

Handling several types of messages over a web socket connection

I have a UIViewController with a Socket Connection established once viewDidLoad. This web socket is a multi-directional ...
3
votes
2answers
2k views

Python WebSocket Server + SQLite + Multiprocessing

I have been wanting to learn more about developing web applications using WebSockets so, with the help of various online tutorials, I built a little Python WebSocket server using Tornado and SQLite. ...
3
votes
0answers
1k views

Using websocket to show progress for slow action with ASP.NET Core MVC

I have a process that takes a substantial amount of time (several minutes) and would like to trigger it from a web browser and give feedback to the user that it is working. I created some code that ...
3
votes
0answers
1k views

Send Opencv::Mat image from Qt application to HTML client, using websocket

I wrote an application in C++ using Qt 5.7, basically is a websocket server, using qwebsocket for this, capable to send an image elaborated with OpenCV to an HTML client. In order to do this I encode ...
3
votes
1answer
998 views

WebSocket API that connects to ASP.NET Core Backend

I'm writing this API that connects to my ASP.NET Core Cloud App and listens for potential Database changes from my CMS. The code runs and works fine but I'm not sure if my code is considered "good" ...
1
vote
1answer
81 views

Java websocket class

I'm developing an architecture with multiple users communicating with each other via server (Glassfish). Inspiration for this was: http://www.oracle.com/webfolder/technetwork/tutorials/obe/java/...
1
vote
0answers
302 views

Simple websocket loop that outputs on an interval

This is a simple app, made with koa, that grabs a question from a database of questions and sends them over websocket. It feels really messy to me. ...
2
votes
1answer
379 views

Golang WebSocket communication between server and app

I've written a simple application that captures frames from my webcam and streams the frames via a websocket. The stream implementation I've come up with feels weird. Networking is not my strong suit....
2
votes
0answers
671 views

Online Snake v0.1 with Python-flask and socketio

What I am essentially doing is writing a snake game that everybody could play on the internet, broadcast their game if they like and so on. Now it looks like this, just websocket-based snake, no user ...
7
votes
1answer
301 views

Robust websocket server for use by a game running on node

This code is a server for websocket connections, it handles the low level stuff and delegates incoming messages to handler objects. I wanted performance to win in any trade off against maintenance ...
7
votes
1answer
598 views

Electron Application with JavaScript Backdoor and Ruby Command-Line Listener

I have created an Electron Application with a JavaScript/NodeJS Backdoor and a Ruby command-line listener. I created this program for remote administration of my home computer securely using a new ...
1
vote
0answers
93 views

Npm-module: socket-event

I've written a small npm module. It is my first module. I'm asking you to review several things: The code. I am rather starter, so any wise critic will be super. Any suggestions or ideas on the ...
2
votes
1answer
350 views

Pass canvas content from client to admin using web socket

The application's aim is to transfer drawings from the client canvas to the admin canvas using web sockets, as smoothly as possible. At every mousemove event, the client canvas is compressed to .png ...
10
votes
1answer
148 views

Chat.SE in Terminal

This is a script that accesses the SE impromptu APIs to receive the fkey, a variable need for connection to chatrooms, and uses it to build a websockets connection ...
12
votes
2answers
307 views

BigBrother - A chat room watcher

Originally, this script stemmed from a small script that watched stars and who made them, but a few days after launching, SE patched it so the people behind the stars aren't sent. Regardless, ...
1
vote
0answers
808 views

Proxying Socket.io requests and other HTTP requests

I have written a proxy server using node HTTP proxy, which can also be found on Github. I am bit unsure about whether I am proxying the web sockets correctly. ...
2
votes
0answers
2k views

Flux & async communication with websockets

I want to arrange async server-client communication with websockets and vanilla flux architecture. There is an excellent article about "Async Server-Side Communication with the Flux Architecture". I ...
4
votes
1answer
1k views

Websocket-based server for Raspberry Pi

I am trying to build a websocket server to run on the Raspberry Pi. The websocket server has to push periodic realtime update to a browser. Here is a sample code that I am planning to use. The example ...
10
votes
1answer
700 views

WebSocket-based API library in Racket

I've developed a library in (typed) Racket that wraps a WebSocket-based API. The API itself is very simple—it operates via a series of three-letter commands optionally followed by a JSON-encoded ...
2
votes
1answer
111 views

Parsing user name and password from binary in Erlang + Cowboy

I am working on a web app that uses a WebSocket to log in users. I would like to minimize bandwidth usage by using binary messages. I came up with the following, and would like to know whether there ...
6
votes
0answers
3k views

Real-time bitcoin data feed and storage using websocket framework

I'm trying to create data feed script for real time bitcoin data for OkCoin exchange using their websocket API (documentation) and a database manager for storing. There are two channels I am ...
4
votes
1answer
67 views

Plugin for communication protocols in browser(s)

I would like to get some feedback from the community regarding a plugin I recently moved from requiring jQuery to a stand alone JS implementation. It is meant to handle browser communication protocols ...
12
votes
2answers
832 views

Stack Exchange websockets wrapper

I've been writing a small library that allows for easy querying of the Stack Exchange websockets. I'm going to add an enum to replace the manual ...
24
votes
3answers
57k views

Websockets client code and making it production-ready

The following code is helpful to anyone who uses websockets in general... and is probably good template for anyone getting started in this area. I'd like to flesh this out into something that is more ...