restreamer icon indicating copy to clipboard operation
restreamer copied to clipboard

Monitoring

Open strarsis opened this issue 5 years ago • 11 comments

Is there a way for being informed when the stream goes down? YouTube doesn't seem to offer a notification when streaming source doesn't send data anymore. What would be best practice?

strarsis avatar May 08 '19 18:05 strarsis

Restreamer provides an API where you can poll the current state of the incoming and outgoing stream. Have a look at https://datarhei.github.io/restreamer/docs/references-http-api.html

/v1/states and/or /v1/progresses would be useful in your case. If your Restreamer is running on http://12.34.56.78:8080/, then accessing the API would be http://12.34.56.78:8080/v1/states.

ioppermann avatar May 09 '19 06:05 ioppermann

@ioppermann: It would be even more awesome if pub/sub could be added to the restreamer REST API so a little microservice (e.g. nodejs/monitoring script on some port like 9091) can be directly informed so an email / notification can be send?

strarsis avatar May 09 '19 15:05 strarsis

Do you mean some kind of webhook that gets notified as soon as a state changes, e.g. by a JSON message?

ioppermann avatar May 09 '19 17:05 ioppermann

@ioppermann: Yes! This would be a better alternative to polling.

strarsis avatar May 09 '19 19:05 strarsis

Per Ora sono riuscito a sviluppare questo oggi pomeriggio, in questi giorni cercherò di creare un bot telegram che invia notifiche sullo stato. dashboard

advantix78 avatar Mar 31 '20 18:03 advantix78

Translation of post from @advantix78 from Italian to English, using deepl.com:

For Now I was able to develop this afternoon, I' m going to try to create a telegram bot these days that sends status notifications. (deepl.com)

strarsis avatar Mar 31 '20 18:03 strarsis

@advantix78 This is awesome! Is it possible that you share it?

ioppermann avatar Apr 01 '20 09:04 ioppermann

Vorrei Finire di configurarlo e poi magari cercherò di condividerlo in modo che tutti lo possano usare. Ovviamente il mio sistema funziona con appositi presupposti, quindi dovrei implementare con una premessa. Annotazione 2020-04-01 123134

advantix78 avatar Apr 01 '20 10:04 advantix78

Hm, streaming stats for Prometheus and event logs for Logstash would also be nice because I can feed that data into my existing ELK/Monitoring stack.

strarsis avatar Apr 01 '20 14:04 strarsis

@ advantix78 Questo è fantastico! È possibile che tu lo condivida?

DashBoard API Restreamer

Si presuppone di avere un server dove è instalato NodeRed oppure da testare se installarlo sulla stessa macchina dove è installato Restreamer che sia esso Raspberry Cloud ecc.

I Nodi sono dei semplici http request code in method GET con URL del server restreamer con finale /API

/v1/ip /v1/statex ecc.. ecc..

Dopodichè un nodo change per spostare il msg.payload.xxxxxxxx a msg.payload

seguito da un nodo dashboard che puo essere un semplice testo o un grafico ecc ecc.

Mi risulta complesso al momento fare un tutorial in quanto ho creato questa dashboard appositamente per il mio caso. il mio server NodeREd si trova a casa su un Orange Pi 0.

Per chi mastica gia Node REd può prendere spunto da questa immagine Annotazione 2020-04-05 174600

advantix78 avatar Apr 05 '20 15:04 advantix78

I am running the dev release. But i have a feeling the API doc (https://docs.datarhei.com/restreamer/api/api-and-developer) are out of sync with the version i am running at least. I get a lot of the following responses:

{
    "code": 404,
    "message": "Not Found",
    "details": [
        "Not Found"
    ]
}

I am looking for a way to get the state of all the streams.. So i can monitor them for issues.

Pimmetje avatar Sep 07 '22 15:09 Pimmetje

Hello

We have converted the request into a feature request. Follow the discussion https://github.com/datarhei/restreamer/discussions/345#discussion-4108562 to stay current, and see when your feature becomes active.

Please appreciate it if we only implement some features, which may take some time.

We are closing this issue.

Cheerio Sven

svenerbeck avatar Nov 23 '22 21:11 svenerbeck