The Doomsday rule

The Doomsday rule This is a repost of an old article :) A few months ago I came across the name of J. H. Conway: you’re wondering who the hell he is. Well, Conway is an English mathematician active in the theory of finite groups, knot theory, number theory, combinatorial game theory and coding theory. He has also contributed to many branches of recreational mathematics and he is the invention of the Game of Life....

December 23, 2022 · 9 min

A monadic reasoning around function composition in Golang

Introduction Function composition is something we as developers do every day, more or less. This concept come from Mathematics: if you search on Wikipedia, you find out that function composition is an operation that takes two functions \(f\) and \(g\) and produces a function \(h\) such that \(h(x) = g(f(x))\). In this operation, the function \(g\) is applied to the result of applying the function \(f\) to the input \(x\). That is, the functions \(f: X \rightarrow Y\) and \(g: Y \rightarrow Z\) are composed to yield a function that maps \(x\) in \(X\) to \(g(f(x))\) in \(Z\)....

September 1, 2022 · 10 min

?(DRY(KIS(afe)S)) => CF(ALB+TLS+SM);

Intro If you work with AWS, you might be involved in building infrastructure to enable some of your customers (both internal and external) to use a particular service, or just to try one of the hundreds open-source application available on Github. Furthermore, most of the ML/AI tools are shipped in docker containers and the philosophy -> if it runs on docker, it runs everywhere has been spread up to the highest level of management (nice, but… sometimes dangerous 😅 ed....

February 1, 2022 · 11 min

How to: create a fleet of container-based-go-lambda with one command

Introduction As you might know, at the re:Invent AWS recently announced the capabilities of running Lambda by getting the code directly from a docker image you provide, as illustrated here. Moreover, they also announced the Amazon ECR Public and Amazon ECR Public Gallery that you can reach at https://gallery.ecr.aws/. And this was pretty much my reaction: What you might need to know before begin First of all: keep calm, because there’s already a Github Repo to build an entire fleet of microservices - with their respective ECR-based repository - with only one command from the shell....

December 12, 2020 · 6 min

My team run VSC in the browser and they are just fine - Part II

Introduction This is a repost of an old article :) In the first part of this series - I run VSC in the browser and I was just fine - I wrote many stupid things around the possibility of having a VSC server instance running inside AWS over a simple, immutable, ec2 instance. The template {that can be easily deployed by a Lambda function [that can be easily deployed behind a route53 record (that can be easily placed as the endpoint of a custom Slack action)]} let you start your IDE and code from wherever you would like to....

October 22, 2020 · 15 min

I run VSC in the browser and I am just fine - Part I

Introduction This is a repost of an old article - that actually also inspired my talk of the last year at FullStackConf2019 :) Serverless and managed things are the best choices if you don’t want to deal with infrastructure (3 2 1: fight) buuuuut…even immutable things are not so bad for this purpose - at least, if they are immutable for real 🤣 Today I wanna talk about a useful way to run an instance(s) of VSC server in AWS and code from everywhere (yes, even your iPad): let’s start!...

September 21, 2020 · 10 min

A Golang Turing machine library

Preamble This is a repost of an old article :) In 1962, Hungarian mathematician Tibor Radó introduced the Busy Beaver competition for Turing machines: in a class of machines, find one which halts after the greatest number of steps when started on the empty input. Even if it could seem trivial, the Busy Beaver competition has implications in computability theory, the halting problem, and complexity theory. I decided to use GoLang to implement a Turing machine library and accomplish three goals: first, having a Turing Machine model to play with for learning purpose; second, learning how to use interfaces and the factory pattern, other then testing package to test my code and let it be more flexible for future enhancement (at least I hope!...

May 20, 2020 · 9 min

?(DRY(KIS(afe)S)) => CF(ALB+TLS+SM);

Intro If you work with AWS, you might be involved in building infrastructure to enable some of your customers (both internal and external) to use a particular service, or just to try one of the hundreds open-source application available on Github. Furthermore, most of the ML/AI tools are shipped in docker containers and the philosophy -> if it runs on docker, it runs everywhere has been spread up to the highest level of management (nice, but… sometimes dangerous 😅 ed....

February 1, 2020 · 11 min

A monadic reasoning around function composition in Golang

Introduction Function composition is something we as developers do every day, more or less. This concept come from Mathematics: if you search on Wikipedia, you find out that function composition is an operation that takes two functions \(f\) and \(g\) and produces a function \(h\) such that \(h(x) = g(f(x))\). In this operation, the function \(g\) is applied to the result of applying the function \(f\) to the input \(x\). That is, the functions \(f: X \rightarrow Y\) and \(g: Y \rightarrow Z\) are composed to yield a function that maps \(x\) in \(X\) to \(g(f(x))\) in \(Z\)....

January 16, 2020 · 10 min

The await/async concurrency pattern in Golang

Introduction First of all…happy new year! I decided after a while to come back online speaking about Golang. In this post, I will focus on parallelism and concurrency and how you can achieve the same behavioral pattern you can achieve with Node.js using await/async statements, without the difficulties (hopefully) of dealing with Single Threaded Event Loop and these primitives (that, btw, keep things really simple). Let’s start! A bit of confusion Concurrency and parallelism are two terms that are bound to come across often when looking into multitasking and are often used interchangeably....

January 2, 2020 · 10 min