Changing Of The Guard


I’ve just replaced GOTSLoadBalancer (a SpringBoot application) with LoadBalancerApplication, which I wrote in Node/Express and I’m very confident that I made the right decision.

Deployed live some moments ago.

I fully expect Node’s natural qualities to shine through as a load balancing application, especially since I’ve recently tried hammering Node with JMeter and it’s held up perfectly.

It will certainly handle more load than the services it is load balancing for, so that’s fair enough.

Anyway, it’s 1.32am, I’m knackered and I’ve got to go. Happy Easter.



Consider Yourself Dockerized!


I’ve just managed to “Dockerize” my base SpringBoot application, so I’m now able to use this as a template for future services. I’d wasted some time following various confusing tutorials, but it turned out to be very simple in the end.

Create Dockerfile

Create a new file in the root directory of the SpringBoot app (on the same level as src folder, pom.xml etc.) simply called Dockerfile (no extension) and put in the following:

FROM java:8
ADD target/MyBuiltApp.jar app.jar
ENTRYPOINT ["java","-jar","app.jar"]

Build Docker Image

Instruct Docker to build the image, and tag it as mydockerizedservice:

NOTE: You must actually build your application in Maven first, otherwise there might not be anything to find at target/…

$ mvn -U clean install
$ docker build -t mydockerizedservice .

Run Docker Container

To initially run a new container from this image:

$ docker run -p 8765:8080 -t mydockerizedservice

To stop and re-run this container:

$ docker ps

This gives us the following Container ID for our service: 51ed23ae9b5f

Now stop the service:

$ docker stop 51ed23ae9b5f

And re-start the existing Container:

$ docker start 51ed23ae9b5f

And that is pretty much it. I’m no Docker expert, evidently, but I’m happy to answer any questions related to this. And I’m spent.



Signed Up To AWS


I’ve just taken the plunge and registered an Amazon Web Services account. It’s time to see what all this cloud nonsense is all about.

I’ve just been playing around with a basic Lambda function for now, just finding my feet really. I’ll be looking for some decent tutorials today, to get some ideas on what would be valuable to learn/implement, and what services are worth tying together.

I definitely like the idea of leaving the infrastructure, high availability, scalability etc. concerns to another entity, and just focusing on the code (and minimising the cost of running said code).

Let’s see where this goes anyway, I might be considering migrating my other services over to AWS soon if I’m suitably impressed with its capabilities.



Balancing The Load


I’ve implemented the first version of a load balancer, called GOTSLoadBalancer, that I’ll be using for (multiple instances of) GeeOhTileServer, and I’m pretty pleased with it.

It’s a SpringBoot app that catches all requests, queries which of the current selection of GeeOhTileServer services are least busy (based on an API which returns current ‘total requests per minute’), and forwards the request verbatim.

I’ve already got it running in production, with just a single instance (due to VM memory limitations), but I’m 100% happy with its function.

I’m definitely pleased to have addressed any worries regarding the scalability of GeeOhTileServer at this point.