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

mgr/dashboard: improve rbd listing #39344

Closed
wants to merge 1 commit into from

Conversation

epuertat
Copy link
Member

@epuertat epuertat commented Feb 7, 2021

Adds TTL caching to ioctx and RBD images in order to speed up listing of many RBD images (> hundreds). Instantiating RBD images is one of the bottlenecks, so by reusing those, only when the TTL cache is cold this method takes longer to complete.

In order to improve the TTL caching, a ttl_spread has been added to the cache, so the items start to progressively expire from ttl*(1 - ttl_spread)/2 to ttl*(1 + ttl_spread)/2.

CAVEATS

  • This assumes that ioctx and RBD image objects will be automatically deallocated by the Python ref-counting mechanism (as no context manager is used or explicit close is called).
  • This still does not fix the underlying issue: since the number of RBD images may be a scaling factor for a Ceph cluster, the latency might sooner or later exceed the poll period.
  • The only fix for that is to introduce pagination. However, that will break some Dashboard features, like the ability to sort RBD images by any property (size, number of objects, provisioned size, etc.), or the ability to filter those images by the same properties. A possibility, already applied in other endpoints, is to disable the periodic polling, while allowing the user to manually refresh the table.

Fixes: http://tracker.ceph.com/issues/39140
Signed-off-by: Ernesto Puerta epuertat@redhat.com

Checklist

  • References tracker ticket
  • Updates documentation if necessary
  • Includes tests for new functionality or reproducer for bug
  • Asynchronous expiration in the ttl cache.

Show available Jenkins commands
  • jenkins retest this please
  • jenkins test classic perf
  • jenkins test crimson perf
  • jenkins test signed
  • jenkins test make check
  • jenkins test make check arm64
  • jenkins test submodules
  • jenkins test dashboard
  • jenkins test api
  • jenkins test docs
  • jenkins render docs
  • jenkins test ceph-volume all
  • jenkins test ceph-volume tox

Adds TTL caching to ioctx and RBD images in order to speed up listing of
many RBD images (> hundreds). It still does not fix the underlying
issue: since the number_of_rbd_images is a scaling factor, the latency
will sooner or later exceed the poll period.

The only fix for that is to introduce pagination. However, that will
break some Dashboard features, like the ability to sort RBD images by
any property (size, number of objects, provisioned size, etc.), or the
ability to filter those images by the same properties.

A possibility, already applied in other endpoints, is to disable the
periodic polling and allow the user to manually refresh the table.

Fixes: http://tracker.ceph.com/issues/39140
Signed-off-by: Ernesto Puerta <epuertat@redhat.com>
@epuertat epuertat changed the title mgr/dashboard: improve rbd listing mgr/dashboard: improve rbd listing Feb 8, 2021
@epuertat epuertat changed the title mgr/dashboard: improve rbd listing mgr/dashboard: improve rbd listing Feb 8, 2021
@epuertat epuertat added this to In progress in Dashboard via automation Feb 8, 2021
@epuertat epuertat moved this from In progress to To do in Dashboard Mar 3, 2021
@epuertat epuertat moved this from To do to Abandoned in Dashboard May 5, 2021
@github-actions
Copy link

github-actions bot commented Jun 1, 2021

This pull request can no longer be automatically merged: a rebase is needed and changes have to be manually resolved

@djgalloway djgalloway changed the base branch from master to main July 6, 2022 00:00
@github-actions
Copy link

github-actions bot commented Sep 4, 2022

This pull request has been automatically marked as stale because it has not had any activity for 60 days. It will be closed if no further activity occurs for another 30 days.
If you are a maintainer or core committer, please follow-up on this pull request to identify what steps should be taken by the author to move this proposed change forward.
If you are the author of this pull request, thank you for your proposed contribution. If you believe this change is still appropriate, please ensure that any feedback has been addressed and ask for a code review.

@github-actions github-actions bot added the stale label Sep 4, 2022
@github-actions
Copy link

This pull request has been automatically closed because there has been no activity for 90 days. Please feel free to reopen this pull request (or open a new one) if the proposed change is still appropriate. Thank you for your contribution!

@github-actions github-actions bot closed this Oct 28, 2022
Dashboard automation moved this from Inactive to Done Oct 28, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Archived in project
Dashboard
  
Done
1 participant