Fix some bugs when testing opensds ansible
[stor4nfv.git] / src / ceph / doc / dev / radosgw / usage.rst
1 ============================
2 Usage Design Overview
3 ============================
4
5
6
7
8 Testing
9 -------
10
11 The current usage testing does the following:
12
13 Following these operations:
14
15  - Create a few buckets
16  - Remove buckets
17  - Create a bucket
18  - Put object
19  - Remove object
20
21 Test:
22
23 1. Verify that 'usage show' with delete_obj category isn't empty after no more than 45 seconds (wait to flush)
24 2. Check the following
25
26   - 'usage show'
27
28     - does not error out
29     - num of entries > 0
30     - num of summary entries > 0
31     - for every entry in categories check successful_ops > 0
32     - check that correct uid in the user summary
33
34
35   - 'usage show' with specified uid (--uid=<uid>')
36
37     - num of entries > 0
38     - num of summary entries > 0
39     - for every entry in categories check successful_ops > 0
40     - check that correct uid in the user summary
41
42   - 'usage show' with specified uid and specified categories (create_bucket,
43     put_obj, delete_obj, delete_bucket)
44
45     - for each category:
46       - does not error out
47       - num of entries > 0
48       - user in user summary is correct user
49       - length of categories entries under user summary is exactly 1
50       - name of category under user summary is correct name
51       - successful ops for the category > 0
52
53   - 'usage trim' with specified uid
54     - does not error
55     - check following 'usage show' shows complete usage info cleared for user
56
57
58 Additional required testing:
59
60  - test multiple users
61
62    Do the same as in (2), with multiple users being set up.
63
64  - test with multiple buckets (> 1000 * factor, e.g., 2000)
65
66    Create multiple buckets, put objects in each. Account the number written data and verify
67    that usage reports show the expected number (up to a certain delta).
68
69  - verify usage show with a date/time range
70
71    Take timestamp of the beginning of the test, and the end of the test. Round timestamps to the
72    nearest hour (downward from start of test, upward from the end of test). List data starting
73    at end-time, make sure that no data is being shown. List data ending at start-time, make sure
74    that no data is shown. List data beginning at start-time, make sure that correct data is
75    displayed. List data ending end end-time, make sure that correct data is displayed. List
76    data beginning in begin-time, ending in end-time, make sure that correct data is displayed.
77
78  - verify usage trim with a date/time range
79
80    Take timestamp of the beginning of the test, and the end of the test. Round timestamps to the
81    nearest hour (downward from start of test, upward from the end of test). Trim data starting
82    at end-time, make sure that no data has been trimmed. Trim data ending at start-time, make sure
83    that no data has been trimmed.  Trim data beginning in begin-time, ending in end-time, make sure
84    that all data has been trimmed.