<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Kevin Lin on Medium]]></title>
        <description><![CDATA[Stories by Kevin Lin on Medium]]></description>
        <link>https://medium.com/@kevins8?source=rss-94907cf170e6------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*cWoG3IPz2kq4nz3kCR7EFA.jpeg</url>
            <title>Stories by Kevin Lin on Medium</title>
            <link>https://medium.com/@kevins8?source=rss-94907cf170e6------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 00:19:33 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@kevins8/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Cache All the Things]]></title>
            <link>https://kevins8.medium.com/cache-all-the-things-da0ec1c1296f?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/da0ec1c1296f</guid>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[pkm]]></category>
            <category><![CDATA[productivity]]></category>
            <category><![CDATA[zettelkasten]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Mon, 26 Sep 2022 00:00:39 GMT</pubDate>
            <atom:updated>2022-09-29T16:02:08.046Z</atom:updated>
            <content:encoded><![CDATA[<p>A PKM workflow to incrementally retain (and find) everything</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*me7BhgcjSgAyGfV7" /></figure><blockquote><em>Infinite knowledge. Digital Art.</em></blockquote><h3>Context</h3><p>An engineering manager that will remain unnamed told me his story of trying to find the solution to a technical problem on the internet. It’s the typical question -&gt; google -&gt; stack overflow -&gt; answer pathway with a twist - when he finally found the answer, he realized that <strong>he himself had created</strong> the question a year prior.</p><p>I like this story because it’s easy to relate to. Haven’t we all searched for something that turned out to be a problem we’ve already encountered?</p><p>The process of searching for answers on the internet is what doing software (and much of knowledge work) is like in the 20th century.</p><p>There is an overwhelming amount of information we need to process just to do our job. It is impossible (nor useful) to keep this information in our heads so we rely on services like google to help look up what we don’t know (or have forgotten).</p><p>While this can work, there is a problem when we come to depend on this workflow for getting through the day. It’s like <strong>only relying</strong> on google maps to get home — while this works, you also lose the ability to navigate on your own in the process.</p><p>This is a <strong>groundhog day loop</strong> — regardless of how much you search, learnings are quickly forgotten and mastery is never built.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*TTXq4fHdia8uQjbF" /></figure><p>Now imagine the same workflow where instead of starting with a search, you look up information in your personal knowledge <a href="https://en.wikipedia.org/wiki/Cache_(computing)">cache</a>. This cache contains every problem you have ever encountered and is accessible in seconds. If you find the answer, you’re done, and if not, you can be <strong>certain that it is not there</strong>. Only then do you fall back to search. When you find the answer, you add it to your cache so you can make use of it in the future.</p><p>This is a mastery loop — instead of losing your place on every question, you build and reinforce your understanding of things with each problem you encounter.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*cNcdPiy2A2o080RV" /></figure><p>The key to building this particular mastery loop comes from combining the following PKM workflows:</p><p>Together, they let you <strong>cache all the things!</strong></p><h3>Progressive Summarization</h3><p>If you’re not familiar with the term, <strong>progressive summarization</strong> is the means of incrementally retaining insights from text to be used at a future date. It is built around five layers of summarization and pioneered by <a href="https://fortelabs.com/">Tiago Forte</a>, a big influencer in the PKM space.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/674/0*JoQP6KKotIukrejO" /></figure><p>The steps are described in more detail below:</p><ol><li>If you come across useful information, save excerpts from it. This is layer 1. The benefit: next time you revisit the notes, you can just go over your excerpts instead the entire text.</li><li>If you happen to need the text again, <strong>bold specific passages</strong> that stand out as you’re reviewing. This is layer 2 and serves to make future skimming easier.</li><li>If you require the text again, ==highlight from the bolded parts== insights that are especially poignant. This is layer 3 and it represents the highest quality insights that you’ve derived from the specific text.</li><li>If you still have need of the text, make a summary of it in your own words. This is layer 4 and represents the start of reframing the text in your own words.</li><li>If you then find the text relevant in some current project, the final step is to remix it into your own material. This is layer 5 and represents the culmination of all the prior layers.</li></ol><p>There are some highly desirable characteristics of <strong>progressive summarization</strong>:</p><ul><li><strong>just in time vs ahead of time</strong>: you only do the work when you need to</li><li><strong>incremental work</strong>: you only do minimal work at each layer which can then be leveraged in later layers</li><li><strong>active vs passive</strong>: you actively read the text instead of skimming it</li></ul><h3>A Hierarchy First Approach to Knowledge Management</h3><p>The <a href="https://blog.dendron.so/notes/3dd58f62-fee5-4f93-b9f1-b0f0f59a9b64">Hierarchy First Approach to Knowledge Management</a> excels at helping people organize lots of information in a consistent structured way for later retrieval.</p><p>It provides a foundation to create a knowledge base that can grow to any size while ensuring that information remains accessible. You can read more about the details of this workflow in the original blog post — <a href="https://www.kevinslin.com/notes/e1455752-b052-4212-ac6e-cc054659f2bb">It’s Not You — It’s Your Knowledge Base</a></p><h3>Cache all the Things</h3><p>Progressive Summarization helps with retaining key insights from text, the Hierarchy First Approach helps organize those summaries so that they can be found again later. The combination of the two lets us create a knowledge base of distilled insights that can be accessed at a moment’s notice.</p><p>There are five levels to this hybrid technique and we’ll spend some time explaining each in greater detail below.</p><h3>Level 1 — Note</h3><p>When you come across information that turns out to be useful, make a note of it. This is done by copying the relevant excerpts from the source material.</p><blockquote><em>Greg is a new engineer at Literal, a social VR company. Their first assignment is to change a hard-coded welcome string to an internationalized string. Their mentor recommends using the CLI tool </em><em>grep to find all instances of the string. Greg has never used </em><em>grep before so spends some time learning about it. He captures a basic example of running the command in his notes.</em></blockquote><pre>grep [OPTIONS] PATTERN [FILE...] grep [OPTIONS] [-e PATTERN | -f FILE] [FILE...]</pre><pre>grep &#39;python&#39; *</pre><h3>Level 2 — Expand</h3><p>If you find yourself continuously going back to the source material because you end up using more functionality, invest in adding more information to your note. For example, this could detail instructions for the new functionality or hard-won insights you’ve discovered through trial and error.</p><blockquote><em>Greg finishes his first assignment and ends up doing more localization work. He uses </em><em>grep quite a lot and discovers that he can use regex to speed up his workflow. He has also at this point noticed some mistakes he keeps making with the options. Greg makes a note of all of this.</em></blockquote><pre>grep [OPTIONS] PATTERN [FILE...] grep [OPTIONS] [-e PATTERN | -f FILE] [FILE...]</pre><pre>grep &#39;python&#39; *</pre><h3>Level 3 — Split</h3><p>If you continue to expand the note, the note will eventually exceed the limit of a single page (eg. 800 words). At this point, you want to split your notes into smaller notes</p><blockquote><em>NOTE: The process of splitting of large notes into smaller notes is also known as the </em><a href="https://wiki.dendron.so/notes/e780000d-c784-4945-8e42-35218a3ecf10"><em>amoeba pattern</em></a></blockquote><blockquote><em>Greg finds himself using grep all the time and he now has to spend time scrolling through his </em><em>grep note to find what he needs. He has a section on snippets that makes up most of the note so he decides to split it off into its own note.</em></blockquote><pre>.<br>└── grep<br>    └── snippets</pre><h3>Level 4 — Standardize</h3><p>As you continue the process of expanding and splitting notes, you tend to find certain clusters of notes will all have the same shape. When this pattern starts to emerge, you can standardize these patterns into hierarchies.</p><blockquote><em>As Greg takes on bigger assignments, he also expands his arsenal of CLI commands. Greg realizes after a while that all CLI commands have a similar structure and so he consolidates it in a hierarchy.</em></blockquote><pre>.<br>└── cli/<br>    ├── grep<br>    │   └── snippets<br>    ├── sed<br>    ├── awk<br>    │   └── snippets<br>    ├── git<br>    ├── test<br>    └── ...</pre><h3>Level 5 — Refactor</h3><p>In software engineering, <a href="https://en.wikipedia.org/wiki/Code_refactoring">refactoring</a> is “the process of restructuring existing (information) — changing the factoring — without changing its external behavior”</p><p>Refactoring is done because the original structure can outgrow its usefulness. Sometimes the underlying information changes or your understanding of it does. Regardless, this means that you will need to update your hierarchies to account for this change.</p><blockquote><em>Greg is tasked with a new assignment that involves working with windows and the PowerShell instead of the Linux terminal. He discovers that the PowerShell has its own set of commands and that the same commands in Linux will have slightly different behavior for Powershell. Greg proceeds to refactor his original hierarchy</em></blockquote><pre>.<br>└── cli/<br>    ├── linux<br>    │   ├── grep<br>    │   │   └── snippets<br>    │   ├── sed<br>    │   ├── awk<br>    │   │   └── snippets<br>    │   ├── git<br>    │   └── test<br>    │   └── ...<br>    └── powershell<br>        ├── CopyCmd<br>        ├── grep<br>        └── ...</pre><h3>Challenges</h3><p>The workflow we just described can be applied outside of CLI commands to cover any information you might want to track. It allows you to systematically build up both your reference of &quot;facts&quot; in a domain as well as an underlying mental model of said domain.</p><p>The challenge in actually implementing this workflow generally surfaces in the latter two levels: standardization and refactoring.</p><p>Standardization into hierarchies is difficult because creating hierarchies is usually time-consuming and adds friction to both the retrieval and capture of new information.</p><p>Refactoring is hard because it usually relies on manually moving old notes into new hierarchies and also breaks links in the process.</p><p>This is why we created <a href="https://wiki.dendron.so/">Dendron</a> — a note-taking tool that helps people <strong>organize and refactor</strong> their notes.</p><p>By making it easy to standardize into hierarchies and refactor as needed, Dendron makes it possible to create, maintain, and make use of knowledge bases that span from a single README file to hundreds of thousands of notes!</p><h3>Conclusion</h3><p>Information can be overwhelming but it doesn’t have to be.</p><p>We’ve long passed the point where we can keep everything in our heads. While that information is available on the internet, it takes time to find and is hard to retain.</p><p>By combining Progressive Summarization with a Hierarchy First Approach to Knowledge Management, we’ve created a workflow that lets us <strong>externalize an unlimited amount of information</strong> and the means to <strong>quickly find it again</strong> when needed.</p><p>This incremental caching of everything represents an escape from the endless cycle of searching for things we’ve already done and instead, lets us focus our efforts on the novel and bigger challenges of the day.</p><p>Imagine how much more effective we could be, as individuals, teams, and as a society, if we could build on top of what we knew instead of spending time forgetting and re-discovering hard-earned knowledge?</p><p>And now stop imagining and start caching!</p><p><em>Originally published at </em><a href="https://blog.dendron.so/notes/o2qlr31o99tycon4hlhgjhw"><em>https://blog.dendron.so</em></a><em> on September 26, 2022.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=da0ec1c1296f" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Hierarchical Tool for Thought]]></title>
            <link>https://kevins8.medium.com/a-hierarchical-tool-for-thought-1bd06870dfbf?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/1bd06870dfbf</guid>
            <category><![CDATA[knowledge-management]]></category>
            <category><![CDATA[productivity]]></category>
            <category><![CDATA[notes]]></category>
            <category><![CDATA[evernote]]></category>
            <category><![CDATA[notetaking]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Sun, 25 Oct 2020 00:00:00 GMT</pubDate>
            <atom:updated>2020-11-01T19:22:15.703Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*NKUwr89f4ULBWBWz.png" /></figure><p>In the summer of 2020, I launched <a href="https://dendron.so/">Dendron</a> — a note-taking tool that helps you manage information using flexible hierarchies.</p><p>You can refer to my <a href="https://www.kevinslin.com/notes/e1455752-b052-4212-ac6e-cc054659f2bb">earlier</a> <a href="https://www.kevinslin.com/notes/3dd58f62-fee5-4f93-b9f1-b0f0f59a9b64">pieces</a> to read about why hierarchies matter.</p><p>A question I’m often asked is what makes Dendron different from all the other tools which also have hierarchies.</p><p>These are mainstay note-taking tools like Evernote, One Note, Google Docs, etc</p><p>My response: all these tools <strong>have</strong> hierarchy — none of them <strong>support</strong> hierarchy.</p><p>The hierarchies in these tools are cumbersome things that tend to get in the way of thought rather than enhance it. They exist, take up space, and sometimes cause a great deal of pain — they are like the human <strong>appendix</strong>.</p><p>The hierarchies in Dendron are fluid and powerful. They let you find and work with knowledge like the mind works with thoughts. Like the human <strong>brain</strong>, these hierarchies are can synthesize vast amounts of information and help transmute it into useful outcomes.</p><p>Dendron <strong>supports</strong> hierarchies. Specifically, this means that the hierarchies in Dendron are <strong>fast</strong>, <strong>flexible</strong> and <strong>functional</strong>.</p><h3>Fast</h3><p>Fast hierarchies allow users to work with information <strong>instantly</strong>.</p><p>Traditionally hierarchies are not fast. Clumsy, slow, manual maybe — but not fast. Traditional hierarchies require you to manually navigate all its levels before you can even see your notes. They require that you construct empty edifices in their name before you can even use them.</p><p>Dendron is fast. Even with thousands of notes, accessing anything by hierarchy can be done in under a second. This is because Dendron uses <a href="https://dendron.so/notes/a7c3a810-28c8-4b47-96a6-8156b1524af3.html">lookup</a> — a way of referencing your notes by their hierarchical path. This works even if you enter a partial path.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*3LaYMwx8q0NWztPq.gif" /></figure><p>This path-based lookup is not just for finding your notes but also for creating them. Lookup will dynamically create hierarchies that don’t exist. This is true even if the path is a new hierarchy that is many levels deep. And if you decide that this is not to be, Dendron will clean up the hierarchy when you delete the note.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*JUhXC8g8z8gUhU0Y.gif" /></figure><p>This means that you can <strong>focus</strong> on your thoughts without being <em>slowed down</em> by your note-taking tool.</p><h3>Flexible</h3><p>Flexible hierarchies allow users to <strong>change</strong> the structure of their information.</p><p>Traditional hierarchies are the antithesis of flexibility — they start ossifying from the moment of creation and become harder to change the more you invest in them. They also require creating a hierarchy upfront.</p><ul><li>Too little of a hierarchy upfront and your notes succumb to entropy</li><li>Too much of a hierarchy upfront and your notes are unable to adjust to change</li></ul><p>And when it comes time to change, links break notes break and are lost for all time.</p><p>Dendron is flexible. We encourage you to iteratively <a href="https://dendron.so/notes/e780000d-c784-4945-8e42-35218a3ecf10.html">build your hierarchy over time</a> — starting with a single note, and only branching off when you have exceeded the bounds of a page.</p><p>Dendron comes with <a href="https://dendron.so/notes/c5e5adde-5459-409b-b34d-a0d75cbb1052.html">schemas</a> — custom metadata to describe the shape of your information. You can use schemas to both document and enforce the structure of your existing hierarchies.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*6OgTXyboOdely6Kd.gif" /></figure><p>When it comes time for change, Dendron lets you transform both individual notes as well as entire hierarchies in one swoop. All links are updated in the process.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Y-vWP4UHR9y_0l-N.gif" /></figure><p>This means that you can <strong>build on your knowledge</strong> without having the <em>perfect structure</em> upfront and make adjustments to it as your understanding deepens.</p><h3>Functional</h3><p>Functional hierarchies allow users to <strong>fully utilize</strong> the hierarchical structure of their data.</p><p>Traditional hierarchies are an afterthought. They are there because something needs to be there. They have not changed for over half a century.</p><p>Dendron is functional. It is built from day one to be a hierarchical tool for thought. There is almost nothing that you can’t do with hierarchies in Dendron.</p><ol><li>You can <strong>create, find, update, search, and remove</strong> information by <a href="https://dendron.so/notes/a7c3a810-28c8-4b47-96a6-8156b1524af3.html">looking up</a> their hierarchies.</li><li>You can <strong>remember</strong> your hierarchies with <a href="https://dendron.so/notes/c5e5adde-5459-409b-b34d-a0d75cbb1052.html">schemas</a>, custom metadata to describe and enforce the shape of your hierarchies.</li><li>You can <strong>transform</strong> your hierarchies, either a <a href="https://dendron.so/notes/eea2b078-1acc-4071-a14e-18299fc28f47.html#rename-note">single note</a> or an <a href="https://dendron.so/notes/eea2b078-1acc-4071-a14e-18299fc28f47.html#refactor-hierarchy">entire hierarchy</a> at a time.</li><li>You can <strong>combine</strong> hierarchies with other constructs like <a href="https://dendron.so/notes/8bc9b3f1-8508-4d3a-a2de-be9f12ef1821.html">tags</a>, <a href="https://dendron.so/notes/301e4129-6933-4be7-a4bd-8125171360d8.html">backlinks</a>, and <a href="https://dendron.so/notes/f1af56bb-db27-47ae-8406-61a98de6c78c.html">note references</a>.</li><li>You can <strong>capture</strong> chronological as well as ad-hoc information using Dendron’s builtin hierarchies</li><li>You can <strong>visualize</strong> your hierarchies through <a href="https://dendron.so/notes/587e6d62-3c5b-49b0-aedc-02f62f0448e6.html">hierarchical graph views</a></li><li>You can <strong>share</strong> any subset of your hierarchy as a <a href="https://dendron.so/notes/73d395c9-5041-4d0d-9db7-080d9586136e.html">published site</a>.</li><li>You can <strong>move</strong> your notes and their hierarchy to <a href="https://dendron.so/notes/66727a39-d0a7-449b-a10d-f6c438185d7f.html">any other tool</a>.</li></ol><p>This means that you can <strong>make use</strong> of information without dealing with the <em>arbitrary restrictions and limitations</em> of the tool holding your notes.</p><h3>Conclusion</h3><p>Dendron is a hierarchical tool for thought. It is built from the ground up to <strong>support</strong> hierarchies that are <strong>fast, flexible, and functional</strong>.</p><p>One day, Elon Musk might launch <a href="https://neuralink.com/">neural link</a> and enable the mythical brain-to-computer interface of science fiction. Until that day, hierarchical tools of thought, and specifically Dendron, will strive to be the best possible means for <strong>humans</strong> to <strong>create, find, and collaborate</strong> on the information that matters to <strong>us</strong>.</p><p><em>Originally published at </em><a href="https://www.kevinslin.com/notes/127a3230-4484-433a-b97f-178679564207.html"><em>https://www.kevinslin.com</em></a><em> on October 25, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1bd06870dfbf" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Dendron — an open source, local first, anti-roam note-taking tool]]></title>
            <link>https://kevins8.medium.com/dendron-an-open-source-local-first-anti-roam-note-taking-tool-ca1ba65d3058?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/ca1ba65d3058</guid>
            <category><![CDATA[pkm]]></category>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[roam]]></category>
            <category><![CDATA[vscode]]></category>
            <category><![CDATA[notetaking]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Fri, 18 Sep 2020 15:12:21 GMT</pubDate>
            <atom:updated>2020-09-18T17:37:26.655Z</atom:updated>
            <content:encoded><![CDATA[<h3>Dendron — an open source, local first, anti-roam note-taking tool</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hgK5r2YRF5ODB2DAu3u0dQ.gif" /></figure><p><a href="https://dendron.so/">Dendron</a> is meant to be the fastest way for people to create, reference, and collaborate on knowledge. It is based on a <a href="https://www.kevinslin.com/notes/3dd58f62-fee5-4f93-b9f1-b0f0f59a9b64.html">hierarchical first approach to note taking</a>.</p><p>Hierarchy first means that Dendron helps you effortlessly create, manage, and reference your notes through flexible hierarchies. I call it anti-roam because instead of having every note be everywhere, every note is exactly in one well defined place (which you can change over time).</p><p>You can read about our principles <a href="https://www.dendron.so/notes/7fcebd7d-6411-4c9d-8baf-65629dc018a1.html">here</a></p><p>I use Dendron to manage a corpus of 20k+ markdown notes. When I need to lookup information inside Dendron, I know I can either <strong>find it in a few seconds</strong>, or if I don’t, to know for certain that it is <strong>not there</strong>. This is an incredibly empowering feeling of control in an age of information overload and it is an ability I want to give to every person in the world.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=ca1ba65d3058" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[A Hierarchy First Approach to Note Taking]]></title>
            <link>https://kevins8.medium.com/a-hierarchy-first-approach-to-note-taking-9d4b176bd5ec?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/9d4b176bd5ec</guid>
            <category><![CDATA[notetaking]]></category>
            <category><![CDATA[productivity]]></category>
            <category><![CDATA[pkm]]></category>
            <category><![CDATA[roam]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Mon, 24 Aug 2020 00:00:00 GMT</pubDate>
            <atom:updated>2020-08-25T14:50:53.511Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/0*y-xxR1CuJt_GuBPK.jpeg" /></figure><p>Ten years ago I wrote a note.</p><p>That led to <strong>another</strong>, and then <strong>another</strong>, and soon enough, I had a <strong>few thousand</strong> of them and an increasingly unhappy dropbox client that refused to sync it all.</p><p>The reason for all these notes is because of technology.</p><p>I worked at AWS and tried to keep on top of <strong>cloud stuff</strong>. I programmed in three different languages and kept notes to help me context switch between different <strong>programming languages</strong>. I also did full-stack development on the side and that, well, it required referencing <a href="https://www.reddit.com/r/webdev/comments/747hfu/does_everybody_find_the_modern_fullstack_learning/"><strong>everything</strong></a>.</p><p>My primary use for notes is as a <a href="https://en.wikipedia.org/wiki/Cache_(computing)">cache</a>. Think <a href="https://redis.io/">Redis</a>, but for humans.</p><p>If I spent <strong>more than 5 minutes</strong> figuring something out, those are five minutes I <strong>never</strong> want to spend again figuring out the <strong>same problem</strong>.</p><p>But this is difficult to do in practice.</p><p>Sometimes you run into a thing that only pops up on some specific version of a cli command on an outdated bash shell on a specific Linux distro. How do you document this sort of thing when you might encounter a dozen of them a day?</p><p>My solution is something I call <strong>hierarchal note taking</strong>. It’s a system I’ve developed over the past ten years that has allowed me to amass a corpus of +10k notes.</p><p>This system has some awesome properties that I haven’t been able to replicate with anything else:</p><ul><li>it lets me <strong>find any specific note within seconds</strong> even with thousands of existing notes</li><li>it helps me build a <strong>comprehensive mental model</strong> around a domain through the act of organizing my notes</li><li>it <strong>can be used on any note-taking tool that supports markdown notes</strong></li><li>it’s compatible with existing note-taking methodologies like <a href="https://fortelabs.co/blog/para/">PARA</a></li></ul><p>The rest of this post will describe the journey I took to arrive at hierarchal note-taking and the problems that they help me solve.</p><p>I spend a lot of time in the command line in Unix-like systems. If you do as well, you might be familiar with the following comic.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*p4Y9t4V7aqwLQqTY.png" /></figure><blockquote><em>Comic from </em><a href="https://xkcd.com/"><em>XKCD</em></a></blockquote><p>I’ve probably used tar a few thousand times in my life but still can&#39;t tell you what the arguments mean (it&#39;s mostly muscle memory at this point). Unix tools do one thing and one thing well, and on most days, that one thing is making you reach for a <a href="https://en.wikipedia.org/wiki/Man_page">man page</a>.</p><p>This is because every command has many dozen options, many of which are invoked with obscure single character letters in a specific order for specific inputs (I’m looking at you rsync).</p><p>Growing tired of reading man pages and stack overflow threads, I wanted a way to capture and reference commands that I’ve run in the past. And so I started taking notes.</p><p>I created a folder called notes. I created a note called tar.md.</p><p>Note that my tar.md note doesn&#39;t have every option or use case involving tar. Instead, it&#39;s only the options that I find most useful and use cases that I&#39;ve had to do. This tends to be my approach to note-taking - I like to capture the bare minimum information I need so that the future me can get value out of the note.</p><p>What started as a single markdown file quickly spawned a few hundred more. It was exhilarating — instead of turning to google every time I ran into a dusty corner of Linux, I could just reference my notes. 95% of the time, there would be a nicely summarized note waiting for me :)</p><p>While the above approach worked for cli commands, things got more complicated as I needed notes on additional domains. Most commonly with my work, it was programming languages.</p><p>Take <a href="https://www.python.org/">python</a> as an example. Python is both a <strong>programming language</strong> as well as a <strong>cli command</strong>. Without changing the name of one of the notes or introducing folders, there would be no way to create notes on both.</p><p>But I didn’t want folders. Folders were messy and besides, weren’t supported in <a href="http://notational.net/">notational velocity</a>, my primary note-taking tool at the time. So instead of folders, I decided to create a hierarchy using the . symbol as my delimiter.</p><p>Now I could represent the language and the cli as two different . delimited hierarchies.</p><p>Though on the surface, this seems like a simple change and not all that different from a traditional folder hierarchy, I found that it equal to the difference between using a <a href="https://en.wikipedia.org/wiki/Commodore_64">commodore 64</a> and the latest (non- <a href="https://www.theverge.com/2020/5/4/21246223/macbook-keyboard-butterfly-magic-pro-apple-design">butterfly keyboard</a>) Macbook.</p><p>For starters, files now had the ability to both contain data and have children. They could act as both files and folders.</p><p>And whereas folders were traditionally used to <strong>organize</strong> information, there was no straightforward way to use a folder hierarchy to quickly <strong>find</strong> information. Having the hierarchy in the filename made it easy to <strong>find</strong> information using the <strong>hierarchy</strong>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*fkNKtrwzC8saF81V.gif" /></figure><p>There’s the joke in computer science that there are only 3 meaningful quantities in the field: 0, 1 or infinite. If you can create a thing more than once, there is nothing in theory that should stop you from creating an infinite amount of said thing.</p><p>Once I realized I had a system of making two-level hierarchies, I realized I didn’t need to stop there. This soon led to deeper hierarchies like the one below.</p><p>The above hierarchy was stored as simple plain text files inside my notes folder.</p><p>With this hierarchy, I could quickly reference anything I needed from a programming language.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*n27abg6BnplixJ-K.gif" /></figure><blockquote><em>Looking up different data structures in python</em></blockquote><p>Once I built out my hierarchy on python, I found that I could also apply it to any other language. This made context switching between languages much easier.</p><p>As an example, I can never remember what counts as truthy in dynamic languages. But now I don&#39;t have to.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*7QgZJTVWkF8rWJch.gif" /></figure><blockquote><em>Finding the truth</em></blockquote><p>The cool thing about this approach is that the implementation details of any particular language became less important as I build out my hierarchies. Instead of thinking in terms of “how well do I understand <strong>python</strong>”, I think in terms of how well I understand <strong>programming languages</strong>.</p><p>As I started building hierarchies across more and more domains, I found that it became useful to document what they were. I called these <em>externalized hierarchies</em> <strong>schemas</strong>. They were a table of contents for a particular hierarchy. I started adding a special schema file directly underneath the root of each hierarchy.</p><p>Inside each schema note, I would have something like the following</p><p>I would use schemas as a common source of truth when building out a hierarchy and use them to make sure that each hierarchy was internally consistent. As I began to use this system day by day, I realized that I had stumbled upon a radically more effective way of learning.</p><p>By associating every note I took to a hierarchy, I found that looking up information no longer felt like an <strong>tax on my time</strong>, but instead, a <strong>path to self augmentation</strong>.</p><p>Whereas before I would look up a thing only to forget it a few weeks later, I could now quickly incorporate it into my notes and <strong>know with certainty</strong> that I will be able to <strong>reference this again</strong> at a later date.</p><p>Better yet, when I found something that didn’t fit any of my existing hierarchies, I could use it as a chance to update my schemas on said hierarchies. This would slowly expand my conceptual understanding of the entire domain.</p><p>A concrete example: earlier this year, I ended up making use of the <a href="https://en.wikipedia.org/wiki/Null_coalescing_operator">null coalescing operator</a> in javascript. This is a convenient way of assigning values when dealing with null</p><p>In the following example, a will be assigned the value of b if the value of b is not null or undefined, otherwise, it will be assigned 3.</p><p>After learning about it, I added it to my language schema under operators.</p><p>Not only did this expand my vocabulary of language operators, but it also let me note down how the equivalent functionality can be expressed in languages that did not natively support it.</p><blockquote><em>Python example of “null coalescing”</em></blockquote><p>What is nice about this approach is that I have completely divorced the concept of “null coalescing” with the implementation detail of any particular language. The next time I’m using python and want to do null coalescing, I can simply look up python.op.null and be reminded of the implementation.</p><p>There are dozens of <strong>main stream</strong> programming languages. There are hundreds of additional domain-specific languages. In a prior life, there would have been no way for me to <strong>know</strong> even a tiny fraction of them. But a hierarchal first approach to note-taking changes the game — instead of having to know the details of <strong>every</strong> language, I can collapse it all down to my <strong>one language schema</strong>. This schema can capture the points of interest of <strong>every language</strong> and in this way, I can claim to <strong>know</strong> something of all programming languages.</p><p>Today, my knowledge base encompasses over a dozen different hierarchies that span 10K+ notes. I’ve expanded my use cases of note-taking beyond caching to also include journaling, task management, creating writing, keeping track of interactions, and lots more.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*inmB6t-nAQ8wM14o" /></figure><blockquote><em>My journal notes for the last five years.</em></blockquote><p>I’ve also expanded my schemas and have migrated from free form bullets to a structured YAML syntax.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*LjXEeSw8e3ienMmq.jpg" /></figure><blockquote><em>My programming language schema</em></blockquote><p>Hierarchal note-taking has been the most valuable investment I’ve made in the last decade. My notes, in turn, have helped me learn, grow, and be better in all areas of my life.</p><p>One thing that has puzzled me over the years is why no one else was doing this. Most of my peers did no kind of note-taking, and the ones that did were constantly switching between different tools and methodologies to try to manage it all.</p><p>A little over a year ago, I left my job at Amazon to work on a note-taking tool built around the concept of hierarchal notes. Hierarchal note-taking is a system that I spent the greater part of a decade iterating on, and it is now a system that I want to share with the world.</p><p>About a month ago, I launched the preview for <a href="https://dendron.so/">Dendron</a>. Dendron is the first-ever note-taking tool built from the ground up to support hierarchal note-taking. Dendron is open source, local first, Markdown-based, and runs as a collection of extension on top of VSCode.</p><p>Dendron lives inside VSCode because I wanted to move fast and focus on the truly novel parts of hierarchal notes without also building all the scaffolding that comes from creating an editor. Living inside VSCode means that users also have access to the thousands of existing extensions that provide everything from <a href="https://marketplace.visualstudio.com/items?itemName=vscodevim.vim">vim keybindings</a> to <a href="https://marketplace.visualstudio.com/items?itemName=MS-vsliveshare.vsliveshare">realtime collaboration editing</a>.</p><p>Over 50 years ago, <a href="https://en.wikipedia.org/wiki/Vannevar_Bush">Vannevar Bush</a>, an early visionary in information science, said something about the field that strikes a deep chord with me.</p><blockquote><em>“We are overwhelmed with information and we don’t have the tools to properly index and filter through it. [The development of these tools, which] will give society access to and command over the inherited knowledge of the ages [should] be the first objective of our scientist” — Vannevar Bush, 1945</em></blockquote><p>50 years later, this statement is just as true. The tools haven’t changed but the information has only become more overwhelming.</p><p>Dendron is my attempt at building a tool that will give humans <strong>access to</strong> and <strong>command over</strong> the <strong>inherited knowledge of the ages</strong>.</p><p>If this mission statement resonates, I hope you join me on the journey! There are many ways to be involved:</p><ul><li>you can <a href="https://marketplace.visualstudio.com/items?itemName=dendron.dendron">download dendron</a> and start/continue a note-taking habit</li><li>you can join our <a href="https://discord.gg/6j85zNX">discord</a> community of fellow note-takers</li><li>you can follow us on twitter at <a href="https://twitter.com/dendronhq">@dendronhq</a></li><li>you can star and watch us on <a href="https://github.com/dendronhq/dendron">github</a></li></ul><p>Whatever path you take, safe travels and hope you take note of the journey!</p><p>If you liked this article and would like to get more like it, feel free to subscribe to my mailing list. I publish around once a week and share my thoughts on knowledge management and workflows that I find effective.</p><p><em>Originally published at </em><a href="https://www.kevinslin.com/notes/3dd58f62-fee5-4f93-b9f1-b0f0f59a9b64.html"><em>https://www.kevinslin.com</em></a><em> on August 24, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=9d4b176bd5ec" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Everything I Learned from One Year of AWS Consulting]]></title>
            <link>https://kevins8.medium.com/everything-i-learned-from-one-year-of-aws-consulting-87ac2c11e404?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/87ac2c11e404</guid>
            <category><![CDATA[consulting]]></category>
            <category><![CDATA[2020]]></category>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Mon, 06 Jan 2020 00:00:00 GMT</pubDate>
            <atom:updated>2020-01-06T19:36:41.779Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/0*I_slbQdCDHSn_HTc.jpg" /></figure><p>They say that hindsight is 2020 — which makes the start of this year the perfect time to reflect on the last.</p><p>2019 was a tumultuous year — both from a macro world socio-economic oh-my-god-what-is-happening standpoint and from a micro individual oh-my-god-what-am-I-doing standpoint.</p><p>On the individual front, I made three life-altering decisions in 2019:</p><ol><li>I left AWS after five years to pursue my own startup(s)</li><li>I started three businesses</li><li>I got married</li></ol><p>This post will focus on the first two decisions and how they played out over the course of my first year outside of big tech. As a first-time entrepreneur, I hope the learnings here will help others making similar transitions.</p><h3>Background</h3><p>I <a href="https://www.geekwire.com/2018/kevin-s-lin/">left Amazon</a> around the beginning of 2019 to pursue my own startup ambitions. While I loved working at Amazon, I never intended to be there forever, and at the five-year mark, that was starting to look like the case.</p><p>Leaving wasn’t easy. I liked Amazon. The culture. The people. The <a href="https://www.amazon.jobs/principles">leadership principles</a>. The autonomy. The compensation.</p><p>But I had an idea of a thing I wanted to build and a hunger to see if I could make it on my own. And so I left.</p><h3>Making Thence</h3><p>I suppose there is some irony that the first thing I did after leaving AWS was to start a consulting business around it. It felt like the right way to dip my toes into the waters of unemployment startup life. I was very much still passionate about the platform, I had deep expertise in how it worked, and there was a great market need for it.</p><p>I won’t go into detail about incorporating the business other than to say that I did and incorporated as Thence LLC, a limited liability corporation based in Washington.</p><p>After incorporating, I was ready for clients but didn’t have the first notion of how to go about it so I studied and read up on the subject. I followed internet people like <a href="https://www.kalzumeus.com/">Patrick McKenzie</a> and <a href="https://daedtech.com/">Eric Dietrich</a>. I read business books like <a href="http://www.amazon.com/dp/product/0787976393/ref=as_li_ss_tl?ie=UTF8&amp;linkCode=ll1&amp;tag=bretttercom-20">Getting Naked</a> and <a href="https://amzn.to/2QsQAym">The Blue Ocean Strategy</a>. And I reached out to folks like <a href="https://twitter.com/QuinnyPig">Corey Quinn</a> and <a href="https://www.1strategy.com/about-us/">Rich Uhl</a> who were already doing the sort of things I aspired to do and were kind enough to give me the time of day.</p><p>From this research, I took away some of the following:</p><ul><li>it’s important to find a niche to specialize in, otherwise, you risk being a commodity</li><li>avoid online agencies like <a href="https://www.upwork.com/">Upwork</a> as they tend to commoditize your skills</li><li>build a brand through channels that you control (e.g. email lists, blogs, etc.)</li><li>always charge more than what you feel comfortable with (a good mark to shoot for is 2x more than your normal hourly rate)</li></ul><h3>Finding a Niche</h3><p>Finding a niche makes sense on paper but it’s hard to be picky when you’re just starting. When I started, I did any work on any cloud for anyone.</p><p>My first gig as a consultant was with an IoT manufacturer running on Azure. While the job was successful, I quickly realized that I spent too much time learning Azure-specific quirks (and wasn’t leveraging my knowledge of AWS specific quirks). And so I decided to focus solely on AWS jobs afterwards.</p><p>What followed was a series of jobs across the stack, from coming up with high-level service architectures to diagnosing database-specific connectivity issues. With each job, I would gather feedback from my clients and myself, with the goal of figuring out my specialty.</p><p>I tried finding something I enjoyed, something I was good at, and something the market needed. The ideal specialty would be at the intersection of all three things.</p><p>Below is a list of “specializations” I experimented with during the year.</p><h3>Scaling</h3><p>I started my career at AWS working on scaling <a href="https://aws.amazon.com/elasticloadbalancing/">Elastic Load Balancers</a> and built three successive generations of scaling systems for the service. This was work that I enjoyed and wanted to do more of.</p><p>Unfortunately, I had a hard time finding clients for scaling. The sort of startups I was meeting early on did not need it and enterprise had teams dedicated to it. As I became more established, I did get a few scaling audit related jobs but they were few and far between.</p><h3>Cost Optimization</h3><p>At AWS, I was one of the main architects behind the <a href="https://aws.amazon.com/elasticloadbalancing/pricing/">Load Balancer Capacity Unit</a> (LCU). This was a custom metric derived from other system metrics and represented the “work” the load balancer did. Subsequently, all load balancers would be billed according to this metric, which meant we had to triple check all our benchmarks to make sure this new billing model would be cheaper than the old one (which billed by bandwidth). This exposed me firsthand to the complexities of AWS billing and made me realize how it was as much an engineering problem as a financial one. Billing in AWS is tied directly to configuration and reducing the bill means understanding both the financial and engineering tradeoffs of a particular configuration.</p><p>As a consultant, cost optimization turned out to be an easy thing to pitch — after all, “I want to pay <strong>more</strong> for AWS” is not a thing anyone has ever said. My offer was a guaranteed minimum of 30% (usually closer to 60%) off your monthly bill in exchange for a percentage of your total spend on AWS (as a consequence, this only made sense for clients that had a minimum monthly spend of 5k/mo or more).</p><h3>HIPAA</h3><p>Near the middle of my AWS tenure, I switched teams to become the first hire on a skunkworks project that eventually spun out into <a href="https://aws.amazon.com/comprehend/medical/">Amazon Comprehend Medical</a>. I build much of the initial ML infrastructure in the first year and learned all about <a href="https://www.hhs.gov/hipaa/for-professionals/index.html">HIPAA</a> and what it means to satisfy it from a technical standpoint.</p><p>I ended up doing a series of jobs in healthcare, most notably architecting the entire AWS stack for an early healthcare startup on the east coast. This proved to be a lucrative niche since the intersection of people that could do AWS and were familiar with HIPAA was quite small.</p><h3>Serverless</h3><p><a href="https://en.wikipedia.org/wiki/Serverless_computing">Serverless</a> was not something I worked on directly at AWS but it was something I followed closely. Just like cloud computing, (I believe) the serverless paradigm will revolutionize how people build digital services. I spent part of last year both <a href="https://kevinslin.com/aws/lambda_cold_start_idle/">writing</a> and <a href="https://kevinslin.com/aws/building_sls_apps/">speaking</a> about serverless as well as <a href="http://backuptable.com/">building</a> a few services on top of it.</p><p>In my consulting, I find that the majority of startups have already adopted serverless or are moving towards it. More often than not, I find my job to be one of cautioning my clients against using serverless for applications it is not (yet) suited for. I’m excited to continue working with serverless and see this space grow in 2020.</p><h3>DevOps and CDK</h3><p>As someone used to writing/generating thousand-line json based cloudformation templates, the introduction of the <a href="https://docs.aws.amazon.com/cdk/latest/guide/home.html">CDK</a> in 2018 was like finding an oasis after years wandering the desert. For the first time, <a href="https://en.wikipedia.org/wiki/Infrastructure_as_code">Infrastructure as Code</a> had an implementation that was not a config or a config-like language but actual code. You can find my initial evangelizing writing about the CDK <a href="https://kevinslin.com/AWS/cdk_all_the_things/">here</a>.</p><p>In my consulting, I use the CDK to deploy infrastructure for my clients when at all possible, because it makes my job easier. What I didn’t expect was for clients to reach out to me specifically because of CDK and wanting to integrate CDK into their production pipeline. I ended up publishing a <a href="https://github.com/kevinslin/open-cdk">CDK best practices guide</a> based off my work and look forward to continued work in this space this year.</p><h3>Education</h3><p>I like learning and teaching what I’ve learned. To that end, AWS is like a fantastical candy shop where the more you consume, the more there is left. I write and give talks to help distill, consolidate and share what I know with others.</p><p>In 2019, I did a small number of on-site training sessions and am open to doing more in 2020.</p><h3>Niche?</h3><p>So at the top of the article, I talked about specializing. My journey of specializing as a consultant went as follows:</p><ul><li>everything on all clouds</li><li>everything on AWS</li><li>a list of very specific things on AWS</li></ul><p>Despite this being a small subset of where I started, one could make the case that this is still too many things to count as a specialty.</p><p>I interviewed <a href="https://www.linkedin.com/in/charlie-bell-05446835">Charlie Bell</a>, the SVP of AWS, many years ago as part of an internal podcast I hosted at Amazon. I asked him how he decides what the company should focus on, and Charlie replied that his job was to “say yes to as many things as possible.”</p><p>Left to my own devices, that tends to be my answer as well. I realize that this is easier for a Fortune 500 company to do than an individual formerly employed at a Fortune 500 company. That’s why I will continue to whittle down this list in 2020 (though I suspect the end result will still be more than one thing).</p><h3>Establishing a Pipeline</h3><p>Finding clients is something that every freelancer struggles with, me included. What I’ve learned is that getting a client is, at the end of the day, about establishing trust (this is the answer to most things involving humans).</p><p>Establishing a client pipeline is finding a scalable means of signaling trust. Like all interesting things in life, there’s no cut and dry way of establishing trust but I’ll go over some of the things I did.</p><h3>Networking</h3><p>Of all channels I’ve tried, I found the personal network to have the highest signal to noise ratio. Especially when first starting out, these sorts of introductions can get you into places you otherwise have no business being. The problem is that this network stays mostly static unless you make an intentional effort to grow it.</p><p>In 2019, I went from never networking (besides the sort that involved packets) to spending half my time at meetups, conferences and user groups (basically attending anything with “AWS” in the name).</p><p>My approach to talking to strangers was to not sell but listen. Figure out what brought them to the event. What they were doing on AWS. If they were encountering problems, offer solutions. It was only at the point when they asked me what I did that I talked about consulting.</p><p>I found this approach to not only be highly effective in getting clients but to also get me over my “moral aversion” to “selling.” It goes back to building trust — I found if I could start there, the rest would follow.</p><p>My other networking trick is to use <a href="https://airtable.com/">airtable</a> to meticulously track every person I’ve met and every interaction I’ve had. For each contact, I track each interaction, what was discussed and the outcome. I also attach the desired frequency of communication with each lead, list problems they had and the number of days since the last follow-up. This tracking has also spilled over to my personal life, as I started tracking my interaction with friends on a similar table.</p><h3>Agencies</h3><p>While networking brought me my initial set of clients, the process was also a crapshoot — for every fifty people I talked to, I might produce one lead. This led me to explore various freelancing agencies like Upwork, Toptal, and Facet.</p><p>I think of networking like dating in real life — you go to different venues to strike up conversations but have no idea if the person is even looking for relationships or is already in one. By this analogy, agencies are like dating sites — they are platforms where at least you know everyone is actively looking for the same things you are.</p><p><a href="https://www.upwork.com/">Upwork</a> is the Amazon of talent agencies. They have the biggest selection of jobs and freelancers and you go on Upwork because you want the lowest price. Most consulting practitioners counsel folks to <a href="https://www.youtube.com/watch?v=PNayKRir14U&amp;feature=youtu.be&amp;t=142">stay off the platform</a> for that reason.</p><p>Starting out, I didn’t see the harm in trying. While the initial jobs did not pay much, it was very easy to find clients and get references. And once you had some history, clients could find you organically when looking for freelancers.</p><p>I found that the discoverability aspect of Upwork made it good for niche specializations (e.g. HIPAA) and I would get a few inbound leads from Upwork every month in this manner. For these jobs, I ended up charging $300/h. While this matched my regular rate, it was more than double the average Upwork rate. I wanted to experiment if Upwork could support higher tier freelancers and with only a few exceptions, I found that it could. Inbound leads make up 100% of my jobs on Upwork at this point.</p><p><a href="https://www.toptal.com/">Toptal</a> I had more trouble with. They advertise themselves as the top 3% of freelancers and screen out people through a multi-part interview process that includes a lengthy take-home project. The problem is that after being let in. there is no possibility of “inbound client requests.” All jobs are posted by Toptal recruiters and they control both sides of the conversation until you agree to a job. The pay was not much more than what you could find on a typical Upwork job and the availability of jobs was far less. I ended up not doing anything on Toptal.</p><p>Finally, I tried <a href="https://www.facetdev.com/">Facet</a>. This was another take on the agency model, but one comprised exclusively of former FANG (Facebook, Amazon, Netflix, and Google) employees (today it’s FANG and FANG like companies). Onboarding was virtually painless (at least at the time I did it in early 2019) and required no additional interviews. Speaking of interviews, I did <a href="http://folkstories.org/16">an interview</a> with the founder of Facet and we talk about the company at length if you’re curious for additional details.</p><p>Facet has the freelancer set their own rates and charges 20% on top of that to employers hiring off the network. This is different from Toptal and Upwork which also have a 20% fee but charge it to the freelancer. Facet’s model usually works out to higher take-home pay and jobs on the network generally start off with much higher hourly rates. My biggest problem with Facet is that almost all the opportunities are full time, which was explicitly what I was not in the market for. Also, like Toptal, they brokered both sides of the transaction which meant no possibility for direct inbound contact with potential clients. I ended up not doing anything on Facet either.</p><h3>Platforms and Branding</h3><p>I left Amazon to control my own destiny. While agencies like Upwork and Toptal help you build credibility from reviews, and platforms like Medium and LinkedIn have reach, you are, at the end of the day, playing in someone else’s sandbox (and at their mercy). Note that I’m not against leveraging those platforms (I do it a lot) but it’s important to me that I’m in complete control of my primary channel(s) — hence this blog.</p><p>Blogging, and more broadly speaking brand building, is a means to build trust. It’s a public inventory of prior thoughts and work. Of all the channels mentioned thus far, it is definitely the hardest to build and maintain but like the humble index fund, has the biggest payoffs over longer periods of time.</p><p>In 2019, I published eight AWS-related posts on my blog. <a href="https://kevinslin.com/aws/lambda_cold_start_idle/">Benchmarking Lambda’s Idle Timeout Before A Cold Start</a>, <a href="https://kevinslin.com/aws/tale_of_two_buckets/">A Tale of Two Buckets: Investigating Multi-Account IAM Issues in S3 and CloudFront</a>, and <a href="https://kevinslin.com/aws/cdk_all_the_things/">CDK All The Things: A Whirlwind Tour</a> were some of my more popular posts in 2019 and correspond to the themes I like to write about (serverless, security, and CDK).</p><p>I have a love/hate relationship with writing — like running marathons, it’s always something I’m glad I did in retrospect even when the process itself can be agonizing. While AWS lends itself to an endless amount of things to write about, translating my thoughts into words is a slog that takes me eight hours on average from beginning to end. Time is something I’m especially cognizant of since every minute spent writing is at the opportunity cost of paying work. Thus, I don’t publish frequently and only when I feel I have something novel to say.</p><p>While there’s no guarantee of any immediate “payoff” after publishing a piece, writing plants the seeds for future opportunities. Some of my biggest clients have come from things I published. This includes a consulting gig with my former employer — AWS.</p><p>And writing doesn’t always have to be an eight-hour slog. In November, I experimented with short-form publication in the form of once-a-day tweets.</p><blockquote><em>in celebration of the 30 days leading up to re:invent, i’m going to be doing an aws tip a day, advent calendar style. tips will cover security, cost, scaling, availability, </em><a href="https://twitter.com/hashtag/awscdk?src=hash&amp;ref_src=twsrc%5Etfw"><em>#awscdk</em></a><em>, and horrible nasty soul sucking edge cases everyone should watch out for</em><a href="https://twitter.com/hashtag/AWS?src=hash&amp;ref_src=twsrc%5Etfw"><em>#AWS</em></a></blockquote><blockquote><em>- Kevin S Lin (@kevins8) </em><a href="https://twitter.com/kevins8/status/1190337312527249408?ref_src=twsrc%5Etfw"><em>November 1, 2019</em></a></blockquote><p>The tweets were received much better than I anticipated and were fun to write. I will probably do more of these in 2020.</p><h3>The best channel</h3><p>At the end of the day, just like with specialization, there wasn’t one single channel that I focused on. I tried everything and they all worked to varying degrees.</p><p>Networking and blogging took the most time and had the least certainty but also had much greater upsides when they eventually did come through. Going through agencies gave the most immediate results but resulted in less pay and dependence on a platform.</p><p>Today, all my leads are inbound — either through a referral or from someone who has read something I’ve published. For 2020, the plan is to continue writing about things that interest me and plant more seeds.</p><h3>Growth and Introspection</h3><p>By late July, I found that the consulting business had been way more successful than I anticipated. I filled my hours, was making up the gap in the lost Amazon salary, and was actively turning down interesting jobs due to time constraints.</p><p>At this time, I was thinking about scaling up and interviewing people to expand my consulting group. It was in the middle of the process that I talked to another AWS consultant who had hired people in the past but was now going solo. She mentioned how hiring people was like taking venture money — it would commit you down a path of always needing more work to pay for the talent you had on file.</p><p>After the conversation, I took some time to reflect on whether this was what I wanted. My motivation with consulting was to create a revenue stream to ease the psychological toll of doing something that might take a great deal of money to bootstrap. It was never meant as a full-time job. I took a few weeks to think it over and ultimately decided against scaling up the consulting business.</p><p>I left Amazon because there was something I wanted to build. Consulting was a means and I didn’t want it to become an end. And because of that, I started weaning down my regular consulting to twenty hours a week so that I could spend time building the thing I left Amazon to build.</p><h3>Baby Steps</h3><p>But before I could build the thing, I built an intermediary thing. I still wasn’t quite sure how to build or monetize what I wanted to build and wanted an early win by shipping a service with more immediate returns.</p><p>And so I took a two-month detour to built <a href="https://backuptable.com/">Backuptable</a>, a SaSS service that does backups of Airtable.</p><p>I mentioned earlier in this article that I use Airtable extensively both personally and professionally. It has no native backup solution, despite that being one of the most requested features in <a href="https://community.airtable.com/t/offline-local-backup/754">user forums</a>. My policy for startups (and SaSS in general) is to have backups of all my data so I had already built a solution for myself.</p><p>It took me a little over a month to finish building the SaSS wrapper around my solution. I launched it on <a href="https://www.producthunt.com/posts/backuptable">product hunt</a> with little fanfare and was pleasantly surprised to find positive feedback and paying customers from the first week. I then spent the next month stabilizing the platform so that it more or less runs without needing any further attention from me.</p><p>After launching, I got a lot of requests for additional features from customers that were willing to pay more for said features, and I was torn between implementing new features versus keeping the project stable. I ultimately decided to forego any further work on the platform outside of bug fixes — Backuptable, like consulting, was a means to an end and I didn’t want to mix up the two (again). And now with a “successful” service release, I would finally start working on the thing I left Amazon to build.</p><h3>Alphacortex</h3><p>Starting in late September 2019, I began working on a service to solve a problem that has been on my mind for much of the last decade. This problem is best described by Vannavear Bush, an early visionary in information science.</p><blockquote><em>“We are overwhelmed with information and we don’t have the tools to properly index and filter through it. [The development of these tools, which] will give society access to and command over the inherited knowledge of the ages [should] be the first objective of our scientist.”</em></blockquote><blockquote><em>- Vannavear Bush</em></blockquote><p>The quote is from an essay Bush published in <strong>1945</strong> and it is no less true today. While we’ve made drastic increases in the amount of information we can put into systems and knowledge bases, getting that information back out remains an unsolved problem.</p><p>All knowledge bases today (e.g. Evernote, Confluence, Notion, etc.) of any sufficient scale ultimately rely on search as the primary interface to “index and filter” information. The problem is that search relies on techniques like keyword frequency and more often than not either returns too many results or none at all. It also relies on a human to scan pages of results. This problem gets worse the more data you have, and makes entering new information like investing in penny stock where the chances of getting back what you put in are quite slim.</p><p>I needed a tool that would ensure anything I indexed I could find again, even if it was several years after the fact. I needed something that could return results instantly without searching or scanning. I needed not just the information I was looking for but also the context around it. I needed something that would work with the 10k+ plaintext markdown notes that I already had.</p><p>Based on these needs, I created <a href="https://alphacortex.io/">Alphacortex</a> — a tool that let me instantly reference all the information I cared about.</p><p>Alphacortex can be best described as a taxonomy engine — it allows users to create taxonomies for the information that they care about and helps index and retrieve information via the given taxonomy. It requires much more upfront work from the user’s side to craft and manage their taxonomy, but the payoff is being able to finally make full use of one’s knowledge base.</p><p>Alphacortex is currently in limited early access for customers that have text-based knowledge bases stored in source control (e.g. Github, Bitbucket, Gitlab, etc.). If you are interested in early access for yourself or your company or want to be notified when we become generally available, please sign up <a href="https://kevinlin147106.typeform.com/to/wQU2Cw">here</a>. Otherwise, if you have additional comments or are simply passionate about organizing information, the best way to reach me is at kevin(at)thence(dot)io.</p><h3>Next</h3><p>I realize that my strategy is a little unorthodox — the common startup advice is to pivot to a new project when you don’t find product market fit with your current one. My pattern this year has been pivoting away from profitable businesses to focus on a project whose fit is unproven. Business wise, it makes no sense. I can only explain it as a deep yearning I feel for something like this to exist in the world and an undeniable impulse to make it so.</p><p>Looking ahead at 2020, I’m looking to double down on my niche(s). I will continue to consult but with a hard cap on my weekly hours. Backuptable will continue to exist and backup tables but otherwise remain as it is. Most of my focus will be spent working on Alphacortex and promoting a search-less paradigm for finding information. There will be a public release of Alphacortex early February with specific AWS-related integrations, and I will write more about that soon.</p><p>Looking back, I’ve worked harder and longer in 2019 than I’ve ever done in my life. While the scale of the systems I work on is smaller than what I did at Amazon, the stakes (for me) feel much bigger. Everything I do directly affects my bottom line and every action I take is ultimately because of a decision I’ve made and am responsible for. This direct ownership of my work has been extremely satisfying and stressful at the same time. 2019 was a rollercoaster of exquisite highs and crushing lows, the details of which I will leave to a future post. Ultimately, I don’t know where the startup path will lead but I’m determined to follow it wherever it goes. It’s about the journey, and this one is just beginning.</p><p><em>Originally published at </em><a href="https://kevinslin.com/aws/everything_i_learned_from_aws_consulting/"><em>https://kevinslin.com</em></a><em> on January 6, 2020.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=87ac2c11e404" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[The Open CDK Guide]]></title>
            <link>https://kevins8.medium.com/the-open-cdk-guide-decd754080c4?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/decd754080c4</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[aws-cdk]]></category>
            <category><![CDATA[open-source]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Thu, 08 Aug 2019 00:00:00 GMT</pubDate>
            <atom:updated>2019-08-08T17:36:37.593Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/630/0*SazDi9vOpNsiGJW-.jpg" /></figure><p>Over the past year, I’ve been following the development of the <a href="https://github.com/aws/aws-cdk">AWS CloudDevelopment Kit</a> (CDK) — a framework built on top of CloudFormation that makes it delightful for users to manage AWS <a href="https://en.wikipedia.org/wiki/Infrastructure_as_code">Infrastructure as Code</a> (IaC).</p><p>This has been my favorite release of AWS in 2019 in a year of many exciting releases — <a href="https://aws.amazon.com/about-aws/whats-new/2019/03/service-control-policies-enable-fine-grained-permission-controls/">SCP Conditionals</a>, <a href="https://aws.amazon.com/blogs/aws/aws-security-hub-now-generally-available/">Security Hub</a>, <a href="https://aws.amazon.com/about-aws/whats-new/2019/06/aws-control-tower-is-now-generally-available/">Control Tower</a>, and <a href="https://aws.amazon.com/about-aws/whats-new/2019/07/introducing-amazon-ec2-resource-optimization-recommendations/">EC2 Resource Optimization Recommendations</a> just to name a few.</p><p>When everything is going right, the CDK will make you feel like a devops wizard. That being said, the cloud is complicated, CloudFormation coverage of AWS is incomplete, and the CDK itself (and IaC in general) is still a young framework with little in the way of established best practices. You can see my past article <a href="https://kevinslin.com/aws/cdk_all_the_things/">here</a> for a more in depth dive into the CDK.</p><p>This is why, after having many repeated discussions about aforementioned best practices, I’m happy to announce the <a href="https://github.com/kevinslin/open-cdk">Open CDK Guide</a>. This guide is a collections of learnings and best practices around all things CDK. t is meant to be a living document, updated on an ongoing basis by the community as the CDK and practices around it mature.</p><p>Feedback and contributions welcome :)</p><p><em>Originally published at </em><a href="https://kevinslin.com/aws/open_cdk_guide/"><em>https://kevinslin.com</em></a><em> on August 8, 2019.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=decd754080c4" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[No Reservations: A Definite Guide to EC2 Reserved Instances]]></title>
            <link>https://kevins8.medium.com/no-reservations-a-definite-guide-to-ec2-reserved-instances-6494673c7ca?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/6494673c7ca</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[ec2-reserved-instances]]></category>
            <category><![CDATA[billing]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Mon, 11 Mar 2019 00:00:00 GMT</pubDate>
            <atom:updated>2019-03-11T19:13:30.933Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/630/0*7NlvX2PlUwghqYnL.jpeg" /></figure><p>EC2 Reserved Instances (RIs) provide steep discounts (up to 75%) to the hourly cost of running an EC2 instance in exchange for an upfront commitment to using a particular instance configuration for either a 1 year or 3 year term. In addition to the billing discount, certain RIs also offer capacity reservations which means EC2 will set aside capacity for your indicated instance configuration. Best of all, RI discounts are automatically applied to existing instances which means you can get cost savings without having to make changes to your infrastructure.</p><p>For most companies of any size, compute, and specifically EC2, will often be the largest contributor to the annual bill (followed by storage, followed by <a href="https://www.reddit.com/r/aws/comments/7obna5/10_tb_bill_for_nat_traffic_with_just_a_few_ec2s/">not using VPC endpoints</a>).</p><p>EC2 also happens to be the area where companies can reap the biggest savings. Though RI purchases are the “easiest” way to realize said savings, most clients I work with underutilize RIs because of perceived complexity and lock in — complexity because understanding RI purchases can feel like getting a college degree and lock in because of the upfront commitment.</p><p>While there is no denying the complexity, the degree of lock in has become much better now that RIs have flexibility for instance size, AZ, and AWS accounts. With the addition of convertible RIs (RIs that you can exchange for other RIs) and the RI marketplace (a place where you can sell the remaining term on your RIs), you now have full control of how committed you want to be while using RIs. Because of this, anyone that runs persistent EC2 based workloads will benefit from purchasing RIs of some sort. The only question is how to choose from what’s out there.</p><p>This article attempts to answer this age old question. We will go over everything you never wanted to know about RIs, including what each of the different purchasing options actually mean, all the different ways a reservation can get applied, and specific strategies best suited for each particular RI offering.</p><p>If you want to skip ahead to the conclusion, you can do so by jumping to the <a href="https://kevinslin.com/aws/no_reservations/#takeaways">takeaways</a>. Otherwise, read on.</p><h3>RIs = Billing</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/630/0*XSRWGU75ojJFWtNh.jpeg" /></figure><p>The first thing to understand about RIs is that despite the name, they aren’t actual instances (well, except for scheduled instances but like 99% of AWS customers, we’re going to pretend they don’t exist for now). Instead, RIs are a billing concept. When you purchase an RI, AWS will automatically apply a discount to your EC2 bill for an instance that matches the configuration of your RI.</p><p>For example, say you are running two t3.large instances in production. You purchase one standard 3 year upfront RI for a single t3.large. AWS will automatically apply the new discounted RI price to one t3.large. The remaining t3.large will continue to be billed at the on demand price.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/620/1*tzWArJWcYAuDpmT6jZ2Guw.jpeg" /></figure><h3>RI Options</h3><p>When purchasing RIs, there are many options to select upfront:</p><ul><li>payment options (no upfront, partial upfront, all upfront)</li><li>term (1 year or 3 year)</li><li>RI attributes (platform, tenancy, instance size, instance family, etc)</li><li>scope (regional or zonal)</li><li>offering class (standard, convertible, scheduled)</li></ul><p>Note that some options like “scope” are not even selectable from the console when first purchasing RIs.</p><h3>Payment Options &amp; Term Length</h3><p>When purchasing RIs, you can select between three payment options:</p><ul><li>no upfront: pay nothing upfront but a fixed monthly fee in addition to the discounted on demand fee</li><li>partial upfront: pay a little upfront and a cheaper fixed monthly fee in addition to the discounted on demand fee</li><li>all upfront: pay a lot upfront and no fixed monthly fee in addition to the discounted on demand fee</li></ul><p>In addition to upfront payment, you must specify a term length at the time of purchase of either one or three years.</p><p>The discount you get varies by payment option and term length and is proportional to your upfront payment and the length of your term.</p><p>For example, lets say you wanted to buy a standard RI for a c5.xlarge in PDX (for all subsequent examples, assume PDX as the implicit region). The following is a chart of expected savings for different payment/terms.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/653/1*Nax9pfZ1WmNG1-ynNe9-Jw.jpeg" /></figure><p>*effective hourly normalizes by upfront payment and monthly payment</p><p>By using 3y full upfront standard RIs, you can save as much as 63.5% off your AWS bill. General rule of thumb is the bigger your commitment, the more your savings.</p><h3>Instance Attributes</h3><p>RIs have a lot of attributes to choose from. Here are the ones you will need to specify at the time of purchase. Note that unless you are buying Convertible RIs, these attributes (excluding instance size) are fixed and cannot be changed after purchase.</p><ul><li>Platform: eg. Linux, RHEL, Windows</li></ul><p>Linux is the most flexible (required for instance size flexibility) and most cost effective, windows is most expensive and restrictive</p><ul><li>Tenancy: Default vs Dedicated</li></ul><p>Default tenancy is shared (depending on your instance size, other customers might be running instances on the same hardware). Dedicated tenancy involves reserving dedicated hardware for only your instances. More expensive. Completely separate on demand and reserved instance pricing</p><ul><li>Instance Family: eg. t2 vs t3</li></ul><p>When you buy an RI, you are locked in to the instance family that you select. You can avoid this by getting Convertible RIs or by selling your RIs in the RI marketplace (both topics addressed later)</p><ul><li>Instance Size: eg. c5.large vs c5.xlarge</li></ul><p>Instance size flexibility will allow RIs to be applied to running instances that are of the same family, even if they are of a different instance size. Note that this only applies to Linux Standard RIs</p><h3>Scope</h3><p>RIs can be either regional or zonal in scope. When purchasing RIs through the console, the scope is set to regional by default. Regional scoped RIs mean that the billing discount will reply regardless of the AZ that the instance is launched in. Zonal scoped RIs means that you will have to specify a particular AZ with your RI. The RI discount will only go into effect if the instance is launched in the same AZ. To makeup for the restriction, Zonal RIs give you a capacity reservation. This means EC2 will reserve capacity on your behalf to guarantee that an instance that matches your RI attributes will be available in that particular AZ. This is not provided by standard RIs, which only give the billing discount but don’t make any guarantees about whether a particular instance configuration is available.</p><p>Note that you can change the scope of an RI at any time, so you can always switch from a zonal RI to a Regional RI if you require greater flexibility.</p><h3>Offering Class</h3><p>When purchasing RIs, there are three primary offerings that you can purchase from:</p><ul><li>standard: most restrictive RI, most cost benefit</li><li>convertible: more relaxed, less cost benefit</li><li>scheduled: most esoteric, useful for specific workloads</li></ul><p>We will discuss each in depth.</p><h3>Standard RI</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/630/0*zQrqr59Yr_5leWtW.jpeg" /></figure><p>Standard RIs are the most restrictive RI category but offer the biggest savings. When you buy a standard RI of a particular instance family (eg. t3.*), you are locked into that instance family and the instance attributes specified at time of purchase. If AWS releases t4’s or your workload shifts and you find that you need c5’s, you have to purchase new RIs.</p><h3>Convertible RI</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/630/0*LYPsxWlJrRDp1-3B.jpeg" /></figure><p>Convertible RI address the problem of RI lockin by allowing you to trade in your existing Convertible RI for another one of equal or greater value. If the value of the new reservation has a greater upfront fee, you pay a one time true-up charge to cover the difference.</p><p>For example, say you bought a 1year all upfront c5.xlarge Convertible RI for $1007 upfront. AWS just came out with the c6 family and you are currently 6 months into your reservation. You want to switch into a 1year all upfront c6.2xlarge RI for the remainder of the year. The upfront cost of c6.2xlarge is $2000. Because you are halfway into your term, you have $503.50 of prorated value left in your reservation. Because you are getting 6 months of the new reservation, the upfront cost would be $1000. The true-up charge in this case is the value of the new reservation minus the prorated value of your current reservation ($1000 — $503.50 = $496.50).</p><p>When you trade in Convertible RIs, you are also allowed to change other attributes of the reservation such as platform and tenancy.</p><p>Convertible RIs cannot be sold in the RI marketplace. You are however, able to subdivide and merge existing reservations. For example, two t2.micro reservations can be converted into a single m4.xlarge reservation. Conversely, one m4.xlarge reservation can be split into two m4.large reservations. You can divide and combine your reservations however you like as long as the resulting reservation(s) has an equal or greater value than what you started off with.</p><p>In exchange for the flexibility, savings on Convertible RIs are (around 9%) less than what you would get from an equivalent standard reservation. Below is a breakdown of savings for c5.xlarge when purchasing a standard vs convertible reservation</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/645/1*pTRJ9XJBKFKGYI4jQqmF2g.jpeg" /></figure><h3>Scheduled RIs</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/630/0*QmOHtaUGp5_uG2UE.jpeg" /></figure><p>Scheduled RIs are the least commonly used reservations. They let you reserve capacity for a specified time interval on a daily, weekly or monthly schedule. Reservations also come with a capacity reservation. Scheduled RIs are only available in limited regions (N. Virginia, Oregon and Ireland) and instance types (C3, C4, M4, and R3). Unlike regular RIs, scheduled RIs are special instance types that EC2 set asides. That means you can only purchase scheduled RIs of a certain schedule if EC2 happens to have it available. After purchase, the discounts <strong>do not</strong> apply to existing instances but rather, only to the purchased scheduled instances which will need to be manually started during the scheduled window. EC2 will also automatically terminate these instances 3 minutes before your schedule expires.</p><p>Scheduled RIs can not be modified and can not be sold. They are only available for 1 year terms. Cost savings for scheduled RIs are 5–10% and depend on whether you schedule falls within peak or off-peak pricing (typically weekday vs weekend pricing). Scheduled RIs require a minimum utilization of at least 1200h per year.</p><p>Its really hard to make a case for when scheduled RIs would be a better fit when you already have spot instances for asynchronous batch jobs and capacity reservations to guarantee capacity for given periods (this is even called out in the official <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-scheduled-instances.html?shortFooter=true">docs</a>). Some use cases that are mentioned at the <a href="https://aws.amazon.com/blogs/aws/new-scheduled-reserved-instances/">launch of scheduled RIs </a>include a bank running risk calculations every weekday and a phone company doing bill calculations at the start of every month.</p><p>As it stands today, it wouldn’t surprise me if this class of RIs takes the same journey as <a href="https://lastweekinaws.com/blog/s3-reduced-redundancy-storage-is-dead.html">reduced redundancy S3 storage</a>.</p><h3>RI Flexibility</h3><p>RIs, like everything in AWS, have gained many new features since they were first announced. There are now a multitude of ways in which RI discounts can be applied.</p><h3>Instance Size Flexibility</h3><p>Back in the day, an RI purchase was tied to a particular instance size and that was it. If you wanted to change sizes, tough luck. This changed in 2017 when EC2 announced <a href="https://aws.amazon.com/blogs/aws/new-instance-size-flexibility-for-ec2-reserved-instances/">Instance Size Flexibility</a>, which allowed you to apply a RI configured for one instance size to another instance of a different size as long as they were in the same instance family. Note that this only applies to Regional RIs for linux instances running with the default tenancy.</p><p>All instances are sized using the following normalization factors.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/345/1*llQ8C3mNXYa4uJf2-G0fOA.jpeg" /></figure><p>With instance size flexibility, you could buy a reservation for one c5.xlarge and apply it to 8 c5.small instances instead. Vice versa, you could apply 2 c5.medium RIs to one 1 c5.large instance.</p><h3>AZ Flexibility</h3><p>When buying a regional scoped RI, the discount will apply regardless of the AZ that the instance is running in. This is in contrast to zonally scoped RIs which can only apply the discount if the instance is running in the same AZ.</p><h3>Account Flexibility</h3><p>RI can be shared across linked accounts. Consolidated billing must be enabled for this to take place. This means that an organization can make all their RI purchases in one central account and any team in the organization can now take advantage of that RI purchase. One caveat is that capacity reservations that come from zonally scoped RIs do not flow down to linked accounts.</p><h3>But wait, there’s more…</h3><p>Some other properties of RIs that didn’t fit in any of the above sections.</p><h3>Marketplace</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/630/0*wFj_9l-wN1j_pZ7d.jpeg" /></figure><p>While purchasing a standard RI locks you into a particular instance family and term, all is not lost if you decide to change. This is because you can still sell the remainder of your reservation in the RI marketplace. You must have owned your RI for longer than 30 days and register as a seller in the reserved instance marketplace before selling.</p><p>To sell, list the RIs that you want gone as well as the one time fee that you want to charge. You can have EC2 automatically decrement this one time fee by a fixed amount over time.</p><p>What gets sold is the remaining term on your RI, rounded down to the nearest month. You are free to continue using your RI capacity until it is sold. Note that AWS does charge a 12% service fee of your upfront price when a sale goes through.</p><p>My experience with the RI marketplace is that you shouldn’t expect to make much of a profit or score much cost savings when buying or selling. Use it to offload excess RIs for a minimal cost or to buy RIs at shorter term lengths.</p><h3>Volume Discounts</h3><p>RIs have tiered pricing meaning that it gets cheaper the more you spend. These discounts start taking into effect once you hold more than $500,000 in RIs and result in a 5% discount on both upfront and hourly RI payments at the lowest tier. They go up to 10% once you surpass $4 million in RI payments. If you hit more than $10 million, you get to contact AWS and negotiate a super secret large customer discount. Note that Convertible RIs do not qualify for the discount though the money you spend on convertible instances count for calculating whether you’ve hit a particular volume tier.</p><h3>Capacity Reservation</h3><p>When you create a Standard or Convertible RI with zonal scope, you automatically create a capacity reservation as well — that is to say EC2 will set aside that capacity and make sure it’s available for your use. The limitation is that you are restricted in applying your RI discount to a particular AZ and that linked accounts do not get the benefit of the capacity reservation.</p><p>One way to get around both issues is to directly purchase <a href="https://docs.aws.amazon.com/AWSEC2/latest/UserGuide/ec2-capacity-reservations.html">capacity reservations</a> instead. EC2 Capacity reservations can be bought separately from RIs. You choose an AZ, instance type, tenancy and desired schedule and EC2 will make sure that capacity is available during that time. Payment works as follows: you pay the normal hourly price on the instance even if it is not running but don’t pay anything extra if the instance is running.</p><p>For example, if you create a capacity reservation for 10 c5.xlarge instances and only run 5 c5.xlarge instances, you will be charged the hourly rate for 10 running instances.</p><p>Capacity reservations work well with Regional RIs — customers can purchase RIs to get the discount on any instance regardless of AZ and still secure capacity using capacity reservations. RI discounts also apply to unused ec2 capacity reservations, which means in the above example, had you bought 10 Regional RIs for c5.xlarge, you would be charged the RI rate for 10 c5.xlarge.</p><p>The best part about capacity reservations is that they require no upfront commitment and can be created and cancelled as needed.</p><h3>Limitations</h3><p>This is not an exhaustive list of limitations but a couple that haven’t been mentioned previously. RIs do not apply for dedicated instances. You will need to purchase standalone <a href="https://aws.amazon.com/ec2/purchasing-options/dedicated-instances/">dedicated instance reservations</a> instead. Each AWS account is subject to 20 RI purchases per region per scope (so in total, a new account can make 20 Regional RI purchases and 20 zonal RI purchases) and must contact AWS to raise that limit.</p><h3>Takeaways</h3><p>If you made it all the way to the end of this article, congratulations, as you now know more about RIs then 90% of all people using AWS. In summary, RIs are a fantastic means to save money on EC2 and are flexible enough now that pretty much anyone using an EC2 instance would benefit from having an RI. Some things to remember:</p><ul><li>Standard RI are the most restrictive but yield the greatest savings</li><li>Convertible RIs are the most flexible but yield a lower discount</li><li>Scheduled RIs are very industry specific and its likely that it doesn’t apply to you — consider using spot and capacity reservations instead</li><li>RIs can also reserve capacity but at the cost of AZ flexibility — to keep both, consider purchasing capacity reservations with Regional RIs</li><li>if you have excess Standard non-dedicated Linux RIs, they can now be sold in the RI marketplace</li><li>if you are part of an organization, use consolidated billing and a central account to buy RIs for all linked accounts</li></ul><p>While we covered EC2 RIs, it’s worth keeping in mind that AWS has RIs for many different services, including:</p><ul><li>RDS: reserve specific instance types</li><li>DynamoDB: reserve Write and Read capacity</li><li>Cloudfront: commit to min monthly usage level (based on volume of data transfer)</li><li>ElasticCache: reserve node type and pay upfront and hourly fees</li><li>Elastic Map Reduce: reserve specific instance types</li><li>Redshift: reserve specific instance types</li></ul><p>Know that the way AWS handles reserved capacity is pretty similar across services — the bigger the commitment, the more the savings. Also know that like with prescription drugs, restrictions may apply and you should read the fine print of each reservation offering to understand what you are signing up for.</p><p>If you’d rather not deal with the nits and grits of RI reservations, considering reserving a consultation at <a href="https://cloud.thence.io/">cloud.thence</a> instead. We deal with all the hassle of RI reservations on your behalf as well as filter through hundreds of other cost saving optimizations and only surface savings that will make a difference to your business. Best of all, we never charge more than what you save.</p><p>Reserve an <a href="https://calendly.com/thence/meet">initial consultation</a>, with no commitment or upfront fees. This offer is available in all regions for all schedules and applies to organizations of all sizes.</p><p><em>Originally published at </em><a href="https://kevinslin.com/aws/no_reservations/"><em>kevinslin.com</em></a><em> on March 11, 2019.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=6494673c7ca" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Benchmarking Lambda’s Idle Timeout Before A Cold Start]]></title>
            <link>https://kevins8.medium.com/benchmarking-lambdas-idle-timeout-before-a-cold-start-cbfd7ef97c18?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/cbfd7ef97c18</guid>
            <category><![CDATA[cold-start]]></category>
            <category><![CDATA[aws-lambda]]></category>
            <category><![CDATA[performance]]></category>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[serverless]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Fri, 01 Feb 2019 00:00:00 GMT</pubDate>
            <atom:updated>2019-02-05T19:11:01.060Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/821/0*FpsRo8U4rRp7VPGH.jpg" /></figure><p>In the not so distant past, businesses that wanted to build internet services needed to provision their own hardware. That meant buying a rack and a bunch of servers and stashing them in a cool part of the building and hope that no one would trip over the wires.</p><p>As businesses grew, so did their IT infrastructure which meant that they sometimes had to expand into data centers to handle all that new traffic. Besides costing an obscene amount of money, this also involved much complexity, especially as traffic spiked, machines failed and disks died.</p><p>Then came the advent of cloud computing which promised to free businesses from all that complexity for a less obscene amount of money. Instead of ordering hardware ahead of time, a server of your choice was just an API call away. This meant that companies could pay only for the traffic they have today but also have the capacity to handle spikes and growth.</p><p>Cloud computing drastically slashed the capital and hardware necessary for businesses to scale up their IT. But under the hood, it was still running workloads on VMs in the same way that people have been doing since dot com. But all this changed in a big way in November of 2014.</p><h3>AWS Lambda</h3><p>AWS introduced <a href="https://aws.amazon.com/lambda/">Lambda</a> during re:invent of 2014 and presented it as a new paradigm for thinking about code. Instead of worrying about servers, upload the application code and lambda would take care of the rest.</p><p>Lambda promised instant deployments and <em>infinite</em> scale with the benefit of costing nothing when it wasn’t invoked. But as with any technology, there are tradeoffs for having nice things and with Lambda, one of those tradeoffs is cold starts.</p><h3>Cold Starts</h3><p>Lambda executes code in <a href="https://www.docker.com/resources/what-container">containers</a>. During the first invocation of your function, Lambda will instantiate the container containing your application code. This initial initialization cost is known as a <strong>cold start</strong>.</p><p>The penalty of a cold start varies by language, framework, memory allocation and whether you’re running your Lambda inside a VPC (just don’t). Typically, it can be anywhere from ~200ms (python) to over 5s (C#). For a more detailed analysis on the breakdown, you can read the following <a href="https://read.acloud.guru/does-coding-language-memory-or-package-size-affect-cold-starts-of-aws-lambda-a15e26d12c76">post</a>.</p><p>Subsequent calls to Lambda will reuse the initial container. Lambda will keep the container <strong>hot</strong> as long as it continues to be invoked within an <em>idle timeout</em> interval. What that <em>idle timeout</em> is is not published by AWS and the subject of this post.</p><p>Before I begin, I have to mention that I’m not the first person to write about this topic. I personally like the <a href="https://read.acloud.guru/how-long-does-aws-lambda-keep-your-idle-functions-around-before-a-cold-start-bf715d3b810">analysis</a> done by AWS Hero Yan Cui. By executing Lambdas of various memory sizes with monotonically increasing idle wait times between each invocation, Cui was able to derive an upper bound for idle timeout of various Lambda sizes. An image of his results is posted below.</p><figure><img alt="Lambda cold start timeouts" src="https://cdn-images-1.medium.com/proxy/1*NjZamQ0Utn2nUudiBm12lg.png" /><figcaption>Cui’s Idle Timeout Numbers</figcaption></figure><p>Based on the above numbers, it seemed that Lambda containers were able to idle for as much as an hour before being reaped. Whether Lambda’s would actually idle for that long seemed to depend on Lambda size and VM utilization.</p><p>Cui published his post in 2017 and Lambda has made extensive changes to the platform in that time, including increasing the memory limit of Lambda to 3GB. I was curious to see how <em>idle timeout</em> changed in the interim and run the test for the bigger Lambda memory sizes.</p><p>For the test, I re-used Yan Cui’s <a href="https://github.com/theburningmonk/lambda-when-will-i-coldstart">code</a> and setup — this involves creating a series of lambdas using the <a href="https://serverless.com/">serverless framework</a> and orchestrating the tests using <a href="https://aws.amazon.com/step-functions/">step functions</a>. We start off with an idle timeout hard coded at 10min and use step functions to continuously invoke the lambda function to see if we get a cold start. If not, we increase the timeout, wait and try again. We repeat this process until we get 10 cold starts and use the maximum timeout to determine an upper bound on the idle timeout.</p><p>The following test was conducted in us-west-2 at 2019–01–29</p><h3>Results (us-west-2)</h3><p>And now for the results. Drum roll… 🥁🥁🥁</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/856/0*aDDxoz50kGBTXWIe.png" /></figure><p>So this turned out not be the most exciting graph in the world and also different from what I was expecting. 26min was not just the max idle timeout but the idle timeout we got in every execution of Lambda across all memory sizes.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/436/0*PQM3pD-meRRJ-Ofn.jpg" /></figure><p>To read the above table, know that the first column is the Lambda memory size and the other columns show the statistical properties of the idle timeout in minutes.</p><p>The idle timeout of 26min is actually half the max idle timeout from when Cui did his <a href="https://read.acloud.guru/how-long-does-aws-lambda-keep-your-idle-functions-around-before-a-cold-start-bf715d3b810">benchmark</a> in 2017. This is also 5x more than what tools like the <a href="https://github.com/FidelLimited/serverless-plugin-warmup">serverless-plugin-warmup</a> will ping your lambda at (default is set to 5min). Something to note is that these results only show the <em>upper bound</em> of the idle timeout and it could very well be the case that the lambdas did timeout after 5minutes though the consistency of the results would suggest otherwise.</p><h3>But Wait…</h3><p>At this point, I was ready to make dinner and call it a day but there was one more thing I wanted to do before wrapping up the experiment. Something to always consider when doing a benchmark on AWS is that it is always region dependent. Each AWS region is designed to be <a href="https://docs.aws.amazon.com/aws-technical-content/latest/aws-overview/global-infrastructure.html">completely isolated</a> from other Amazon regions — this means physical proximity, hardware, power supply, etc. The instance type availability differs from region to region and so can the code that is deployed within each region. us-east-1 is AWS’s oldest region and has the widest possible skew in terms of instance availability and workloads. I wanted to find out if the observed Lambda idle timeouts were also consistent here so I repeated the above experiment in us-east-1.</p><p>The following test was conducted in us-east-1 at 2019–02–01</p><h3>Results (us-east-1)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/856/0*ui6otc_7wNXoA8Li.png" /></figure><p>So this is a more interesting graph. Note that there is a general trend of the idle timeout decreasing with higher memory allocations.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/519/0*wz7tztGfQSAFtZUq.jpg" /></figure><p>Some immediate observations:</p><ul><li>2624MB lambda shows the same behavior as us-west-2 lambda, having a consistent idle timeout of 26min</li><li>all other lambdas have higher idle timeouts, all the way up to 65min</li><li>initial idle timeout still starts at 26min with two exceptions, 31min for 256MB and 22min for 1856MB</li><li>1024MB lambda is only Lambda under 1536MB to have under 60min of idle timeout</li></ul><p>Now that we know what the max idle timeout is, what about idle timeouts less than that? That is to say, before we hit the upper bound in idle timeout, what were the other idle timeout’s that Lambda hit along the way?</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*I0UBBlGksr-XzdGX.png" /></figure><p>There’s a lot going on here but some observations:</p><ul><li>there is much less variance among bigger Lambdas — after 1792MB, most of the idling is done at the max idle timeout (which ranges from 26–54min)</li><li>smaller Lambdas (under 1792MB) have a much higher variance when it comes to idle timeout lengths but tend to idle at high timeouts (~1h)</li></ul><h3>Takeaways</h3><p>So takeaways from this experiment?</p><ul><li>Lambdas in us-west-2 have a consistent idle timeout of 26min for all lambda sizes</li><li>Lambdas in us-east-1 have varying idle timeouts, ranging from 22min — 65min</li><li>Lambdas in us-east-1 with smaller memory sizes (under 1536MB) have the highest upper idle timeouts</li><li>idle timeout is different between different AWS regions and you should not assume that benchmarks done in one region stay consistent across regions</li><li>any number that is not officially announced by AWS is subject to change</li></ul><p>Finally,I would be remiss at this point not to add the disclaimer that these benchmarks were done to satisfy my own curiosity and you shouldn’t base your production worloads off these results.</p><p>That being said, if you’re curious to run through any of the above scenarios, you can find the source code to run this experiment on <a href="https://github.com/kevinslin/lambda-when-will-i-coldstart">github</a></p><p>Some ideas for further tests:</p><ul><li>Idle timeout of Lambda using Lambda Layers</li><li>Idle timeout of Lambda run at increasing concurrencies</li><li>Idle timeout of Lambda in VPC</li><li>Idle timeout of Lambda that make use of their scratch space</li><li>Idle timeout of Lambda run during region peak hours (looking at you <a href="https://qz.com/india/989659/netflix-nflx-peak-viewing-hours-are-very-different-in-india-and-argentina-compared-to-the-us-and-europe/">Netflix</a>)</li></ul><p>Hope you found this article useful and may the Lambda be (warm) with you!</p><p><em>Originally published at </em><a href="https://kevinslin.com/aws/lambda_cold_start_idle/"><em>kevinslin.com</em></a><em> on February 1, 2019.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=cbfd7ef97c18" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Giving Third Parties Limited Access to your AWS Account]]></title>
            <link>https://kevins8.medium.com/giving-third-parties-limited-access-to-your-aws-account-7cc09f14c08b?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/7cc09f14c08b</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[consulting]]></category>
            <category><![CDATA[how-to]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Thu, 17 Jan 2019 22:37:58 GMT</pubDate>
            <atom:updated>2019-01-22T19:05:49.221Z</atom:updated>
            <content:encoded><![CDATA[<p>4 minute read</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*lyDVooCsFTqzqqBd.jpg" /></figure><p>Whenever I’m working with a new client, one of the first things we talk about is access. Most clients have the majority of their business running on top of AWS and don’t feel comfortable (nor would I recommend) that they give a consultant complete access on day one. That being said, said consultant does need minimal access in order to advise, whether this is on security, architecture, cost, or any number of reasons. This is when we turn to IAM.</p><p><a href="https://aws.amazon.com/iam/">IAM</a> (Identity Access Management) is one of the longest running and most comprehensive service in AWS (and arguably the most feature rich IAM service of any cloud provider). With IAM, users can specify precisely the level of access any given entity will have to their AWS resources. You can narrow down permissions to single actions in specific services (eg. Bob can only call s3:GetLifecycleConfiguration on bucket Foo) as well as use wildcards to specify a whole range of permissions (eg. Bob can call s3:List* actions on all buckets starting with Foo*). IAM is an incredibly flexible and powerful way of only providing exactly the permissions that are actually necessary but comes at the cost of being verbose and tricky to get right. AWS is aware of this issue and offers <a href="https://docs.aws.amazon.com/IAM/latest/UserGuide/access_policies_managed-vs-inline.html#aws-managed-policies">managed policies</a> that deal with some common use cases. The advantage of using managed policies is that they are implemented and managed by AWS security engineers and are regularly updated to include the latest services and features.</p><p>Today, we’re going to talk about three of these managed policies which I recommend my clients use when giving third parties access. They are as follows:</p><ul><li>ViewOnlyAccess: This policy grants permissions to view resources and basic metadata across all AWS services.</li><li>great for initial audit since it allows the user to see all aws resources and metadata but not the actual business and customer data</li><li>eg: will allow user to see EC2 instances, RDS instance, S3 buckets and objects (only the names but not the contents, configs), etc</li><li>SecurityAudit: This policy grants access to read security configuration metadata. It is useful for software that audits the configuration of an AWS account.</li><li>great for security assessments — very similar to ViewOnlyAccess but grants additional access to configuration/policy while limiting certain view operations</li><li>comparison: ViewOnlyAccess allow users to perform glacier:List* operations but no glacier:Get* operations whereas SecurityAudit allows glacier:ListVault and limited GET operations like glacier:GetVaultAccessPolicy. Similar trade-offs are made throughout other AWS services</li><li>ReadOnlyAccess: This policy provides read-only access to AWS services and resources.</li><li>great for a deeper audit — useful for troubleshooting issues because users can read data out of aws resources like S3 and Dynamo</li><li>comparison: all the permissions of ViewOnlyAccess with additional permissions to read resource contents as well as the metadata</li><li>note that anyone with this policy can <strong>READ AND DOWNLOAD DATA from S3, Dynamo and your other aws services</strong> — for most cases, ViewOnlyAccess is sufficient</li></ul><p>While the above mentioned security policies are updated to include the latest AWS services, the rate that AWS releases changes means that these even these policies can be out of date. As of this writing, here are some shortcomings I found:</p><ul><li>ViewOnlyAccess:</li><li>missing permissions for GuardDuty, Alexa4Business, Cloud9, Comprehend, etc</li><li>SecurityAudit:</li><li>missing permissions for Inspector, Lex, Lightsail, Polly, Simple Work Flow, WorkDocs, etc</li><li>a lot of the missing permissions here center around high level services like Lex and WorkDocs so that might be why they’re excluded but it’s surprising that Inspector isn’t in here as it is a security assessment service</li><li>ReadOnlyAccess:</li><li>missing permissions for AppMesh, Chime, License Manager, MediaConnect, Quicksight, Resource Access Manager, RoboMaker, SecurityHub, AWSMarketPlace, etc</li><li>most of the missing permissions are with recently launched services (eg. RoboMaker, AppMesh), but the AWSMarketPlace is surprising since ViewOnlyAccess has the aws-marketplace:ViewSubscriptions permission which makes me suspect that this is an oversight</li></ul><p>The takeaway here is that these managed policies are a good starting point to give a third party access limited access to your AWS account. They do miss whitelisting a service here and there but it is much better to whitelist a few services after the fact then realize you’ve given too many permissions and blacklist.</p><p>Now that we’ve gone over a few managed policies, below are instructions on how to apply them to your own AWS Account. Note that the instructions are for applying the ViewOnlyAccess policy but the same steps apply for the other managed policies.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/636/0*HqwN20uQCM1U9DPf.jpg" /></figure><ul><li>Set a name for the user and enable both Programatic and Console Access. Then click to Next: Permissions</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*NalkGF0mrXqhZ9rK.jpg" /></figure><ul><li>Click Attach existing policy directly and look for ViewOnlyAccessPolicy. Select the policy before clicking Next: Tags</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ZDaiMSFgJ8-CvayP.jpg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*C9H1_x_XtkkKOnbU.jpg" /></figure><ul><li>Optionally, add a tag to the project for tracking purposes. Click Next when done.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Gr1nin_VgzfMe6KW.jpg" /></figure><ul><li>Make sure that everything looks right and click Create User</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*ImVgs9rN_AaYJnEr.jpg" /></figure><ul><li>Download the csv and send an email to the person you are granting access to with the IAM login link. Send the csv with the credentials along with the email or separately in a different channel of your choice.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/944/0*f1FGT67jcfEoU8dh.jpg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/640/0*36FoOg1sQSguJT3r.jpg" /></figure><ul><li>After the audit is done, its important to delete the credentials to limit further access (optionally, you can also choose to disable the keys and password but this guide will cover deleting the credential). To do so, go back to the IAM user page <a href="https://console.aws.amazon.com/iam/home#/users">here</a>. Select the user you wish to delete and click Delete User. Click Yes on the ensuing confirmation box.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*PxcX3lIGdXWnFYdi.jpg" /></figure><p>And you’re done. Hope this article was informative and feel free to reach out or comment if you have any questions or feedback for this post.</p><p><strong>Tags: </strong><a href="https://kevinslin.com/tags/#howto">howto</a>, <a href="https://kevinslin.com/tags/#iam">iam</a>, <a href="https://kevinslin.com/tags/#security">security</a></p><p><strong>Categories: </strong><a href="https://kevinslin.com/categories/#aws">aws</a></p><p><strong>Updated:</strong> January 17, 2019</p><p><a href="https://twitter.com/intent/tweet?text=Giving+Third+Parties+Limited+Access+to+your+AWS+Account%20https%3A%2F%2Fkevinslin.com%2Faws%2Faws_account_access_policies%2F">Twitter</a> <a href="https://www.facebook.com/sharer/sharer.php?u=https%3A%2F%2Fkevinslin.com%2Faws%2Faws_account_access_policies%2F">Facebook</a> <a href="https://plus.google.com/share?url=https%3A%2F%2Fkevinslin.com%2Faws%2Faws_account_access_policies%2F">Google+</a> <a href="https://www.linkedin.com/shareArticle?mini=true&amp;url=https%3A%2F%2Fkevinslin.com%2Faws%2Faws_account_access_policies%2F">LinkedIn</a></p><p><em>Originally published at </em><a href="https://kevinslin.com/aws/aws_account_access_policies/"><em>kevinslin.com</em></a><em> on January 17, 2019.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7cc09f14c08b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Creating a Transcription Service in 12h]]></title>
            <link>https://kevins8.medium.com/creating-a-transcription-service-in-12h-c0d9443ca945?source=rss-94907cf170e6------2</link>
            <guid isPermaLink="false">https://medium.com/p/c0d9443ca945</guid>
            <category><![CDATA[aws]]></category>
            <dc:creator><![CDATA[Kevin Lin]]></dc:creator>
            <pubDate>Sun, 25 Nov 2018 06:50:03 GMT</pubDate>
            <atom:updated>2018-11-25T06:50:03.651Z</atom:updated>
            <content:encoded><![CDATA[<p>For Thanksgiving weekend, I decided that instead of get new things, I would take a look at my bucket list and try to take things out instead. One thing in particular that’s been on my mind is making audio transcriptions. I run a <a href="http://folkstories.org/">podcast</a> and recently I’ve been experimenting with generating automatic transcripts for easy archival and search inside the episode functionality. I was struck by the relatively ease this can be done now thanks to cloud services like <a href="https://aws.amazon.com/transcribe/">AWS Transcribe</a> and thought that it didn’t seem too much to build a simple drag-and-drop web interface to allow anyone to upload transcripts.</p><p>They are no shortage of transcription services in the interwebs but they aren’t cheap and all require you to create an account and login. And so the idea for <a href="http://scribe.thence.io/">Scribe</a> was born.</p><p>The impetus to make me do this project was the Product Hunt Maker’s contest that I signed up for a while back. The deadline is November 24 at 11pm PT (as I write this, it is ~1h until this deadline). So I set off to work November 24 at 9AM PT.</p><p>The architecture for scribe consist of the following components:</p><ul><li>frontend: React and antd</li><li>backend: express</li><li>infrastructure: AWS</li><li>financials: Stripe</li></ul><p>Frontend, I decided to limit the scope and create what turned out to be an extended webform. Home page presented a form to upload a media file, another form to collect information and present payment dialogue and a final form to indicate that the users information has been processed.</p><p>Backend is an express app that processed file uploads, payments and kicked off workflows to take care of transcriptions. Originally, the backend was going to be completely serverless (lambda + api gateway) but found out 1.5h from the Product Hunt deadline that API gateway has a payload limit of 10mb which doesn’t work out when customers are uploading wavefiles that easily exceed that limit. Considering options with creating signed s3 urls but decided that would be too risky as I hadn’t had much experience and things always take twice as long when you’re doing them for the first time. Thus, temporarily abandoned the serverless catchphrase and setup traditional server + loadbalancer using ElasticBeanstalk.</p><p>Payments are handled by stripe. I’ve been using them for a bunch of my projects now and never had any problems with their APIs and documentation. I love that every production action can be mirrored inside their Test mode.</p><p>To actually do the transcription, I kick off jobs to AWS Transcribe and have lambdas that periodically poll and check whether the jobs are completed. When they are, I’ll do some post-processing to generate human readable transcripts and send an email to the customer with the transcription documents which will be available via a unique URL for up to 30 days.</p><p>The initial product is pretty bare bones. Over the coming days and weeks, I’ll be working on supporting more inputs (eg. mp4 files, mp3 files, etc) and outputs as well as giving users options to submit custom vocabulary. There are also plans on creating an online transcription editor so users can correct transcriptions before downloading. I’m also interested in creating new sorts of visualizations for transcriptions and display word bubbles and frequency of use charts. Most importantly, I’ll be listening to early user feedback to help guide the design of Scribe. So if this all sounds interesting and you want to play around or simply give feedback, I encourage you to check out <a href="http://scribe.thence.io/">Scribe</a> and tell me what you think :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=c0d9443ca945" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>