E
E
ENeLsOn2018-03-25 09:48:07
PHP
ENeLsOn, 2018-03-25 09:48:07

How to collect information from game servers for monitoring site?

A large number of servers (10000+) are planned, with a frequency of 5-10 minutes to collect information: Status (on / off-line), Players online, slots.
I tried to take an example from here https://github.com/xPaw/PHP-Minecraft-Query/blob/m... , implemented it using a loop - it turned out to be very long, 0.3-1 sec for 1 server. On average, 10 servers were obtained - 6-8 seconds (taking into account the fact that some servers may be offline, and the request timeout is 1 second).

Answer the question

In order to leave comments, you need to log in

4 answer(s)
E
ENeLsOn, 2018-06-24
@ENeLsOn

It's funny that the question was marked as simple, but in the end no one gave a sensible answer.
Solution: use python

D
Dmitry Chekanov, 2018-03-25
@LanDer931

Dig queues .
and put them on Supervisor for example

X
xmoonlight, 2018-03-27
@xmoonlight

Here

R
Roman Mirilaczvili, 2018-06-15
@2ord

Collection of data from sites should be performed in parallel. Enqueue metric data during collection. As the queue is processed, update the data in the database.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question