listed in 'osd class default list' requires a capability naming the class
(e.g. 'allow class foo').
+* The 'rgw rest getusage op compat' config option allows you to dump the description of user stats
+ or not in s3 GetUsage API. This config option is of bool type and defaults to false.
+ If the value is true, the reponse data of s3 GetUsage like below:
+
+ "stats": {
+ "TotalBytes": 516,
+ "TotalBytesRounded": 1024,
+ "TotalEntries": 1
+ }
+
+ Or if the value is false, the reponse of s3 GetUsage like below and as it does before we add this config option:
+
+ {
+ 516,
+ 1024,
+ 1
+ }.
+
11.0.0
------
OPTION(rgw_list_bucket_min_readahead, OPT_INT, 1000) // minimum number of entries to read from rados for bucket listing
+OPTION(rgw_rest_getusage_op_compat, OPT_BOOL, false) // dump description of total stats for s3 GetUsage API
+
OPTION(mutex_perf_counter, OPT_BOOL, false) // enable/disable mutex perf counter
OPTION(throttler_perf_counter, OPT_BOOL, true) // enable/disable throttler perf counter
formatter->dump_int("SuccessfulOps", total_usage.successful_ops);
formatter->close_section(); // total
formatter->close_section(); // user
- }
+ }
+
+ if (s->cct->_conf->rgw_rest_getusage_op_compat) {
+ formatter->open_object_section("Stats");
+ }
+
formatter->dump_int("TotalBytes", header.stats.total_bytes);
formatter->dump_int("TotalBytesRounded", header.stats.total_bytes_rounded);
formatter->dump_int("TotalEntries", header.stats.total_entries);
+
+ if (s->cct->_conf->rgw_rest_getusage_op_compat) {
+ formatter->close_section(); //Stats
+ }
+
formatter->close_section(); // summary
}
formatter->close_section(); // usage