s3gw icon indicating copy to clipboard operation
s3gw copied to clipboard

rgw/sfs: implement user stats rest call

Open giubacc opened this issue 2 years ago • 6 comments

Stats information can be retrieved via /admin/user?uid=xxxxx&stats=true rest call. In sfs this call is not implemented; currently the call returns an empty response:

'stats': {'size': 0, 'size_actual': 0, 'size_utilized': 0, 'size_kb': 0, 'size_kb_actual': 0, 'size_kb_utilized': 0, 'num_objects': 0}

While this kind of information is logically bound with a bucket instance, we should investigate what approach we want to implement. Some options:

  • we want this information to be always in sync with the stored data
  • we want to allow a certain grade of dis-alignment with the stored data
  • sync / async information update ?
  • storing information in the bucket row (periodic update) ?

giubacc avatar Aug 30 '22 13:08 giubacc

This issue is related to #75.

votdev avatar Aug 30 '22 13:08 votdev

@votdev @jecluis have you an opinion when the activity on this issue should start? user stats could be something important to have in the context of the LH integration.

giubacc avatar May 11 '23 14:05 giubacc

/admin/user?uid=xxxxx&stats=true is the RGW specifc Admin API (https://docs.ceph.com/en/latest/radosgw/adminops/)

I think we should rather focus on S3. There are stats requests there as well. For example https://docs.ceph.com/en/latest/radosgw/s3/serviceops/#get-usage-stats

irq0 avatar May 11 '23 15:05 irq0

Both admin api and S3 end up calling SFSUser::read_stats

irq0 avatar May 11 '23 16:05 irq0

@votdev @jecluis have you an opinion when the activity on this issue should start? user stats could be something important to have in the context of the LH integration.

IMO we need to maintain and enhance the current UI as long as LH integration has been done. So i vote to have the ability to request stats and display them in the UI.

votdev avatar May 12 '23 10:05 votdev

Related to #143 and blocking #145 - aiming for v0.23.0.

jecluis avatar Oct 19 '23 05:10 jecluis