About this blog

Millross Consultants is a small independent software development consultancy, focused mainly on JVM development, agile processes and architecture (both monolithic and SOA/microservices).

The blog is a way of sharing things we’ve learned with our colleagues, clients, and potential clients. If you have further questions regarding anything you read on the blog, please contact Jeremy Prime (at the address above). It’s possible, though far from certain, that he will be able to help.

Introduction to CompletionStage and CompletableFuture

2017-02-26 As mentioned previously I decided to expose the API for an async version of the pac4j API via the CompletableFuture class, using this to wrap values which will be determined in the future.

As this work progressed, I learned that some of my default assumptions regarding error propagation in CompletableFuture (strictly CompletionStage) pipelines is incorrect. I’ve decided to document these, along with some exception-handling patterns, but ran into the fact that to do so, I probably needed to write an introduction to CompletableFutures and the CompletionStage API they implement. This article is a basic (and quick) introduction to the CompletableFuture/CompletionStage API, and will lead into subsequent articles on error propagation in CompletionStage pipelines, and approaches to handling exceptions raised during the pipeline processing. Read more

A Brief Introduction to the Vert.x Context Object

2017-01-22 Recently I’ve been looking at the possibility of building an asynchronous version of the pac4j library, with a view to then migrating the vertx-pac4j implementation to use the asynchronous version of pac4j by default.

I’m keen (for obvious reasons) that the async version of pac4j is not tightly coupled to one particular asynchronous/non-blocking framework, I decided to expose the API via the CompletableFuture class, using this to wrap values which will be determined in the future. However, I opted to use the vert.x framework for my asynchronous testing as a way of testing the API as it emerged. This in turn has led me to learn some aspects of the vert.x Context class which I didn’t really understand before.

Liuwei Fire has kindly made a Chinese translation of this article available here. Read more

Automating AsciiDoctor With Maven

2016-05-16 In the previous blog entry about AsciiDoctor, I recommended saving the generation command into a shell script or batch file to make it easy to add additional processing/pre-processing later.

While at the time this seemed very straightforward, for those of us who want to generate documentation as part of a Java build, there’s a more convenient approach. There is a Maven plugin for AsciiDoctor (Maven appears to have plugins for just about everything), making it easy to generate documentation from templates as part of a Maven build. This in turn can be used in conjunction with other functionality provided by Maven (e.g. Maven resources plugin to move custom css into an appropriate location ready for upload to a website) to make a more complete build script. Read more

Building a Blog with AsciiDoc

2014-09-05 Given that we at millross have to write different kinds of documentation, it seems less than ideal to write our blog in one markup language (MarkDown), but other technical documentation in AsciiDoc, so we thought we’d look at writing our own blog in AsciiDoc and generating HTML ready for upload. This is how we went about it: it may not be the perfect (or even the best) approach, but it’s how we got this blog up and running. Read more