Типы событий | |
---|
service:up – конфигурация сервиса принята и все службы запустились корректно.
| service:up
JSON
{
"data": {
"at": 1706626775,
"pid": 533277
},
"device": "mediaserver",
"event": "service:up",
"pid": 533277,
"seq": 1324967661364755,
"server": "ms-test-dev1",
"timestamp": 1706626775
}
|
service:down – сервис получил сигнал на остановку и пытается корректно завершить работу (данное событие может не всегда приходить).
| service:down
JSON
{
"data": {
"at": 1706624875,
"pid": 533277
},
"device": "mediaserver",
"event": "service:down",
"pid": 533277,
"seq": 1324967661364755,
"server": "ms-test-dev1",
"timestamp": 1706624875
}
|
service:pulse – сервис функционирует, событие отправляется с периодичностью 60 секунд.
| service:puls
JSON
{
"data": {
"at": 1706627715,
"pid": 533643
},
"device": "mediaserver",
"event": "service:pulse",
"pid": 533643,
"seq": 1325847587881315,
"server": "ms-test-dev1",
"timestamp": 1706627715
}
|
service:emergency – произошло критическое событие, связанное с отказом работы одной из служб или средой выполнения.
| |
stream:create – Mediaserver создал поток. Событие наступает при добавлении потока.
| stream:create
JSON
{
"data": {
"access": "public",
"address": "192.168.204.10",
"camera": "camera-uid5065687",
"dvr": false,
"enable": true,
"kind": "primary",
"reconnects": {
"attempt": 0,
"limit": 10,
"total": 0
},
"source": "rtsp://192.168.204.10/Streaming/Channels/101/",
"state": "active",
"stime": 1706627843,
"subscribers": 1,
"type": "capture",
"uid": "camera-uid5065687-primary",
"video": {
"bitrate": 0,
"codec": "H265",
"fps": 0
}
},
"device": "mediaserver",
"event": "stream:create",
"pid": 533735,
"seq": 1326036436599590,
"server": "ms-test-dev1",
"timestamp": 1706627843
}
|
stream:pulse – поток успешно захватывается, событие отправляется с периодичностью отправки на камеру команды PING .
| stream:pulse
JSON
{
"data": {
"access": "public",
"address": "192.168.204.10",
"camera": "camera-uid5065687",
"dvr": false,
"enable": true,
"kind": "primary",
"reconnects": {
"attempt": 0,
"limit": 10,
"total": 0
},
"source": "rtsp://192.168.204.10/Streaming/Channels/101/",
"state": "active",
"stime": 1706627843,
"subscribers": 1,
"type": "capture",
"uid": "camera-uid5065687-primary",
"video": {
"bitrate": 3383431,
"codec": "H265",
"fps": 75
}
},
"device": "mediaserver",
"event": "stream:pulse",
"pid": 533735,
"seq": 1326036436599594,
"server": "ms-test-dev1",
"timestamp": 1706627933
}
|
stream:reconnect – Mediaserver пытается переподключиться к потоку.
| stream:reconnect
JSON
{
"data": {
"access": "public",
"address": "192.168.204.10",
"camera": "camera-uid5065687",
"dvr": false,
"enable": true,
"kind": "primary",
"reconnects": {
"attempt": 0,
"limit": 10,
"total": 0
},
"source": "rtsp://192.168.204.10/Streaming/Channels/101/",
"state": "active",
"stime": 1706627843,
"subscribers": 1,
"type": "capture",
"uid": "camera-uid5065687-primary",
"video": {
"bitrate": 3383431,
"codec": "H265",
"fps": 75
}
},
"device": "mediaserver",
"event": "stream:reconnect",
"pid": 533735,
"seq": 1326036436599594,
"server": "ms-test-dev1",
"timestamp": 1706627933
}
|
stream:state – событие наступает при обновлении статуса потока.
| stream:state
JSON
{
"data": {
"access": "public",
"address": "192.168.204.10",
"camera": "camera-uid5065687",
"dvr": false,
"enable": true,
"kind": "primary",
"reconnects": {
"attempt": 0,
"limit": 10,
"total": 0
},
"source": "rtsp://192.168.204.10/Streaming/Channels/101/",
"state": "active",
"stime": 1706627843,
"subscribers": 1,
"type": "capture",
"uid": "camera-uid5065687-primary",
"video": {
"bitrate": 3383431,
"codec": "H265",
"fps": 75
}
},
"device": "mediaserver",
"event": "stream:state",
"pid": 533735,
"seq": 1326036436599594,
"server": "ms-test-dev1",
"timestamp": 1706627933
}
|
stream:delete – событие наступает при удалении потока.
| stream:delete
JSON
{
"data": {
"access": "public",
"address": "192.168.204.10",
"camera": "camera-uid5065687",
"dvr": false,
"enable": true,
"kind": "primary",
"reconnects": {
"attempt": 0,
"limit": 10,
"total": 0
},
"source": "rtsp://192.168.204.10/Streaming/Channels/101/",
"state": "active",
"stime": 1706627843,
"subscribers": 1,
"type": "capture",
"uid": "camera-uid5065687-primary",
"video": {
"bitrate": 3383431,
"codec": "H265",
"fps": 75
}
},
"device": "mediaserver",
"event": "stream:state",
"pid": 533735,
"seq": 1326036436599594,
"server": "ms-test-dev1",
"timestamp": 1706627933
}
|
stream:dvr – событие о диапазонах DVR потока. События наступает при появлении нового range .
| stream:dvr
JSON
{
"access": "public",
"address": "192.168.204.10",
"atime": 1709713661,
"camera": "camera-uid5065687",
"ctime": 1709713539,
"dvr": {
"range": {
"from": 1709713539,
"size": 36967784,
"to": 1709713659,
"type": "regular"
}
},
"error": {
"msg": "",
"no": 0
},
"source": "rtsp://192.168.204.10/Streaming/Channels/101/",
"state": "active",
"stime": 1709713539,
"type": "capture",
"uid": "camera-uid5065687-primary"
}
|
server:capture – событие о захвате потоков серверов.
| server:capture
JSON
{
"data": {
"ms-test-dev1.navek.dev": [
"camera-uid8672832-primary",
"camera-uid8672833-primary"
]
},
"device": "mediaserver",
"event": "server:capture",
"pid": 534459,
"seq": 1326626505543974,
"server": "ms-test-dev1",
"timestamp": 1706628543
}
|
server:release – событие об окончании захвата вторичных потоков.
| server:release
JSON
{
"data": {
"ms-test-dev1.navek.dev": [
"camera-uid8672832-primary",
"camera-uid8672833-primary"
]
},
"device": "mediaserver",
"event": "server:release",
"pid": 534459,
"seq": 1326626505543974,
"server": "ms-test-dev1",
"timestamp": 1706628543
}
|