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 ]

Alternative Patterns for Method Overloading in Golang

Categories

Tags backend-development software-engineering

Chris Tomich shares in this post 3 patterns, 2 of which can be used, to deal with Golang’s lack of method overloading – a functional way, an object oriented way, and a “JavaScript” way. Author realises that method overloading can be pretty badly abused but it’s perfect for default values.

The functional way example uses Golangs ability to return multiple values from a function and the ability to immediately accept those multiple values as an argument list for another function.

The object oriented way - is vastly more readable. And The JavaScript way example is also included, but author points out that it should be never really used in production.

Chris concludes that you will probably end up using a hybrid of the functional method and the object oriented methods. Example code for all above mentioned approaches in included.

[Read More]

Tuning Your DBMS Automatically with Machine Learning

Categories

Tags ai-and-machine-learning data-and-analytics

Dana Van Aken, Geoff Gordon, and Andy Pavlo from Carnegie Mellon University guest blog post on AWS demonstrates how academic researchers can leverage AWS Cloud Credits for Research Program to support their scientific breakthroughs.

Database management systems (DBMSs) are the most important component of any data-intensive application. They can handle large amounts of data and complex workloads. OtterTune, a new tool written in Python that’s being developed by students and researchers, can automatically find good settings for a DBMS’s configuration.

Article then goes on explaining:

  • How OtterTune works
  • The machine learning pipeline
  • Implementation
  • Evaluation with MySQL and Postgres

Also loads of charts supporting the explanation. Nice!

[Read More]

Buildah - build your containers from the ground up!

Categories

Tags devops-and-ci-cd architecture-and-apis

Tom Sweeney from Project Atomic wrote an article about the Buildah tool for building Open Container Initiative (OCI) complaint container images. The tool requires golang. The buildah package provides a command line tool which can be used to (amongts other):

  • Create a working container, either from scratch or using an image as a starting point
  • Create an image, either from a working container or via the instructions in a Dockerfile
  • Images can be built in either the OCI image format or the traditional upstream docker image format
  • Mount a working container’s root filesystem for manipulation

Buildah simplifies the process of creating, building and updating images while decreasing the learning curve of the container environment. What’s really neat is there is no requirement for a container runtime daemon to be running on your system chewing up resources and complicating the build process.

As usually article sports command line examples for building and playing with container images.

[Read More]

How to Handle Exceptions in Python

Categories

Tags backend-development software-engineering

Monty Shokeen wrote neat article about handling exceptions in Python programming language. It is very common to encounter errors during the execution of a program. Two common kinds of errors that you may have to deal with are syntax errors and exceptions.

Exceptions occur during the execution of a program when something unexpected happens. For example, let’s say you are asking the user to input a number in order to perform a division.

In this tutorial, you will learn how to properly handle and raise exceptions in Python. Article describes many types of exceptions, including:

  • NameError
  • TypeError
  • ValueError
  • ZeroDivisionError
  • NotImplementedError
  • FileNotFoundError

Code examples, including ones with more complex multiple exceptions, are present. Good read.

[Read More]

Development of a REST API in Spring Boot Framework

Categories

Tags architecture-and-apis

Dario Carrasque wrote post blog on topic of the evaluation of frameworks to develop REST APIs to satisfy requirements of modularity and availability.

Author describes process of framework selection including considering various languages, e.g.: Python, Scala, and Ruby. A backward compatibility with core Java applications was the most important requirement, though.

They considered 3 frameworks:

  • Spring Boot
  • Play
  • Lagom

Read, how and why they decided to go with Spring Boot and what were their criteria for selection process. Examples of the code including hint to swagger documentation in article.

[Read More]

How to better organize your React applications?

Categories

Tags software-engineering frontend-and-mobile

Alexis Mangin deep dive on a good architecture for very large web applications in React. if you didn’t start with a good architecture, it can become difficult to keep your code organized.

Author spent time comparing solutions from Nathanael Beisieg and others but decided to go with his own approach. He also compares common boilerplate projects on GitHub. They often organize all the files by type, but many of them do not account for application grows; and it often becomes difficult to maintain it later.

He takes liking in Ember and it’s ability to structure your project by features, instead of by type. Author decided to group all related features together, and nest them as needed. Recommended way is to create services to manage all api requests.

Code with examples in ReactJS provided. Excellent article!

[Read More]

Explaining Programming to 6 Years Old Kids

Categories

Tags software-engineering leadership-and-career

Tomek Kaczanowski journey into explaining what you do at work to a group of 6 years old kids, how to explain programming to them in engaging and funny way. Interesting article built on ideas for a successful presentation:

  • Keep children them engaged by asking questions and drawing (big drawing, drawing while talking).
  • Build upon what they already know (YouTube, laptops, tablets, DVDs).

All children new about laptops of their parents, smartphones, tables and often consumed content over the internet. Author explained in simple ways (drawings) what computers are, how they work, that they use a funny language which consists only of zeros and ones. Methods which worked are also mentioned, e.g.:

  • Drawing pictures is the right way to go - grabs their attention.
  • Be prepared for repeating things over and over again.
  • Write carefully - e.g. they will protest when you write 1 so it looks like 7.
  • ~25 minutes is enough; their attention span is simply too short.
  • There is no point in correcting them about technical details, important is to understand the concept.

Very interesting and educational.

[Read More]

Functional Programming for Android Developers

Categories

Tags software-engineering backend-development frontend-and-mobile product-and-design

Anup Cowkur post on topic: why not use some of the concepts and techniques from the functional world in Android programming.

The term Functional programming is an umbrella for a range of programming concepts which the moniker doesn’t quite do justice to. At it’s core, it’s a style of programming that treats programs as evaluation of mathematical functions and avoids mutable state and side effects. Declarative, Explicit and Concurrent code that is easier to reason about and is designed to avoid surprises.

Authors then describes how to use pure functions. A function is pure if its output depends only on its input and has no side effects. Code examples demonstrating functional programming in both Java and Kotlin are included… Good reading.

[Read More]

JavaScript — A First-Class Language At Last

Categories

Tags frontend-and-mobile

Tom Goldenberg nice article pointing out why JavaScript deserves respect. JavaScript the most widely used computing language.

However, JavaScript still doesn’t command the same respect that other languages do. JavaScript is increasingly being used in aspects of software development other than stylistic effects — for example, backend tasks, web servers, and data processing. JavaScript “is the result of evolution, not design…”

Author analyses growing ecosystem, job opportunities for JavaScript engineers in US and also considers criticisms of JavaScript. JavaScript has come a long way in the past 5 years. In the last 2 years, the technology for sending JavaScript code to the browser has improved dramatically (see: webpack).

Although JavaScript may have started as the language of the browser, it is becoming more ubiquitous in all aspects of computer science — the web, mobile, IoT, and back-end services… Good reading.

[Read More]

Build a simple Twitter Bot with Node.js in just 38 lines of code

Categories

Tags backend-development ai-and-machine-learning frontend-and-mobile

Brandon Morellinot complicated tutorial aiming to build a simple Twitter favorite bot with Node.js in just 38 lines of code.

You will learn how to create a Node.js application that interacts with the Twitter API. In this application, the API will allow us to search for tweets, and favorite the tweets that our application finds. It will guide you how to register your app with Twitter.

It will also teach you how to create project and package.json in Node.js. The workflow of the bot app is very simple" first, you search for Tweets, then you select one and favorite it.

The full app.js file is provided on GitHub. And there is also second article in the series which will show you how to do a lot more with Twitter API.

[Read More]