Welcome to curated list of handpicked free online resources related to IT, cloud, Big Data, programming languages, Devops. Fresh news and community maintained list of links updated daily. Like what you see? [ Join our newsletter ]

17 JavaScript / Node.js performance coding tips to make applications faster

Categories

Tags programming javascript web-development

Paul Shan article about misconceptions, shallow knowledge, bad assumptions among the JavaScript community members. In this article author has come up with a list of tips, which can make your JavaScript application faster.

This article is about coding in JavaScript to make the performance better.

Some rules and tips form the article:

  • No global vars please
  • Only homogeneous Array
  • Put common codes in a function
  • Closure & timer – a deadly combo
  • Create class for similar kind of objects
  • forEach vs for()
  • Avoid for…in

And many more in the article. Increasing your server’s configuration, scaling it out, distributing the services are some of the very well known processes to make your application perform better.

But if your code is causing memory leaks or sequential processing; all those dev-ops steps will not able to save your server getting slowed down or even crashed. Good read even for seasoned programmer!

[Read More]

Productive with Docker in 20 minutes

Categories

Tags containers aws docker

George Fogle article about how to find a better, more productive development workflow with Docker. Docker and container-based development is really going to save you time in the future. As well as make working and debugging code a breeze.

A container is acting like an entirely separate computer, even though it’s on your computer. So using the name localhost inside of a container is not the same as using localhost in code that is running on your computer.

The article then explain how to use:

  • Docker
  • Docker Compose
  • Dockerfile
  • Image
  • Containers
  • Debugging effectively

When we’re creating an image, we first create a script file that will run some commands that Docker recognizes called a Dockerfile. The output of these commands create an image, that we’ll start container processes based off of.

Article also describe usage of environment variables with the environments keyword in docker-compose.yml.

Author also mentions how we can be more effective at debugging by using breakpoints that attach to the node process in our container. We an expose a port, where we can attach and set breakpoints from inside IDE. Interesting, give it a go!

[Read More]

Comparing AWS Lambda performance of Node.js, Python, Java, C# and Go

Categories

Tags serverless aws performance apis

Yun Zhi Li – VP of Engineering APAC at continoHQ – wrote this article as a reaction to comparison of lambdas done in previous year by Yan Cui. He noticed that despite AWS adding more languages to lambda runtime, old languages were not neglected. In the article he reviewed and updated runtime performance benchmark of all five programming languages supported by AWS Lambda.

Similar to the original performance tests, author ignored the initial cold start time – and focused only on the duration metric to compare runtime performance between the different languages.

To manage the performance load test, he created a script that calls artillery.io. The script executes a load test across all twelve APIs over a one-hour period:

Some observations:

  • Observation 1 – .Net Core 2.0 significantly outperforms
  • Observation 2 – Go performance is comparable to Java
  • Observation 3 – Consistent performance of compiled vs dynamic

With Go and .Net Core 2.0 support, AWS continues to lead the FaaS race as the most mature provider – with the widest range of supported languages. Good read!

[Read More]

How to securely store API keys

Categories

Tags infosec apis restful

Bruno Pedro detailed blog post focusing on secure storage of your API keys in the cloud. Many people store sensitive information in private git repositories. If you do this, please think about it twice.

Storing API Keys, or any other sensitive information, on a git repository is something to be avoided at all costs. Whenever you integrate a third-party application with one of the services like GitHub, GitLab, Bitbucket, you might be opening your private repositories to those third parties.

He then describes how to use various tools to encrypt keys:

  • git-remote-gcrypt lets you encrypt a whole git repository
  • git-secret is a tool that works on your local machine and encrypts specific files
  • git-crypt is a binary executable to encrypt your files
  • BlackBox from Stak Overflow supports the encryption of small strings and not just entire files
  • Heroku configuration and config vars
  • Docker secrets
  • AWS Parameter Store

This article will help you become aware of the dangers of storing sensitive information such as API keys and secrets on public and also private git repositories. Click on the link to learn how to mitigate the risks. Great!

[Read More]

Addressing the Theory of Constraints with DevOps

Categories

Tags devops programming software-architecture

In his article Stefan Thorpe focuses on Theory of Constrains and DevOps. “Theory of Constraints” was originally conceived by Israeli business management educator and philosopher, Dr. Eliyahu M. Goldratt. Theory of Constraints inspired the development of new business management concepts and systems to revolutionize production procedures in manufacturing.

These practices of systems management all seek to improve on or, where possible, remove bottlenecks through process analysis.

Theory of Constraints has become a reputed model for eliminating waste, recognizing opportunities for better collaboration, and streamlining the flow of work down the value stream.

Author then identifies five steps to improving your development pipeline:

  • Identify the constraint
  • Exploit the constraint
  • Subordinate everything else
  • Elevate the constraint
  • Repeat the process

Diagrams and charts explain these five points. Please read to learn how Lean influences within the DevOps methodology actually provide a great defense strategy to follow on a daily basis. Very good!

[Read More]

Elegant patterns in modern JavaScript RORO

Categories

Tags javascript programming nodejs

Bill Sourour from DevMastery.com wrote this article to introduce the pattern he has been using. He claims he did not invent it and came across it in other people’s code and eventually adopted it himself. The pattern is Receive an object, return an object (RORO).

Receive an object, return an object (RORO) Most of author’s functions now accept a single parameter of type object and many of them return or resolve to a value of type object as well. This patterns uses:

  • Named parameters
  • Cleaner default parameters
  • Richer return values
  • Easy function composition

RORO relies on destructuring feature introduced in ES2015. An added benefit of using destructuring for our parameter object is that it promotes immutability.

See function definition example bellow, with all parameters optional:

function findUsersByRole ({
  role,
  withContactInfo,
  includeInactive
} = {}) {...}

To learn more, read this article. Excellent!

[Read More]

NEAL, Uber's Open Source language-agnostic linting platform

Categories

Tags open-source programming

Tadeu Zagallo announcment and introduction into NEAL. To make code reviews easier, Uber engineers built Not Exactly a Linter (NEAL), an open source language-agnostic tool that allows engineers to write custom syntax-based rules, thereby automating sections of the code review process.

NEAL lets engineers write their own set of rules to cover any part of the codebase, taking the code review process one step closer to full automation. In fact, to make this process easier, NEAL uses its own domain-specific language.

NEAL is extensively used for:

  • Improve the reliability of our tests by checking for patterns
  • Control the growth of our binary size
  • Enforce high-level restrictions on executable code

NEAL is designed to be completely extensible across three dimensions. To learn how please read whole article. Exciting!

[Read More]

AWS AppSync GraphQL API with Golang Lambda source

Categories

Tags aws serverless app-development apis

Sebastian Muller wrote this article / tutorial about AWS AppSync, a serverless GraphQL with support for custom data sources using AWS Lambda. To enable easy access to his RSS feed, author created a simple GraphQL API using AWS AppSync.

Tricky part was the deployment of the API due to lack of CloudFormation support for AWS AppSync. In the tutorial, you will find:

  • AWS Lambda function to fetch and parse RSS feed
  • Serverless Application Model to deploy Lambda function
  • AppSync GraphQL API setup using AWS CLI

Tutorial then describes in detail what dependencies are, how to install Golang packages, configure environment and deploy using AWS Serverless Application Model. And finally you will learn how to use the GraphQL API. Great article!

[Read More]

Open Source documentation by example

Categories

Tags open-source programming

John Tucker addresses important question how to create documentation for open source project. He takes us through example and will demonstrate a compelling documentation organization for an open source project.

Author pieced together the project’s documentation organization. Documentation entry point is in 3 places:

  • Web site of HTML pages (including a search feature) generated with GitBook
  • README.md markup file in the root folder of the master branch
  • README.md markup file in the docs folder of the master branch

The HTML pages are generated from source markup files from the master branch of the repository. Author also offered solution for automation of the documentation updates using Travis CI (via travis.yml configuration filke). You will also find code examples for this article in the GitHub repository together with explanation how to use GitHub Pages. Interesting.

[Read More]

Winding down an open source project

Categories

Tags open-source programming

Guys from The Linux Foundation produced this Open Source Guide which is designed to offer advice about how your enterprise and your development team can plan for the day when you are ready to end or move away from an unneeded open source project.

They touch on many interesting points of open source project, including:

  • Why life cycle planning is important
  • How to protect your company’s reputation
  • Seek a diverse contributor base
  • How to end an open source project
  • The importance of clear communications

They suggest that once you’ve decided to make the move, you must determine whether to end it, transfer it to another organization, or just pull out and end your direct involvement.

This is excellent guide, well worth your time!

[Read More]