{"id":904,"date":"2013-04-04T00:07:06","date_gmt":"2013-04-04T00:07:06","guid":{"rendered":"http:\/\/garysieling.com\/blog\/?p=904"},"modified":"2013-04-04T00:07:06","modified_gmt":"2013-04-04T00:07:06","slug":"philly-ete-druid-column-oriented-database","status":"publish","type":"post","link":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/","title":{"rendered":"Druid &#8211; A Column Oriented Database"},"content":{"rendered":"<p>I attended a talk at <a href=\"http:\/\/phillyemergingtech.com\/2013\">Philly ETE<\/a> by <a href=\"http:\/\/metamarkets.com\/\">Metamarkets<\/a>, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a traditional relational database (star schema + pre-computed fact subsets), and then when that didn&#8217;t work out, they tried using a key-value store (!) with many possible queries pre-computed.<\/p>\n<p>Rather than purchasing a database from EMC (Greenplum) or Oracle, they decided to roll their own, which apparently is cheaper(?!). Likely, the reason this works is that there are an increasing number of OSS components, such as <a href=\"http:\/\/zookeeper.apache.org\/\">Zookeeper<\/a>, <a href=\"http:\/\/kafka.apache.org\/\">Kafka<\/a>, <a href=\"http:\/\/hive.apache.org\/\">Hive<\/a>, etc, so one can construct a bundled database product (a similar model to <a href=\"http:\/\/hortonworks.com\/\">HortonWorks<\/a>). Their system is called Druid, and was recently released as an open-source project, although as of this writing they admit it&#8217;s not the easiest thing to configure and stand up.<\/p>\n<p>Unsurprisingly, the solution they built makes extensive use of bitmap indexes. Fact table data is partitioned into batches of up to a 1-2 million rows &#8211; each dimension is produced per batch, then query results are merged. This limits the cardinality of dimensions &#8211; each bitmap index will have no more unique values than rows in the partition. Bitmap indexes are nice, in that they can be ANDed and ORed directly in large batches, with one bit per unique value, so are much smaller than the source data. In fact, <a href=\"http:\/\/en.wikipedia.org\/wiki\/Bitmap_index#Compression\">this data is also compressed<\/a> in a way which can allow for boolean operations to work &#8211; Metamarkets claims the resulting index is 30-40% the size of an inverted index. Incidentally, there is a <a href=\"https:\/\/code.google.com\/p\/javaewah\/\">handy Java implementation<\/a> of this compression algorithm.<\/p>\n<p>This system appears to allow much wider scaling than a typical RDBMS (e.g. 100 nodes), and mitigates network I\/O by tracking which nodes control a segment of data (they&#8217;re not the only DB vendor who has this &#8211; perhaps it&#8217;s a feature of zookeeper?). Data segments are also considered immutable &#8211; when changes are made, a new segment is created, the old one soft-deleted, and background jobs run nightly to clean up duplicates\/leftover data.<\/p>\n<p>More information here-<\/p>\n<p><a href=\"http:\/\/metamarkets.com\/2011\/druid-part-i-real-time-analytics-at-a-billion-rows-per-second\/\">http:\/\/metamarkets.com\/2011\/druid-part-i-real-time-analytics-at-a-billion-rows-per-second\/<\/a><\/p>\n<p><a href=\"http:\/\/metamarkets.com\/druid\/\"><span style=\"color: #333333;\">http:\/\/metamarkets.com\/druid\/<\/span><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a &hellip; <\/p>\n<p class=\"link-more\"><a href=\"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Druid &#8211; A Column Oriented Database&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"om_disable_all_campaigns":false,"_monsterinsights_skip_tracking":false,"footnotes":""},"categories":[6,25],"tags":[85,95,160,392],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 4.9.9 - aioseo.com -->\n\t<meta name=\"description\" content=\"I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a\" \/>\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<meta name=\"author\" content=\"gary\"\/>\n\t<link rel=\"canonical\" href=\"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/\" \/>\n\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 4.9.9\" \/>\n\t\t<meta property=\"og:locale\" content=\"en_US\" \/>\n\t\t<meta property=\"og:site_name\" content=\"Gary Sieling - Software Engineer\" \/>\n\t\t<meta property=\"og:type\" content=\"article\" \/>\n\t\t<meta property=\"og:title\" content=\"Druid \u2013 A Column Oriented Database - Gary Sieling\" \/>\n\t\t<meta property=\"og:description\" content=\"I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a\" \/>\n\t\t<meta property=\"og:url\" content=\"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/\" \/>\n\t\t<meta property=\"article:published_time\" content=\"2013-04-04T00:07:06+00:00\" \/>\n\t\t<meta property=\"article:modified_time\" content=\"2013-04-04T00:07:06+00:00\" \/>\n\t\t<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n\t\t<meta name=\"twitter:title\" content=\"Druid \u2013 A Column Oriented Database - Gary Sieling\" \/>\n\t\t<meta name=\"twitter:description\" content=\"I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"BlogPosting\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#blogposting\",\"name\":\"Druid \\u2013 A Column Oriented Database - Gary Sieling\",\"headline\":\"Druid &#8211; A Column Oriented Database\",\"author\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/#author\"},\"publisher\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#organization\"},\"datePublished\":\"2013-04-04T00:07:06+00:00\",\"dateModified\":\"2013-04-04T00:07:06+00:00\",\"inLanguage\":\"en-US\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#webpage\"},\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#webpage\"},\"articleSection\":\"Data Science, SQL Performance Tuning, big data, business intelligence, databases, nosql\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/www.garysieling.com\\\/blog\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/category\\\/data-science\\\/#listItem\",\"name\":\"Data Science\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/category\\\/data-science\\\/#listItem\",\"position\":2,\"name\":\"Data Science\",\"item\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/category\\\/data-science\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#listItem\",\"name\":\"Druid &#8211; A Column Oriented Database\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#listItem\",\"position\":3,\"name\":\"Druid &#8211; A Column Oriented Database\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/category\\\/data-science\\\/#listItem\",\"name\":\"Data Science\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#organization\",\"name\":\"Gary Sieling\",\"description\":\"Software Engineer\",\"url\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/\"},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/#author\",\"url\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/\",\"name\":\"gary\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#authorImage\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/0be925276d848ffe98a6a9dc8cf33e67?s=96&d=identicon&r=g\",\"width\":96,\"height\":96,\"caption\":\"gary\"}},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#webpage\",\"url\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/\",\"name\":\"Druid \\u2013 A Column Oriented Database - Gary Sieling\",\"description\":\"I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/philly-ete-druid-column-oriented-database\\\/#breadcrumblist\"},\"author\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/#author\"},\"creator\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/author\\\/gary\\\/#author\"},\"datePublished\":\"2013-04-04T00:07:06+00:00\",\"dateModified\":\"2013-04-04T00:07:06+00:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/\",\"name\":\"Gary Sieling\",\"description\":\"Software Engineer\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/www.garysieling.com\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Druid \u2013 A Column Oriented Database - Gary Sieling","description":"I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a","canonical_url":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"BlogPosting","@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#blogposting","name":"Druid \u2013 A Column Oriented Database - Gary Sieling","headline":"Druid &#8211; A Column Oriented Database","author":{"@id":"https:\/\/www.garysieling.com\/blog\/author\/gary\/#author"},"publisher":{"@id":"https:\/\/www.garysieling.com\/blog\/#organization"},"datePublished":"2013-04-04T00:07:06+00:00","dateModified":"2013-04-04T00:07:06+00:00","inLanguage":"en-US","mainEntityOfPage":{"@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#webpage"},"isPartOf":{"@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#webpage"},"articleSection":"Data Science, SQL Performance Tuning, big data, business intelligence, databases, nosql"},{"@type":"BreadcrumbList","@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog#listItem","position":1,"name":"Home","item":"https:\/\/www.garysieling.com\/blog","nextItem":{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/category\/data-science\/#listItem","name":"Data Science"}},{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/category\/data-science\/#listItem","position":2,"name":"Data Science","item":"https:\/\/www.garysieling.com\/blog\/category\/data-science\/","nextItem":{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#listItem","name":"Druid &#8211; A Column Oriented Database"},"previousItem":{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#listItem","position":3,"name":"Druid &#8211; A Column Oriented Database","previousItem":{"@type":"ListItem","@id":"https:\/\/www.garysieling.com\/blog\/category\/data-science\/#listItem","name":"Data Science"}}]},{"@type":"Organization","@id":"https:\/\/www.garysieling.com\/blog\/#organization","name":"Gary Sieling","description":"Software Engineer","url":"https:\/\/www.garysieling.com\/blog\/"},{"@type":"Person","@id":"https:\/\/www.garysieling.com\/blog\/author\/gary\/#author","url":"https:\/\/www.garysieling.com\/blog\/author\/gary\/","name":"gary","image":{"@type":"ImageObject","@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#authorImage","url":"https:\/\/secure.gravatar.com\/avatar\/0be925276d848ffe98a6a9dc8cf33e67?s=96&d=identicon&r=g","width":96,"height":96,"caption":"gary"}},{"@type":"WebPage","@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#webpage","url":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/","name":"Druid \u2013 A Column Oriented Database - Gary Sieling","description":"I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/www.garysieling.com\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/#breadcrumblist"},"author":{"@id":"https:\/\/www.garysieling.com\/blog\/author\/gary\/#author"},"creator":{"@id":"https:\/\/www.garysieling.com\/blog\/author\/gary\/#author"},"datePublished":"2013-04-04T00:07:06+00:00","dateModified":"2013-04-04T00:07:06+00:00"},{"@type":"WebSite","@id":"https:\/\/www.garysieling.com\/blog\/#website","url":"https:\/\/www.garysieling.com\/blog\/","name":"Gary Sieling","description":"Software Engineer","inLanguage":"en-US","publisher":{"@id":"https:\/\/www.garysieling.com\/blog\/#organization"}}]},"og:locale":"en_US","og:site_name":"Gary Sieling - Software Engineer","og:type":"article","og:title":"Druid \u2013 A Column Oriented Database - Gary Sieling","og:description":"I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a","og:url":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/","article:published_time":"2013-04-04T00:07:06+00:00","article:modified_time":"2013-04-04T00:07:06+00:00","twitter:card":"summary_large_image","twitter:title":"Druid \u2013 A Column Oriented Database - Gary Sieling","twitter:description":"I attended a talk at Philly ETE by Metamarkets, a company doing real-time analytics for advertising. Having worked on a couple Oracle-based reporting projects, I entered with interest. Their system is built around dimensional modeling, although with atypically high volume inserts and low latency for updating reports. They attempted to build this system with a"},"aioseo_meta_data":{"post_id":"904","title":null,"description":null,"keywords":null,"keyphrases":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_url":null,"og_image_width":null,"og_image_height":null,"og_image_custom_url":null,"og_image_custom_fields":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_url":null,"twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_title":null,"twitter_description":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[]},"schema_type":"default","schema_type_options":null,"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"limit_modified_date":false,"created":"2023-02-04 16:11:45","updated":"2026-07-06 00:52:35","ai":null,"breadcrumb_settings":null,"seo_analyzer_scan_date":null},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.garysieling.com\/blog\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/www.garysieling.com\/blog\/category\/data-science\/\" title=\"Data Science\">Data Science<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">&raquo;<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tDruid \u2013 A Column Oriented Database\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/www.garysieling.com\/blog"},{"label":"Data Science","link":"https:\/\/www.garysieling.com\/blog\/category\/data-science\/"},{"label":"Druid &#8211; A Column Oriented Database","link":"https:\/\/www.garysieling.com\/blog\/philly-ete-druid-column-oriented-database\/"}],"amp_enabled":true,"_links":{"self":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts\/904"}],"collection":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/comments?post=904"}],"version-history":[{"count":0,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/posts\/904\/revisions"}],"wp:attachment":[{"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/media?parent=904"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/categories?post=904"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/www.garysieling.com\/blog\/wp-json\/wp\/v2\/tags?post=904"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}