Forget Writing Code.
Start Building Software.

Get weekly inspiration to kickstart your building journey and transform your ideas into digital reality.

Spring Boot default metrics

Spring Boot 2’s actuator module provides monitoring and management capabilities for your application, and includes the Micrometer metrics collection facility. Micrometer comes preconfigured with many useful default metrics, and also includes the ability for you to configure your own. In this article we’ll run through the most important default metrics provided in Spring Boot, and how you can use them to more effectively highlight problems within your application. Spring Boot Actuator and Micrometer overview The Spring Boot Actuator exposes many different monitoring and management endpoints over HTTP and JMX....

Published 22 May 2020 · 10 min read · Tom Gregory

Gradle Project Properties Best Practices

Gradle project properties provide an easy way to customise builds which may need to run differently in certain situations. In this article you’ll learn the most effective ways to use and set properties, along with some common scenarios you might come across in your Gradle project. UPDATED in July 2021 to reflect recent versions of Gradle. Why do we need project properties in a Gradle build? A Gradle project property is a property that can be accessed in your project’s build....

Published 15 May 2020 · 6 min read · Tom Gregory

Unleashing the Spring Boot Gradle plugin

1. Introduction Spring Boot is a framework to build Java applications with minimal boilerplate code required, whereas Gradle is a highly configurable build automation tool. Using Gradle to build your Spring Boot application is a good approach, but the process is made infinitely easier using the Spring Boot Gradle plugin to provide build functionality specific to Spring Boot. In this article, we’ll explore the most common uses case to get up and running with the Spring Boot Gradle plugin, as well as how to customise it to meet your specific requirements....

Published 8 May 2020 · 6 min read · Tom Gregory

AWS SNS for CloudWatch alarm email notifications

Do you want to learn how to setup email notifications to tell you about important events that happen in CloudWatch? In this article you’ll discover how to setup the AWS Simple Notification Service (SNS) to send you emails whenever a CloudWatch alarm gets triggered. We’ll run through a full working example, setting up the alarm and SNS resources, and demonstrating the notifications coming through in real time. What is AWS SNS?...

Published 1 May 2020 · 7 min read · Tom Gregory

Shipping AWS EC2 logs to CloudWatch with the CloudWatch agent

Want to learn how to monitor EC2 logs automatically without having to manually log into servers? Well, in this article we’ll explore how to setup the CloudWatch agent on an EC2 instance to easily stream your logs to AWS. We’ll also setup a simple alarm for when the logs contain certain text that we want to watch out for, all within a worked example. Why would you want to ship your EC2 logs to CloudWatch in the first place?...

Published 24 Apr 2020 · 10 min read · Tom Gregory

Running Docker in Docker on Windows (Linux containers)

If you need to run Docker within a container, or in other words Docker in Docker, this can sometimes be confusing, especially in Windows where it’s not obvious how Docker is setup. In this article, we’ll be lifting the covers on Docker for Windows and exploring how to run Docker commands in containers. Note that we’ll be covering only Linux based containers in this article. UPDATED in June 2021 to use the now default Docker for Windows WSL 2 engine....

Updated 30 Jun 2021 · 8 min read · Tom Gregory

When to use an AWS S3 VPC endpoint

What is an S3 VPC endpoint? To understand what an S3 VPC endpoint is, we first need to know what problem it solves. Imagine we want to get access to S3 from an AWS resource. In the example below, we have an EC2 instance that needs to copy a file from an S3 bucket: This works, because: the EC2 instance is in a public subnet, so has access to the internet therefore the EC2 instance can reach the AWS S3 URL to copy the file from the S3 bucket Public subnets A public subnet is simply one that has a route to the internet....

Published 10 Apr 2020 · 8 min read · Tom Gregory

Deploying a Spring Boot application into AWS with Jenkins (part 3 of microservice devops series)

How to take a Docker image and deploy it into AWS Elastic Container Service.

Published 4 Apr 2020 · 14 min read · Tom Gregory

Building a Spring Boot application in Docker and Jenkins (part 2 of microservice devops series)

How to get a Spring Boot application running in a Docker container.

Published 29 Mar 2020 · 11 min read · Tom Gregory