

{"id":4721,"date":"2016-12-16T11:35:27","date_gmt":"2016-12-16T16:35:27","guid":{"rendered":"https:\/\/rud.is\/b\/?p=4721"},"modified":"2018-03-07T16:40:37","modified_gmt":"2018-03-07T21:40:37","slug":"minding-the-zookeeper-with-r","status":"publish","type":"post","link":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/","title":{"rendered":"Minding the zoo[keeper] with R"},"content":{"rendered":"<p>I&#8217;ve been drafting a new R package &mdash; [`sergeant`](https:\/\/github.com\/hrbrmstr\/sergeant) &mdash; to work with [Apache Drill](http:\/\/drill.apache.org\/) and have found it much easier to manage having Drill operating in a single node cluster vs `drill-embedded` mode (esp when I need to add a couple more nodes for additional capacity). That means running [Apache Zookeeper](https:\/\/zookeeper.apache.org\/) and I&#8217;ve had the occasional need to ping the Zookeeper process to see various stats (especially when I add some systems to the cluster). <\/p>\n<p>Yes, it&#8217;s very easy+straightforward to `nc hostname 2181` from the command line to issue commands (or use the Zookeeper CLIs) but when I&#8217;m in R I like to stay in R. To that end, I made a small reference class that makes it super-easy to query Zookeeper from within R. Said class will eventually be in a sister package to `sergeant` (and, a more detailed post on `sergeant` is forthcoming), but there may be others who want\/need to poke at Zookeeper processes with [4-letter words](https:\/\/zookeeper.apache.org\/doc\/trunk\/zookeeperAdmin.html#sc_zkCommands) and this will help you stay within R. The only command not available is `stmk` since I don&#8217;t have the pressing need to set the trace mask. <\/p>\n<p>After you source the self-contained reference class you connect and then issue commands as so:<\/p>\n<pre id=\"zk-ex\"><code class=\"language-r\">zk &lt;- zookeeper$new(host=&quot;drill.local&quot;)\r\n\r\nzk$ruok()\r\n\r\nzk$conf()\r\nzk$stat()<\/code><\/pre>\n<p>Drop a note in the comments (since this isn&#8217;t on github, yet) with any questions\/issues.<\/p>\n<pre id=\"zk-class\"><code class=\"language-r\">zookeeper &lt;- setRefClass(\r\n\r\n  Class=&quot;zookeeper&quot;,\r\n\r\n  fields=list(\r\n    host=&quot;character&quot;,\r\n    port=&quot;integer&quot;,\r\n    timeout=&quot;integer&quot;\r\n  ),\r\n\r\n  methods=list(\r\n\r\n    initialize=function(..., host=&quot;localhost&quot;, port=2181L, timeout=30L) {\r\n      host &lt;&lt;- host ; port &lt;&lt;- port ; timeout &lt;&lt;- timeout; callSuper(...)\r\n    },\r\n\r\n    available_commands=function() {\r\n      return(sort(c(&quot;conf&quot;, &quot;envi&quot;, &quot;stat&quot;, &quot;srvr&quot;, &quot;whcs&quot;, &quot;wchc&quot;, &quot;wchp&quot;, &quot;mntr&quot;,\r\n                    &quot;cons&quot;, &quot;crst&quot;, &quot;srst&quot;, &quot;dump&quot;, &quot;ruok&quot;, &quot;dirs&quot;, &quot;isro&quot;, &quot;gtmk&quot;)))\r\n    },\r\n\r\n    connect=function(host=&quot;localhost&quot;, port=2181L, timeout=30L) {\r\n      .self$host &lt;- host ; .self$port &lt;- port ; .self$timeout &lt;- timeout\r\n    },\r\n\r\n    conf=function() {\r\n      res &lt;- .self$send_cmd(&quot;conf&quot;)\r\n      res &lt;- stringi::stri_split_fixed(res, &quot;=&quot;, 2, simplify=TRUE)\r\n      as.list(setNames(res[,2], res[,1]))\r\n    },\r\n\r\n    envi=function() {\r\n      res &lt;- .self$send_cmd(&quot;envi&quot;)\r\n      res &lt;- stringi::stri_split_fixed(res[-1], &quot;=&quot;, 2, simplify=TRUE)\r\n      as.list(setNames(res[,2], res[,1]))\r\n    },\r\n\r\n    stat=function() {\r\n      res &lt;- .self$send_cmd(&quot;stat&quot;)\r\n      version &lt;- stri_replace_first_regex(res[1], &quot;^Zoo.*: &quot;, &quot;&quot;)\r\n      res &lt;- res[-(1:2)]\r\n      sep &lt;- which(res==&quot;&quot;)\r\n      clients &lt;- stri_trim(res[1:(sep-1)])\r\n      zstats &lt;- stringi::stri_split_fixed(res[(sep+1):length(res)], &quot;: &quot;, 2, simplify=TRUE)\r\n      zstats &lt;- as.list(setNames(zstats[,2], zstats[,1]))\r\n      list(version=version, clients=clients, stats=zstats)\r\n    },\r\n\r\n    srvr=function() {\r\n      res &lt;- .self$send_cmd(&quot;srvr&quot;)\r\n      zstats &lt;- stringi::stri_split_fixed(res, &quot;: &quot;, 2, simplify=TRUE)\r\n      as.list(setNames(zstats[,2], zstats[,1]))\r\n    },\r\n\r\n    wchs=function() {\r\n      res &lt;- .self$send_cmd(&quot;wchs&quot;)\r\n      conn_path &lt;- stri_match_first_regex(res[1], &quot;^([[:digit:]]+) connections watching ([[:digit:]]+) paths&quot;)\r\n      tot_watch &lt;- stri_match_first_regex(res[2], &quot;Total watches:([[:digit:]]+)&quot;)\r\n      list(connections_watching=conn_path[,2], paths=conn_path[,3], total_watches=tot_watch[,2])\r\n    },\r\n\r\n    wchc=function() {\r\n      stri_trim(.self$send_cmd(&quot;wchc&quot;)) %&gt;% discard(`==`, &quot;&quot;) -&gt; res\r\n      setNames(list(res[2:length(res)]), res[1])\r\n    },\r\n\r\n    wchp=function() {\r\n      .self$send_cmd(&quot;wchp&quot;) %&gt;% stri_trim() %&gt;% discard(`==`, &quot;&quot;) -&gt; res\r\n      data.frame(\r\n        path=qq[seq(1, length(qq), 2)],\r\n        address=qq[seq(2, length(qq), 2)],\r\n        stringsAsFactors=FALSE\r\n      )\r\n    },\r\n\r\n    mntr=function() {\r\n      res &lt;- .self$send_cmd(&quot;mntr&quot;)\r\n      res &lt;- stringi::stri_split_fixed(res, &quot;\\t&quot;, 2, simplify=TRUE)\r\n      as.list(setNames(res[,2], res[,1]))\r\n    },\r\n\r\n    cons=function() { list(clients=stri_trim(.self$send_cmd(&quot;cons&quot;) %&gt;% discard(`==`, &quot;&quot;))) },\r\n    crst=function() { message(.self$send_cmd(&quot;crst&quot;)) ; invisible() },\r\n    srst=function() { message(.self$send_cmd(&quot;srst&quot;)) ; invisible() },\r\n    dump=function() { paste0(.self$send_cmd(&quot;dump&quot;), collapse=&quot;\\n&quot;) },\r\n    ruok=function() { .self$send_cmd(&quot;ruok&quot;) == &quot;imok&quot; },\r\n    dirs=function() { .self$send_cmd(&quot;dirs&quot;) },\r\n    isro=function() { .self$send_cmd(&quot;isro&quot;) },\r\n    gtmk=function() { R.utils::intToBin(as.integer(.self$send_cmd(&quot;gtmk&quot;))) },\r\n\r\n    send_cmd=function(cmd) {\r\n      require(purrr)\r\n      require(stringi)\r\n      require(R.utils)\r\n      sock &lt;- purrr::safely(socketConnection)\r\n      con &lt;- sock(host=.self$host, port=.self$port, blocking=TRUE, open=&quot;r+&quot;, timeout=.self$timeout)\r\n      if (!is.null(con$result)) {\r\n        con &lt;- con$result\r\n        cat(cmd, file=con)\r\n        response &lt;- readLines(con, warn=FALSE)\r\n        a &lt;- try(close(con))\r\n        purrr::flatten_chr(stringi::stri_split_lines(response))\r\n      } else {\r\n        warning(sprintf(&quot;Error connecting to [%s:%s]&quot;, host, port))\r\n      }\r\n    }\r\n\r\n  )\r\n\r\n)<\/code><\/pre>\n","protected":false},"excerpt":{"rendered":"<p>I&#8217;ve been drafting a new R package &mdash; [`sergeant`](https:\/\/github.com\/hrbrmstr\/sergeant) &mdash; to work with [Apache Drill](http:\/\/drill.apache.org\/) and have found it much easier to manage having Drill operating in a single node cluster vs `drill-embedded` mode (esp when I need to add a couple more nodes for additional capacity). That means running [Apache Zookeeper](https:\/\/zookeeper.apache.org\/) and I&#8217;ve had [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":true,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"activitypub_content_warning":"","activitypub_content_visibility":"","activitypub_max_image_attachments":3,"activitypub_interaction_policy_quote":"anyone","activitypub_status":"","footnotes":""},"categories":[91],"tags":[810],"class_list":["post-4721","post","type-post","status-publish","format-standard","hentry","category-r","tag-post"],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.2 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Minding the zoo[keeper] with R - rud.is<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Minding the zoo[keeper] with R - rud.is\" \/>\n<meta property=\"og:description\" content=\"I&#8217;ve been drafting a new R package &mdash; [`sergeant`](https:\/\/github.com\/hrbrmstr\/sergeant) &mdash; to work with [Apache Drill](http:\/\/drill.apache.org\/) and have found it much easier to manage having Drill operating in a single node cluster vs `drill-embedded` mode (esp when I need to add a couple more nodes for additional capacity). That means running [Apache Zookeeper](https:\/\/zookeeper.apache.org\/) and I&#8217;ve had [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/\" \/>\n<meta property=\"og:site_name\" content=\"rud.is\" \/>\n<meta property=\"article:published_time\" content=\"2016-12-16T16:35:27+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2018-03-07T21:40:37+00:00\" \/>\n<meta name=\"author\" content=\"hrbrmstr\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"hrbrmstr\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"1 minute\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/\"},\"author\":{\"name\":\"hrbrmstr\",\"@id\":\"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886\"},\"headline\":\"Minding the zoo[keeper] with R\",\"datePublished\":\"2016-12-16T16:35:27+00:00\",\"dateModified\":\"2018-03-07T21:40:37+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/\"},\"wordCount\":265,\"commentCount\":4,\"publisher\":{\"@id\":\"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886\"},\"keywords\":[\"post\"],\"articleSection\":[\"R\"],\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/\",\"url\":\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/\",\"name\":\"Minding the zoo[keeper] with R - rud.is\",\"isPartOf\":{\"@id\":\"https:\/\/rud.is\/b\/#website\"},\"datePublished\":\"2016-12-16T16:35:27+00:00\",\"dateModified\":\"2018-03-07T21:40:37+00:00\",\"breadcrumb\":{\"@id\":\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\/\/rud.is\/b\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Minding the zoo[keeper] with R\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/rud.is\/b\/#website\",\"url\":\"https:\/\/rud.is\/b\/\",\"name\":\"rud.is\",\"description\":\"&quot;In God we trust. All others must bring data&quot;\",\"publisher\":{\"@id\":\"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/rud.is\/b\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":[\"Person\",\"Organization\"],\"@id\":\"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886\",\"name\":\"hrbrmstr\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1\",\"url\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1\",\"contentUrl\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1\",\"width\":460,\"height\":460,\"caption\":\"hrbrmstr\"},\"logo\":{\"@id\":\"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1\"},\"description\":\"Don't look at me\u2026I do what he does \u2014 just slower. #rstats avuncular \u2022 ?Resistance Fighter \u2022 Cook \u2022 Christian \u2022 [Master] Chef des Donn\u00e9es de S\u00e9curit\u00e9 @ @rapid7\",\"sameAs\":[\"http:\/\/rud.is\"],\"url\":\"https:\/\/rud.is\/b\/author\/hrbrmstr\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Minding the zoo[keeper] with R - rud.is","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:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/","og_locale":"en_US","og_type":"article","og_title":"Minding the zoo[keeper] with R - rud.is","og_description":"I&#8217;ve been drafting a new R package &mdash; [`sergeant`](https:\/\/github.com\/hrbrmstr\/sergeant) &mdash; to work with [Apache Drill](http:\/\/drill.apache.org\/) and have found it much easier to manage having Drill operating in a single node cluster vs `drill-embedded` mode (esp when I need to add a couple more nodes for additional capacity). That means running [Apache Zookeeper](https:\/\/zookeeper.apache.org\/) and I&#8217;ve had [&hellip;]","og_url":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/","og_site_name":"rud.is","article_published_time":"2016-12-16T16:35:27+00:00","article_modified_time":"2018-03-07T21:40:37+00:00","author":"hrbrmstr","twitter_card":"summary_large_image","twitter_misc":{"Written by":"hrbrmstr","Est. reading time":"1 minute"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/#article","isPartOf":{"@id":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/"},"author":{"name":"hrbrmstr","@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"headline":"Minding the zoo[keeper] with R","datePublished":"2016-12-16T16:35:27+00:00","dateModified":"2018-03-07T21:40:37+00:00","mainEntityOfPage":{"@id":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/"},"wordCount":265,"commentCount":4,"publisher":{"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"keywords":["post"],"articleSection":["R"],"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/","url":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/","name":"Minding the zoo[keeper] with R - rud.is","isPartOf":{"@id":"https:\/\/rud.is\/b\/#website"},"datePublished":"2016-12-16T16:35:27+00:00","dateModified":"2018-03-07T21:40:37+00:00","breadcrumb":{"@id":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/rud.is\/b\/2016\/12\/16\/minding-the-zookeeper-with-r\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/rud.is\/b\/"},{"@type":"ListItem","position":2,"name":"Minding the zoo[keeper] with R"}]},{"@type":"WebSite","@id":"https:\/\/rud.is\/b\/#website","url":"https:\/\/rud.is\/b\/","name":"rud.is","description":"&quot;In God we trust. All others must bring data&quot;","publisher":{"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/rud.is\/b\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":["Person","Organization"],"@id":"https:\/\/rud.is\/b\/#\/schema\/person\/d7cb7487ab0527447f7fda5c423ff886","name":"hrbrmstr","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","url":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","contentUrl":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1","width":460,"height":460,"caption":"hrbrmstr"},"logo":{"@id":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2023\/10\/ukr-shield.png?fit=460%2C460&ssl=1"},"description":"Don't look at me\u2026I do what he does \u2014 just slower. #rstats avuncular \u2022 ?Resistance Fighter \u2022 Cook \u2022 Christian \u2022 [Master] Chef des Donn\u00e9es de S\u00e9curit\u00e9 @ @rapid7","sameAs":["http:\/\/rud.is"],"url":"https:\/\/rud.is\/b\/author\/hrbrmstr\/"}]}},"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p23idr-1e9","jetpack_likes_enabled":true,"jetpack-related-posts":[{"id":4852,"url":"https:\/\/rud.is\/b\/2017\/01\/08\/2017-01-authored-package-updates\/","url_meta":{"origin":4721,"position":0},"title":"2017-01 Authored Package Updates","author":"hrbrmstr","date":"2017-01-08","format":false,"excerpt":"The rest of the month is going to be super-hectic and it's unlikely I'll be able to do any more to help the push to CRAN 10K, so here's a breakdown of CRAN and GitHub new packages & package updates that I felt were worth raising awareness on: epidata I\u2026","rel":"","context":"In &quot;dplyr&quot;","block_context":{"text":"dplyr","link":"https:\/\/rud.is\/b\/category\/dplyr\/"},"img":{"alt_text":"","src":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/01\/epi2.png?fit=982%2C1200&ssl=1&resize=350%2C200","width":350,"height":200,"srcset":"https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/01\/epi2.png?fit=982%2C1200&ssl=1&resize=350%2C200 1x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/01\/epi2.png?fit=982%2C1200&ssl=1&resize=525%2C300 1.5x, https:\/\/i0.wp.com\/rud.is\/b\/wp-content\/uploads\/2017\/01\/epi2.png?fit=982%2C1200&ssl=1&resize=700%2C400 2x"},"classes":[]},{"id":4929,"url":"https:\/\/rud.is\/b\/2017\/01\/22\/create-parquet-files-from-r-data-frames-with-sergeant-apache-drill-a-k-a-make-parquet-files-great-again-in-r\/","url_meta":{"origin":4721,"position":1},"title":"Create Parquet Files From R Data Frames With sergeant &#038; Apache Drill (a.k.a. Make Parquet Files Great Again in R)","author":"hrbrmstr","date":"2017-01-22","format":false,"excerpt":"2021-11-04 UPDATE: Just use {arrow}. Apache Drill is a nice tool to have in the toolbox as it provides a SQL front-end to a wide array of database and file back-ends and runs in standalone\/embedded mode on every modern operating system (i.e. you can get started with or play locally\u2026","rel":"","context":"In &quot;Apache Drill&quot;","block_context":{"text":"Apache Drill","link":"https:\/\/rud.is\/b\/category\/apache-drill\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":4753,"url":"https:\/\/rud.is\/b\/2016\/12\/20\/sergeant-a-r-boot-camp-for-apache-drill\/","url_meta":{"origin":4721,"position":2},"title":"sergeant : An R Boot Camp for Apache Drill","author":"hrbrmstr","date":"2016-12-20","format":false,"excerpt":"I recently mentioned that I've been working on a development version of an Apache Drill R package called sergeant. Here's a lifted \"TLDR\" on Drill: Drill supports a variety of NoSQL databases and file systems, including HBase, MongoDB, MapR-DB, HDFS, MapR-FS, Amazon S3, Azure Blob Storage, Google Cloud Storage, Swift,\u2026","rel":"","context":"In &quot;Apache Drill&quot;","block_context":{"text":"Apache Drill","link":"https:\/\/rud.is\/b\/category\/apache-drill\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":6111,"url":"https:\/\/rud.is\/b\/2017\/07\/17\/ten-hut-the-apache-drill-r-interface-package-sergeant-is-now-on-cran\/","url_meta":{"origin":4721,"position":3},"title":"Ten-HUT! The Apache Drill R interface package \u2014\u00a0sergeant \u2014\u00a0is now on CRAN","author":"hrbrmstr","date":"2017-07-17","format":false,"excerpt":"I'm extremely pleased to announce that the sergeant package is now on CRAN or will be hitting your local CRAN mirror soon. sergeant provides JDBC, DBI and dplyr\/dbplyr interfaces to Apache Drill. I've also wrapped a few goodies into the dplyr custom functions that work with Drill and if you\u2026","rel":"","context":"In &quot;Apache Drill&quot;","block_context":{"text":"Apache Drill","link":"https:\/\/rud.is\/b\/category\/apache-drill\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":12855,"url":"https:\/\/rud.is\/b\/2020\/11\/20\/updated-apache-drill-r-jdbc-interface-package-sergeant-caffeinated-with-dbplyr-2-x-compatibility\/","url_meta":{"origin":4721,"position":4},"title":"Updated Apache Drill R JDBC Interface Package {sergeant.caffeinated} With {dbplyr} 2.x Compatibility","author":"hrbrmstr","date":"2020-11-20","format":false,"excerpt":"While the future of the Apache Drill ecosystem is somewhat in-play (MapR \u2014 a major sponsoring org for the project \u2014 is kinda dead), I still use it almost daily (on my local home office cluster) to avoid handing over any more money to Amazon than I\/we already do. The\u2026","rel":"","context":"In &quot;Apache Drill&quot;","block_context":{"text":"Apache Drill","link":"https:\/\/rud.is\/b\/category\/apache-drill\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]},{"id":7637,"url":"https:\/\/rud.is\/b\/2017\/12\/20\/r%e2%81%b6-series-random-sampling-from-apache-drill-tables-with-r-sergeant\/","url_meta":{"origin":4721,"position":5},"title":"R\u2076 Series \u2014 Random Sampling From Apache Drill Tables With R &#038; sergeant","author":"hrbrmstr","date":"2017-12-20","format":false,"excerpt":"(For first-timers, R\u2076 tagged posts are short & sweet with minimal expository; R\u2076 feed) At work-work I mostly deal with medium-to-large-ish data. I often want to poke at new or existing data sets w\/o working across billions of rows. I also use Apache Drill for much of my exploratory work.\u2026","rel":"","context":"In &quot;Apache Drill&quot;","block_context":{"text":"Apache Drill","link":"https:\/\/rud.is\/b\/category\/apache-drill\/"},"img":{"alt_text":"","src":"","width":0,"height":0},"classes":[]}],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts\/4721","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/comments?post=4721"}],"version-history":[{"count":0,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/posts\/4721\/revisions"}],"wp:attachment":[{"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/media?parent=4721"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/categories?post=4721"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/rud.is\/b\/wp-json\/wp\/v2\/tags?post=4721"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}