Closed burgerni10 closed 2 years ago
We already have support to forward health signal requests. Instead of adding something specific for loki, would not be better to have a general proxy support, which could be used by other OIBus instances for any purposes? It could receive a JSON body with all the information required to forward the request:
{
"url": "https://example.com/endpoint",
"type": "POST",
"headers": {it could also contain the authentication},
"body": any
}
The health signal is now logged so we can monitor through the logs (locally : SQLite, file, console) the health status of OIBus. If loki is enabled, the log will be managed by loki too. It allows the use to trace OIBus activity. We can still send HTTP Health signal beside/instead log Health signal
I think I missed your point. I guess that's the correct approach. I need to think more about it : for logs, proxy must be used only when loki is activated (with a proxy). Maybe by using an ad-hoc winston transport...
Now that we switch to pino logs, I think we can work again on this issue. @kukukk I think your approach is the right one Loki logs are sent in standard HTTP requests, let's see how to reuse the proxy logic in the pino loki transport. Let me know when you start working on that so we can discuss the implementation
And manage some local forwarding data to display on the oibus