From: Xuehan Xu Date: Mon, 11 Mar 2024 08:38:54 +0000 (+0800) Subject: test/osd/TestRados: add parameter max-attr-len X-Git-Tag: testing/wip-jcollin-testing-20240625.102731-squid~67^2~1 X-Git-Url: http://git.apps.os.sepia.ceph.com/?a=commitdiff_plain;h=63786e0da4051d4fdb8232eba53ef645fba88e58;p=ceph-ci.git test/osd/TestRados: add parameter max-attr-len SeaStore can't handle too big attributes Signed-off-by: Xuehan Xu (cherry picked from commit 45a6d3f2c7fd5281a398b08762849fd37488ac21) --- diff --git a/src/test/osd/RadosModel.h b/src/test/osd/RadosModel.h index 1e5d0e908bc..8bb94e7f3a0 100644 --- a/src/test/osd/RadosModel.h +++ b/src/test/osd/RadosModel.h @@ -215,6 +215,7 @@ public: bool enable_dedup, std::string chunk_algo, std::string chunk_size, + size_t max_attr_len, const char *id = 0) : pool_obj_cont(), current_snap(0), @@ -226,7 +227,7 @@ public: rados_id(id), initialized(false), max_size(max_size), min_stride_size(min_stride_size), max_stride_size(max_stride_size), - attr_gen(2000, 20000), + attr_gen(2000, max_attr_len), no_omap(no_omap), no_sparse(no_sparse), pool_snaps(pool_snaps), diff --git a/src/test/osd/TestRados.cc b/src/test/osd/TestRados.cc index 1a1389b2a18..876b5eb8dd7 100644 --- a/src/test/osd/TestRados.cc +++ b/src/test/osd/TestRados.cc @@ -523,6 +523,7 @@ int main(int argc, char **argv) bool enable_dedup = false; string chunk_algo = ""; string chunk_size = ""; + size_t max_attr_len = 20000; for (int i = 1; i < argc; ++i) { @@ -554,6 +555,8 @@ int main(int argc, char **argv) pool_snaps = true; else if (strcmp(argv[i], "--write-fadvise-dontneed") == 0) write_fadvise_dontneed = true; + else if (strcmp(argv[i], "--max-attr-len") == 0) + max_attr_len = atoi(argv[++i]); else if (strcmp(argv[i], "--ec-pool") == 0) { if (!op_weights.empty()) { cerr << "--ec-pool must be specified prior to any ops" << std::endl; @@ -700,6 +703,7 @@ int main(int argc, char **argv) enable_dedup, chunk_algo, chunk_size, + max_attr_len, id); TestOpStat stats;