Archive for the ‘Work’ Category

Lockdown 2

Saturday, February 27th, 2021

October started with Duncan’s birthday. It was a pretty quiet affair at home with Christine’s parents visiting and a film in the evening. Friday night has become film night more generally now (after a trial of Sky Cinema we signed up for a discounted subscription). Trying to select a film is always a bit of a trial, particularly balancing Emma’s desire for action against age-appropriate content for Duncan! I’m usually the one who ends up making a final decision to try and satisfy everyone’s needs.

Swimming lessons continued, as did long walks and cycle rides at the weekend. In addition to Tuesday Night Runs (now with beer inside but with face masks and table service), I managed a couple of runs with the IBM gang. We went to another SCJS training with Duncan, this time in the New Forest. We were back in the Forest a couple of weeks later for an event I planned at Anderwood. I managed to put one control in the wrong place – the perils of doing all of my planning in one visit to the area the week before the event – but otherwise everything went well!

Still with vacation to burn, I had half term off. Much of it was taken up redecorating Emma’s room: out with the little girl pink, in with the teenage grey (there was much debate about quite how dark a grey she could have!). Duncan and I amused ourselves soldering and assembling the MERG DCC command station and handset kits for his railway. Two pairs of hands definitely made the job easier, not to mention Duncan’s eyesight when it came to the surface-mounted components in the handset. Remarkably, it all worked once assembled but the train and track now need a bit of an upgrade to get a reliable signal.

Lockdown returned for four weeks in November which brought the more sociable activities to an end (at least face-to-face). You were still allowed to exercise with one other person, so Tuesday Night Runs involved Ian and I running around Chandler’s Ford, and I could still go out cycling with Alasdair. Through an article in CompassSport, we had discovered the Turf app (think Pokémon GO but without the cute characters) which, even four months later, is still getting us out the door.

Duncan bought himself a small drone which we then promptly had to retrieve from the garden two doors down the road! He also bought himself a penknife which has, so far, only caused the loss of blood on one occasion! The month ended with Christine’s birthday. Come December, Christine was also allowed to tell the world that she had succeeded in her promotion to Professor. At least she now needn’t worry about being called upon to help in an emergency!

Emma’s inflatable boot had not helped her ankle but we were then left waiting for the hospital to start operating on children again. We were eventually given a date at the start of December (still over a month before the NHS would have even started to look at her ankle). Christine would go with her so both had to traipse up to Basingstoke for a Covid test three days beforehand, and then the whole family had to isolate until the day itself. Having been on the front of the list, Emma was awake again by mid-morning and home early afternoon. All seemed to go well and, rather than a plaster cast, she got to use the inflatable boot again. By Christmas, she was walking around normally again although is still a bit wary of cycling.

Things opened up again for the next few weeks. Orienteering resumed with events at Bramshaw and Farley Mount. We even managed the annual Run the Pubs, albeit that the meal afterwards had to be in the pub garden as we were not all from the same household. I managed to give blood (having been turned away with a sore throat on the previous occasion). We also had a big online launch event for the Software Delivery Management product I’m working on, for which everyone in the company received a set of glassware in the post so we could drink a toast. (You had to provide your own drink though!)

The dreaded R-number was on the rise again in the run-up to Christmas and there was much debate about what we might be able to do. At best, it was possible that we might be able to meet family for a few hours outside but, by the 19th, Hertfordshire (where my family is based) was put in the topmost tier, ruling even that out. By Boxing Day, we joined them in Tier 4 and we were to enter another national lockdown in the New Year. The Christmas period was therefore spent at home, enjoying the frosty conditions outside, and doing yet more decorating!

New Year’s Eve was made a bit special as we cashed in the money that CloudBees was contributing to a festive meal and had a nice takeaway. Emma was then determined to stay up until midnight and we thought we should probably keep her company! As the year came to an end, I’m sure everyone had the same wish: that 2021 should be a better one.

And we’re back!

Wednesday, February 10th, 2021

From time-to-time, I feel the urge to write a blog post on something and then I realise that there’s this gaping void since I last wrote anything (16 months) for which it would be remiss not to say anything given all that has happened. So, the next few posts will be a whistle-stop tour of that gap, hopefully, followed by some more regular posting. The advantage of going back over a year is that I get to relive life pre the big ‘C’ (that’s Covid, not Cancer, for those looking back at some point in the future when hopefully this is all but a distant memory).

So what happened between Duncan’s birthday and the end of 2019? There was lots of outdoor activity, starting with Christine running the Clarendon Marathon. I did a couple of the CC6 cross-country events, as well as two Hants XC League races. The one at Sparsholt college was a particularly good mudbath! I was also continuing to run the monthly Strava challenges set by my ex-colleagues at IBM and returning to Hursley every other Wednesday to either run or marshall the fit52 5k events.

On the orienteering front, I planned an event at Fritham which was well attended despite the atrocious weather. After hanging controls, the rest of the family disappeared to get the car MOT’d as we’d discovered the night before that it had expired! I managed to leave one of the controls out in the forest but thankfully was back there a couple of days later for a Tuesday evening run and could retrieve it.

During half-term, we all went along to a Military League South event at Roundhill. It was the November Classic at the end of that week and I had the fun job of parking cars in an area that we were sharing with Totton RC’s Stinger race. It seemed to work okay although I then had a terrible run on Bramshaw. Emma was meant to attend an O-Camp at Burley Youth Hostel that weekend but it ended up being only a single night due to more bad weather.

We also managed another club event at Kings Garn Gutter and the British Schools Orienteering Champs near Slough where both children had good runs. SOC was also having monthly MapRun events taking us to Winchester, Romsey, and Southampton.

Music was another theme with Christine performing in two Thornden Community Wind Band concerts, Duncan taking his Grade 3 recorder exam, and Emma appeared in a school concert singing and playing the violin and recorder (not all at once). Not sure what my contribution to this them was!

On the work front, I had two overseas trips. An internal meeting in Raleigh (again) and then I was on booth duty at our DevOps World event in Lisbon (a first visit to Portugal for me). I was interviewed for, and offered, a job which would have seen me return to an office location. After much soul searching and discussion with my current management, I decided to turn the offer down but it did precipitate my move into a tech lead role at CloudBees.

Indirectly related to work, I gave one of Christine’s lectures on “Databases and SQL”, a subject that has been occupying a disproportionate amount of my time. I also helped out at a Code Retreat back at IBM which was good fun. I made a last-minute decision to go to the London Java Community’s Unconference. I almost didn’t make it when my key got stuck in my bike lock at the station but, with some WD40 courtesy of SW Trains, I was on my way again. There were some good sessions as well as providing an opportunity to catch up with some old friends.

Despite many an hour spent completing Advent of Code (in Python this year), there was still time for some socialising in the run-up to Christmas starting with the CloudBees Whitely Christmas meal. The “Run the Pubs” tradition continued, albeit with less running and fewer pubs! It was also our turn to host a group of friends for pre-Christmas drinks. We’d just about recovered from that before disappearing to Monmouth for Christmas itself. We then made a trip across to my parents before New Year which was to prove to be the last time we’d see them face-to-face for over a year…

Knative Intro @ Devoxx UK

Thursday, May 30th, 2019

I presented an introduction to Knative at Devoxx UK, the recording for which can be found below. I’m afraid I deviated somewhat from the abstract given the changes to the project in the five months since I submitted it. With only half an hour, I probably shouldn’t have tried to cover Tekton as well but I wanted to have an excuse to at least touch on Jenkins X, however briefly! The demo gods largely favoured me except when hey failed to return (not the part of the demo I was expecting to fail!). The script and source for the demo are on GitHub although I’m afraid I haven’t attempted to abstract them away from the Docker Hub/GCP accounts.

Debugging with Telepresence

Monday, February 11th, 2019

I’ve spent the last few days trying to debug an issue on Kubernetes with an external plugin that I’ve been writing in Go for Prow. Prow’s hook component is forwarding on a GitHub webhook and the plugin mounts in various pieces of configuration from the cluster (the Prow config, GitHub OAuth token and the webhook HMAC secret). As a consequence, running the plugin standalone in my dev environment is tricky, but just the sort of scenario that Telepresence is designed for.

The following command is all that is needed to perform a whole host of magic:

  • It locates the my-plugin-deployment deployment already running in the cluster and scales down the number of replicas to zero.
  • It executes the my-plugin binary locally and creates a replacement deployment in the cluster that routes traffic to the local process on the exposed port.
  • It finds the volumes defined in the deployment and syncs their contents to /tmp/tp using the mount paths also specified in the deployment.
  • Although not needed in this scenario, it also sets up the normal Kubernetes environment variables around the process and routes network traffic back to the cluster.

Now, it was convenient in this case that the binary already exposed command line arguments for the configuration files so that I could direct them to the alternative path. Failing that, you could always use Telepresence in its--docker-run mode and then mount the files onto the container at the expected location.

And the issue I was trying to debug? I had used the refresh plugin as my starting point and this comment turned out to be very misleading. The call to configAgent.Start() does actually set the logrus log level based on the prow configuration (to info by default). As a consequence, everything was actually working as it should and my debug statements just weren’t outputting anything!

Farewell IBM

Thursday, August 2nd, 2018

On 2nd August, I handed back my IBM badge, just shy of twenty years after I first joined the company. I’ll come back to the ‘why?’ and ‘where next?’ questions and start with a recap of those intervening years (with apologies for the consequent length of this post!).

I started at IBM Hursley on 6th October 1998, fresh out of university with a degree in Engineering and Computer Science. I was a month late for the beginning of the graduate programme having taken some time out to travel across Canada by Greyhound coach! I began working on IBM’s C++ CORBA offering (Component Broker) with a brief spell in test before switching to development in the transactions team. (Remember when ‘test’ and ‘development’ were two different teams?) Many of my colleagues in that team (too many to name but they should know who they are) formed the basis of a network that would define the shape of my future career. (My Component Broker mug is still going strong but I’m afraid I ditched the set of foils describing the product that I found when clearing out my desk!)

At university I’d used, the then nascent, Java in a couple of projects and those skills were to become of use as we started to add a Java client. Before long, the focus switched to the newly-defined J2EE specifications and WebSphere Application Server was born. After working on the JTA and Activity Session implementations, I joined a team looking at integration with MQ. When the time came to implement an embedded JMS provider in WebSphere Application Server V6, it was natural I should move to work on that.

Six years in, I was starting to make architectural decisions but desired a better understanding of how customers were actually using our products. When the opportunity came up to work as a software consultant in IBM Software Services for WebSphere (aka Lab Services), I jumped at the chance. The next few years were spent travelling across Europe, doing everything from performance bake-offs, resolving critical situations, to participating in first-of-a-kind projects. I particularly enjoyed this time, learning to survive on your wits on those occasions when it wasn’t possible to draw on that all important network. This was also the period during which this blog began.

On returning from a short-term assignment to Norway a, by now one-year old, daughter meant it was time to get my feet back under a development desk. Having worked with customers on WebSphere ESB, it was natural to join that team. From there, I had the pleasure of building and leading a new development team to take over what was to become WebSphere Appliance Management Center. We had great fun, rewriting the offering to build on the new WebSphere Liberty Profile with a shiny new JavaScript front-end (thankfully IBM later moved on from Dojo though) in what I still think was one of the most passable efforts at agile I’ve seen in IBM.

Eventually, the team were moved to work on IBM API Management. The eight-hour time zone difference to the half of the team in California didn’t work for me and, after a nine-year break, I rejoined the WebSphere Application Server family. Initially, I was working on the open source Cloud Foundry buildpack. A side project relating to Netflix OSS was the start of an interest in microservices. From there, I lead efforts relating to containerization, including the publication of official images on Docker Hub.

This, in turn, led to Microservice Builder: a platform for developing, building and deploying, cloud-native applications on Kubernetes. This was then rolled into an offering called Microclimate which added a greater emphasis on the developer experience and that brings us to the current day.

So why, after so many years working with such great people on such a variety of interesting projects, am I now set to leave? Sure, there have been frustrations in working for IBM, but I’m sure many of those are common to all large, shareholder-owned, multi-national companies. As an example, take the laying down of corporate instructions that mandate that all 380,000 employees be treated in some particular way that cannot possibly be equally applicable to all. Thankfully I’ve been blessed with managers who have all excelled in the flexible interpretation of those rules. Many of those same managers are helping to revive Hursley as the vibrant technical community that I first joined.

Really, my departure just boils down to wanting to experience working for a different company. I’ve often said that IBM is the best employer within a two-mile radius of my house and I’ve set a lot of store by that convenience. My LinkedIn profile has been ‘open to offers’ for a few years now but I’ve been resistant to the lure of London money/startups or the peripatetic life of the solution architect. In this case though, I was offered the opportunity to work from home, not as the lone outcast, but for a company that is almost entirely distributed. It was also an opportunity that would utilize the skills around the cloud and DevOps (in particular Kubernetes and Jenkins) that I’ve garnered over the past few years. Such is the overlap that I even credited one of my technical interviewers in a presentation I gave earlier this year when citing their work!

So, without further ado, from 28 August I will be a Senior Sofware Engineer at CloudBees where I’ll be joining the architecture team for their core (Jenkins) offering. At eight-years-old, the company is very much a late-stage venture but, with the distribution list for my leaving email at IBM having more people on it than there are in the entire company, it will be quite a different prospect to working at IBM. Much more than that, I can’t tell you because, quite frankly, I don’t know, but I’m looking forward to new colleagues and challenges. Stay tuned to this blog to find out what happens next!

 

Scratching at Work

Saturday, May 12th, 2018

Not satisfied with a four-day Bank Holiday week, I was back in work today for a Scratch Day organised by the inimitable Dale Lane, supported by an all-star cast of IBMers, past and present. The day got off to an ‘exciting’ start with Duncan and I cycling there along Hursley Road. Emma joined us by car, just as the day got going, hot foot from her swimming lesson.

There was a good turnout from IBM and other local families. On offer was a selection of projects from Code Club and Dale’s own Machine Learning for Kids. Emma and Duncan worked separately and I probably spent most of my time helping Duncan (although both are familiar with Scratch from school and home). Typically, Duncan picked two of the ‘advanced’ options but, having heard Dale talk about them at a lunchtime session, I was more than happy to try out a couple of the ML exercises.

We started with Judge a book which performs image classification on book covers to try and identify genre. I was a bit slow to realise that Duncan was logged in to my Amazon account whilst performing his searches but thankfully we switched to an incognito session before getting to the flesh-covered books under Romance! He’d picked Horror and Fantasy as two of his other genres and it wasn’t surprising that the classifier occasionally got those confused.

I had to help out a fair amount with the Headlines exercise as there was a lot of typing to enter the training set from different newspapers. We didn’t manage to finish before the end of the day but we still had an interesting discussion about the differences between tabloid and broadsheet headlines.

The event closed with an opportunity for the children to show what they had done to the others. Although some were a little reticent, this was a great opportunity for them to build a little confidence and soak up the applause that each invariably got.

All-in-all, we had a great day and my thanks go to all those that gave up a day (and more) to help out. We’ll certainly be checking out a few of the other projects and hope that Scratch Day makes a return to Hursley next year.

Index Developer Conference

Sunday, February 25th, 2018

IBM launched a new conference in San Francisco under the name Index and I was lucky enough to attend. This wasn’t your usual IBM conference focused on brands and products. Although the tracks were aligned with IBM’s strategic areas (Cloud, Blockchain and AI talks were much in evidence, for example) it really was a developer conference with keynotes and speakers from well-renowned figures across the industry.

You can watch my session covering deploying Jenkins on Kubernetes with Helm and deploying to Kubernetes from Jenkins with Helm below. You can find the deck on SlideShare and the demo material on GitHub. For those who know what I work on, it will be no surprise that this is based on our discoveries when developing Microservice Builder. I highly recommend you also check out some of the other sessions on the conference playlist and watch out for Index 2019!

https://youtu.be/xzbMHj1ly9c

The timing of the conference meant I had Friday to be a tourist with some colleagues. We headed over to SF MoMA and then made the most of the sunshine with a stroll along the waterfront to see the sea lions and then to have to have lunch overlooking the bay.

Optional Kubernetes resources and PodPresets

Thursday, July 27th, 2017

The sample for Microservice Builder is intended to run on top of the Microservice Builder fabric and also to utilize the ELK sample. As such, the Kubernetes configuration for the microservice pods all bind to a set of resources (secrets and config-maps) created by the Helm charts for the fabric and ELK sample. The slightly annoying thing is that the sample would work perfectly well without these (you just wouldn’t get any logging to the ELK stack) only, as we shall see in a moment, deployment fails if the fabric and ELK sample have not already been deployed. In this post we’ll explore a few possibilities as to how these resources could be made optional.

I’m going to assume a minikube environment here and we’re going to try to deploy just one of the microservices as follows:

If you then perform a kubectl describe  for the pod that is created you’ll see that it fails to start as it can’t bind the volume mounts:

Elsewhere in the output though you’ll see a clue to our first plan of attack:

Doesn’t that optional  flag look promising?! As of Kubernetes 1.7 (and thanks to my one-time colleague Michael Fraenkel) we can mark our usage of secrets and config-maps as optional. Our revised pod spec would now look as follows:

And lo and behold, with that liberal sprinkling of optional attributes we can now successfully deploy the service without either the fabric or ELK sample. Success! But why stop there? All of this is boilerplate that is repeated across all our microservices. Wouldn’t it be better if it simply wasn’t there in the pod spec and we just added it when it was needed? Another new resource type in Kubernetes 1.7 comes to our rescue: the PodPreset. A pod preset allows us to inject just this kind of configuration at deployment time to pods that match a given selector.

We can now slim our deployment down to the bare minimum that we want to have in our basic environment:

Note that we have also added that runtime: liberty  label to the pod which is what we’re going to use to match on. In our advanced environment, we don’t want to be adding the resources to every pod in the environment, in particular,  we don’t want to add it to those that aren’t even running Liberty. This slimmed down deployment works just fine, in the same way that the optional version did.

Now, what do we have to do to get all of that configuration back in an environment where we do have the fabric and ELK sample deployed? Well, we define it in a pod preset as follows:

Note that the selector is matching on the label that we defined in the pod spec earlier. Now, pod presets are currently applied by something in Kubernetes called admission control and, because they are still alpha, minikube doesn’t enable the admission controller for PodPresets by default. We can enable it as follows:

(Note that, prior to minikube v0.21.0 this property was called apiserver.GenericServerRunOptions.AdmissionControl, a change that cost me half an hour of my life I’ll never get back!)

With the fabric, ELK sample and pod preset deployed, we now find that our pod regains its volume mounts when deployed courtesy of the admission controller:

Pod presets are tailor-made for this sort of scenario where we want to inject secrets and config maps but even they don’t go far enough for something like Istio where we want to inject a whole new container into the pod (the Envoy proxy) at deployment time. Admission controllers in general also have their limitations in that they have to be compiled into the API server and, as we’ve seen, they have to be specified when the API server starts up. If you need something a whole lot more dynamic that take a look at the newly introduced initializers.

One last option for those who aren’t yet on Kubernetes 1.7. We’re in the process of moving our generated microservices to use Helm and in a Helm chart template you can make configuration optional. For example, we might define a logging  option in our values.yaml with a default value of disabled , and then we can define constructs along the following lines in our pod spec:

Then all we’ve got to do when we’re deploying to our environment with the fabric and ELK sample in place is to specify an extra --set logging=enabled  on our helm install. Unlike the pod preset, this does mean that the logic is repeated in the Helm chart for every microservice but it certainly wins on the portability stakes.