You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using Webbit for streaming video over a websocket,
I want to apply some adaptive streaming, but I am scratching my head on how I can detect the bandwidth of the user, or just whether to check when data is still outgoing.
WebsocketConnection.send(data) will return immediately afaik.
Is there a way in Webbit to check whether a connection is busy? Is that even an option?
The text was updated successfully, but these errors were encountered:
Kjos
changed the title
Detect client bandwidth or WebSocket Connection is busy
Detect client bandwidth or whether WebSocket Connection is busy
Jan 12, 2018
Quick update; I've just added a message from the client to the server when the FPS is too low, in which case it will lower quality in a PID loop. This seems to work well, but if there is a better way it'd be glad to hear it.
I saw writeMessage returns a Future, but I didn't check whether it has a listener for bytes sent, because I think it was protected anyway.
So I've added a function to WebSocketConnection called sendFuture which returns the ChannelFuture. I then listen to operationComplete. operationComplete then sets a boolean whether the Channel is busy or not.
This doesn't work reliably however.
I'm using Webbit for streaming video over a websocket,
I want to apply some adaptive streaming, but I am scratching my head on how I can detect the bandwidth of the user, or just whether to check when data is still outgoing.
WebsocketConnection.send(data) will return immediately afaik.
Is there a way in Webbit to check whether a connection is busy? Is that even an option?
The text was updated successfully, but these errors were encountered: