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

Xmage server uses excessive network bandwidth #2812

Open
Daenyth opened this issue Jan 23, 2017 · 7 comments

Comments

Projects
None yet
6 participants
@Daenyth
Copy link

commented Jan 23, 2017

I was talking today with a server operator who runs both cockatrice and xmage servers, and they mentioned that the XMage server consumed over 500gb of network in one day for 200 users, where the cockatrice server used 250gb for 23 days with 600 users.

It sounds like you're using an xml or json based protocol. Cockatrice used to use an xml one, and when we switched to using Protocol Buffers, network traffic dropped by over 95%.

This matters quite a lot for players or server operators who are on metered internet. The situation I mentioned above came up because the operator discussed that he had originally moved the xmage server to a cheaper but bandwidth-metered server and had to change it again due to the heavy traffic requirements.

@magenoxx

This comment has been minimized.

Copy link
Member

commented Feb 12, 2017

Interesting note on protocol buffers. Let me look into what can be done.

@magenoxx magenoxx self-assigned this Feb 12, 2017

@magenoxx

This comment has been minimized.

Copy link
Member

commented Apr 19, 2017

Reproduced issue in tests, working on changes on protocol.
See feature/network_bandwidth branch

@JayDi85

This comment has been minimized.

Copy link
Member

commented Apr 20, 2018

It's a users and active games list. I've got 1 GB income traffic in xmage client by 6 hours (not matches, only active online users list and tables):

shot_180420_102745

@LevelX2

This comment has been minimized.

Copy link
Contributor

commented Apr 20, 2018

It's the user list and the games table that is completely transfered about every 2 seconds.
There is for sure potential to reduce.

@Daenyth

This comment has been minimized.

Copy link
Author

commented Apr 20, 2018

Is the protocol event based? In cockatrice we use a "user joined/left" and "game created/removed" event from the server. Would be a rather massive win

@theelk801

This comment has been minimized.

Copy link
Contributor

commented Apr 24, 2018

I'd be interested in helping with this, however it's not something I know a lot about. What would be a good way for me to learn?

@JayDi85 JayDi85 referenced this issue Apr 24, 2018

Closed

update #4854

@JayDi85

This comment has been minimized.

Copy link
Member

commented Mar 1, 2019

250 players online example from last commit 38293e4:

  • old version downloads 1.7 MB per minute;
  • new version downloads 1.0 MB per minute.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.