Beginning Ansible

May 12, 2021

I wanted to spend some more time learning about Ansible, this post covers the setup I created to do this.

VirtualBox

First of all, I created three VMs in VirtualBox. These were all the latest Debian linux, and all were installed from scratch.

Next, I configured these VMs to have ...

NoClassDefFoundError

August 11, 2020

Here's a useful code snippet for tracking down the cause of a NoClassDefFoundError in Java. It'll tell you the actual file that a class was loaded from.

System.out.println(TheNoDefFoundClass.class.getProtectionDomain().getCodeSource().getLocation());

Streams in Java

July 30, 2020

Here's a few examples on how Streams can be used in Java.

package uk.co.drumcoder;

import java.util.Arrays;
import java.util.Collections;
import java.util.List;
import java.util.Optional;
import java.util.Set;
import java.util.stream.Collectors;
import java.util.stream.Stream;

public class Test ...

Testing "Use Current Location"

June 19, 2020

The Use Current Location javascript functions don't work on insecure URLs in current versions of Chrome. This caused me problems as I had a local webserver hosting my site that wasn't protected by https.

There is an exemption when using localhost but this didn't help in my ...

PHP Simple Logger

June 2, 2020

I'm currently working in PHP and for various reasons I can't log to the console, all logging goes into a database. I'd then have to login as an admin to the UI to see these logs, and that's not good enough where the testing needs to ...