Latest Posts

Install MongoDB 7 Community Edition on Rocky Linux 9

In this post we go through the process of installing MongoDB 7 on a Rocky Linux instance. This includes the basic setup, enabling authentication and creating an admin user.

Continue Reading

Minimal Rocky Linux 9 Virtual Box image for Java development

On June 30, 2024 CentOS 7 will reach end of life. Time to use Rocky Linux 9 as base distribution for my Virtual Box images. In this post I describe a step-by-step process to create and configure the initial Virtual Box image.

Continue Reading

Count bytes while writing to a file using CountingOutputStream from commons io package

Sometimes it is useful to know how many bytes have already been written to an output stream in Java. In this post we will use CountingOutputStream to achieve this goal easily.

Continue Reading

Process big JSON files using steam based JsonParser

Most JSON data can be parsed in memory, but there are some edge cases when we have to process big data files - e.g. a database export or a data from a third party provider. For these scenarios the Jackson library provides stream-based read and write mechanisms to handle huge files efficiently.

Continue Reading

Read and write JSON data using Jackson low-level methods

Most of the time it is beneficial to parse and modify JSON data using an underlying Java object. But, there are some scenarios where parsing the entire data structure is not necessary and thus, low-level read and write methods from the Jackson library might be more efficient. In this post I will evaluate how these low-level methods can be used.

Continue Reading