From 78621bb742cd0a816dc507010743a7d765d84538 Mon Sep 17 00:00:00 2001 From: Victor Shyba Date: Thu, 10 Aug 2017 00:15:01 -0300 Subject: [feature] add path partitioning to namespaces All blobs were being stored in a single folder when using namespaces, this commits adds path partitioning as discussed on #8882, which should help with a large number of files (each folder will hold a smaller subset, allowing the use of better filesystem walk strategies). Also, the default empty namespace is now called 'default' to prevent it from listing other namespaces contents. So everything will always use namespaces, with the option to use it explicitly or just fall to the default one. -- Related: #8882 --- testing/tests/server/test_blobs_server.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'testing/tests/server') diff --git a/testing/tests/server/test_blobs_server.py b/testing/tests/server/test_blobs_server.py index cf370147..f57a1d2d 100644 --- a/testing/tests/server/test_blobs_server.py +++ b/testing/tests/server/test_blobs_server.py @@ -161,7 +161,8 @@ class BlobServerTestCase(unittest.TestCase): yield manager._encrypt_and_upload('blob_id2', BytesIO("2")) blobs_list = yield manager.remote_list(order_by='date') self.assertEquals(['blob_id1', 'blob_id2'], blobs_list) - self.__touch(self.tempdir, 'user', 'b', 'blo', 'blob_i', 'blob_id1') + parts = ['user', 'default', 'b', 'blo', 'blob_i', 'blob_id1'] + self.__touch(self.tempdir, *parts) blobs_list = yield manager.remote_list(order_by='+date') self.assertEquals(['blob_id2', 'blob_id1'], blobs_list) blobs_list = yield manager.remote_list(order_by='-date') -- cgit v1.2.3