Anti Climax after 30 years

So it is all over, Liverpool are premier league champions. It is a very strange thing. Kenny Daglish said that if someone told him when he was manager and they last won it, that they would go 30 years before they won it again, the person would have been certified.

I had the misfortune of starting to support them the year after they last won it. So while there have been some incredible moments during those 30 years it feels like a relief now that Liverpool have won what they most wanted to win. Relief in general is the overriding feeling for me this week.

Most people would say this premier league win means more than the two champions league that liverpool won in between. I feel the same. However it is hard to say that this is more enjoyable than 2005, maybe as satisfying and more meaningful than the 2005 champions league win but not as enjoyable. Istanbul will always stand out in my head and the treble under Houllier also.

Those liverpool teams, I would argue were more enjoyable to watch in general. Perhaps less slick, but they were less controlled and focused. That made them, more unpredictable and that was part of the appeal I guess.

The likes of Michael Owen, Robbie Fowler and the spice boys have been resigned to history but now that Liverpool have finally won the league I feel like I can enjoy those memories more and it feels like it balances that lack of success out.

The reality is that it is probably quite boring watching the team that wins all the time and that is probably what has kept we interested over the years as a liverpool fan. It was never dull, apart from now arguably.

Liverpool have ended the 30 year wait in the most boring way possible. After being 20 plus points ahead of second place, they were forced to endure the lockdown break and then were not even on the pitch when they won the title as had to wait for Man City to lose.

Finally we cant celebrate properly as we are still house bound. Is that some kind of sick irony or is that the only way it could have been. Liverpool never seem to be able to do it easy.

In the past people might have thought it was something they do themselves but really they left nothing to chance this year and really shed that inconsistent tag they had developed but fate intervened to delay things and put it in doubt so perhaps it is just fate. Perhaps this is in liverpools DNA, never walking alone but always through the wind and rain to sunshine. My feeling is that this sunshine will last for a while despite this lockdown but will see.

I’ll probably hang up my supporters hat now for a while but will watch over the next few years to see how the ‘kloppites’ develop. If they manage to follow success with success great, but equally would be happy if some other team comes along and has success as it is good to share it around.

Premature Abstraction

In an ideal world every abstraction is pure. We don’t live in an ideal world (yet) though. Abstractions can be hard. They can cause frustration and people to give up on them or wait for the perfect solution.

In my experience, often the right thing to do is wait for the perfect abstraction but I think in a lot of cases it is right to go ahead and do the abstraction. You can always replace it or refactor it if need be but I think the key is not over doing it if not sure – keep it simple.

You want a good return on your investment and you dont want to make a brittle abstraction which limits peoples options down the line or causes tears and frustration.

Also, as with everything you should talk to people and get advice before creating your monster.

Single Reponsibility and Seperation Of Concerns in the real world

A straight forward example I encountered recently in a common lib I use at work.

The library is reasonably new and a work in progress I guess but the code has been in production for a while and the task was actually to merge the library with another ironicaly enough (side note: I read before that as opposed to the related principle Seperation of Concerns, Single Responsibility does not encourage over seperation). There is very little structure or code in both repos as is, the code to be merged was a utils library and the the other repo was a broader sdk. So I guess it did make sense to merge the two. 

I didn't want to complete the merge without dealing with a broadly named class called 'utils'. I had problems with the name anyway as the lib already had utils in the name. I have heard it said many times before that if you can't think of a good name for a class then you should probably consider splitting it up. This was particularly true here – and so I did. The utils class essentially contained file upload and file download functionality. The code in itself had been ported from one language to another and so I would consider it a little hairy. It was essentially an untidied grouping of functions relating to the two purposes already mentioned.

The upload and download functionality shared very little in the way of common functionality – I would have been less inclined to touch the class if they did. The download relied on axios and the upload the s3 sdk (Javascript). The upload had a little more complexity around security whereas the download was from a standard url (usually a signed url but not always). In my opinion there is no advantage at all in having these two concerns threated as one. So I seperated and the code base is better for it hopefully.

One thing I didn't do was group the File download and upload functionality into a files module – I left them with other utils such as a retry calculator and page counter.  As I said before the code base is quite small and I didn't want to over engineer. Also I am aware that I work with others who are less keen on abrstactions and so I don't want to step on toes or be rude. Thats important too!

Cheers to WordPress

I have probably said it before but will say again … WordPress is great. I spend most of my day writing and reviewing code at work and is nice to be able to write in words for a change. 

Word press is built with PHP – I know PHP has it's critics and sure there is a lot of hacked together PHP scripts out there but I am sure there are is a lot of good code also. WordPress is it's real success story (sorry not a facebooker) in my opinion.

In the past I have dug into the code base and found it a little hairy (used to OOP) – this was years ago though. I don't know what it looks like now, and whatever about the code base the ui seems to be orgainzed very well.

WordPress is just so flexible and straight forward and is great fun. Not sure about using it for businesses to be honest – have been there before and I think eventually you out grow it. Small businesses should be fine!

Messaging Systems


Why use messaging at all ?

Recover-ability – if all else fails hopefully you will still have messages and once normal services have been restored, then you can proceed getting your systems back online, hopefully with minimal damage done.

Dealing with spikes in traffic – you want to make sure that you systems can handle load above it's capacity even if takes a long time to process each message.

There are probably other reasons also but those are two main ones I can think of right now.


I have used a few and here is a brief discription of each and a comparison of their value. 


Rabbit is written in Erlang. It is an interesting language and has the following characteristics, from wikipedia  – it is functional, fault-tolerant, highly available, soft-realtime (soft means tolerable if there is a delay in processing):

It is also known for it’s pattern matching capabilities which I guess are useful with topics (more later) and above all I guess concurrency is it’s principal strength – which is great when you are dealing with millions of messages.

I once spoke to guy who programmed in Erlang and he seemed so engrossed in the language that I am sure he swapped English for Erlang and was speaking to me like so.

It uses a protocol called AMQP.

It also has many client libraries in Js, C# and many other languages which are pretty well implemented. This shouldn’t be taken for granted!

Messages are submitted to exchanges and queues are bound to the exchanges. You can have one to one relationships or indeed one to many.


You can submit with topics which ensures only the consumers with that specific topic receive those messages.  Subscribing to the relevant queue with the correct topic ensure that you only get messages you desire.

You can host yourself or use something like cloudAmqp.


To SNS or not to SNS

This is Amazons messaging system. Can be used in conjunctions with SNS or on it’s own. When used with SNS – SNS works as a sort of exchange and SQS as the queue.

SQS uses standard http underneath and offers a polling model for subscription. Is a little primitive in my opinion. The client libraries are also pretty basic although people are starting to build better libraries on top. With dotnet as an example though, easynetq is much more complete than any client offerings in SQS – we have had to essentially roll our own.

It’s not as sophisticated as something like RabbitMq. It’s strengths lie in it’s simplicity and it’s ability to scale, also the fact that hosting is taken care of by aws means we don’t have to worry about that side of things and also that it plays well with other AWS technologies such as lambda Dynamo db.


JMS is from the Java community and is an API specification as opposed to a protocol like AMQP. It can use a number of different protocols underneath – we use tcp in our implementation.

Coming from a dotnet background I found it a little difficult as had to consume using a c# library called NMS.

It has various implementations and the one I used was called ActiveMq. It us open source and relatively easy to install although creating and consuming messages is a little trickier.


All three options are useful depending on your needs. Rabbitmq probably has the nicest feature set but is not the easiest to get setup and started. Sqs is a better option if already using aws and I guess jms / active mq is nice for those who use Java. 

There are other options also such as Kafka but I would encourage you think if you really need the complexity of a messaging system before implementing as it does add it's own complexity.

Up the Deise !

Roy Keane once said Irish by birth, Corkonian by grace of god boy! I’m from cork myself but I have mixed blue blood in that my father comes from just outside the Waterford border in Tallow.

He is a keen supporter of the hurling and in particular the Waterford hurling team. When I was younger despite protesting that I was from cork and that I should be brought to see Cork play, I was brought to all the Waterford games instead.

This was in the early 90s and Waterford were not as good then as they are now. I remember dads clinched fist rise though when Waterford scored a goal better than anything else. I was quite young then but old enough to sense that it meant a lot to him.

I live in London these days and living abroad probably makes you more aware of where you come from in a sense. Ireland and the UK are next door to each other and so there is a keen rivalry when the two play in sports. It’s not particularly enjoyable to have to go into work surrounded by supporters of the other side either following a devastating defeat at their teams hands. Living and working in Cork all his life meant that dad has had to face the music on probably more than a few occasions but is fair to say he had last laugh (for the day) a few times also.

Also being married to a serious cork supporter was probably going to focus your supporting game. I’m not saying anything in particular only that a few flags have been known to go missing from time to time and accusations of unsporting supporting behaviour have been mentioned in the past also.

I also think that losing makes you a better and more loyal supporter. I don’t know why that is but I guess it proves you are there not just for the good times. Waterford have had their fair share of wins and losses over the years but there is probably no team more deserving of an all Ireland win in hurling the Waterford. Galway are funnily enough an other team that spring to mind, but I think no one would begrudge either side winning – even a Cork man close to the border.

There were so many great Waterford players over the last 10 years. Paul Flynn, Ken McGrath, Dan Shanahan, John Mullane and Tony Browne. I won’t say it is a crime that they didn’t win an all Ireland because crimes are for more serious matters. I won’t say tragedy either because no one died and it would be more of a tragedy if we started think like that. Sport should be for enjoyment alone – no room for tears. It is a pity though that they haven’t won an all Ireland at senior level since the 50s.

This is not the case under age though. The younger players have experience of winning and I think this shows in their play. Dan Shanahan seems to be doing a good job of adding his experience from the sides. So hopefully Waterford will have their day this September, they deserve it and so too does my dad!