Photo by Anja Junghans on Unsplash

What is Thymeleaf?

Thymeleaf is a dynamic templating engine for serverless applications like Micronaut or Spring. It is really useful if you want to create non static content that gets generated dynamically. Or with the words of the official website:

Thymeleaf is a modern server-side Java template engine for both web and standalone environments.


A problem that i recently had was, that i needed to read the contents of some zipped files, which i didn’t wanted to unzip into temp, because i really only needed the content as a String. I had some Zip files, which contain a Metadata.yaml file with some informations like id or title in it. I wanted to read the content of the Metadata.yaml file and put the values into a data class, which is then stored inside a HashMap.

Some of my files don’t contain the Metadata.yaml file, so to compensate that, we use the documentTitle as the id…


Photo by Tom Crew on Unsplash

Recently I had a problem, where I should get the last successful build hash of a Jenkins Job. For this I used a simple json api call via http and got a HttpResponse back. Now, the problem was, that I somehow needed to extract the value for the hash out of this HttpResponse. The first thing that came in mind was just to use substrings, but i recognised that this approach is not that save and future proof, if somebody changes something on the pattern of the json output. I needed a better, yet more programmatically solution to this.

First…


Photo by Mildly Useful on Unsplash

Yesterday I had the problem, that I needed to log some events of my application in different log styles (different color, other order of information). I still wanted to use the same logger and didn’t wanna create a new one for each style. How to do that? With custom log levels.

What are log levels?

Log levels are used to differentiate different logs based on their importance. There are already some pretty useful log levels predefined by log4J.


Photo by Randall Ruiz on Unsplash

A few days ago, I had a problem with running git commands inside of my Kotlin application. First of all, I used the jGit api to run git directly in my code. The problem was, that I would need to handle all the authentication process by my own, regardless if the ssh key or password is already defined on my machine. This meant that we would need to read in the password and username for the git account every time someone uses my tool. The only way to get a password as a user input that I found was over…


Photo by Petri R on Unsplash

Recently I had the problem, that I needed to log some warnings for my application. Since I normally work test driven, it was pretty important to me, that I could create some unit tests for it. My test engine is JUnit 5. I found the logging library Log4J, which has a new name since version 2 (Log4J2) and used this one.

What is Log4J2?

Apache Log4j 2 is an upgrade to Log4j, which is pretty common in the industry, that provides significant improvements over its predecessor, Log4j 1.x, …


Photo by David Knox on Unsplash

In this article, I want to talk about what Helm is, how to install and use it, and how to push its images to artifactory. This sounds like a whole lot of stuff, it actually is, but it is a really important step in CI/CD, so I will try to explain it as good as I can.

What is Helm

In short, Helm is a package manager for Kubernetes that allows developers and operators to more easily package, configure, and deploy applications and services onto Kubernetes clusters.

Helm has the opportunity to set variables for Kubernetes, which you can then assign to your…


Photo by JJ Ying on Unsplash

A few days ago, I needed to create a new Project without any templates from scratch, that should be able to use Micronaut as a serverless Framework. My application is written in Kotlin. In the end, It should work like a webserver, that gets deployed on Kubernetes. First of all, There are three key components. The first one is the Application itself. This application needs to be converted to a docker image. The next part is the Pipeline. It needs to run some automated tests and build the whole image if the tests are successful. It should also push the…


Photo by Steve Johnson on Unsplash

In this article I want to talk about mocking server responses with Wiremock. How would you test a function or a whole class, that uses a http request to get its data and processes it? You would need an actual test server with actual data on it to test it. This data should not be changed anymore, because tests would be depending on it. This would be a really bad solution, because you needed to configure a new dataset for every test and end up with a by itself useless server with even more useless data on it. …


Photo by alevision.co on Unsplash

This Article is about using Jenksins REST API for getting information about the last successful build. Jenkins has no official Java/Kotlin API. This means, that we either have to use some third party Github developers java API, or just to use Jenkins REST API, that is guaranteed to work.

The Problem

I have a Jenkins Instance, on which different jobs are running. I need the git hash of the last successful build for another project.

What can I do? I can go to Jenkins, scroll down to the last successful build of a branch and click on it. The git hash is…

Manserpatrice

Developer Experience Engineer

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store