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 ]

Getting started with SwiftIO


Tags swiftlang ios app-development robotics

SwiftIO is an electronic circuit board that runs Swift on the bare metal. It can control sensors, displays, lights, motors and more. By Tibor Bödecs.

MadMachine’s SwiftIO board is an Arduino-like system, but it can run Swift code natively on the hardware. Swift is a great programming language for education purposes, it is a modern language with a JavaScript-like syntax that is easy to learn and understand. Swift is safe and efficient, this combination makes it a perfect candidate for embedded systems. The SwiftIO board enables us regular Swift / iOS developers to build IoT projects using our favorite programming language.

The board itself has a small footprint, it’s just about 1,57” x 2,36” (4cm x 6cm) big.

It’s quite a powerful microcontroller. It is definitely the most affordable Swift language learning device. It can be ideal for STEM education purposes for students who want to see how to build electronic circuits and get some basic Swift programming skills at the same time.

The article main parts:

  • Technical specifications (Arm® Cortex®-M7 core @600MHz)
  • Ports, communication, architecture
  • The SwiftIO environment
  • Installing the MadMachine SDK & CLI
  • The MadMachine toolchain
  • The SwiftIO framework
  • Using Xcode

… and more. You can build some really fun stuff with SwiftIO, it’s a perfect tool for learning how electric circuits work. Good read!

[Read More]

Pulsar advantages over Kafka


Tags apache devops queues event-driven messaging app-development

Recently, author has been looking at Pulsar and how it compares to Kafka. A quick search will show you that there is a current war between the two most famous open source messaging systems. By Javier Ramos.

Author focuses on the Pulsar advantages and give you some reasons why you should consider it over Kafka. But let’s be clear, in terms of production usage, support, community, documentation, etc; Kafka clearly surpasses Pulsar according the author.

Pulsar is very flexible; it can act as a distributed log like Kafka or a pure messaging system like RabbitMQ. It has multiple types of subscriptions, several delivery guarantees, retention policies and several ways to deal with schema evolution. It also has a big list of features …

Pulsar architecture

Source: https://pulsar.apache.org/docs/en/concepts-architecture-overview/

The article then describes:

  • Kafka in a nutshell
  • Kafka pain points
  • Pulsar in a nutshell
  • Pulsar features
  • Pulsar hands-on
  • Akka streams example
  • Pulsar function example
  • Pulsar advantages
  • Pulsar cons
  • Pulsar use cases

Competition is good, it drives innovation. Kafka is a mature, resilient, and battle-tested product used all over the world with great success. However, Pulsar is still quite immature and I would be careful before introducing into production. Perform analysis, do benchmarks, research and write proof of concepts before incorporating Pulsar into your organization. Nice read!

[Read More]

Angular push notifications: complete step-by-step guide


Tags angular web-development frontend app-development

In this post, we are going to go through a complete example of how to implement Web Push Notifications in an Angular Application using the Angular Service Worker. By Angular University.

Note that these are the exact same native notifications that we receive for example on our mobile phones home screen or desktop, but they are triggered via a web application instead of a native app. When well used, Push notifications are a great way of having our users re-engage with our application.

You will also learn along the way how Push Notifications work in general, as we follow and explain the complete flow that a given notification follows.

The article content is split into:

  • How do Push Notifications work?
  • Browser Push Service Providers
  • What is a VAPID key pair?
  • generating a VAPID key pair using node webpush
  • Subscribing to Push Notifications
  • showing again the Allow/Deny Notifications popup
  • Understanding the PushSubscription object and its properties
  • How to use the Push Subscription?
  • Sending Push Notifications from a Node backend
  • Push Notifications In Action - Demo
  • Source Code + Github Running Example (complete Angular PWA)

When the Push service receives the message (e.g. Firebase Cloud Messaging), it will know to which browser instance to forward the message to based on the unique url of the endpoint. Please, also check a video channel with free Angular videos. Perfect!

[Read More]

Migrating our Ansible roles to a collection


Tags ansible web-development devops web-development app-development

An article by Sebastian Gumprich about their experience with decision to move their existing Ansible roles for Linux, ssh, nginx and MySQL into an Ansible collection. Collections are a distribution format for Ansible content that can include playbooks, roles, modules, and plugins.

Having only one repository for all roles means we don’t have to duplicate code. We have one common test-suite for all roles that works the same for every role. Also Collections are the future, as there is possibly no support for roles in the next version of Ansible Galaxy (see ansible/galaxy_ng#58).

However, collections are only supported from Ansible 2.9 and onwards. And Ansible 2.8 is still supported (https://docs.ansible.com/ansible/latest/reference_appendices/release_and_maintenance.html#release-status). This means we need to support the separate roles until 2.9 is the oldest maintained release.

The guide then describes:

  • The plan
  • Problems and other interesting things
  • The Result
  • The future

The hardest bug we encountered was a problem with AppArmor and MySQL on recent Ubuntu distributions. Here’s the bug: https://bugs.launchpad.net/ubuntu/+source/mysql-5.7/+bug/1610765. A faulty AppArmor profile prevents MySQL from starting because AppArmor blocks access to MySQL’s configuration files. And Github Actions run on a Ubuntu 18.04 virtual machine with AppArmor enabled. So I wondered why the role does work when running molecule locally (btw: I use Arch) but not in the CI-pipeline. It took some days to figure this one out. However once I found out the reason for this, the solution was found much faster. Robert de Bock also had this problem and fixed it here

Nice one!

[Read More]

How to keep NgRx state on refresh in Angular


Tags frontend nodejs angular javascript web-development

It’s a common requirement: persisting NgRx state in order to load it back up when your Angular application is restarted. This process of populating an empty object with domain data is called re-hydration. While it’s common to persist the store data to the browser storage (mostly localStorage), you might also re-hydrate from a server-side cache. By Nils Mehlhorn.

There are some pitfalls to watch out for when applying this pattern. For one thing, you should take care not to store sensitive data in potentially insecure storages. Consider factors such as multiple users working on the same machine. Additionally, the state you’re storing can become outdated. Consequently, you might incorporate techniques like validation and partial re-hydration.

The article pays attention to:

  • Persist with Redux DevTools
  • Re-Hydration Meta-Reducer
  • Re-Hydration Meta-Reducer + Effects

You will find detailed code examples for each of the discussed topics. The only disadvantage To learn about advantages and disadvantages of re-hydration follow the link to full article. Nice one!

[Read More]

A sysadmin's guide to containerizing applications


Tags software linux devops how-to cio

Curious how to containerize your Linux applications? Learn by example, and understand the challenges of various application types and how to overcome them. By Scott McCarty (Red Hat, Sudoer).

Author’s admission how he just couldn’t find time to convert his personal Linux services. So don’t feel bad if you are still staring, longingly, from afar, at other people’s fancy containerized services, as author has only recently gotten over the hump himself.

He wants to share his technical solution and break down his conscious design decisions. He hopes it will help you move your own services into containers. The goal is to give you some solid, concise, and technical guidance.

The author will deal with the three services: WordPress, MediaWiki, Request Tracker.

The article describes the process, how to consider one of industry accepted methodologies (Lift & Shift, Refactor, Rewrite), how to analyze architecture, security, and performance. You will get the links to further reading. Really good!

[Read More]

Stateful serverless on Google Cloud with Cloudstate and Akka Serverless


Tags akka streaming scala serverless gcp

In recent years, stateless middle-tiers have been touted as a simple way to achieve horizontal scalability. But the rise of microservices has pushed the limits of the stateless architectural pattern, causing developers to look for alternatives. By James Ward, Developer Advocate at Google Cloud and Viktor Klang, Head of Cloud Engineering and Deputy CTO at Lightbend.

Stateless middle-tiers have been a preferred architectural pattern because they helped with horizontal scaling by alleviating the need for server affinity (aka sticky sessions). The stateless model pushed all “state” out of the middle-tier into backing data stores. In reality the stateless pattern just moved complexity and bottlenecks to that backing data tier.

New patterns are now emerging which fundamentally change how we compose a system from many services running on many machines. One approach, is to build an event-driven system that co-locates partitioned data in the application tier, while backing the event log in a durable external store. To take the fraud detection example, this means a consumer can receive transactions for a given customer, keep those transactions in memory for as long as needed, and perform real-time analysis without having to perform an external query. Each consumer instance receives a subset of commands.

Commands and queries in event driven system

Source: https://cloud.google.com/blog/topics/developers-practitioners/stateful-serverless-on-google-cloud-with-cloudstate-and-akka-serverless

By separating commands and queries we can easily achieve end-to-end horizontal scaling, fault tolerance, and microservice decoupling. The new Cloudstate open-source project attempts to enable building more approachable programming and operational models. Cloudstate’s programming model is built on top of protocol buffers (protobufs) which enable evolvable data schemas and generated service interaction stubs. When it comes to data schemas, protobufs allow you to add fields to event / message objects without breaking systems that are still using older versions of those objects.

You will also get video that walks through the full fraud detection sample and find the source for the sample on GitHub. Exciting!

[Read More]

What is Ask Pattern in Akka?


Tags akka streaming scala programming

In Akka, ask is a pattern and involves Actors as well as Futures. Ask is used to sends a message asynchronously and it returns a Future which represents a possible reply. If the actor does not reply and complete the future, it will expire after the timeout period. After the timeout period, it throws a TimeoutException. By Purva Agrawal.

This is short and straight to the point article reading about:

  • Communication among Actors
  • What is Ask pattern?
  • Using the Ask pattern
  • Combining Ask and PipeTo patterns
  • Ask pattern: Do’s and Don’ts

In Akka, actors communicate with each other by sending and receiving messages. The messages can be sent in many patterns like: Fire and Forget, Request and Response. Good read!

[Read More]

Modern Distributed Data Architecture with Event Streams, Stream Processing and Derived Data


Tags cloud streaming software-architecture big-data cio data-science

Some of the most interesting projects I worked on at LinkedIn involved building large scale real-time pricing and machine learning products. They required crafting fault-tolerant distributed data architectures to support model training, forecasting and dynamic control systems. By Luthfur Chowdhury.

None of this work involved a traditional relational database. Instead event streams, derived data and stream processing became the core building blocks.

The author worked with teams which built entire multi-billion dollar products on top of these architectures. The experience gave hom a new perspective on how organizations can think about their data infrastructure in terms of data flows.

The article deals with:

  • Logs and Event Streams
  • Loose Coupling of Systems
  • Unbundling the Database
  • Data Integrity and Fault Tolerance
  • Data Quality, Integrity and Security

Log based data integration promises to improve data availability across the breadth of an organization. It creates the ability to democratize data access and analysis. With stream processing systems we are able to work with continuous flow of data in real-time using composable components. The links to further reading is provided. Nice one!

[Read More]

In search for future of cloud storage, researchers look to holographic storage solutions


Tags cloud performance servers miscellaneous machine-learning

Data storage has always been a key tenet of compute, and with the massive growth in cloud compute, the demand for cloud data storage has opened an avenue for both revisiting prior technologies and developing new ones. It is projected that around 125 zettabytes of data will be generated annually by 2024, and storing this in a cost-effective way is going to be a big challenge. By Benn Thomsen , Senior Principal Researcher Dushyanth Narayanan , Senior Principal Researcher Ant Rowstron , Distinguished Engineer / Deputy Lab Director.

The cloud has also changed the way we think about compute and storage. In the cloud, services are virtualized. In cloud data storage, for example, customers pay for storage capacity and access rate rather than for physical storage devices.

The massive growth we see in the cloud today has been largely powered by advances in integrated electronics. Looking forward, however, these advances are stalling.

In the article you will find more information on:

  • How does holographic storage work?
  • So why revisit holographic storage as a solution for the cloud?
  • Bringing holographic storage to the present with commodity hardware and deep learning
  • Looking forward: Scaling up optical storage solutions for the cloud

It is exciting to see how the team has exploited machine learning on high resolution images to do in software what previously required expensive optics or could not be done at all, pushing the holographic storage performance beyond the state of the art. Great!

[Read More]