{"id":157,"date":"2018-02-24T15:08:14","date_gmt":"2018-02-24T15:08:14","guid":{"rendered":"http:\/\/67bricks.com\/blog\/?p=157"},"modified":"2018-02-24T15:08:14","modified_gmt":"2018-02-24T15:08:14","slug":"dev-meeting-data-intensive-applications-and-rust","status":"publish","type":"post","link":"https:\/\/blog.67bricks.com\/?p=157","title":{"rendered":"Dev meeting &#8211; Data intensive applications; and Rust"},"content":{"rendered":"<p>At our dev meeting this week, Rich talked about &#8216;<strong>Designing Data Intensive Applications<\/strong>&#8216;, that he&#8217;d been reading, and Inigo talked about &#8216;<strong>Talking to your TV using Rust<\/strong>&#8216;.<\/p>\n<p>&#8216;Designing Data Intensive Applications&#8217;, from O&#8217;Reilly, describes various tools and approaches for storing and processing data. It&#8217;s split into four sections. Section 1 discusses the basics of databases and how they store content, for SQL databases, NoSQL databases, flat file stores. It covers in-memory stands, b-trees, indexing structures, and the best approaches to use in various situations. Section 2 talks about distributed databases &#8211; clustering, transactions, serializing commits at a point in time so shared logs can work, and so on. Section 3 discusses distributed batch processing, using tools like Spark. The first three sections were all very interesting and informative. The fourth section was not as good &#8211; it covered the future of data, and was a lot woollier than the previous sections. Rich found the book on the whole good.<\/p>\n<p>To talk to his TV using Rust, Inigo used a Google Home Mini, an RM 3 Mini IR blaster, an Open Source library to interface with the IR blaster, and some Rust on a Raspberry Pi. The Google Home part was setting up a Google Home App via <a href=\"https:\/\/developers.google.com\/actions\/building-your-apps\">https:\/\/developers.google.com\/actions\/building-your-apps<\/a> &#8211; you configure a set of actions and intents online, and then assign a &#8216;fulfillment&#8217; to it, which is a web service you make available via HTTPS. This part is fairly straightforwards &#8211; it requires filling in various web forms, and it&#8217;s easy to publish a test version of an app that&#8217;s only available via your own Google account.<\/p>\n<p>To actually use this for a home application, you need to have SSL, so you need a domain name and a certificate. Inigo used Amazon Route 53 for the domain name, and Lets Encrypt for the certificate. There are various other services that will provide a domain name for a dynamic IP address for free, although the original dyndns is no longer free.<\/p>\n<p>THe &#8216;fulfillment&#8217; part is a web service that Inigo wrote that accepts JSON from Google, and then calls out to a Python library that interacts with the IR blaster. He wrote the first version in Scala, to get something simple working fast, and then rewrote it in Rust. He learned from O&#8217;Reilly&#8217;s Programming Rust book, and used IDEA&#8217;s Rust plugin. The experience was positive, although it was a bit tricky to get some of the memory management working correctly as a first-timer using Rust. The code is on Github at <a href=\"https:\/\/github.com\/inigo\/googlehome-remotecontrol\">https:\/\/github.com\/inigo\/googlehome-remotecontrol<\/a>.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>At our dev meeting this week, Rich talked about &#8216;Designing Data Intensive Applications&#8216;, that he&#8217;d been reading, and Inigo talked about &#8216;Talking to your TV using Rust&#8216;. &#8216;Designing Data Intensive Applications&#8217;, from O&#8217;Reilly, describes various tools and approaches for storing and processing data. It&#8217;s split into four sections. Section 1 discusses the basics of databases &hellip; <a href=\"https:\/\/blog.67bricks.com\/?p=157\" class=\"more-link\">Continue reading<span class=\"screen-reader-text\"> &#8220;Dev meeting &#8211; Data intensive applications; and Rust&#8221;<\/span><\/a><\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[1],"tags":[],"class_list":["post-157","post","type-post","status-publish","format-standard","hentry","category-uncategorized"],"_links":{"self":[{"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=\/wp\/v2\/posts\/157","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=157"}],"version-history":[{"count":1,"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=\/wp\/v2\/posts\/157\/revisions"}],"predecessor-version":[{"id":158,"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=\/wp\/v2\/posts\/157\/revisions\/158"}],"wp:attachment":[{"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=157"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=157"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/blog.67bricks.com\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=157"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}