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.
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!
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!
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): https://en.wikipedia.org/wiki/Erlang_(programming_language)
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.
Gutenberg is the new way of doing things in wordpress and involves blocks, this is a paragraph block.
It's supported as a plugin for now but will eventually be part of the install in 5.0.
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!
I bought my 3ds about 5 years ago when I first moved to London.
Unfortunately I thought it had cooked it today when after searching high and low for it, Lex found it in the freezer! Amazingly it survived 24 hours at sub zero conditions.
I put it up on the radiator to taw it out and let it dry. I then googled ‘frozen 3ds’ to see if anyone else experienced the same thing and to see if I could find a prognosis. Then I have to admit I was surprised when I powered it on that it still worked!
I bought it from game around Oxford Street – which is one of the busiest shopping streets in world. It has been a great companion to me and has seen me through tick and thin. I feel it’s one big sign of wear and tear – it’s crack on the top right is a testament to what we have been through together.
For those who don’t know – a 3ds is the latest in the line of Nintendo handheld consoles which originated with game boy (or at least became famous). The switch is out now and is also portable and I’m planning on getting one of those at some stage but I still feel a connection and strong bond to my 3ds.
I bought mario kart first, then street fighter. I really got a lot of value from mario kart and played street fighter a little also. Then – I don’t know the exact order but I think it is…I got ocarina of time which is my favourite game of them all. Followed by majoras mask and possibly lylat wars. I got a link to the past and new super mario bros.
Lately, I have gotten into the virtual console which is all the old Nintendo games rereleased.
I was half way through Zelda links awakening, so am happy that i’ll get to finish that out! Nintendo games age so well.
So if you have frozen your 3ds and are wondering the chances of it working again then know that it did for me! I would leave it thaw out well though before switching it on and make sure water has evaporated.
I visited Turin recently, it is a lovely city. My wife wrote about it and you can read about it here.
I have always liked the title of my website only sometimes I think that I might change it to something more positive in the future.
Starting your website with the word “no” might been interpreted as negative when really it is just an acceptance that it is not easy to find a good web address today that is free.
There are also a lot more domain extensions available today also such as “.me”. I think I’m really saying I had fun with nogoodurls maybe now it is time to change!
I have supported Liverpool since the age of 11 or 12. In Ireland, at least when I was growing up everyone supported either Liverpool or Man United. So a premier league ‘derby’ in Ireland was Liverpool VS United. Many of my school chums back then initially supported Liverpool but then as the balance of power shifted towards Manchester there was a slew of transfers in that direction!
I kept the faith though, I suffered for a lot of years and in many cases on my own. I did my part with regards recruitment – I signed my brother Gerald and sister Betty (whom I don’t even think liked football) to the cause, I think I also converted my cousins in West Cork, or at least had a positive influence on them. My youngest brother Liam was allowed support United as I thought it was healthy to have a little rivalry in the house and I think I felt like I had done my bit. Liam lost interest anyway but I’m still a fan, though my interest has waned at times.
I remember listening to the crackle of 5 live and Alan Green on my dads radio with Gerald (my brother), often in the middle of winter. We couldn’t hear a thing and the noise always seemed to got worse when the action happened – ‘Gerrard…great pass..to Michael Owen..now…..tackled by Hen..Beckham….Robbie Fow….’ and then an explosion of crackly noise! You knew something had happened of significance but you weren’t always sure what it was, but it was the worst kind of torture because you were never sure which team had struck the mortal wound to the other! These are nice memories to have looking back really and I do value them but I think, still we did suffer for our team!
I also remember being told to grow up by mum when Man United beat them in the FA cup final – she could never understand my sorrow. I was 11 or 12 but it was the last time I cried about football because I think I soon after realized it was only a game. That is kind of my attitude to this day – I love to see them do well but I don’t get too upset when they lose.
And I learned from one of the best supporters of anything in my dad. His sport is Ireland’s own indigenous hurling. It is a great sport and I think soccer could learn a thing or two from it. It is full of passion, love of the game, but also loyalty. I digress slightly but my dad loves hurling probably more than he loves me and he definitely loves Waterford more than he loves any one thing in the world. It really affects his mood though and the Monday after Waterford have been knocked out of the championship is the end of the word – for everyone. I don’t think it is worth that anymore.
So I learned from watching him but I also learned from my own experiences. I remember going to Anfield for the first time with another massive Liverpool fan – my friend Anil. We came over from Ireland assured our tickets were in place but when we arrived it seemed like something had gone awry at the ticket office and our entry was in doubt – I couldn’t believe it after coming all the way over – I think if I didn’t get in that day it would have ended my ties with the club as the taste would have been too bitter!
We got in at the last as the confusion was cleared up – it was really only on Anils clear head and thinking though. Once we got inside we headed straight to the sidelines to get as close to the players warming up as we could and there they were, all the lads; Stevie, Pepe, Crouchie. I felt like waving at them as I new them so well. It is the strangest kind of feeling but then you realize and remember that they don’t know you at all. I thought there was an unhealthy unbalance in this relationship and I think it sunk home then a bit. One way relationships are never good.
None the less I really enjoyed the experience and was happily able to return the following year with my brother and I think my support levels recovered a bit. It was the era of Rafa Benitez and Liverpool were really good – they got to two champions league finals, winning one and became the top ranked team in all of Europe at one stage. I got carried away – we all did and I remember not getting too excited by them winning the FA cup. It seemed like a matter of time before thy won the league and ended the wait. Then it all fell apart.
Xabi Alonso left for Real Madrid. To be honest I think his loss was as much psychological as anything else as he grew in reputation as a player with every day away from Liverpool. I blame the fans – they lost faith in Rafa and the team. Things went down hill quickly, Roy Hodgson was brought in and to be fair he never stood a chance. He got a few months but everything had got so negative it would have been hard for anyone.
King Kenny was brought in to save the day and results picked up for a while but it didn’t last and the final nail in the coffin was hammered when Fernando Torres left. I’ll not talk about Fernando as his story is a sad story and every one knows it. That was the worse moment for me as Liverpool supporter – it was et tu ‘El Ninio’. You are leaving too. A part of Stevie G died that day and apart of the Liverpool in me died too. I don’t know if I will ever get that back.
I felt like I have been through a great many highs and lows as a Liverpool fan but I think I will always support the team. I think though at times Liverpool (and other clubs doubtlessly) take supporters for granted and should give more back. I live in London these days and try to go see them once or twice a year. You need to pay for a membership before you any real chance of getting tickets though and basic membership is around 26 pounds. I got a membership for both my brother and I this year and made the mistake of telling him that I was gonna get tickets for both of us an Xmas present.
I was gutted when I logged in on sale day to find all tickets had gone! I was disappointed to have to tell my brother that I had failed in getting the tickets but I was a little angry and disappointed with Liverpool Football club too. I wrote to them asking if I could transfer my membership to next year as I had little need for the membership this year. Despite persistence I was repeatedly told what felt like ‘computer says no’. I was angry because I felt that Liverpool were using my loyalty towards them against me, assuming that I would sign up again next year regardless. I guess they think, what is he going to do, support Man United? – ha ha ha. I wouldn’t do that of course!
I think if football clubs are to continue to do well they need to support the fans back. There ticketing policy doesn’t seem wholly fair and I think it needs a review. I have invested a great deal of time, money and emotion in watching and supporting my team over the many years and I think I should be seen as more than just a customer. I don’t expect Stevie to come over or wave at me when I go to a game but I expect a little bit more back from Liverpool in situations like this where I have spent my hard earned money and to no avail.