Alex Collins – Blog

Things I'm learning; lessons or otherwise…

Category Archives: Programming

Docker Desktop for JEE /Grails Development

by atc on May 11, 2014, no comments

With all the hype surrounding Docker I thought it only prudent to investigate and give it a try. Holy cow it’s awesome; here’s an example of why. I routinely want to get a decent Grails development environment up and running, and VMs seem one way of doing so. Having a clean, fresh install can be […]

Holiday Hack: reading Java class files

by atc on March 24, 2013, 2 comments

I spent a week by the pool in Egypt with my girlfriend, relaxing and…hacking. The lack of WiFi meant I had to rely on instinct and intellect to get me through my pet project and it proved a worthy exercise in problem solving and perseverance… I had the crazy idea of practicing my C programing […]

Hacking with JDK8 Lambda

by atc on March 15, 2013, no comments

So being a functional programming fan I ventured into the JDK 8 binaries and started playing with the myriad of changes relating to the introduction of Lambdas in JDK 8. All my code’s now on github and it’s work in progress, but take a look and contribute/comment if you care to.

The final keyword in Java

by atc on January 16, 2013, 3 comments

Whilst many will frown at the use of the final keyword in Java code, I find it a breath of fresh air. Perhaps it’s that I tend to lean on the side of caution, conservatism and safety when it comes to code: immutability being one of many examples of such. In this post I argue […]

Back to IntelliJ IDEA

by atc on December 23, 2012, no comments

Like hundreds of others I bet, I purchased an upgrade personal license for Intellij IDEA 12 in their “end of world” sale. I’d heard good things about this latest version, most importantly significant improvements in the area of performance. I used IntelliJ for about 2 years a while back and was really happy with it […]

Clojure’s Concurrency: easy atoms

by atc on August 5, 2012, no comments

Clojure’s atoms let one transactionally and atomically store values. When one uses an atom, Clojure manages the mutation of the value and guarantees atomicity. Such a feature is very useful in a highly concurrent application. Much like Java’s Atomic* classes, but somewhat more powerful. This is a brief introduction. Atomic Values To define an atom, […]

Clojure’s Concurrency: Futures and Agents in Harmony

by atc on July 29, 2012, no comments

I’ve previously written on the wonders of Clojure’s agents, giving the programmer a wonderfully easy way of writing asynchronous code with very little effort. Here’s a slightly more complex example for those wanting more context. Combining Futures and Agents We’ll use this (deliberately poor) inefficient find-primes in a (future) to allow for asynchronous processing in […]

00 (agent) – Clojure’s Concurrent Agents in action

by atc on July 29, 2012, 2 comments

or Clojure’s concurrency agents – a simple example Clojure has some fantastic concurrency idioms. Agents are but one example of what’s available to the JVM lisper — alongside refs, atoms and vars — that make concurrent programming very easy. I thought I’d articulate my understanding to help embed the knowledge but to also provide a […]

Clojure LIX Parser

by atc on June 17, 2012, no comments

I’m loving the challenge that Clojure (or LISP in general) is giving me. I have to approach problems in an entirely new way. One of my go-to challenges when learning a new language is to write a LIX parser and I’ve just finished it in Clojure. Of course, it’s open source and available on Github.