Web Application Development Series: Bridge Status Alerts revisited – Part 1

In 2014, as an introduction to composer dependency management, I implemented a ‘quick solution’ for a friend who needed updates for when the M4/M48 Severn Bridges were closed or congested, which I documented in a blog post summarising my use of Silex and other Symfony packages to achieve what I needed.

Since then, I’ve been introduced to concepts of Behaviour Driven Development (using phpspec), Behaviour Acceptance Testing (using behat)  and general agile methodologies such as having nominated product owners, user stories, acceptance criteria – and I’d like to re-implement the bridge status alerts using these approaches, with the hope of being able to share what I’ve learned about this way of working.

Continue reading Web Application Development Series: Bridge Status Alerts revisited – Part 1

Nurses & Developers, the ‘no spare time’ effect

From what I have heard (and I hear a lot, being married to a Staff Nurse), NHS nurses have been complaining of understaffing and overstretching for a number of years. Recent cuts to the health service from the current coalition government has left those still with jobs on wards working 12 hour shifts with few breaks, frequently staying beyond the end of their shift to finish what they didn’t have time to do in their normal working day. The problem with the act of staying late and working themselves to exhaustion is that it masks the problem from those with the power to change it.

From a management perspective, staff levels are down (and therefore so are wage bills), but the care is still being delivered. What a great decision it was to cut staff, the staff that were there before must’ve been wasting time, right?


While the core parts of the job are getting done, there’re several unsustainable problems that will, over time, compound:

  1. Staff are working too hard and for too long, which means they will become exhausted
  2. Tired and overstretched people make mistakes – risking patients’ well-being
  3. The small parts of being a nurse that make a real difference to quality of care received by patients can’t be completed – taking an extra 5 minutes to talk to an upset individual, having enough time to notice when patients start to go off-colour
  4. Unexpected problems – e.g. ward emergencies – can cause huge problems and a lengthy backlog for the normal patient care that is still required

These are problems that, observed in a short timescale, don’t seem particularly critical. But compounded over a number of weeks/months/years, this causes major problems. The quality of healthcare offered by our NHS deteriorates, mistakes are made, lives lost. Staff become demotivated, nursing becomes a less attractive career.

Yet the decision makers, those who don’t necessarily see the amazing effect nurses having an extra few minutes to spend with each patient has, those who don’t live with and observe how stressed/exhausted the staff are, see their cuts/staffing levels as a success.

Why am I talking about this on a development blog?

While the impact of developers being tired, overstretched and prone to mistakes isn’t necessarily quite as serious as those in charge of the lives of others, comparisons can still be made. Developers that are scheduled to be working at 100%, or who have very little spare time, will suffer from similar problems;

  1. Staff are working too hard and for too long, which means they will become exhausted
  2. Tired and overstretched people make mistakes – risking introduction of software bugs that will cause customers problems, and dent your business reputation
  3. The small parts of being a developer that make a real difference to quality of solutions delivered to clients can’t be completed – taking an extra 5 minutes to improve a user experience, having enough time to notice when systems can be improved or optimised
  4. Unexpected problems – e.g. unexpected software failures – can cause huge issues with scheduling and a lengthy backlog for the normal customer care that is still required

Making sure that your developers have leeway in their working day will encourage innovation and will increase the quality of their output.

Unfortunately, it is so often the case that the only way these problems can be brought to managers’ attention is by allowing failure. By not staying beyond your shifts. By not putting in the extra time. By allowing patients to get hurt/software to fail. But we are professionals. Nurses are aware that if they don’t do everything, patients might die. Using a patients death as a negotiation tool would be unforgivable. As software developers we’re aware of the negative impact unresolved queries has on our reputation as a business. We shouldn’t need to allow failure for our problems to be taken seriously.

So if developers are screaming for more spare time, more capacity, it isn’t necessarily because they want to have lazy days. It might be because they’re putting in more time than you know to get done what should be achievable in standard working hours. It’s because they want to return to delivering a high quality of care to their software/clients. It’s because they know that they do a better job when they’re not overworked. It’s because they know that the business will be better for the change.

The importance of having something to aim for or somewhere to go

I started running in August 2013 and for a number of months I was able to make sure I got out a few times a week and was seeing steady improvements, to the point where I was proud to say (warning: I’m not naturally athletic!) that I could run 5 miles at about 8 minute 30 second per mile pace. But my personality is such that I bore of things quickly, and between November 2013 and April 2014 I stopped running completely, having lost weight and achieved my short term goal.

Having put on a few kilograms again at the beginning of the year, at the start of April 2014 I set myself a target of running in and completing a half marathon on 11th May 2014 (6 weeks or so in the future). I began April vastly unprepared and far from ready to run over 13 miles, but with the event approaching fast I have had no choice but to get off my arse and run at least three or four times a week so that I stand even the slightest chance of finishing the distance. There have been mornings and evenings where I’ve wanted to do anything but run, but have had to force myself out anyway. This has been great for me and means I stand a very good chance of making good progress with my fitness and general health.
Continue reading The importance of having something to aim for or somewhere to go

My foray in to public speaking – unified.diff February 2014

Since unified.diff first got going in Cardiff (as long ago as February 2012!), I have been teasing @craigmarvelley (one of the organisers of the event) with the prospect of me “probably doing a talk one day”.  In December 2013 I decided that I would make myself do it rather than continuing with empty “one day” type promises, and so, having an idea that I would speak about my experiences remote working (but having not written anything for it yet), I asked Craig for a speaking slot at the February 2014 unified.diff meetup.  I’m writing about my experience doing this in the hope that it will encourage others in and around Cardiff to participate in the unified.diff event.

Continue reading My foray in to public speaking – unified.diff February 2014

A quick Silex & Component-driven PHP project: Severn Crossing status alerts

My friend Craig crosses the bridges in to England several times a week to get to his job in Avonmouth.  Sometimes, bridge closures can catch him off guard and he has to go a longer way around.  He said he’d always craved for the bridge website to include an “SMS alert” or “Email alert” service to tell him at specified times when there were problems with the bridge.  He asked if this was something I could bash together, and this is the result.

Continue reading A quick Silex & Component-driven PHP project: Severn Crossing status alerts

Driving and implementing change

Over the last few years of my career I’ve been fortunate enough to join a company and a team where the development process and tools available to us are well established, tried and tested.  We do things better than a large number of companies.  But I also surround myself, out of work, with people that work for companies that are further along the path to ‘the perfect development setup.’.  At first this was tricky and I got frustrated – why aren’t we doing these things? Why aren’t we automating our deployment? Why aren’t we using test driven development?

Continue reading Driving and implementing change

Use tools for good reasons

Further to my wanting to be an expert at everything post, I’ve recently also been thinking about why and when we should use new tools or approaches.  I’ve observed some twitter conversations recently about whether CSS pre-processors are an unnecessary complication, whether static site generators such as jekyll are useful, and whether or not we’re overcomplicating the simple delivery of web sites with complex tools.  I think sometimes there’s a danger of using tools or approaches for the sake of it.  Using only the tools needed for each job is a good approach…

Continue reading Use tools for good reasons

Desktop website performance

There’s been a worrying trend in page weights on the web which has been well documented over the last year.  I think most web designers and developers are aware of the need for a quick loading website when considering mobile optimised experiences, but far too few people building websites give the same consideration to desktops.  I think this is a mistake.

Continue reading Desktop website performance

Don’t forget the PHP interactive shell for quick testing…

We use geolocation of IP addresses in PHP to determine where to redirect visitors to, dependent on their likely location.  We use the geoip_country_code_by_name PHP function to do this.  We were getting unexpected results from a particular IP and we needed to see why.

All I wanted to do was, after making updates to our GeoIP database, see if the output of geoip_country_code_by_name() for the IP address in question was then correct.

Our “normal way” of doing this would be to set up a PHP script that simply echoes out the output of geoip_country_code_by_name and then refresh the browser after making various changes behind the scenes. But this approach carries with it a few frustrations from my point of view…
Continue reading Don’t forget the PHP interactive shell for quick testing…

Embracing Criticism and Peer Reviews

Six months after a project is completed, I’m my harshest critic.  I can find opportunities for improvement throughout almost all work I’ve been involved in.  Now, this isn’t necessarily a bad thing – it shows that the quality of work is advancing.  I’m sure this applies to many others in our industry also.  This critical point of view is a very useful tool to have, but six months after the end of a project isn’t a great time to have it.  If this viewpoint were available during a project, the project could be completed to a higher standard. So from where else can we get constructive feedback in a project? Continue reading Embracing Criticism and Peer Reviews

A sporadic commentary on lessons learned in Web Development