Inject Page via path using Sling Model

A common use-case is configuring a path to a page via a dialog and then fetch the wrapper Page object to retrieve information about that page. And there is a really easy way to do so. ...

September 27, 2022 · 2 min

Debug Maven plugins

While working on a new project, I ran into an issue when running a Maven plugin connecting to a local web service. The dreaded Service unavailable error message appeared over and over again. As this project had a complicated setup and running the the curl version of this maven plugin was successful I turned on the debug mode of Maven. Only thing you need to do is add the -Xswitch to your maven command....

September 12, 2022 · 1 min

Sneak Preview of Devoxx.be 2022 talks

Disclaimer: This is a static site. The data is pulled from the cfp.dev API at generation time. This means this overview is a snapshot at the time this page was generated. There might be changes to the official schedule that are not yet reflected here! styling might be off as the summary can contain inline styling these proposals have not been written by me these talks have been accepted by the program committee but are not guaranteed....

August 18, 2022 · 148 min

Proper JMS conversion to POJOs

While looking into Azure Service bus with Spring Boot, I stumbled upon a nasty stacktrace caused by an IllegalArgumentException: java.lang.IllegalArgumentException: Property name must not be null So what is going on here? Setup I configured a queue persons on Azure service bus and in my spring boot application I defined a QueueListener using the @JmsListener annotation @Component public class PersonQueueListener { private static final String QUEUENAME="persons"; @JmsListener(destination = QUEUENAME) public void receiveMessage(Person person) throws JsonProcessingException { log....

June 14, 2022 · 3 min

Mockaroo Intro - Generate Person Data

As I’m looking into GraphQL and Spring Boot, I needed some test data. I didn’t feel very creative but I didn’t want to settle for user1, user2, … either. Enter Mockaroo! Generating Person data Mockaroo offers a wide range of predefined types, such as first name, IBAN, color, email, IP, and what not. For my GraphQL application I just need this: Field Name Field Mockaroo Type firstName First Name lastName Last Name email Email Next I set the number of rows to 10 and the format to JSON....

January 10, 2022 · 1 min

Reduce docker ps Output Clutter with AWK

I’m a fan of docker, especially with my brand new macbook - spinning up loads of containers is always fun 😀. However when listing the containers, things get a bit unclear. Check the following output: CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES d52c11b67cfe docker.elastic.co/elasticsearch/elasticsearch:7.13.2 "/bin/tini -- /usr/l…" 2 hours ago Up 2 hours 0.0.0.0:9200->9200/tcp, :::9200->9200/tcp, 0.0.0.0:9300->9300/tcp, :::9300->9300/tcp vb-bo_elasticsearch_1 76fee05889f0 logstash:7.13.2 "/usr/local/bin/dock…" 2 hours ago Up 50 minutes 0.0.0.0:5044->5044/tcp, :::5044->5044/tcp, 0....

July 8, 2021 · 2 min

Summarize Latest Changes In Your Codebase

You are probably familiar with this workflow work on different stories pull requests are approved and merged deploy changes inform the team For the last part, you check your todo list to get a nice description instead of some mysterious ID. You could do this manually, but this is very time-consuming, not to mention mind-numbing. Scripts to the rescue! High level approach Fetch the version information of the environment you want to deploy to....

June 27, 2021 · 3 min

Templating as Automation

In this post, I’ll cover different examples of what I like to call templating. Doing the same over and over again, but only few parts change each iteration. Environment Variables While working on integrating an API, I had to authenticate with a Bearer token in the authentication header. These tokens are typically short-lived, so they change multiple times a day. As part of the integration, I write down the API calls in Typora, a very nice markdown editor....

April 17, 2021 · 3 min

Simple Jackson Deserializer

As I was working on some random data with a ZonedDateTime, it turned out Jackson was unable to deserialize it. How come? Why not use Jackson datetime module? The codebase I was working on, did not support the Jackson datetime module. It was also not possible to add this module as all Jackson related code was provided and the vendor stressed very clearly ‘not to mess things up with other versions’....

March 17, 2021 · 1 min

Automate AEM development

When working with AEM, you’re confronted with tedious work - writing components with dialogs defined in XML, lots of boiler-plating. Ideal for automation! Enter your favorite code generator Yeoman, “the Web’s Scaffolding ToolFor Modern Webapps” is great for this purpose. I came to know this when working on some JHipster project. It’s very easy to define generator (eg. generate an AEM component) using templates (renderscript, dialog, ….) I’ve put things together in the AEM Generator Repo....

February 8, 2021 · 1 min