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

Add uptime stats of the portal itself to the Dashboard #214

Open
SebastianOpriel opened this issue May 24, 2024 · 7 comments
Open

Add uptime stats of the portal itself to the Dashboard #214

SebastianOpriel opened this issue May 24, 2024 · 7 comments
Assignees
Labels
area/backend area/frontend component/ap Impacts Authority Portal or requires development on Authority Portal. feature-access/closed-source feature is available to paying customers. source code is proprietary to sovity. kind/enhancement New feature or request status/blocked/needs-product requires input from product owner

Comments

@SebastianOpriel
Copy link
Member

SebastianOpriel commented May 24, 2024

As Uptime Kuma is used as a separate service, the dashboard shall show its own historic uptime. It shall also be added to the CSV Report.

image

@SebastianOpriel SebastianOpriel added the kind/enhancement New feature or request label May 24, 2024
@AbdullahMuk AbdullahMuk added the clean-backlog requires backlog cleaning label May 29, 2024
@kamilczaja kamilczaja changed the title Add System Status of Portal to Dashboard Add uptime stats of the portal itself to the Dashboard May 29, 2024
@kamilczaja kamilczaja added area/backend area/frontend and removed clean-backlog requires backlog cleaning labels May 29, 2024
@kamilczaja
Copy link
Collaborator

Not trivial. We need to check whether Uptime Kuma already monitors the AP. If not, we need to figure out which component to perform health checks on - backend? frontend? both combined?

@jkbquabeck jkbquabeck added this to the MDS 2.2 milestone Aug 5, 2024
@kamilczaja
Copy link
Collaborator

Feasibility analysis

Currently, there is no feasible way to display the Portal uptime consistently and correctly in the portal itself.
The components are monitored by an Uptime Kuma instance which reports only the current online status. The portal gathers and saves the data to calculate the components' uptime.

Problem

The portal cannot fetch the online status from Uptime Kuma when the portal itself is offline. Thus, it cannot save the data and it cannot calculate the uptime. Uptime Kuma unfortunately does not provide any historical data to its external API, so this is not an option either.

Possible solution 1 (not recommended)

Create a completely new service that is deployed independently. This service would take over the portal's current uptime calculation methods and provide historical data via an API. The portal could just fetch the ready-to-display data and display it on the Dashboard.
Needless to say, this approach would be silly due to increased complexity, dependencies and hosting costs.

Possible solution 2

Instead of Uptime Kuma, a better service like Prometheus could be used for uptime monitoring, that would provide historical data to the portal. This would enable the portal to just display the data instead of needing to calculate component uptime by itself. This solves the issue with the portal needing to monitor its own uptime.

Possible solution 3 (recommended)

Disregard this idea as it requires too much work for close to zero benefit.

Summary

Regardless of the approach chosen, completion of this task is dependent on the operator providing us with solid historical uptime data. A component cannot monitor itself.

@AbdullahMuk @jkbquabeck

@kamilczaja kamilczaja added the status/blocked/needs-product requires input from product owner label Aug 21, 2024
@AbdullahMuk AbdullahMuk added the component/ap Impacts Authority Portal or requires development on Authority Portal. label Sep 5, 2024
@AbdullahMuk
Copy link
Collaborator

Planned for implementation for milestone "AP White Label - Product Iteration 2".

@SebastianOpriel
Copy link
Member Author

SebastianOpriel commented Sep 23, 2024

Uptime Kuma unfortunately does not provide any historical data to its external API, so this is not an option either.

Might this help? https://github.com/MedAziz11/Uptime-Kuma-Web-API

@kamilczaja
Copy link
Collaborator

Uptime Kuma unfortunately does not provide any historical data to its external API, so this is not an option either.

Might this help? https://github.com/MedAziz11/Uptime-Kuma-Web-API

Unfortunately we do not control the external Uptime Kuma instance that is hosted by Orbiter. I also don't think we intend to use this service in the future on our sides and will most probably adjust the AP to be compatible with more widespread and potent Uptime monitoring services

@SebastianOpriel
Copy link
Member Author

Okay, let's follow best practice approaches. What do you think about:

  • Implement a ENV-Var switch to toggle between the current and an optimized version.
  • Optimized version will simply deactivate the Dashboard and add a "Status" link to the footer. Like here:
    image
    This allows to implement a proper Status page with desired tooling.

@AbdullahMuk AbdullahMuk added the feature-access/closed-source feature is available to paying customers. source code is proprietary to sovity. label Oct 25, 2024
@AbdullahMuk
Copy link
Collaborator

@kamilczaja aligned with @SebastianOpriel , @yylian that we will not tackle it in Q4/2024.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/backend area/frontend component/ap Impacts Authority Portal or requires development on Authority Portal. feature-access/closed-source feature is available to paying customers. source code is proprietary to sovity. kind/enhancement New feature or request status/blocked/needs-product requires input from product owner
Projects
None yet
Development

No branches or pull requests

4 participants