]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
store_test: improve synthetic test coverage of long object names
authorSamuel Just <sjust@redhat.com>
Fri, 11 Mar 2016 22:05:37 +0000 (14:05 -0800)
committerSamuel Just <sjust@redhat.com>
Mon, 9 May 2016 21:38:22 +0000 (14:38 -0700)
1/2 of objects will now have long names, and we'll shift the region
of the hash space where new objects are created every 1024 objects
created.

Signed-off-by: Samuel Just <sjust@redhat.com>
(cherry picked from commit 4b44720f752ebac63454ecd338e2b0c77c8fe501)

Conflicts:
src/test/objectstore/store_test.cc

src/test/objectstore/store_test.cc

index 5f6b7a35c794cad639db91da9f3d1c446469fef9..aeee85d91e8fdcc1235964d4341062fc1683053e 100644 (file)
@@ -531,6 +531,12 @@ public:
       name = "DIR_" + name;
     }
 
+    if (seq % 2) {
+      for (unsigned i = 0; i < 300; ++i) {
+       name.push_back('a');
+      }
+    }
+
     // hash
     //boost::binomial_distribution<uint32_t> bin(0xFFFFFF, 0.5);
     ++seq;