{"id":1385,"date":"2018-10-06T13:32:50","date_gmt":"2018-10-06T20:32:50","guid":{"rendered":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/"},"modified":"2018-10-06T13:32:50","modified_gmt":"2018-10-06T20:32:50","slug":"ycsb-json-implementation-for-couchbase-and-mongodb","status":"publish","type":"post","link":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/","title":{"rendered":"YCSB-JSON: Implementation for Couchbase and MongoDB"},"content":{"rendered":"\n<p><span>YCSB is a great benchmarking tool built to be easily extended by any driver which supports and implements basic operations like: insert, read, update, delete and scan.\u00a0<\/span><span>Plain synthetic data introduced by YCSB fits this paradigm perfectly. <\/span><\/p>\n\n\n\n<p><span>But when it comes to working with JSON databases such as Couchbase and MongoDB, YCSB is helpful because queries became way more sophisticated: querying arrays and nested objects, running joins, and aggregations.<\/span><\/p>\n\n\n\n<p><span>The YCSB-JSON extension on one hand should be able to utilize all possible JSON operations supported by a database.<br>\n<\/span><span>On the other hand, implementing this approach should be generic enough to be easily extended from YCSB and MongoDB, Couchbase, or\u00a0<em>any<\/em> other database driver, no matter what level of JSON querying it supports.<\/span><\/p>\n\n\n\n<p><span>The YCSB-JSON connection is designed to better emulate realistic, end-user scenarios. It is designed to work on any JSON data either real datasets or pseudo-realistic or fully synthetic. And one of the requirements for the tool is that there shouldn\u2019t be any hardcoded values in query predicates. Users can only control the data cardinality during the dataset generation process.\u00a0<\/span><\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\" wp-image-5864 aligncenter\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/YCSB-JSON-Implementation-300x232-1.png\" alt=\"\" width=\"656\" height=\"507\"><\/p>\n\n\n\n<p>\u00a0Fig 1. YCSB-JSON implementation at a glance<\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><b>Data Model<\/b><\/h4>\n\n\n\n<p><span>The \u00a0data model we choose for this benchmark is well described in this article: <\/span><a href=\"https:\/\/dzone.com\/articles\/ycsb-json-benchmarking-json-databases-by-extending\"><span>https:\/\/dzone.com\/articles\/ycsb-json-benchmarking-json-databases-by-extending<\/span><\/a><br>\n<span>The dataset is generated by using a fakeit tool and loaded into a database (Couchbase, MongoDB) by external scripts. <\/span><span>While the model is defined and fixed values are randomly generated, this data is randomly generated but it&#8217;s not synthetic.<\/span><\/p>\n\n\n\n<p>\u00a0<\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><b>Data Management <\/b><\/h4>\n\n\n\n<p><span>For each operation in the workload queries are fixed, but bound values for each parameterized predicate are non-deterministic. So, the following data management flow was chosen:<br>\n<\/span><\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><span>Generate documents by fakeit.\u00a0<\/span><\/li>\n\n\n<li><span>Load generated \u00a0data to a database by any external script.<\/span><\/li>\n\n\n<li><span>Run the load phase. During this phase the YCSB will read a random subset of the generated documents, store all its values in its internal cache.<\/span><\/li>\n\n\n<li><span>During the run phase the YCSB will use the values from its cache while binding and executing queries against the database.<\/span><\/li>\n\n<\/ol>\n\n\n\n<p>\u00a0<\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><b>Predicates Generator<\/b><\/h4>\n\n\n\n<p><span>The YCSB uses generators when operating with data. The connector introduces its own generator mapped to a particular data model. The mapping and the model exists only within the generator namespace. The generator output is a set of generic predicates (field-value pairs) for particular queries. This allows users to modify models\u00a0 and extend the tool with other queries without modifying the rest of the core code.<\/span><\/p>\n\n\n\n<h5 class=\"wp-block-heading\"><span>Predicates generator: <a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/generator\/soe\/Generator.java\">Generator.java\u00a0<\/a><\/span><\/h5>\n\n\n\n<p>\u00a0<\/p>\n\n\n\n<p><span>Example #1:\u00a0 <strong>Pagination query<\/strong><\/span><\/p>\n\n\n\n<p><span>One of the YCSB-JSON operations, the pagination query, can be represented by the following statement:<br>\n<\/span><\/p>\n\n\n\n<p><em><span>SELECT * FROM &lt;bucket&gt; WHERE address.zip = &lt;value&gt; OFFSET &lt;num&gt; LIMIT &lt;num&gt;<\/span><\/em><\/p>\n\n\n\n<p><span>The query predicate is a field within an object. When using Couchbase N1QL the field can be simply accessed as \u201caddress.zip\u201d. But other databases might not be as flexible so the YCSB-JSON generator creates 2 predicates: the parent predicate (address) and child\/nested predicate (zip).<\/span><\/p>\n\n\n\n<p><span>And the child predicate has a value randomly picked from the list of sample values for this particular field.\u00a0<\/span><\/p>\n\n\n\n<p><span>The function below generates the <a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/workloads\/soe\/SoeQueryPredicate.java\">SoeQueryPredicate object<\/a><br>\n<\/span><span>Where <code>name<\/code> is \u201c<\/span><span>address<\/span><span>\u201d<br>\n<\/span><span>And <code>nested predicate<\/code> is another SoeQueryPredicate object with name \u201c<\/span><span>zip<\/span><span>\u201d and value <\/span><span>\u00a0&lt;value&gt;:<\/span><\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5851\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/Screen-Shot-2018-10-02-at-10.09.25-AM-300x89-1.png\" alt=\"\" width=\"991\" height=\"294\"><\/p>\n\n\n\n<p>\u00a0<\/p>\n\n\n\n<p><span>Example #2 \u00a0<strong>Report query<\/strong><\/span><\/p>\n\n\n\n<p><span>Predicates for more complex queries are generated the same way. With only difference that when query introduces multiple predicates the predicates sequence (array of predicates) is being generated instead for a single predicate. Here is the Report query:<\/span><\/p>\n\n\n\n<p><em><span>SELECT \u00a0o2.month, c2.address.zip, SUM(o2.sale_price) <\/span><\/em><em><span>FROM &lt;bucket&gt; c2<br>\nINNER JOIN orders o2 ON KEYS c2.order_list<br>\n<\/span><span>WHERE c2.address.zip = \u201cvalue\u201d AND o2.month = \u201cvalue\u201d<br>\n<\/span><span>GROUP BY o2.month, c2.address.zip ORDER BY SUM(o2.sale_price)<\/span><\/em><\/p>\n\n\n\n<p><span>Function below generates sequence of:<br>\n<\/span><span>\u201cMonth\u201d predicate, \u201caddress\u201d predicate with nested \u201czip\u201d predicate, \u201csale_price\u201d predicate, etc:<\/span><\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5852\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/Screen-Shot-2018-10-02-at-10.13.34-AM-300x217-1.png\" alt=\"\" width=\"942\" height=\"681\"><\/p>\n\n\n\n<p><span>Other queries generators can be found here:<br>\n<\/span><a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/generator\/soe\/Generator.java\"><span>https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/generator\/soe\/Generator.java<\/span><\/a><\/p>\n\n\n\n<p>\u00a0<\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><b>New Operations<\/b><\/h4>\n\n\n\n<p><span>The code needs to be updated with new operations. <\/span><\/p>\n\n\n\n<p><span>Signatures in DB class:\u00a0<\/span><br>\n<a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/DB.java#L140\"><span>https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/DB.java#L140<\/span><\/a>:<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5853\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/Screen-Shot-2018-10-02-at-10.16.42-AM-260x300-1.png\" alt=\"\" width=\"1013\" height=\"1169\"><\/p>\n\n\n\n<p><span>Implementations in DBWrapper:\u00a0<\/span><br>\n<a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/DBWrapper.java#L346\"><span>https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/DBWrapper.java#L346<\/span><\/a>:<\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5854\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/Screen-Shot-2018-10-02-at-10.19.53-AM-257x300-1.png\" alt=\"\" width=\"707\" height=\"825\"><\/p>\n\n\n\n<p><span>Extending CoreWorkload with new operations: <a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/core\/src\/main\/java\/com\/yahoo\/ycsb\/workloads\/soe\/SoeWorkload.java\">SoeWorkload.java<\/a><\/span><\/p>\n\n\n\n<p>\u00a0<\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><b>Implementation of YCSB-JSON Operations for<\/b><strong>\u00a0Couchbase and MongoDB<\/strong><\/h4>\n\n\n\n<p><span>The DB driver function of a YCSB-JSON operation takes an additional parameter which is a generator object. It is being passed by the Workload class and it has a particular predicate sequence prebuilt.<\/span><\/p>\n\n\n\n<p><span>Because predicates structure and sequences are well defined by the \u00a0generator a DB driver can access names and values directly and construct the query using its native query language or other access methods. Below are examples of implementing Page and Report queries.<\/span><\/p>\n\n\n\n<p><span><strong>Page query,<\/strong>\u00a0generating query statement for Couchbase:<\/span><\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5855\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/Screen-Shot-2018-10-02-at-10.24.14-AM-300x68-1.png\" alt=\"\" width=\"966\" height=\"219\"><\/p>\n\n\n\n<p><span>for MongoDB:<\/span><\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5856\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/Screen-Shot-2018-10-02-at-10.25.14-AM-300x128-1.png\" alt=\"\" width=\"888\" height=\"379\"><\/p>\n\n\n\n<p><span><\/span><\/p>\n\n\n\n<p><span><strong>Report query<\/strong>, Couchbase:<\/span><\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5858\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/Screen-Shot-2018-10-02-at-10.28.10-AM-300x126-1.png\" alt=\"\" width=\"1105\" height=\"464\"><\/p>\n\n\n\n<p><span>MongoDB:<\/span><\/p>\n\n\n\n<p><img loading=\"lazy\" decoding=\"async\" class=\"alignnone wp-image-5857\" src=\"https:\/\/www.couchbase.com\/wp-content\/uploads\/sites\/5\/2026\/05\/Screen-Shot-2018-10-02-at-10.29.47-AM-291x300-1.png\" alt=\"\" width=\"994\" height=\"1025\"><\/p>\n\n\n\n<p><span>All Couchbase implementations:\u00a0<a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/couchbase2\/src\/main\/java\/com\/yahoo\/ycsb\/db\/couchbase2\/Couchbase2Client.java\">Couchbase2Client.java<\/a><\/span><\/p>\n\n\n\n<p><span>All MongoDB implementations:\u00a0<a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/blob\/soe\/mongodb\/src\/main\/java\/com\/yahoo\/ycsb\/db\/MongoDbClient.java\">MongoDbClient.java<\/a><\/span><\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><\/h4>\n\n\n\n<h4 class=\"wp-block-heading\"><strong>References<\/strong><\/h4>\n\n\n\n<p>Article part 1:<br>\n<a href=\"https:\/\/www.couchbase.com\/blog\/ycsb-json-benchmarking-json-databases-by-extending-ycsb\/\">\u00a0https:\/\/www.couchbase.com\/blog\/ycsb-json-benchmarking-json-databases-by-extending-ycsb\/<\/a><\/p>\n\n\n\n<p>YCSB-JSON Implementation:<br>\n<a href=\"https:\/\/github.com\/couchbaselabs\/YCSB\/tree\/soe\">https:\/\/github.com\/couchbaselabs\/YCSB\/tree\/soe<\/a><\/p>\n\n\n\n<p>FakeIt:<br>\n<a href=\"https:\/\/github.com\/bentonam\/fakeit\">\u00a0https:\/\/github.com\/bentonam\/fakeit<\/a><\/p>\n\n\n\n<h4 class=\"wp-block-heading\"><\/h4>\n\n\n\n<h4 class=\"wp-block-heading\"><b>Next steps<\/b><\/h4>\n\n\n\n<p><span>Implement fakeit-like generator in to simplify data and query predicates generation.<\/span><\/p>\n","protected":false},"excerpt":{"rendered":"<p>YCSB is a great benchmarking tool built to be easily extended by any driver which supports and implements basic operations like: insert, read, update, delete and scan.\u00a0Plain synthetic data introduced by YCSB fits this paradigm perfectly. But when it comes to working with JSON databases such as Couchbase and MongoDB, YCSB is helpful because queries [&hellip;]<\/p>\n","protected":false},"author":23019,"featured_media":18,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"inline_featured_image":false,"footnotes":""},"categories":[127,179,54,189,17,18,64],"tags":[329,175,30,44,6,330],"ppma_author":[332],"class_list":["post-1385","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-application-design","category-couchbase-architecture","category-couchbase-server","category-data-modeling","category-performance","category-n1ql-query","category-tools-sdks","tag-benchmark","tag-database","tag-json","tag-mongodb","tag-nosql-database","tag-ycsb"],"yoast_head":"<!-- This site is optimized with the Yoast SEO Premium plugin v27.6 (Yoast SEO v27.6) - https:\/\/yoast.com\/product\/yoast-seo-premium-wordpress\/ -->\n<title>YCSB-JSON: Implementation for Couchbase and MongoDB<\/title>\n<meta name=\"description\" content=\"For JSON databases such as Couchbase and MongoDB, YCSB is helpful for executing more sophisticated queries. Learn how to use YCSB-JSON today.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"YCSB-JSON: Implementation for Couchbase and MongoDB\" \/>\n<meta property=\"og:description\" content=\"For JSON databases such as Couchbase and MongoDB, YCSB is helpful for executing more sophisticated queries. Learn how to use YCSB-JSON today.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/\" \/>\n<meta property=\"og:site_name\" content=\"The Couchbase Blog\" \/>\n<meta property=\"article:published_time\" content=\"2018-10-06T20:32:50+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/5\/2026\/05\/couchbase-nosql-dbaas.png\" \/>\n\t<meta property=\"og:image:width\" content=\"1800\" \/>\n\t<meta property=\"og:image:height\" content=\"630\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Alex Gyryk\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Alex Gyryk\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"4 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/\"},\"author\":{\"name\":\"Alex Gyryk\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#\\\/schema\\\/person\\\/cf7700be3c6aa11a0e343b4e772d370f\"},\"headline\":\"YCSB-JSON: Implementation for Couchbase and MongoDB\",\"datePublished\":\"2018-10-06T20:32:50+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/\"},\"wordCount\":873,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#organization\"},\"image\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/5\\\/2026\\\/05\\\/couchbase-nosql-dbaas.png\",\"keywords\":[\"benchmark\",\"database\",\"JSON\",\"mongodb\",\"NoSQL Database\",\"ycsb\"],\"articleSection\":[\"Application Design\",\"Couchbase Architecture\",\"Couchbase Server\",\"Data Modeling\",\"High Performance\",\"SQL++ \\\/ N1QL Query\",\"Tools &amp; SDKs\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/\",\"url\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/\",\"name\":\"YCSB-JSON: Implementation for Couchbase and MongoDB\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/#primaryimage\"},\"image\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/#primaryimage\"},\"thumbnailUrl\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/5\\\/2026\\\/05\\\/couchbase-nosql-dbaas.png\",\"datePublished\":\"2018-10-06T20:32:50+00:00\",\"description\":\"For JSON databases such as Couchbase and MongoDB, YCSB is helpful for executing more sophisticated queries. Learn how to use YCSB-JSON today.\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/#primaryimage\",\"url\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/5\\\/2026\\\/05\\\/couchbase-nosql-dbaas.png\",\"contentUrl\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/5\\\/2026\\\/05\\\/couchbase-nosql-dbaas.png\",\"width\":1800,\"height\":630},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/ycsb-json-implementation-for-couchbase-and-mongodb\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"YCSB-JSON: Implementation for Couchbase and MongoDB\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/\",\"name\":\"The Couchbase Blog\",\"description\":\"Couchbase, the NoSQL Database\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#organization\",\"name\":\"The Couchbase Blog\",\"url\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/5\\\/2026\\\/06\\\/logo.svg\",\"contentUrl\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/wp-content\\\/uploads\\\/sites\\\/5\\\/2026\\\/06\\\/logo.svg\",\"width\":\"1024\",\"height\":\"1024\",\"caption\":\"The Couchbase Blog\"},\"image\":{\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/#\\\/schema\\\/person\\\/cf7700be3c6aa11a0e343b4e772d370f\",\"name\":\"Alex Gyryk\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/baaaa3ba944997d5062b1e71633c1645559a8a91739c8509f659c16283fddc0e?s=96&d=mm&r=g9626fc579c5bf8bdb5fa4d15149f816a\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/baaaa3ba944997d5062b1e71633c1645559a8a91739c8509f659c16283fddc0e?s=96&d=mm&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/baaaa3ba944997d5062b1e71633c1645559a8a91739c8509f659c16283fddc0e?s=96&d=mm&r=g\",\"caption\":\"Alex Gyryk\"},\"description\":\"Alex Gyryk is a Principal Software Engineer, Performance at Couchbase. Prior to joining Couchbase, he spent a few years in Forte Group as Senior Performance Analyst.\",\"url\":\"https:\\\/\\\/www.couchbase.com\\\/blog\\\/author\\\/oleksandr-gyrykcouchbase-com\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO Premium plugin. -->","yoast_head_json":{"title":"YCSB-JSON: Implementation for Couchbase and MongoDB","description":"For JSON databases such as Couchbase and MongoDB, YCSB is helpful for executing more sophisticated queries. Learn how to use YCSB-JSON today.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/","og_locale":"en_US","og_type":"article","og_title":"YCSB-JSON: Implementation for Couchbase and MongoDB","og_description":"For JSON databases such as Couchbase and MongoDB, YCSB is helpful for executing more sophisticated queries. Learn how to use YCSB-JSON today.","og_url":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/","og_site_name":"The Couchbase Blog","article_published_time":"2018-10-06T20:32:50+00:00","og_image":[{"width":1800,"height":630,"url":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/5\/2026\/05\/couchbase-nosql-dbaas.png","type":"image\/png"}],"author":"Alex Gyryk","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Alex Gyryk","Est. reading time":"4 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/#article","isPartOf":{"@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/"},"author":{"name":"Alex Gyryk","@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/person\/cf7700be3c6aa11a0e343b4e772d370f"},"headline":"YCSB-JSON: Implementation for Couchbase and MongoDB","datePublished":"2018-10-06T20:32:50+00:00","mainEntityOfPage":{"@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/"},"wordCount":873,"commentCount":0,"publisher":{"@id":"https:\/\/www.couchbase.com\/blog\/#organization"},"image":{"@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/#primaryimage"},"thumbnailUrl":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/5\/2026\/05\/couchbase-nosql-dbaas.png","keywords":["benchmark","database","JSON","mongodb","NoSQL Database","ycsb"],"articleSection":["Application Design","Couchbase Architecture","Couchbase Server","Data Modeling","High Performance","SQL++ \/ N1QL Query","Tools &amp; SDKs"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/","url":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/","name":"YCSB-JSON: Implementation for Couchbase and MongoDB","isPartOf":{"@id":"https:\/\/www.couchbase.com\/blog\/#website"},"primaryImageOfPage":{"@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/#primaryimage"},"image":{"@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/#primaryimage"},"thumbnailUrl":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/5\/2026\/05\/couchbase-nosql-dbaas.png","datePublished":"2018-10-06T20:32:50+00:00","description":"For JSON databases such as Couchbase and MongoDB, YCSB is helpful for executing more sophisticated queries. Learn how to use YCSB-JSON today.","breadcrumb":{"@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/#primaryimage","url":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/5\/2026\/05\/couchbase-nosql-dbaas.png","contentUrl":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/5\/2026\/05\/couchbase-nosql-dbaas.png","width":1800,"height":630},{"@type":"BreadcrumbList","@id":"https:\/\/www.couchbase.com\/blog\/ycsb-json-implementation-for-couchbase-and-mongodb\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/www.couchbase.com\/blog\/"},{"@type":"ListItem","position":2,"name":"YCSB-JSON: Implementation for Couchbase and MongoDB"}]},{"@type":"WebSite","@id":"https:\/\/www.couchbase.com\/blog\/#website","url":"https:\/\/www.couchbase.com\/blog\/","name":"The Couchbase Blog","description":"Couchbase, the NoSQL Database","publisher":{"@id":"https:\/\/www.couchbase.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/www.couchbase.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/www.couchbase.com\/blog\/#organization","name":"The Couchbase Blog","url":"https:\/\/www.couchbase.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/5\/2026\/06\/logo.svg","contentUrl":"https:\/\/www.couchbase.com\/blog\/wp-content\/uploads\/sites\/5\/2026\/06\/logo.svg","width":"1024","height":"1024","caption":"The Couchbase Blog"},"image":{"@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/www.couchbase.com\/blog\/#\/schema\/person\/cf7700be3c6aa11a0e343b4e772d370f","name":"Alex Gyryk","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/baaaa3ba944997d5062b1e71633c1645559a8a91739c8509f659c16283fddc0e?s=96&d=mm&r=g9626fc579c5bf8bdb5fa4d15149f816a","url":"https:\/\/secure.gravatar.com\/avatar\/baaaa3ba944997d5062b1e71633c1645559a8a91739c8509f659c16283fddc0e?s=96&d=mm&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/baaaa3ba944997d5062b1e71633c1645559a8a91739c8509f659c16283fddc0e?s=96&d=mm&r=g","caption":"Alex Gyryk"},"description":"Alex Gyryk is a Principal Software Engineer, Performance at Couchbase. Prior to joining Couchbase, he spent a few years in Forte Group as Senior Performance Analyst.","url":"https:\/\/www.couchbase.com\/blog\/author\/oleksandr-gyrykcouchbase-com\/"}]}},"acf":[],"authors":[{"term_id":332,"user_id":23019,"is_guest":0,"slug":"oleksandr-gyrykcouchbase-com","display_name":"Alex Gyryk","avatar_url":"https:\/\/secure.gravatar.com\/avatar\/?s=96&d=mm&r=g","0":null,"1":"","2":"","3":"","4":"","5":"","6":"","7":"","8":""}],"_links":{"self":[{"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/posts\/1385","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/users\/23019"}],"replies":[{"embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/comments?post=1385"}],"version-history":[{"count":0,"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/posts\/1385\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/media\/18"}],"wp:attachment":[{"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/media?parent=1385"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/categories?post=1385"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/tags?post=1385"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/www.couchbase.com\/blog\/wp-json\/wp\/v2\/ppma_author?post=1385"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}