• Posted on

    Testing Active Record Integration in Ruby Gems

         When I was writing the expiry calculator gem (extracted from a license management system), the library’s main logic has some sort of integration with ActiveRecord, and I needed to verify that the easy way.

         Mocking the built-in active record connection pool and tables mapping showed to be cumbersome and may not ideally allow to validate the intended behaviour. Luckily, I found pieces in SO and Github to do the unit testing in few simple steps, with on the fly db (Sqlite). I have put it together in the following guide, polished for Rspec with ad-hoc migration methods.

  • Posted on

    A Short Essay on Popular Virtualization Technologies

    This post reviews four main virtualization options in short.

    💡 VM technologies are essentially considered by people when addressing on-premise use cases or when building DR for data centers.

    VMware Virtualization

    • Started at (2003).

    • Offers type-1 hypervisor that runs on bare-metal called ESXi with minimum disk image footprint (32MB), with resources, storage, and networking capabilities, and UI console (DCUI).

  • Posted on

    Reflections on IaC using Terraform - Part II

    This post is a follow up on the previous one where I discussed the concept of infrastructure as code and Terraform. In this post, I will provide few useful notes I took while working on IaC projects, with examples to illustrate the techniques on two of the public providers (AWS / Oracle).

  • Posted on

    On Amazon Builders' Library

    I have enjoyed reading this piece on stability and reliability by Colm MacCárthaigh. It is part of a concise and valuable series by AWS about the art of system operations collected under the name “Amazon Builders’ Library”.

    The comparison between coffee urn and computers when building reliable operational model is perfect and up to the point. Then, three characteristics taken from this analogy are observed: 1. have a simple constant function that does not scale based on load stress solely, 2. no different modes or operational branching, 3. anti-fragility which is the preparations that hold systems reliable when most needed. The author mentions the coined term for these principles on reliability: “Constant Work Patterns”. Route 53 and S3 are presented as use cases that fit and demonstrate the model.