In early and mid-1990s, object-oriented programming (OOP) revolutionized software development by dividing applications into modular components as objects and classes. Today, the rise of microservice architectures and containerization technologies enable a similar revolution in developing distributed systems and SaaS/PaaS products. “Containers” and “container images” are analogus to “objects” and “classes” in OOP, respectively, as a unit of development and deployment in distributed systems. In this paper, the authors argued that just like Design Patterns for Object-Oriented Programming, codified in the famous “Gang of Four” book, some Design Patterns have emerged for Container-based Distributed Systems. In the same paper, the authors attempted to do something similar, documenting the most common patterns and their usage.
Groovy Hook Script and Jenkins Configuration as Code
This post discusses Groovy Hook Scripts and how to use them for full configuration-as-code in Jenkins with Docker, Pipeline. This can help us to set up local environment for developing Jenkins Pipeline libraries and to evaluate various Jenkins features.
`src` Folder in Jenkins Shared Library
This post reviews best practices when we implement Groovy classes and/or static Groovy methods, in src
folder as opposed to vars
folder, for Jenkins Shared Library.
TCP Ping
This post explains a work-around for pinging hosts in network where ICMP requests are blocked.
Jacoco in Maven Projects
This blog post goes over some recipes for adding code coverage report to Maven-based projects with Jacoco.
Keep Gruntfile Clean With Load-grunt-config
In this post, we look into how to keep our Gruntfile clean and tidy. By keeping our Gruntfile clean and tidy, it is easier for us to refine and improve the Grunt build process with its numerous plugins.
DSL Implementation in Groovy
Domain-Specific Language is a mini language for a specific problem and/or in a narrow context. For example, internally used automation tools usually define some small DSL for configuration and most users understand the context and what DSL offers.
This blog post offers my simplistic view of how an internal DSL is implemented in Groovy via closure delegation. It shows the progression from standard Java-like implementation -> its fluent version -> final DSL form. This might help undrestanding the inner workings of a DSL such as Jenkins’s Pipeline steps. There are probably more advanced methods/frameworks for creating DSL. However, those are not in the scope of this post.