<?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[Software Engineering - Medium]]></title>
        <description><![CDATA[Languages, tools, experiences and other things related to programming - Medium]]></description>
        <link>https://medium.com/software-engineering?source=rss----9ef0bc905be6---4</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*tV1FC2A4aj-BIcm2.jpeg</url>
            <title>Software Engineering - Medium</title>
            <link>https://medium.com/software-engineering?source=rss----9ef0bc905be6---4</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Mon, 30 Nov 2026 11:12:29 GMT</lastBuildDate>
        <atom:link href="https://medium.com/feed/software-engineering" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com" rel="hub"/>
        <item>
            <title><![CDATA[IT Consolidation]]></title>
            <link>https://medium.com/software-engineering/it-consolidation-d6cd557b9c7e?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/d6cd557b9c7e</guid>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Sun, 01 Apr 2018 16:11:20 GMT</pubDate>
            <atom:updated>2018-04-01T16:14:38.726Z</atom:updated>
            <content:encoded><![CDATA[<p>I’ve been working on the new edition of my best selling book Full Stack JavaScript. I was updating references, links and names of the services. A lot of libraries are dead and the links are unreachable. A lot of services are dead or being bought by big companies. The list is huge. Compose which was MongoHQ is now part of IBM. StrongLoop is part of IBM. Heroku is part of Salesforce. Parse.com was bought and discontinued. Firebase is part of Google. Joyent is part of Samsung.</p><p>It’s kind of depressing. Take a look at this page. Nodejitsu, which was one of the first Node PaaS solutions, says it joins GoDaddy which is just an hiring of the team. They refer to Modulus which you think is another PaaS, but it’s not. It’s a very poorly-done website for what looks like some consulting company in the trading space. The link to the blog post is 404 Not Found.</p><p>The previous edition of Full Stack JavaScript was published in 2015. In three years, a lot of companies either sold for scraps or closed or both (sold then closed the projects). It’s very refreshing to see this trend in a long span of several years.</p><p>Every market goes through cycles. First there’s an expansion with various offerings and then there’s a retraction with just a few major players dominating. It’s a winner takes all economy. Amazon, Google, Microsoft and IBM are serving major cloud services now. Startups are hard and most of them don’t know how execute. VCs are pushing for startups to spend more to acquire marketshare. The big companies have more leverage and more room for mistakes. They can just buy the best startup in the end. Is it still worth trying to start your tech startup in 2018? Probably not unless it’s something completely new. You can’t drive forward while looking in a rear view mirror.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d6cd557b9c7e" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/it-consolidation-d6cd557b9c7e">IT Consolidation</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[On Managing]]></title>
            <link>https://medium.com/software-engineering/on-managing-aa4b32faa4de?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/aa4b32faa4de</guid>
            <category><![CDATA[leadership]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Wed, 09 Aug 2017 19:59:40 GMT</pubDate>
            <atom:updated>2017-08-09T19:59:39.531Z</atom:updated>
            <content:encoded><![CDATA[<p>The more I work in tech, the more I see the most successful management being at the core about these three separate and often conflicting areas:</p><ul><li>Company: Contributing to your companies bottom line by understanding the business value and long-term strategy</li><li>Customers: Taking care of your costumer by delivering product they want and love</li><li>Culture: Growing your engineers as well as positively impacting engineering culture in the company as a whole</li></ul><p>At the intersection of these areas, there are two often conflicting axis which create a healthy push and pull if used with a right balance:</p><ul><li>Short-term vs long-term, e.g., delivering projects on time vs. doing what will scale better in the future</li><li>Us vs. them, e.g., caring about your team vs. company or the entire engineering population</li></ul><p>A good manager in the information-based working environment will find a way to combine the aforementioned areas and axis to form a win-win situation. It’s not always possible, but I find that it’s possible more often than not when I just push a little bit more and don’t give up early, when I try to come up with just one more creative solution.</p><p>PS: To continue musings, there are two books on the topic worth mentioning. I wrote a short summary on one of them which is called <a href="https://webapplog.com/managing-humans-summary"><em>Managing Humans</em></a>. I really liked that book, but recently I read another book called <a href="http://amzn.to/2vkm3IK">The First-Time Manager</a> which seems to be the source of inspiration for <em>Managing Humans</em>, to put it mildly. I’m not accusing the author of Managing Humans in plagiarism, but I had a strong feeling of deja vu. It felt like Managing Humans borrowed the outline and a lot of ideas and concepts from The First-Time Manager. Interesting…. So go for “original” (The First-Time Manager). It’s not as specific and tailored to software engineers but a useful perspective. Then follow up with <a href="http://amzn.to/2vk9yNm">The 48 Laws of Power</a> for a completely different view. :)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=aa4b32faa4de" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/on-managing-aa4b32faa4de">On Managing</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[One Technique Guaranteed to Improve Your Coding Skill FREE]]></title>
            <link>https://medium.com/software-engineering/one-technique-guaranteed-to-improve-your-coding-skill-free-2c8eb2193b72?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/2c8eb2193b72</guid>
            <category><![CDATA[coding]]></category>
            <category><![CDATA[careers]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[software-development]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Sun, 11 Jun 2017 15:32:43 GMT</pubDate>
            <atom:updated>2017-06-11T15:32:21.087Z</atom:updated>
            <content:encoded><![CDATA[<p><em>Originally published at </em><a href="https://webapplog.com/one-technique/"><em>webapplog.com</em></a><em> on June 11, 2017.</em></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*o3OzfC2f3Yv72VPtmV5hWA.jpeg" /></figure><p><strong>Node University: The Ultimate Node.js Resource</strong> with Courses on Node.js, React and JavaScript</p><p>Become an expert with my comprehensive Node.js, React.js and JavaScript courses.</p><p><a href="https://node.university/">Learn Full Stack Javascript →</a></p><p>What if I told you, there’s a one technique which will GUARANTEE an improvement in your coding skills and… it’s FREE. There’s no need for a partner, or expensive equipment, or supplements/nootropics. <em>I’ve been using it for many years now and I became much better software engineer as a result.</em> I was able to write 14 technical books while having a full-time job coding, speaking at conferences and teaching workshops all over the world.</p><p>More over, a lot of people outside of tech and coding use this technique to gain great advantage and improvement in their work: actors, writers, athletes, etc. It’s one of the best kept secrets and has been for many hundreds of years and probably longer. But hundreds of year ago, only select few people knew about this technique. Now anyone can tap into its power… but will <em>you</em> be the one to rip the benefits of this awesome technique for your career?</p><p>But let’s get back to coding.</p><p>Let me ask you: <strong>What is the most important important skill in coding?</strong></p><p>What allows you to dig deeper into a problem and come up with a solution? No. Programming languages and apps are just tools.</p><p>To make it more specific, what allows you to track a function call and keep in memory three different variable values while also applying methods on an array and noticing places where you can refactor the code to make it better?</p><p>Let me give you the hint: <em>experienced programmers (10+ years) have this skill in abundance</em>. This is why they can solve complex problems and work with technologies which make any one else on their team cry like small baby. Senior programmers are masters of this skill and I won’t be surprised to find out that most of them use this productivity-boosting technique.</p><p>Do you know by now?</p><p>Can you guess?</p><p>It’s focus! Focus is the most important skill for a programmer. If you can focus more, then you can solve very complex problems. If you can change your focus from one thing to another faster, then you can be more productive. Most coding tasks require focus, e.g., finding bugs or find abstraction patterns to improve code and systems.</p><p>And what is a free technique to improve the focus? It’s meditation. It’s free. There’s no need for equipment. There’s no need for a partner. It’s affordable to anyone!</p><p>Any excuses like “I’m not good at meditation” just means you need meditation the MOST to calm your monkey brain. In our world of Slack, Facebook, Twitter, Snapchat and <a href="http://azat.co/blog/open-offices/">open offices</a> it’s the people who can perform <a href="http://amzn.to/2gaZwUd">deep work</a> that will be value and will get ahead.</p><p>Not convinced? Meditation is popular in India and look how many programmers from India are out there! I’m not saying I have hard data to prove anything. It could be just a coincidence, but my gut feeling is that there must be something to it.</p><p>Sidenote: If you like this post and interested in a corporate on-site JavaScript, Node.js and React.js training to boost productivity of your team, then contact <a href="https://webapplog.com/hire-azat/">NodeProgram.com</a>.</p><p>Also, programming itself is a state of <a href="http://azat.co/blog/flow/">a blissful flow or trance</a>. The more you do it the better you become at going into the flow state. Programming itself is like a meditation!</p><p>I paid more than $3,000 for my yoga teacher training. That’s an expensive way to learn meditation which basically what yoga is. Luckily, you don’t have to pay as much unless you want to have a motivation from spending all that money.</p><p>You can start just by counting from one to four for FREE. Start with 5 minutes per day for 1 month, then increase to 10 minutes. Give it a few months. Notice any improvement in your ability to focus while coding. Leave a comment here or write me an email about your results.</p><p><strong>Node University: </strong>Courses on Node.js, React and JavaScript</p><p>Become an expert with my comprehensive Node.js, React.js and JavaScript courses.</p><p><a href="https://node.university/">Learn Full Stack Javascript →</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/100/0*oniv-Ot4vR1d99Mu." /></figure><p><a href="https://www.linkedin.com/in/azatm">https://www.linkedin.com/in/azatm</a><br> To contact Azat, the main author of this blog, submit <a href="http://webapplog.com/azat">the contact form</a>.</p><p>Also, make sure to get 3 amazing resources to <a href="http://eepurl.com/Tj3F9">FREE when you sign up for the newsletter.</a></p><p>Simple. Easy.</p><p>No commitment.</p><p><em>Originally published at </em><a href="https://webapplog.com/one-technique/"><em>webapplog.com</em></a><em> on June 11, 2017.</em></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2c8eb2193b72" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/one-technique-guaranteed-to-improve-your-coding-skill-free-2c8eb2193b72">One Technique Guaranteed to Improve Your Coding Skill FREE</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Node Toolchain for Newbies: The Best Node Apps and Libraries to Increase Productivity]]></title>
            <link>https://medium.com/software-engineering/node-toolchain-for-newbies-the-best-node-apps-and-libraries-to-increase-productivity-989b1fb2366c?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/989b1fb2366c</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[web-development]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Thu, 27 Apr 2017 18:16:55 GMT</pubDate>
            <atom:updated>2017-04-27T18:39:04.851Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*dcxYua1ShkN6v_fhYIeoVQ.png" /></figure><p><em>Original is posted at </em><a href="https://node.university/blog/725514/node-toolchain">https://node.university/blog/725514/node-toolchain</a></p><p>I get this question very often: “What tools would you recommend for Node development?” Software engineers love to optimize and increase productivity instead of wasting their time. I bet you are one of them! Read on to find out the best Node tools for development.</p><ul><li>IDEs/code editors</li><li>Libraries</li><li>GUI tools</li><li>CLI tools</li></ul><h3>IDEs/code editors</h3><p>When it comes to your primary tool, the code editor, I recommend sticking with lighter and simpler editors like Atom or VS Code instead of full-blown IDEs like Webstorm. Of course an IDE will do more for you but this comes with a learning curve and the need to configure. Node is interpreted, thus there’s no need to compile it. The files are just plain text files with the .js extension.</p><p>Here’s my list of the best Node editors:</p><ul><li><a href="https://www.npmjs.com/package/atom-package-manager">Atom</a>: created and maintained by GitHub; uses Electron, HTML, JS and CSS under the hood which makes it very easy to customize or add functionality; allows to have Git and terminal support via packages. Price: free.</li><li><a href="https://code.visualstudio.com">VS Code</a>: a newer addition; uses similar to Atom web-based tech; was created from Azure’s Monaco editor; comes with debugging, smart autocomplete based on types, Git and terminal support. Price: free.</li><li><a href="https://www.jetbrains.com/webstorm">WebStorm</a>: more of an IDE than an editor, developed by JetBrains and based on IntelliJ platform; has <a href="https://www.jetbrains.com/webstorm/features/coding-assistance.html">code assistance</a>, debugging, testing, Git. Price: starts at $59/yr for individuals.</li></ul><p>There are more options like Brackets, Sublime Text 3 and of course IDEs like Eclipse, Aptana Studio, NetBeans, Komodo IDE, and cloud-based like Cloud 9, Codenvy.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*wNFjFLfjT7bELodt7NKddg.gif" /></figure><p>What to pick? Any of the three in the list is good choice. I have heard good things about VS Code and their smart autocomplete is a nice thing, but I didn’t find it a good enough reason for me to switch from Atom. So try VS Code and Atom and see which one you like more. Both of them offer a wide variety of packages and themes.</p><h4>The most popular and useful libraries and project dependencies</h4><p>Here’s the list of the most used and most popular modules which you would install as dependencies of your projects. Node developers use most of these modules (or alternatives) in almost all of their projects.</p><p>The libraries are listed with the npm names, so you can execute npm i {name} substituting {name} with the name of the package/module:</p><ul><li><a href="https://webpack.github.io/docs/node.js-api.html">webpack</a>: Builds static assets like browser JavaScript, CSS and even images. It allows to use node modules in the browser.</li><li><a href="https://babeljs.io">babel</a>: Allows to code in the latest versions of JavaScript/ECMAScript without having to worry about your runtime by converting the new code to the code compatible with older versions of ECMAScript</li><li><a href="https://www.npmjs.com/package/axios">axios</a>: Makes HTTP requests</li><li><a href="https://expressjs.com">express</a>: the most popular Node web framework</li><li><a href="http://mongoosejs.com">mongoose</a>: MongoDB object-document mapper library</li><li><a href="https://www.npmjs.com/package/sequelize">sequelize</a>: PostgreSQL object-relational mapper library</li><li><a href="https://socket.io">socket.io</a>: Real-time library with support of Web Sockets and others.</li><li><a href="https://cheerio.js.org">cheerio</a>: jQuery syntax for working with HTML-like data on the server</li><li><a href="https://www.npmjs.com/package/node-oauth">node-oauth</a>: Low-level but very mature and tested library to roll out any OAuth integration</li><li><a href="http://passportjs.org/">passport</a>: OAuth library to quickly integrate with major services</li><li><a href="http://yargs.js.org">yargs</a></li><li><a href="http://documentup.com/shelljs/shelljs">shelljs</a></li><li><a href="https://mochajs.org">mocha</a>: Testing framework</li><li><a href="https://www.npmjs.com/package/async">async</a>: Controls flow by running function concurrently, sequentially or any way you want</li><li><a href="https://www.npmjs.com/package/concurrently">concurrently</a>: Allows to execute CLI tools (local) as multiple processes all at the same time, e.g., webpack and node-static.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/808/1*E2eAM4ytZN-2YZCzBjNbaA.gif" /></figure><p>Note: Some of the libraries/tools listed above like webpack or mocha, can be installed globally instead of locally in your project folder. However, installing them globally is an old practice and currently is an anti-pattern because local installation allows developers to use multiple versions of the tool with different projects in addition to have these tools specified in package.json.</p><p>Of course there are a lot of different options in each category. For example, <a href="https://www.npmjs.com/package/request">request</a> and <a href="https://www.npmjs.com/package/superagent">superagent</a> are also extremely popular HTTP agent libraries. However, I don’t want to give too many options and confuse you with the differences, I listed only one tool (typically the one I use the most currently).</p><h4>CLI tools (global)</h4><figure><img alt="" src="https://cdn-images-1.medium.com/max/640/1*lM2zKGxCyquTXwSich81iw.gif" /></figure><p>Unlike the previous section, these tools are okay to install globally since most likely their version won’t affect or break your project.</p><ul><li><a href="https://www.npmjs.com/package/nodedev">node-dev</a>: Monitor and restart your Node app automatically on any file change within the current folder</li><li><a href="https://www.npmjs.com/package/node-static">node-static</a>: Serve files over HTTP web server</li><li><a href="https://www.npmjs.com/package/node-inspector">node-inspector</a>: Debug Node code in a familiar interface of DevTools (now part of Node starting with v7)</li><li><a href="https://www.docker.com/">docker</a>: Build and run Docker containers to isolate app environment, speed up deployment and eliminate conflicts between dev and prod (or any other) environments</li><li>curl: Make HTTP(S) requests to test your web apps (default for POSIX but can <a href="https://curl.haxx.se/download.html">get for Windows too</a>)</li><li><a href="https://github.com/creationix/nvm/blob/master/README.markdown">nvm</a>: Change Node versions without having to install and re-install them each time</li><li><a href="http://wintersmith.io/">wintersmith</a>: Build static website using Node templates and Markdown</li><li><a href="http://pm2.keymetrics.io/">pm2</a>: Process manager to vertically scale Node processes and ensure fail-tolerance and 0-time reload</li></ul><h4>GUI tools</h4><p>A good share of Node developers prefer GUI (graphical user interface) tools at least for some of the tasks because these tools require less typing and have features which makes them more productive and the development easier and simpler.</p><p><a href="https://giphy.com/gifs/3og0IG8RtIxAAk1oTm">Animated GIF - Find &amp; Share on GIPHY</a></p><ul><li><a href="https://www.getpostman.com">Postman</a>: HTTP client with ability to save requests and history, change formats (JSON, form, etc.) and do other things</li><li><a href="https://github.com/azat-co/mongoui">MongoUI</a>: Modify and inspect your MongoDB data in a web interface. You can host this web app on your server to enable the database management.</li><li><a href="https://www.google.com/chrome/browser/desktop">Chrome</a>: DevTools is a great way to inspect your requests, network, traffic, CPU profiles and other developer related data which is very useful for debugging</li><li>iTerm, itermocil and zsh: A better alternative to a native macOS Terminal app which together with itermocil and zsh increases productivity greatly</li><li><a href="https://www.sourcetreeapp.com">SourceTree</a>: Visual git trees and histories</li></ul><p>If you liked this post, next step is to understand the Node platform better. For this reason, check out this FREE course <a href="https://node.university/p/you-dont-know-node">You Don’t Know Node</a>.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=989b1fb2366c" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/node-toolchain-for-newbies-the-best-node-apps-and-libraries-to-increase-productivity-989b1fb2366c">Node Toolchain for Newbies: The Best Node Apps and Libraries to Increase Productivity</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[On Tech Leadership: Managing Humans Summary]]></title>
            <link>https://medium.com/software-engineering/on-tech-leadership-managing-humans-summary-70db614b2390?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/70db614b2390</guid>
            <category><![CDATA[leadership]]></category>
            <category><![CDATA[software]]></category>
            <category><![CDATA[startup]]></category>
            <category><![CDATA[management]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Sat, 04 Feb 2017 21:04:13 GMT</pubDate>
            <atom:updated>2017-02-04T21:05:12.713Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/560/1*-tMQ8LtFctdkiDfVE_EDVg.png" /></figure><p>Here is the summary for <a href="http://amzn.to/2kEFQ0z">Managing Humans</a>, a book on software engineering management along with my interpretation and comments.Text in quote are direct excerpts from the <a href="http://amzn.to/2kEFQ0z">book</a>.</p><p><strong>Read the full post on </strong><a href="https://webapplog.com/managing-humans-summary/"><strong>https://webapplog.com/managing-humans-summary/</strong></a></p><ul><li>People on your team have different needs, e.g., promotion, challenge, less stress. By filling their needs, you can make them content and productive. Your job as a leader is to listen to them and mentally document how they are wired. This is the essence of a software manager’s job.</li><li>Manager is connector between the team and the rest of the organization. The main way for an engineer to show the work to the company is to communicate to the manager. Hence should balance external and internal focus.</li><li><em>“Schedule one-on-ones with direct reports, keep them on the same day and time, and never cancel them.”</em> One-on-ones are paramount. Keep them regular and at least 30 min. Maybe 45min is better. Not 15min. Avoid missing scheduled one-on-ones and doing status reports. Weekly is the best. These meetings are for managers to listen 50%+. If no issues, then focus on career building and needs of your reports.</li><li>Know your boss’ place… and yours, in the food chain besides just the title of the org chart. <em>“Politically active managers are informed managers. They know when change is afoot and they know what action to take to best represent their organization.”</em></li><li>In a meeting, if someone is doing anything else except listening (open laptop? iPhone?), he is not listening. Ban laptops from your meetings altogether. Paper notebooks still work for notes (info can be digitized later), and they don’t require charging unlike laptops.</li><li>In conflict resolution, listen to both stories. Preferably in-person not over email. People prone to unconsciously augment memory, misinterpret and twist facts to make a story in their favor. <em>“If the story can’t stand up to the first three questions that pop into your mind, then there’s an issue”</em></li><li>Two pizza team rule. With more than 10–15 direct reports it becomes extremely hard to really listen people.</li><li>Sometimes just listening helps to vent a frustration. If communication is broken, then listen and repeat to understand.</li><li>Meetings must have an agenda at the beginning, and a clear set of actionable steps at the end.</li><li>Incrementalist vs. perfectionists. In a deadlock, it’s better to make an “executive” decision to move forward.</li><li>“In the absence of information, people will create their own”. Kill gossips in your staff meetings. Don’t spread them yourself and prevent others from spreading them. Also, don’t tell too much. <em>“As a manager, your job is that of a bullshit umbrella”.</em></li><li><em>“The point of a performance review is not the review itself but the conversation that stems from it”</em>. Send the report a few days in advance so it’s not a shock to the team member. Aim to mitigate any boredom and complacency by giving directions, i.e., learn Elixir.</li><li>Speak the same language as the person you’re talking to: managerial (managementese) with other leads and technical with coders.</li><li>Off-sites help remove day-to-day distractions and focus on strategic.</li><li>If you want to progress as a manager, you need to stop coding while still coding but on prototypes, research, proof-of-concepts, i.e., no core products. This way you are still in the latest trends but not an impediment if you fail to deliver a critical feature or worse delivered a bug which crashed other parts (and your team had to fix it). <em>“Stay flexible, remember what it means to be an engineer, and don’t stop developing”</em>.</li><li>Always allow your team to question your decisions but once the decision is made — all hands on board.</li><li>Process must be a documentation of the engineering culture and value so it can be passed along to new members when engineers leave or company grows. Process must NOT be a way to control.</li><li>Humans are bad at estimations. It becomes a bit better once they start working on a task.</li><li>Project manager makes sure to ship the product; product manager makes sure that the right product is shipped; while program manager makes sure multiple (typically interelated and dependent) products are shipped, generally at the same time.</li><li>Rotate your engineering between boring tasks like bug fixes, tests or tech debt.</li><li>Each new engineer bring overhead of communication, decision, and error correction. (Read <a href="http://amzn.to/2jPaXm6">The Mythical Man-Month</a>). Ensure the cultural fit. All things equal, it’s better to hire for attitude than skill. Know about strategic vs. tactical visions.</li><li>Engineers treasure consistency, predictability, and efficiency.</li><li>There are mechanical (data oriented) and organic (human oriented) managers. Make sure you speak with them on their level not yours.</li></ul><p>Certain thing I didn’t agree with are:</p><ul><li>Multitasking: There are studies which shows multitasking and interruption is not good. As a manager often we have to multitask, i.e., be responsive over email and IM and keep the “doors” open for the team to communicate to us. Read Deep Work.</li><li>Nerds are cute: My definition of a nerd is someone narrow minded in life, and prefers inanimate objects over humans. Merriam-Webster <a href="https://www.merriam-webster.com/dictionary/nerd">says</a> nerd is unstylish and unattractive or socially inept person. Not cute at all. I believe it’s possible to be a good software engineer and not be a nerd.</li><li>Not a disagreement, but I just had to have the third bullet point. :) The author didn’t write about remote work and keeping things remote-friendly. It’s becoming more and more prevalent and more effective to have remote members or even whole <a href="https://m.signalvnoise.com">companies</a>.</li></ul><p>There are other gems in this book on how to focus, get into flow, optimize meetings, etc. However, these points above are all my take aways as far as engineering management.</p><p>Disclaimer: I filtered the content of the book through my own lens of experience in both tech leadership and individual contributor, so go for the real thing, i.e., buy the book and read it yourself. It has a good amount of humor as well like <em>“Facebook — The means by which you keep in touch with people you’re trying to forget”</em> or <em>“Collaboration — A word used to convince you to work with people you’d rather avoid.”</em></p><p><strong>Read the full post on </strong><a href="https://webapplog.com/managing-humans-summary/"><strong>https://webapplog.com/managing-humans-summary/</strong></a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=70db614b2390" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/on-tech-leadership-managing-humans-summary-70db614b2390">On Tech Leadership: Managing Humans Summary</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[ES7 and ES8 Features]]></title>
            <link>https://medium.com/software-engineering/es7-and-es8-features-eddb22115925?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/eddb22115925</guid>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[es8]]></category>
            <category><![CDATA[ecmascript]]></category>
            <category><![CDATA[es7]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Wed, 01 Feb 2017 00:40:41 GMT</pubDate>
            <atom:updated>2017-02-01T00:41:30.814Z</atom:updated>
            <content:encoded><![CDATA[<p>Recently I wrote a blog <a href="https://webapplog.com/es6">post</a> and even created an <a href="https://node.university/p/es6">online course</a> on ES6/ES2015. Guess what? TC39 — the mighty overseer of JavaScript — is moving forward with ES8 so let’s cover ES7 and ES8 (or ES2016 and ES2017 officially). Luckily, they are much, much, much smaller than the best of a standard that was ES6. Really! ES7 has only two (2) features!</p><p>ES7 features:</p><ol><li>Array.prototype.includes</li><li>Exponentiation Operator</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*oTV7SSanfIL8gZuUPfXV4A.png" /></figure><p>ES8 is not finalized yet as of this writing (Jan, 2017) but we can assume all finished proposals (stage 4) and most of stage 3 (more on stages <a href="https://tc39.github.io/process-document">here</a> and in my <a href="https://node.university/p/es6">course</a>). The finished 2017 (ES8) proposals are:</p><ol><li>Object.values/Object.entries</li><li>String padding</li><li>Object.getOwnPropertyDescriptors</li><li>Trailing commas in function parameter lists and calls</li><li>Async Functions</li></ol><p>I won’t include stage 3 proposals in this post, but you can check the status of proposals from stage 1 to 3 <a href="https://github.com/tc39/proposals/blob/master/README.md">here</a>.</p><p>Let’s dive deeper into the proposals and features.</p><h4>The rest of the article: <a href="https://node.university/blog/498412/es7-es8">https://node.university/blog/498412/es7-es8</a></h4><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eddb22115925" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/es7-and-es8-features-eddb22115925">ES7 and ES8 Features</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Beautiful Node APIs]]></title>
            <link>https://medium.com/software-engineering/beautiful-node-apis-eaf0b636cbe?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/eaf0b636cbe</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Sun, 01 Jan 2017 20:40:23 GMT</pubDate>
            <atom:updated>2017-01-01T20:40:22.453Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/851/1*iozM4w6NgmwRBFqBEkAazQ.png" /></figure><h3>Beautiful APIs in Node</h3><p>This post is on how to build beautiful APIs in Node.js. Great, and what is an API? The definition says Application Programming Interface, but what does it mean? It could mean on of the few things depending on the context:</p><ul><li>Endpoints of a service service-oriented architecture (SOA)</li><li>Function signature</li><li>Class attribute and methods</li></ul><p>The main idea is that an API is a form of a contract between two or more entities (objects, classes, concerns, etc.). Your main goal as a Node engineer is to build beautiful API so that developers who consume your module/class/service won’t be cursing and sending you hate IM and mail. The rest of your code can be ugly but the parts which are public (mean for usage by other programs, and developers) need to be conventional, extendable, simple to use and understand, and consistent.</p><p>Let’s see how to build beautiful APIs for which you can make sure other developer</p><h4>Beautiful Endpoints in Node: Taming the REST Beast</h4><p>Most likely, you are not using core Node http module directly, but a framework like Express or Hapi. If not, then strongly consider using a framework. It will come with freebies like parsing and route organization. I’ll be using Express for my examples.</p><p>Here’s our API server with CRUD for the /accounts resource listed with an HTTP method and the URL pattern (`{} means it’s a variable):</p><ul><li>GET /accounts: Get a list of accounts</li><li>POST /accounts: Create a new account</li><li>GET /accounts/{ID}: Get one account by ID</li><li>PUT /accounts/{ID}: Partial update one account by ID</li><li>DELETE /accounts/{ID}: Remove one account by ID</li></ul><p>You can notice immediately that we need to send the resource (account) ID in the URL for the last three endpoints. By doing so we achieve the goals of having a clear distinction between resource collection and individual resource. This in turn helps to prevent mistakes from the client side. For example, it’s easier to mistake DELETE /accounts with ID in the body of the request for the removal of all accounts which can easily get you fired if this bug ever makes it into production and actually causes the deleting of all accounts.</p><p>Additional benefits can be derived from caching by URL. If you use or plan to use Varnish, it caches responses and by having /accounts/{ID} you will achieve better caching results. Still not convinced? The let me tell you that Express will just ignore payload (request body) for requests like DELETE so the only way to get that ID is via a URL.</p><p>Express is very elegant in defining the endpoints. For the ID which is called a URL parameter, there’s a req.params object which will be populated with the properties and values as long as you define the URL parameter (or several) in the URL pattern, e.g., with :id.</p><pre>app.get(&#39;/accounts&#39;, (req, res, next) =&gt; {<br>  // Query DB for accounts<br>  res.send(accounts)<br>})<br><br>app.put(&#39;/accounts/:id&#39;, (req, res, next) =&gt; {<br>  const accountId = req.params.id<br>  // Query DB to update the account by ID<br>  res.send(&#39;ok&#39;)<br>})</pre><p>Now, a few words about PUT. It’s misused a lot because according to the specification PUT is for complete update, i.e., replacement of the whole entity, not the partial update. However, a lot of API even of big and reputable companies use PUT as a partial update. Did I confuse you already? It’s just the beginning of the post! Okay, let me illustrate the difference between partial and complete.</p><p>If you update with{a: 1} an object {b: 2}, the result is {a: 1, b: 2} when the update is partial and {a: 1} when it’s a complete replacement.</p><p>Back to the endpoints and HTTP methods. A more proper way is to use PATCH for partial updates not PUT. However, PATCH specs is lacking in implementation. Maybe that’s the reason why a lot of developers pick PUT as a partial update instead of PATCH.</p><p>Okay, so we are using PUT because it became the new PATCH. So how do we get the actual JSON? There’s body-parser which can give us a Node/JavaScript object out of a string.</p><pre>const bodyParser = require(&#39;body-parser&#39;)<br>// ...<br>app.use(bodyParser.json())<br>app.post(&#39;/accounts&#39;, (req, res, next) =&gt; {<br>  const data = req.body<br>  // Validate data<br>  // Query DB to create an account<br>  res.send(account._id)<br>})<br><br>app.put(&#39;/accounts/:id&#39;, (req, res, next) =&gt; {<br>  const accountId = req.params.id<br>  const data = req.body<br>  // Validate data<br>  // Query DB to update the account by ID<br>  res.send(&#39;ok&#39;)<br>})</pre><p>Always, alway, always validate the incoming (and also outgoing) data. There are modules like joi and express-validator to help you sanitize the data elegantly.</p><p>In the snippet above, you might have noticed that I’m sending back the ID of a newly created account. This is the best practice because clients will need to know how to reference the new resource. Another best practice is to send proper HTTP status codes such as 200, 401, 500, etc. They go into categories:</p><ul><li>20x: All is good</li><li>30x: Redirects</li><li>40x: Client errors</li><li>50x: Server errors</li></ul><p>By providing a valid error message you can help developers on the client side <em>dramatically</em>, because they can know if the request failure is their fault (40x) or server fault (500). In the 40x category, you should distinguish at the very least between authorization, poor payload, and not found.</p><p>In Express, status codes are chained before the send(). For example, for POST /accounts/ we are sending 201 created along with the ID:</p><pre>res.status(201).send(account._id)</pre><p>The response for PUT and DELETE doesn’t have to contain the ID because we know that client knows the ID. They used in the URL after all. It’s still a good idea to send back some okay message saying that it all when as requested. The response might be as simple as {“msg”: “ok”} or as advanced as</p><pre>{ <br>  &quot;status&quot;: &quot;success&quot;,<br>  &quot;affectedCount&quot;: 3,<br>  &quot;affectedIDs&quot;: [<br>   1,<br>   2, <br>   3<br>  ]<br>}</pre><p>What about query strings? They can be used for additional information such as a search query, filters, API keys, options, etc. I recommend using query string data for GET when you need to pass additional information. For example, this is how you can implement pagination (we don’t want to fetch all 1000000 accounts for the page that shows only 10 of them). The variable page is the page number and the variable limit is how many item is needed for a page.</p><pre>app.get(&#39;/accounts&#39;, (req, res, next) =&gt; {<br>  const {query, page, limit} = req.query<br>  // Query DB for accounts <br>  res.status(200).send(accounts)<br>})</pre><p>Enough about endpoints, let’s see how to work on a lower level with functions.</p><h4>Beautiful Functions: Embracing the Functional Nature of Node</h4><p>Node and JavaScript are very (but not completely) functional meaning we can achieve a lot with functions. We can create objects with functions. A general rule is that by keeping functions pure you can avoid future problems. What is a pure function? It’s a function which does NOT have side effects. Don’t you love smart asses who define one obscure term with another even more obscure one? A side effect is when a function “touches” something outside, typically a state (like a variable or an object). The proper definition is more complex, but if you remember to have function which only modify their argument, you’ll better off than majority (with majority only being 51% — and it’s my humble guesstimate anyway).</p><p>This is a beautiful pure function:</p><pre>let randomNumber = null<br>const generateRandomNumber = (limit) =&gt; {<br>  let number = null  <br>  number = Math.round(Math.random()*limit)<br>  return number<br>}<br>randomNumber = generateRandomNumber(7)<br>console.log(randomNumber)</pre><p>This is a very impure function because it’s changing randomNumber outside of its scope. Accessing limit out of scope is an issue too because this introduce additional interdependency (tight coupling):</p><pre>let randomNumber = null<br>let limit = 7<br>const generateRandomNumber = () =&gt; {<br>  randomNumber = Math.floor(Math.random()*limit)<br>}<br>generateRandomNumber()<br>console.log(randomNumber)</pre><p>The second snippet will work alright but only up to a point in the future as long as you can remember about the side effects limit and randomNumber.</p><p>There are a few things specific to Node and function <em>only</em>. They exist because Node is asynchronous and we didn’t have the hipster promises or async/await back in 201x when the core of Node was forming and growing rapidly. In short, for async code we need a way to schedule some future code execution. We need to be able to pass a callback. The best approach is to pass it as the last argument. If you have a variable number of argument (let’s say a second argument is optional), then still keep the callback as last. You can use arity (arguments) to implement it.</p><p>For example, we can re-write our previous function from synchronous execution to asynchronous by using callback as the last argument pattern. I intentionally left randomNumber = but it will be undefined since now the value will be in the callback at some point later.</p><pre>let randomNumber = null<br>const generateRandomNumber = (limit, callback) =&gt; {<br>  let number = null  <br>  // Now we are using super slow but super random process, hence it&#39;s async<br>  slowButGoodRandomGenerator(limit, (number) =&gt; {<br>    callback(number)<br>  })<br>  // number is null but will be defined later in callback <br>}<br><br>randomNumber = generateRandomNumber(7, (number)=&gt;{<br>  console.log(number)<br>})<br>// Guess what, randomNumber is undefined, but number in the callback will be defined later</pre><p>The next pattern which is closely related to async code is error handling. Each time we set up a callback, it will be handled by event loop at some future moment. When the callback code is executed we don’t have a reference to the original code anymore, only to variable in the scope. Thus, we cannot use try/catch and we cannot throw errors like I know some of you love to do in Java and other synchronous languages.</p><p>For this reason, to propagate an error from a nested code (function, module, call, etc.), we can just pass it as an argument… to the callback along with the data (number). You can check for your custom rules along the way. Use return to terminate the further execution of the code once an error is found. While using null as an error value when no errors are present (inherited or custom).</p><pre>const generateRandomNumber = (limit, callback) =&gt; {<br>  if (!limit) return callback(new Error(&#39;Limit not provided&#39;))<br>  slowButGoodRandomGenerator(limit, (error, number) =&gt; {<br>    if (number &gt; limit) {<br>      callback(new Error(&#39;Oooops, something went wrong. Number is higher than the limit. Check slow function.&#39;), null)<br>    } else {    <br>      if (error) return callback(error, number)<br>      return callback(null, number)<br>    }<br>  })<br>}<br><br>generateRandomNumber(7, (error, number) =&gt; {<br>  if (error) {<br>    console.error(error)<br>  } else {<br>    console.log(number)<br>  }<br>})</pre><p>Once you have your async pure function with error handling, move it to a module. You have three options:</p><ul><li>File: The easiest way is to create a file and import it with require()</li><li>Module: You can create a folder with index.js and move it to node_modules. This way you don’t have to worry about pesky __dirname and path.sep). Set private: true to avoid publishing.</li><li>npm Module: Take your module a step further by publishing it on npm registry</li></ul><p>In either case, you would use CommonJS/Node syntax for modules since the ES6 import is nowhere near TC39 or Node Foundation roadmap (as of Dec 2016 and a talk from the main contributor I’ve heard at Node Interactive 2016). The rule of thumb when creating a module is <em>what you export is what you import</em>. In our case, it’s function so:</p><pre>module.exports = (limit, callback) =&gt; {<br>  //...<br>}</pre><p>And in the main file, you import with require. Just don’t use capital case or underscores for file names. Really, don’t use them:</p><pre>const generateRandomNumber = require(&#39;./generate-random-number.js&#39;)<br>generateRandomNumber(7, (error, number) =&gt; {<br>  if (error) {<br>    console.error(error)<br>  } else {<br>    console.log(number)<br>  }<br>})</pre><p>Aren’t you happy that generateRandomNumber is pure? :-) I bet it would have taken you longer to modularize an impure function, due to the tight coupling.</p><p>To sum up, for beautiful function, you would typically make the asynchronous, have data as the first argument, options as the second and callback as the last. Also, make the options an optional argument and thus callback can be second or third argument. Lastly, the callback will pass error as <em>first</em> argument event if it’s just null (no errors) and data as the last (second) argument.</p><h4>Beautiful Classes in Node: Diving into OOP with Classes</h4><p>I’m not a huge fan of ES6/ES2015 <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Classes">classes</a>. I use function factories (a.k.a. functional inheritance pattern) as much as I can. However, I expect more people would start coding in Node who came from front-end or Java background. For them, let’s take a look at the OOP way to inherit in Node:</p><pre>class Auto {<br>  constructor({make, year, speed}) {<br>    this.make = make || &#39;Tesla&#39;<br>    this.year = year || 2015<br>    this.speed = 0<br>  }<br>  start(speed) {<br>    this.speed = speed<br>  }<br>}<br>let auto = new Auto({})<br>auto.start(10)<br>console.log(auto.speed)</pre><p>The way class is initialized (new Auto({})) is similar to a function call in the previous section, but here we pass an object instead of three argument. Passing an object (you can call it options) is a better more beautiful pattern since it’s more versatile.</p><p>Interestingly enough, as with functions, we can create named functions (example above) as well as anonymous classes by storing them in variables (code below):</p><pre>const Auto = class {<br>  ...<br>}</pre><p>The methods like the one called start in the snippet with Auto are called prototype or instance method. As with other OOP languages, we can create static method. They are useful when methods don’t need access to an instance. Let’s say you are a starving programmer at a startup. You saved $15,000 from your meager earning by eating ramen noodles. You can check if that enough to calling a static method Auto.canBuy and there’s no car yet (no instance).</p><pre>class Auto {<br>  static canBuy(moneySaved) {<br>    return (this.price&lt;moneySaved)<br>  }<br>}<br>Auto.price = 68000<br><br>Auto.canBuy(15000)</pre><p>Of course, it all would have been too easy if TC39 included the standard for static class attributes such as Auto.price so we can define them right in the body of class instead of outside, but no. They didn’t include class attribute in ES6/ES2015. Maybe we’ll get it next year.</p><p>To extend a class, let’s say our automobile is a Model S Tesla, there’s extends operand. We must call super() if we overwrite constructor(). In other words, if you extend a class and define your own constructor/initializer, then please invoke super to get all the things from the parent (Auto in this case).</p><pre>class Auto {<br>}<br>class TeslaS extends Auto {<br>  constructor(options) {<br>    super(options)<br>   }<br>}</pre><p>To make this beautiful, define an interface, i.e., public methods and attributes/properties of a class. This way the rest of the code can stay ugly and/or change more often without causing any frustration or anger to developers who used the private API (sleep and coffee deprived developers tend to be the angriest — have a snack handy in your backpack for them in case of an attack).</p><p>Since, Node/JavaScript is loosely typed. You should put extra effort in documentation than you would normally do when creating classes in other language with strong typing. Good naming is part of documentation. For example, we can use _ to mark a private method:</p><pre>class Auto {<br>  constructor({speed}) {<br>    this.speed = this._getSpeedKm(0)<br>  }<br>  _getSpeedKm(miles) {    <br>    return miles*1.60934<br>  }<br>  start(speed) {<br>    this.speed = this._getSpeedKm(speed)<br>  }<br>}<br>let auto = new Auto({})<br>auto.start(10)<br>console.log(auto.speed)</pre><p>All the things related to modularizing described in the section on functions apply to classes. The more granular and loosely coupled the code, the better.</p><p>Okay. This is enough for now. If your mind craves more of this ES6/ES2015 stuff, check out my <a href="https://node.university/p/library">cheatsheet</a> and <a href="https://webapplog.com/es6">blog post</a>.</p><p>You might wonder, when to use a function and when a class. It’s more of an art than a science. It’s also depends on your background. If you spent 15 years as a Java architect, it’ll be more natural for you to create classes. You can use Flow or TypeScript to add typing. If you are more of a functional Lisp/Clojure/Elixir programmer, then you’ll lean towards functions.</p><h4>Wrap-up</h4><p>That’s was a hell of a long essay but the topic is not trivial at all. Your well being might depend on it, i.e., how much maintenance the code will require. Assume that all the code is written to be changed. Separate things which change more often (private) from other things. Expose only interfaces (public) and make them robust to changes as much as possible.</p><p>Lastly, have unit tests. They will serve as documentation and also make your code more robust. You will be able to change the code with more confidence once you have a good test coverage (preferably automated as GitHub+CI, e.g. CircleCI or Travis).</p><p>And keep on Nodding!</p><p>— Azat Mardan</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/100/0*7pNtXOs4y281hJQt." /></figure><p><a href="https://www.linkedin.com/in/azatm">https://www.linkedin.com/in/azatm</a><br> To contact Azat, the main author of this blog, submit <a href="http://webapplog.com/azat">the contact form</a>.</p><p>Also, make sure to enroll in <a href="http://node.university">amazing online courses</a> for FREE at Node University (<a href="http://node.university">http://node.university</a>).</p><p>Simple.</p><p>Easy.</p><p>No commitment.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eaf0b636cbe" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/beautiful-node-apis-eaf0b636cbe">Beautiful Node APIs</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Node.js in Containers Using Docker]]></title>
            <link>https://medium.com/software-engineering/node-js-in-containers-using-docker-48649e4a9d67?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/48649e4a9d67</guid>
            <category><![CDATA[docker]]></category>
            <category><![CDATA[containers]]></category>
            <category><![CDATA[javascript]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Sun, 01 Jan 2017 20:01:27 GMT</pubDate>
            <atom:updated>2017-01-01T20:02:06.312Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/960/1*e0MRZajOhmCCICxOIOQuUg.png" /></figure><p>Container technology is one of the best options for software development and deployment. It allows you to share some of the OS resources while encapsulating the code and other concerns. You can think of containers as virtual machines but with less footprint.</p><p>Containers are great for micro services where you replace monoliths with many services. Each of them works in isolation and communicates with other services via a well defined interface (typically REST).</p><p>Docker is one of the most popular implementations of containers. Docker’s <a href="https://www.docker.com/what-docker">What is Docker?</a> page has a a neat comparison of containers with VMs. In a nutshell, VMs use hypervisor and each VM has it’s own OS while containers share OS and only separate libraries, bin, executables, etc.</p><p>This is a simplified diagram on how VMs work (source: docker.com).</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*4EaPmvyhWQ_To8HQXmnCBA.png" /></figure><p>While with containers, more things are shared. Thus, you get faster startup, execution, spin up, etc.</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*fW6NvQ4k04x29piOwlbulw.png" /></figure><p>Here are some of the benefits of Docker containers:</p><ul><li>Allow for rapid application development/deployment.</li><li>Are Extendable.</li><li>Are Lightweight.</li><li>Are portable across machines &amp; environments.</li><li>Are fast with a lightweight footprint.</li><li>Are easy to use.</li><li>Allow consistent behavior from dev to production.</li><li>Can be versioned and components can be reused.</li><li>Allow for community/collaboration.</li><li>Are easily maintained.</li></ul><p>Before we can start working with Docker, we should define commonly used terms, i.e., terminology that is used frequently in the Docker ecosystem:</p><p><strong>Images</strong> — The blueprints of our application which form the basis of containers. We will use the docker pull command to download the specified image.</p><p><strong>Containers</strong> — Created from Docker images and run the actual application. We create a container using docker run. A list of running containers can be seen using the docker ps command.</p><p><strong>Docker Daemon</strong> — The background service running on the host that manages building, running and distributing Docker containers. The daemon is the process that runs in the operation system to which clients talk to. It is what makes Docker Engine work.</p><p><strong>Docker Client</strong> — The command line tool that allows the user to interact with the daemon. There can be other forms of clients — such as Kitematic which provides a GUI.</p><p><strong>Docker Hub</strong> — A registry of Docker images. You can think of the registry as a directory of all available Docker images. If required, one can host their own Docker registries and can use them for pulling images.</p><p><strong>Dockerfile</strong> — A recipe from which you can create an image. Dockerfile has the base image, instructions to add or copy files, commands to execute, ports to expose and other information. Dockerfile is case sensitive.</p><p><strong>Docker Compose</strong> — A mechanism to orchestrate multiple containers needed for a service(s) from a single configuration file docker-compose.yml.</p><p><strong>Host</strong> — Your computer which hosts docker daemon or a remote machine which hosts docker deamon/engine.</p><p>Node.js is one of the fastest growing platforms. It’s great for web applications and API, especially for microservices. Let’s take a look how you can get started with Node and Docker in these steps:</p><ul><li>Installing Docker</li><li>Docker Basics</li><li>Creating Node images</li><li>Working with multiple containers: Node and MongoDB</li></ul><h4>Installing Docker</h4><p>First of all, you would need to get the Docker deamon. If you are a macOS user like I’m, then the easiest way is to just go to the official Docker website <a href="https://docs.docker.com/docker-for-mac">https://docs.docker.com/docker-for-mac</a>.</p><p>If you are not a macOS user, then you can select one of the options from this page: <a href="https://docs.docker.com/engine/installation">https://docs.docker.com/engine/installation</a>.</p><p>Once install is complete, test your Docker installation by running:</p><pre>$ docker run hello-world</pre><p>If you see a message like this most likely you didn’t start Docker:</p><pre>Cannot connect to the Docker daemon. Is the docker daemon running on this host?</pre><p>Start Docker. If you used macOS, you can utilize the GUI app. Otherwise, CLI.</p><p>This is how running Docker deamon looks on my macOS:</p><figure><img alt="" src="https://cdn-images-1.medium.com/proxy/1*xfa1yZ4Ec6wb9GtxF5uwLw.png" /></figure><p>I can even configure how much memory it takes, whether it updates automatically or starts itself on the log in.</p><figure><img alt="title" src="https://cdn-images-1.medium.com/proxy/1*3Z0CJX1PWl9PkfJfUlaGig.png" /><figcaption>title</figcaption></figure><p>On the contrary, if you see a message like the one below, then deamon is running and you are ready to work with Docker!</p><pre>Unable to find image &#39;hello-world:latest&#39; locally<br>latest: Pulling from library/hello-world<br> <br>c04b14da8d14: Pull complete<br>Digest: sha256:0256e8a36e2070f7bf2d0b0763dbabdd67798512411de4cdcf9431a1feb60fd9<br>Status: Downloaded newer image for hello-world:latest<br> <br>Hello from Docker!<br>This message shows that your installation appears to be working correctly.<br> <br>...</pre><p>Next, we will download a lightweight version of Linux as an image. It’s called Alpine. We will get this Alpine image from Docker Hub.</p><pre>$ docker pull alpine</pre><p>Wait for the image to download. I hope you have a fast internet speed. The good thing is that you need to download image just once. It will be stored on your computer for future usage. Let’s actually go ahead and check that the image is there by running:</p><pre>$ docker images</pre><p>It will show you Alpine, hello world and probably nothing else. It’s okay, because you just started working with Docker. Let’s learn Docker basics first.</p><h4>Docker Basics</h4><p>First, to install an image (pull) from Docker Hub, there’s a docker pull {name} command. You already used it for Alpine:</p><pre>$ docker pull alpine</pre><p>Some other images by names from Docker Hub are:</p><ul><li>boron: Node.js v6 based on Debian Jessie</li><li>argon: Node.js v4 based on Debian Jessie</li><li>ubuntu: Ubuntu</li><li>redis: Redis based on Debian Jessie</li><li>mongodb: MongoDB based on Debian Wheezy</li></ul><p>Once you download an image, you can run it with docker run {name}, e.g.,</p><pre>$ docker run alpine</pre><p>But then <strong>nothing</strong> happened! That’s because when you call $ docker run {name}, the Docker client (CLI):</p><ul><li>Finds the image (alpine in this case)</li><li>Loads up the container</li><li>Runs commands (if any) in the container</li></ul><p>When we run $ docker run alpine, we didn’t provide any commands, so the container booted up, ran an empty command and then exited.</p><p>Let’s try a better command which will print hello world from alpine:</p><pre>$ docker run alpine echo &quot;hello from alpine&quot;</pre><p>As a result, Docker runs the echo command in our alpine container and then exits.</p><p>Imagine how long it could have taken to boot up a virtual machine, run a command in it and then killing it! Much longer then a container. That’s a benefit of containers.</p><p>If it was the case that containers can only run one echo command and exit, they would be very useless. Luckily, containers can perform long running processes, i.e., they are running without exiting. To see all containers that are currently running, use this command:</p><pre>$ docker ps</pre><p>The ps will show you a list of all containers that we’ve run on this computer (called host):</p><pre>$ docker ps -a</pre><p>To stop a detached container, run $ docker stop {ID} by giving the container ID.</p><p>Some useful options to the doker run command are:</p><ul><li>-d will detach our terminal (bg/daemon).</li><li>-rm will remove the container after running.</li><li>-it attaches an interactive tty in the container.</li><li>-p will publish/expose ports for our container.</li><li>— name a name for our container.</li><li>-v mounts a volume to share between host and container.</li><li>-e provides environment vars to the container.</li><li>docker run — help for all flags</li></ul><h4>Creating Docker Images</h4><p>If you remember from definition, there’s such a thing as Dockerfile. It’s how we can create new images. In fact, each image on Docker Hub has Dockerfile. A Dockerfile is just a text file that contains a list of commands that the Docker client calls while building an image.</p><p>You can include the following instructions in the Dockerfile:</p><ul><li><strong>FROM</strong>: (required as the first instruction in the file) Specifies the base image from which to build the Docker container and against which the subsequent Dockerfile instructions are run. The image can be hosted in a public repository, a private repository hosted by a third-party registry, or a repository that you run on EC2.</li><li><strong>EXPOSE</strong>: Lists the ports to expose on the container.</li><li><strong>ADD</strong>: adds specified files to a location on the container</li><li><strong>WORKDIR</strong>: sets the current working directory to run commands in the container.</li><li><strong>VOLUME</strong>: marks a mount point as externally available to the host (or other containers).</li><li><strong>CMD</strong>: Specifies an executable and default parameters, which are combined into the command that the container runs at launch. Use the following format:</li><li>CMD [“executable”,”param1&quot;,”param2&quot;]</li></ul><p><strong>CMD</strong> can also be used to provide default parameters for an <strong>ENTRYPOINT</strong> command by omitting the executable argument. An executable must be specified in either a <strong>CMD</strong> or an <strong>ENTRYPOINT</strong>, but not both. For basic scenarios, use a <strong>CMD</strong> and omit the <strong>ENTRYPOINT</strong>.</p><p><strong>ENTRYPOINT</strong>: Uses the same JSON format as <strong>CMD</strong> and, like <strong>CMD</strong>, specifies a command to run when the container is launched. Also allows a container to be run as an executable with docker run.</p><p>If you define an <strong>ENTRYPOINT</strong>, you can use a CMD as well to specify default parameters that can be overridden with docker run’s -d option. The command defined by an <strong>ENTRYPOINT</strong> (including any parameters) is combined with parameters from **CMD **or docker run when the container is run.</p><p><strong>RUN</strong>: Specifies one or more commands that install packages and configure your web application inside the image.</p><p><strong>ENV</strong> — sets the environment variable {key} to the value {value} using {key}={value}. Syntax example:</p><pre>ENV myName=&quot;John Doe&quot; myDog=Rex The Dog myCat=fluffy</pre><p>For more information about instructions you can include in the Dockerfile, go to Dockerfile Reference: <a href="http://docs.docker.io/reference/builder">http://docs.docker.io/reference/builder</a>. For Dockerfile tips and best practices: <a href="https://docs.docker.com/engine/userguide/eng-image/dockerfile_best-practices">https://docs.docker.com/engine/userguide/eng-image/dockerfile_best-practices</a></p><p>Volumes can share code between host (your computer) and the container. In other words, a Docker volume is a wormhole between an ephemeral Docker container and the host. It’s great for development or persistent data. The following command will mount a volume from a current working directory (pwd) on host. The files will be available in /www/ in the container. The way to remember the options is left to right, i.e., host:contaner.</p><pre>$ docker run -v $(pwd)/:/www/ -it ubuntu</pre><p>Once the command is run, you will be inside of the container thanks to the -it. There you can navigate to the /www with cd /www. What do you see (use ls)? Your files! Now here’s the magic. If you modify, remove add files to your host folder, those changes will be automatically in the container!</p><p>More over, even if the container is stopped, the persistent data still exists on the Docker host and will be accessible.</p><h4>Creating Docker Node Images</h4><p>Now, when it comes to Node, you have an option to get one of the official Node images from Docker Hub. The current versions are Boron and Argon, but there are also version 7 and nightly releases.</p><p>Another option is to build Node image from Debian or Ubuntu base. You don’t even have to compose the Dockerfile all by your self. You can borrow a few lines from official images and add/remove as necessary.</p><p>We will proceed with the first option since it’s the simplest way. So we create Dockerfile in our Node.js project folder right where you have package.json and node_modules, i.e., the root of the project. Each project is typically a folder or even a separate Git repository. Then, write in Dockerfile instructions:</p><pre>FROM node:argon<br> <br># Create app directory<br>RUN mkdir -p /usr/src/app<br>WORKDIR /usr/src/app<br> <br># Install app dependencies<br>COPY package.json /usr/src/app/<br>RUN npm install<br> <br># Bundle app source<br>COPY . /usr/src/app<br> <br>EXPOSE 3000<br>CMD [ &quot;npm&quot;, &quot;start&quot; ]</pre><p>We are starting from Argon image, creating a folder for your application code. Then, we copy the source code files from the current folder (project root). Finally we expose the app port (for some strange reason it’s almost alway 3000) and boot up the server with npm start assuming you have that npm script defined in your package.json. If you are not a fan of npm scripts like npm start, then simply use node app.js or node server.js depending on your file name.</p><p>To build the Node.js app image, run $ docker build . It might take longer the first time you run it if you don’t have agron already. Next time, it’ll be faster. Once the build is over, you can run your app container like any other images:</p><pre>$ docker run {name}</pre><p>Here’s a catch. You might have noticed your new image has no name if you just used docker build. And most likely, you already have or will have multiple images. Therefore, it’s better to name and tag images when you build them. Use -t flag and nam:tag format. For example,</p><pre>$ docker build -t {your-name}/{your-app-name}:{tag} .</pre><p>Containers are fast but it’s not very cool to build new images each time you make a change to your source code. So for development, we can mount source code as a volume and use something like forever or nodemon or node-dev to listen for file changes and restart the server anytime we make press save. In the case of a volume, there’s no need to copy source code since it’ll be mounted from the volume.</p><pre>FROM node:argon<br> <br>WORKDIR /usr/src/app <br>RUN npm install<br><br>EXPOSE 3000<br>CMD [ &quot;nodemon&quot;, &quot;app.js&quot; ]</pre><p>The command to run this image will be slightly more advance since now we need to mount the volume:</p><pre>$ docker run -v ./:/usr/src/app -it {name}</pre><p>Now, the changes you make will be passed to container, the server will restart and you can develop in your host environment while running code in container. Best of both world! (It’s great because the container environment will be <em>exactly</em> the same in production as the one you have now.) But apps don’t function by themselves. You need some persistence and other services.</p><h4>Working with Multiple Containers: Node, and MongoDB</h4><pre>version: &#39;2&#39;<br>services:<br> <br>  mongo:<br>    image: mongo<br>    command: mongod --smallfiles<br>    networks:<br>      - all<br> <br>  web:<br>    image: node:argon<br>    volumes:<br>      - ./:/usr/src/app<br>    working_dir: /usr/src/app<br>    command: sh -c &#39;npm install; npm run seed; npm start&#39;<br>    ports:<br>      - &quot;3000:8080&quot;<br>    depends_on:<br>      - mongo<br>    networks:<br>      - all<br>    environment:<br>      MONGODB_URI: &quot;mongodb://mongo:27017/accounts&quot;<br> <br>networks:<br>  all:</pre><p>Let inspect this ymp file line by line. We start with a list of services. Name of a service, i.e., mongodb will be available in other containers so we can connect to MongoDB with mongodb://mongo:27017/accounts. You don’t have to pass this connection string in an environmental variable. I just did it to show that you can do it.</p><p>The image, volumes, ports and other fields mimic the Dockerfile instructions. The key distinction is that we use depends_on. This will tell the web service to use the mongo service.</p><p>To run the Docker compose, simply execute this terminal command (assuming deamon is running):</p><pre>$ docker-compose up</pre><p>You can look at the full working example of a MERN (MongoDB, Express, React and Node) app at <a href="https://github.com/azat-co/mern/blob/master/code">https://github.com/azat-co/mern/blob/master/code</a>. Docker compose is a brilliant and easy way to startup multi-container environment.</p><h4>Wrap-up</h4><p>Containers are great to getting your code safely in multiple environment with very little overhead. This allows you to minimize any discrepancies. The basic idea is that by developing in an environment identical to the production, you will eliminate any potential issues related to differences between dev and prod. Moreover, by getting encapsulation cheaper than with VMs, we can split our apps into more granular services. They can divided be not just into app, database, cache, web server, but even further. We can split web apps into containers by resources, e.g., endpoints for /accounts in one container, endpoints for /users in another, etc…. but this is a topic for another post.</p><h4>Further Reading and Docker Resources</h4><p>Learning never stops! Here’s some reading on Docker along with resources.</p><ul><li><strong>Awesome Docker:</strong> <a href="https://github.com/veggiemonk/awesome-docker">https://github.com/veggiemonk/awesome-docker</a></li><li><strong>Hello Docker Workshop:</strong> <a href="http://docker.atbaker.me">http://docker.atbaker.me</a></li><li><strong>Why Docker:</strong> <a href="https://blog.codeship.com/why-docker">https://blog.codeship.com/why-docker</a></li><li><strong>Docker Weekly and archives:</strong> <a href="https://blog.docker.com/docker-weekly-archives">https://blog.docker.com/docker-weekly-archives</a></li><li><strong>Codeship Blog:</strong> <a href="https://blog.codeship.com">https://blog.codeship.com</a></li></ul><p>PS: The AWS part mentioned in the featured image will be covered in a new post.</p><p>— Azat Mardan</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/100/0*7pNtXOs4y281hJQt." /></figure><p><a href="https://www.linkedin.com/in/azatm">https://www.linkedin.com/in/azatm</a><br> To contact Azat, the main author of this blog, submit <a href="http://webapplog.com/azat">the contact form</a>.</p><p>Also, make sure to get 3 amazing resources to <a href="http://eepurl.com/Tj3F9">FREE when you sign up for the newsletter.</a></p><p>Simple. Easy.</p><p>No commitment.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=48649e4a9d67" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/node-js-in-containers-using-docker-48649e4a9d67">Node.js in Containers Using Docker</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why it might be the time to start looking for a new profession if you are a software engineer?]]></title>
            <link>https://medium.com/software-engineering/why-it-might-be-the-time-to-start-looking-for-a-new-profession-if-you-are-a-software-engineer-e01c0e711053?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/e01c0e711053</guid>
            <category><![CDATA[it-career]]></category>
            <category><![CDATA[web-development]]></category>
            <category><![CDATA[careers]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Sun, 10 Jul 2016 23:10:18 GMT</pubDate>
            <atom:updated>2016-07-21T15:51:01.685Z</atom:updated>
            <content:encoded><![CDATA[<h3>Software Engineering Future: How Your Job is Becoming a Commodity and Might Even Disappear</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OIDdbsuZX5_gPlAV0E84jw.jpeg" /></figure><p>Update: There’s a follow up <a href="https://medium.com/@azat_co/will-software-engineering-become-a-commodity-part-ii-d969121aacd5#.wpnbe4pxt">post</a>.</p><p><strong>My Musings on why it might be the time to start looking for a new profession if you are a software engineer? Original post: </strong><a href="http://webapplog.com/software-engineering-future/">http://webapplog.com/software-engineering-future/</a></p><p>You know how in the early 20th century pilots were like heroes? It was extremely dangerous to fly planes which were highly unreliable. Most of the time, only true adventures would learn how to fly a plane and become a pilot.</p><p>Then, fast forward 50 years and during 1950s, we started to have first commercial flights. It was still prestigious to become a pilot. If you remember, <a href="http://www.imdb.com/title/tt0264464"><em>Catch Me If You Can</em></a>, the villain played by Leo DiCaprio used pilot’s uniform to instill more trust in other people so he can cash fake checks.</p><p>In the 21th century, most airlines don’t make much money and they operate on a slim margin. The pilot’s job has become a commodity: there are a lot of schools and you need to study many years to become a pilot, but you get paid not that much more money than a bus driver. Autopilot is doing most of the flying except for landing and take offs. Airlines constantly merge and layoff their staff. Most of the times the attire is not as sharp as we see on pilots in movies, old newspapers and posters.</p><p>I believe almost every profession or trade undergoes a few cycles not dissimilar to the famous adoption curve. There are five steps, but I’ll simplify it to just three:</p><ul><li>In the beginning, there’s very little reward but a high entry barrier</li><li>In the middle, you get most benefits from the wider demand for a certain skill and it’s less risky and less troublesome to get started in it</li><li>In the final phase, you get even smaller barrier to entry the profession: there are a lot of known paths, schools, books, best practices. Then also the tools and equipment becomes better than in the first two phases. However, the demand and the benefits to an individual from that profession diminish compare to what it was in the middle phase.</li></ul><p>After the third phase, the profession become a commodity. It’s not necessarily a disaster for people in this trade, but it’s certainly not a rarity. Then, the profession can event disappear completely! I’m sure you can come up with some examples that disprove my little theory, but before you do so, let’s take a look at programming.</p><p>In the 1950s, programming was close to science. A typical programmer had background in math or physics. They were white lab coats and most likely possessed PhDs. Oh yes, they worked on large mainframes, not personal computers.</p><p>In 1980s, think Steve Jobs and Bill Gates. They didn’t had to have science degrees (but most of them still did), and wore jeans and shirts. The aforementioned founders of Apple and Microsoft were treated like celebrities.</p><p>The programming has become easier than it was 10 years ago. Nowadays, you can learn programming in 2 months at <a href="http://webapplog.com/biggest-challenges-before-joining-a-coding-bootcamp">a dev bootcamp</a>, and wear jeans and T-Shirts to work. You can even work remotely from anywhere in the world. The barrier to entry the profession is the lowest it has ever been in its history.</p><p>However, programming has become a commodity. You can hire a freelance developer for $5 per hour… yes, I know that experienced software engineers in Silicon Valley and San Francisco can easily <a href="http://www.businessinsider.com/silicon-valley-engineer-negotiated-a-starting-salary-from-120k-to-250k-in-just-a-few-weeks-2016-4">make $150,000 per year in salary</a> but that could be attribute to a bubble.</p><p>Now, it’s trendy to be a programmer thanks to <a href="http://www.imdb.com/title/tt1285016"><em>The Social Network</em></a> and the new wave of app billionaires and millionaires. But how long will it continue? My personal observation, being in the industry for 14 years, and the adaption curve shows than programming won’t be in such high demand indefinitely. The demand in Silicon Valley drives innovation in frameworks, tools, programming languages, and platforms, while the supply increases by dev bootcamps (factories of good habits) and layoff in other industries. Soon, we’ll see the changes in the trade:</p><ul><li>Programming will become even easier, maybe it’s be as easy as a drag and drop or what you see is what you get editor, or something akin to Excel spreadsheet formulas/macros. It’ll be a common place to switch to a software engineering from let’s say being a violin player.</li><li>The demand will go down or shift in nature, because there would be better frameworks, languages and libraries which will automate a huge chunk of manual tasks and coding. For example, Twitter Bootstrap, Cloud Computing and PaaS (like Heroku), Ruby on Rails, WordPress, etc.</li><li>The salaries and prestige will drop down because of the lesser demand and ability to outsource internationally (programming like no other manufacturing job is easily outsourced).</li></ul><p>What is the next thing will be in 2030–2050 which will be as adventurous and unexplored as programming and computers were 50 years ago? Or maybe programming (especially programming of AI) will be the last job not replaced by robots?</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=e01c0e711053" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/why-it-might-be-the-time-to-start-looking-for-a-new-profession-if-you-are-a-software-engineer-e01c0e711053">Why it might be the time to start looking for a new profession if you are a software engineer?</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Node+React.js Course in San Francisco on April 30, 2016 ]]></title>
            <link>https://medium.com/software-engineering/node-react-js-course-in-san-francisco-on-april-30-2016-22f768b8510f?source=rss----9ef0bc905be6---4</link>
            <guid isPermaLink="false">https://medium.com/p/22f768b8510f</guid>
            <category><![CDATA[nodejs]]></category>
            <category><![CDATA[reactjs]]></category>
            <category><![CDATA[javascript]]></category>
            <dc:creator><![CDATA[Professor Azat Mardan]]></dc:creator>
            <pubDate>Tue, 19 Apr 2016 05:04:33 GMT</pubDate>
            <atom:updated>2016-04-19T05:03:52.289Z</atom:updated>
            <content:encoded><![CDATA[<p>🙋Node+React.js Course in San Francisco on April 30, 2016 🌉</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fkyn6Wq8w0M1dVgHo0gIgw.jpeg" /></figure><p>Before the announcement, here’s <a href="http://www.tusharsaxena.com/blog/2016/03/14/nodeprogram-in-march/">a blog post</a> from one of the engineers who attended NodeProgram.com course in March 2016 in NYC at Flatiron School:</p><blockquote><em>The NodeProgram weekend workshop taught by Azat Mardan was very well done. It was fast-paced and took no prisoners — not just familiarity but a minimal fluency with Javascript was assumed and required to keep up with the presentations and the exercises. I decided to attend both days of the weekend for a combined Sat+Sun of React and Node goodness. How else to productively spend a weekend?</em></blockquote><blockquote><strong><em>Saturday : React</em></strong></blockquote><blockquote><em>Saturday was devoted to React.js which I only had a passing familiarity with through osmosis (Hacker News, other fora). React is a very interesting model of front-end development and I thank Azat for helping me grok its fundamental nature — that of composability — the ability to compose components out of other components in a modular fashion. The urge to update the DOM through a quick jQuery function still nags my brain and will have to be trained out thru repeated React usage. We ended up working on Nodeschool ‘learnyoureact’ workshop between presentations of theoretical explanations. Mentors were available to assist people with their challenges and Azat walked around helping a lot as well. There was a supplementary presentation on React Native, which I paid minimal attention to as I’m not currently focused on building mobile apps and even when I play around with Swift on iOS, it’s good to have a solid understanding of a platform before (potentially) ruining one’s understanding with frameworks.</em></blockquote><blockquote><strong><em>Sunday : Node</em></strong></blockquote><blockquote><em>Azat emphasized repeatedly the asynchronous nature of Node.js, which was our topic for Sunday. The format of the day was similar to Saturday’s with working on Nodeschoolworkshops (learnyounode, ExpressWorks, learnyoumongo) interspersed with theory and explanations of Node.js, Express.js and the usage of MongoDB with Node and Express. As I’d earlier played around with Node back in 2012 (but, regrettably hadn’t followed it through to a major project), I was aware of some of the basics but Azat’s explanations solidified my understanding and I’m excited to build on top of my newly acquired knowledge.</em></blockquote><blockquote><em>I find it worthwhile to mention that Azat has a personality. He not only delivers good presentations and helps with one’s code, but also describes various scientifically tested learning strategies such as spaced repetition. He clearly keeps up with the learning geekosphere online! He also took the liberty of filling the ‘space’ in our spaced repetition with a quick foray to introduce meditation! Enjoyable and unique.</em></blockquote><blockquote><em>Overall, </em><strong><em>NodeProgram has reinforced my belief in hard, weekend workshops — it’s the ideal way to get a quick, rigorous introduction to a new technology — far more sticky in my mind than going through a dozen tutorials online</em></strong><em>. One can’t discount the serendipity of meeting great people either.</em></blockquote><p>Soooo, NodeProgram.com — one of the best JavaScript/Node.js education companies — is bringing this two-day in-person React.js+Node.js/Express/Meteor course in San Francisco, California on April 30 and May 1, 2016.</p><p>Are you tired of Java/PHP/Ruby/Python? No time to read books or watch videos? Come to our live in-person hands-on two-day training! Learn fullstack JavaScript for fun and profit. ;)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*CvZvgN2Ve9PyiOCKWvrxYw.jpeg" /></figure><p>Over the span of two day, you get into the isomorphic/universal JavaScript development with:</p><ul><li>React.js</li><li>Node.js</li><li>Express.js</li><li>MongoDB</li><li>Meteor</li></ul><p>WHAT</p><p><strong>Node, Express, Meteor, MongoDB and React.js 2-day live in-person workshop with Azat — the author of 13 books.</strong></p><p>WHEN</p><p>9am-5pm April 30-May 1, Lunch break (BYO) ~12–1pm.</p><p>WHERE</p><p>Make School: The college replacement for founders and developers</p><p><a href="https://www.makeschool.com">https://www.makeschool.com</a></p><p>REGISTER — -&gt;&gt;&gt; <br><a href="http://nodeprogram.com">http://nodeprogram.com</a> or <a href="http://node-react.eventbrite.com">http://node-react.eventbrite.com</a></p><p>😄</p><p>Azat Mardan,</p><p>Author of Practical Node.js and React Quickly</p><p><a href="http://azat.co">http://azat.co</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=22f768b8510f" width="1" height="1" alt=""><hr><p><a href="https://medium.com/software-engineering/node-react-js-course-in-san-francisco-on-april-30-2016-22f768b8510f">🙋Node+React.js Course in San Francisco on April 30, 2016 🌉</a> was originally published in <a href="https://medium.com/software-engineering">Software Engineering</a> on Medium, where people are continuing the conversation by highlighting and responding to this story.</p>]]></content:encoded>
        </item>
    </channel>
</rss>