Feature #36675
closedTasks #36451: mgr/dashboard: Scalability testing
Bug #36453: mgr/dashboard: Some REST endpoints grow linearly with OSD count
mgr/dashboard: Provide API endpoint providing minimal health data
100%
Description
Currently the dashboard polls both /api/summary
and /api/dashboard/health
every 5s. The latter endpoint returns a large amount of data, but the amount needed to actually render the dashboard is quite small by comparison.
I think it would make sense to get rid of /api/dashboard/health
and replace it with e.g. /api/health/full
and /api/health/minimal
.
Another idea would be to merge the minimal health data into /api/summary
, but that might warrant more discussion.
A caveat here is that /api/dashboard/health
currently provides logging data which will be moving out as a result of #24571 - perhaps the solution to that piece is to simply move that data out to a new /api/logs
endpoint.
Updated by Lenz Grimmer over 5 years ago
Zack Cerza wrote:
Currently the dashboard polls both
/api/summary
and/api/dashboard/health
every 5s. The latter endpoint returns a large amount of data, but the amount needed to actually render the dashboard is quite small by comparison.
I think these endpoints are a verbatim copy of the ones used by the original read-only dashboard. They likely haven't been modified when dashboard v2 was initially created.
I think it would make sense to get rid of
/api/dashboard/health
and replace it with e.g./api/health/full
and/api/health/minimal
.
And the content of /api/health/minimal
would be defined by the requirements of the dashboard landing page?
Another idea would be to merge the minimal health data into
/api/summary
, but that might warrant more discussion.A caveat here is that
/api/dashboard/health
currently provides logging data which will be moving out as a result of #24571 - perhaps the solution to that piece is to simply move that data out to a new/api/logs
endpoint.
Sounds like a good idea to me. The current /api/dashboard/health
endpoint seems to be a tad bit too bloated...
Updated by Zack Cerza over 5 years ago
An update on what my WIP has changed so far, along with some thoughts:
/api/health/full
provides what/api/dashboard/health
used to report, minus logs.- This isn't used by anything, yet.
/api/health/minimal
provides just what the dashboard landing page needs, and no more.- Since I am preserving the original format to avoid unnecessary compatibility breaks, certain fields look a bit awkward. For example, the only thing we need to know about pools is the count - so that piece looks like
"pools": [{}, {}, {}]
- Since I am preserving the original format to avoid unnecessary compatibility breaks, certain fields look a bit awkward. For example, the only thing we need to know about pools is the count - so that piece looks like
/api/logs/all
provides audit_log and clog.- I'm not sure if we would ever want one log and not the other. If so, I'll add separate endpoints. If not, we might prefer to just use
/api/logs
for both, dropping the/all
.
- I'm not sure if we would ever want one log and not the other. If so, I'll add separate endpoints. If not, we might prefer to just use
/api/dashboard
is gone.
Of course I'm open to any feedback on these items. I'm very close to submitting a PR, and am happy to make further changes.
Updated by Zack Cerza over 5 years ago
- Status changed from In Progress to Fix Under Review
- % Done changed from 80 to 100
Updated by Lenz Grimmer over 5 years ago
- Related to Bug #34320: mgr/dashboard: Read/Write OPS in pool stats always show 0 added
Updated by Lenz Grimmer over 5 years ago
Just wondering: is the issue mentioned in #34320 somehow related to this work? Or have these pool metrics been obtained via a different API endpoint?
Updated by Zack Cerza over 5 years ago
Lenz Grimmer wrote:
Just wondering: is the issue mentioned in #34320 somehow related to this work? Or have these pool metrics been obtained via a different API endpoint?
I hadn't seen that issue - I don't think they're related at all.
Updated by Lenz Grimmer over 5 years ago
- Status changed from Fix Under Review to Resolved
Updated by Ernesto Puerta about 5 years ago
- Status changed from Resolved to Closed