10 Years a Software Developer

November 7, 2019 8:06 pm

July marked the 10-year anniversary of my starting work at the Lab. I got a certificate and lapel pin (not that I ever have any lapels on which to put it). And also a bump in vacation time and 401k contributions.

I’m still working with the same group I started with on the same general applications. But a lot has changed in that time.

Falling into the Past

When I started, the existing development team had collapsed for unknown reasons. I joined a basically black-box pile of software written in Java with custom, homegrown libraries and support packages. No documentation. Some of the compiled code had no matching source code (that I could find anyway).

It was a bit like being thrown back in time by at least 10 years in how web applications were built. I can admit now that it didn’t take long before I felt a bit worried about whether that job was going to be at all fulfilling for me. The code was a mess of JSP files intermingling core business logic with HTML output (a la the bad old days of PHP). It couldn’t be run locally, so making a code change involved modifying source files, compiling the code, deploying to the test server, restarting the application server (which also hosted the production application, so restarts impacted users), and then testing the change. A round-trip process of 15+ minutes. It was brutal.

I came in to the job with web application experience and I knew that there were much better ways of developing web applications. It wasn’t fusion research–that’s a different department–it was a fairly mature world.

By the Fall of 2009 I had settled in enough that I felt comfortable (or maybe just desperate?) enough to pitch the idea of using an open-source framework for our applications. Essentially saying, “Let’s toss the existing codebase and start over.”

Thankfully, my manager (who I’m grateful is still my manager) was willing to hear me out. But, we had some restrictions. The IT group was run separate from the software team and they dictated our deployment environment. So whatever we did needed to still run on the Solaris operating system, using Oracle Weblogic for the application server, behind Oracle iPlanet web server, talking to an Oracle database.

Even in 2009 that technology stack was unpopular at best and approaching obsolete. Trying to figure out how to configure Weblogic or iPlanet resulted in reading a lot of forum posts like “How do I do this in Weblogic?” answer, “You don’t, use literally anything else.” And that was if you were lucky enough to find an answer at all.

I had experience working with Python/Django, but that as a non-starter. Can’t deploy a Django app on Weblogic. It was a Java world. And our IT staff wasn’t much interested in supporting anything they didn’t already know.

Stepping into the Present

I found the Grails framework which lives in the Java ecosystem (technically it’s Groovy, but it runs on the JVM and as far as the system was concerned it was Java). It looked promising, certainly a huge step forward from what we had. We could go from coding with both arms tied behind our backs to one arm in a sling (which I did literally for a few weeks when I broke my arm, but that was years later).

I prototyped a brand-new type of application for our system. A geospatial view of the data utilizing Google Earth in the browser (back when GE was a browser plugin). Using a real framework I had a functioning prototype in a couple of weeks and it became immediately obvious that this was going to be our future.

That prototype was fleshed out into a full application and has since been overhauled 5 times and remains one of our core applications. It would never have been possible without moving our development work to Grails.

Over the past decade I kept pushing on modernizing our infrastructure as much as we could. Eventually the IT staff were consolidated under the software manager and over time they were replaced with people willing to consider a world outside of Solaris.

We moved our infrastructure to RedHat Linux, migrated from SVN to Git, switched our application server to Tomcat, finally swapped iPlanet for Apache, and even dumped the Oracle database for Postgres. We were finally in a sane development world (not to mention saving, literally, tens of millions of dollars on hardware and licensing). The arm was out of the sling and we got a lot of work done.

We had added additional software team members throughout the years, but never had a real focused approach to creating software. We were making it up as we went along and if you looked at the code, it showed.

In some ways, this was a necessity. As I said, the software team was non-existent when I joined. I had no experience managing a “real” codebase. Certainly not one expected to last for years. But, at the same time, the broader group we supported–the people we were trying to make more effective via software–didn’t have any trust in the software team. We needed to give them wins quickly to show them it was worth their time to interact with us.

And that’s what we did. That first prototype gave them a way of working with their data they never had previously and they wanted more. So, rather than work out a disciplined approach to building software with no experience to guide us, we wrote code. A lot of code.

Building the Future

It’s now 2019 and, for myriad reasons, it’s time to leave Grails behind. This year I became the team lead for the software group so I’ve had a lot of decisions to make. But, this time I have 10 years of experience to draw on.

We’re moving our applications to Python/Django. Something we could have done in 2009 had the IT staff been supportive of the software needs. But it is what it is. The good thing here is that it means the codebase will start from scratch. And, having had 10 years of dealing with a codebase built on the whims of the individual developers, we are doing things differently.

Our legacy applications are functional and stable so we have time to do things right. I spent a huge amount of effort up front picking the tools we’ll use to maintain good code “hygiene.” That is, tools and processes that ensure code is written consistently, that tests have been written, that obvious bugs have been caught, that the tests actually run and pass, etc. This discipline is already making a big difference in code quality.

We also have the luxury of an existing suite of applications–which we have to migrate over to Python–but which means we know what we’re trying to build ahead of time. A lot of our work in the past 10 years was speculative: we think this would be helpful, let’s build it and see what the users think. And a lot of it was trying to meet user demands when the users didn’t really know what they wanted, just a vague idea.

Our first rebuilt-in-Python application went to production in October. It took longer than expected, but I feel really good about the quality of the code in it.

Retrospective

Supposedly, software developers in the Bay Area switch jobs, on average, every 3 years or less. So why have I stayed here for 10?

I like my job. I like the work I’m doing. I like my manager. I like my coworkers. I like that I live 6 miles away and don’t have to get on a highway to commute. I like the impact my work has. I like that I can effect meaningful changes that improve our products. They don’t happen fast or all at once, but I’m quite sure I’d be doing something else if we were still writing everything in house and deploying on Solaris.

The nature of the projects I work on prevents me from saying much of anything about them, but I find the work meaningful. I’m not spending my days trying to figure out how to get more ads in front of more people. Our software has international impact on a regular basis with the goal of improving not just national security, but global security.

I’m not going to get rich, but our health insurance is great, we’re saving money for retirement, we managed to get a house while prices weren’t insane, we’re building up long-term savings and work stays at work. I don’t bring a laptop home, I don’t work on the weekends. I don’t answer emails after dinner.

I like what I’m doing, so I’m going to keep doing it.

Kyle’s Birthday 2019

June 29, 2019 3:19 pm

On my birthday we went on a family adventure to Japantown in San Francisco. I had a goal of finding a bamboo fountain (a shishi-odoshi fountain). I was unsuccessful in that goal, but I did find some neat ceramic dishes and a sake set because I think it looks neat.

Our adventure in to the city just about did us in. But did go out to dinner and then get back home for cake.

Kyle’s Weekend of Solitude

July 19, 2018 9:14 pm

Jess, Heather, and Corinne went down to Texas to visit with her family for about a week.  This left me in the unprecedented situation of having a weekend with no one home.  I decided to take the opportunity to go do something that no one else in the family would want to do with me.  So I drove up in to the forest and hiked a mountain.

There are a handful of old fire lookouts scattered across the American West that you can rent out.  I thought that’d be fun to do, but when I was making these plans a couple months ago everything was already booked.  So I thought it would still be fun to hike up to one anyways.  Turns out the one I was looking at is closed for repairs so I could hike up and not bother anyone.  I found a little hidden gem of a cabin nearby.  I wasn’t sure it really existed as I could find no information about it except the one Recreation.gov information page.

Hirz Cabin

I’m a bit reluctant to share my find because right now it’s basically unused and easily booked.  But that runs the risk of it being closed down due to inactivity and it could use a few repairs.  So, here it is: Hirz Cabin on Shasta Lake.

It is fully off grid with solar panels and a battery bank to provide electricity.  It has a propane tank for heat, hot water, and refrigerator.  I had never seen a propane refrigerator before; didn’t know they even existed.

It has two bathrooms, three bedrooms, a full kitchen, dining table, living area, and deck.  Nothing else around it with a private gated driveway.  The introvert’s dream.

Finding it is not easy–even with directions.  So I’ll help out with that.  Here are the geo-coordinates of the cabin: 40.868194, -122.255826.

Here are some pictures.  You should find all these same pictures on the Recreation.gov page (once they’re approved) as I uploaded them all to their site as well.

Driveway and gate, coordinates 40.86750, -122.25534

Front of cabin. 2 picnic tables. Grill.

Back of cabin. Deck with Adirondack chairs.

1 of 2 bathrooms. Mirror images of each other. Shower stall, toilet, sink, heater.

Kitchen

Dining / Living Area

Downstairs bedroom

Upstairs Bedroom 1

Upstairs Bedroom 2

I arrived Friday evening and hiked along the lake for a couple of hours before heading to bed.  On Saturday I slept in, ate breakfast, and swept and mopped the floors downstairs as they really needed it.  I did some reading and preparing of my gear.  I cooked myself a nice dinner to load up for my hike.

The Hike to Hirz Mountain Lookout

As sunset approached it was time to head up the mountain.  Since the day was about 109F my plan to was to take off in time to reach the top before sunset and then hang out and cool down before returning after dark.  The location of this lookout was also not entirely clear.  Some Google-maps sleuthing led me to correct location of the trailhead, but I wasn’t able to identify the location of the lookout.

So, here’s the geo-coordinates of the trailhead: 40.873803, -122.292095.  You can drive up the dirt access road using a 2-wheel-drive vehicle until you reach 40.886311, -122.287697.  At that point the road becomes 4-wheel-drive / high-clearance only.  The lookout itself is at 40.897022, -122.245674.

Trailhead to Hirz Mountain Lookout

I drastically underestimated how long it would take me to get up the mountain (5 miles with a 36-pound backpack) so I did not make it up in time for sunset.  I took a picture with my phone along the way, but it does not do it justice, it was a really nice sunset:

I did, however, get up in time to catch moonset–which was awesome:

Moonset from Hirz Lookout. July 14, 2018.

Venus, I believe, was hanging out with the Moon that evening:

Venus and the Moon from Hirz Lookout. July 14, 2018.

Since it was dark I wasn’t able to get a picture of the lookout itself, but here’s the plaque at the base as proof I did make it up:

Hirz Mountain Lookout Plaque

And the last full view of the moon before it slipped below the mountains:

I had originally intended to hang out at the lookout past sunset and take some pictures of the stars.  But, I discovered that during my 3-hour hike up I had drunk all but a cup of my 100 ounces of water.  So I figured I better start heading down again while that water was still in my system as I had no way to replenish it.

2 hours and 40 minutes later I was back down the mountain and my legs ready to collapse.  I drove back to the cabin and dropped in to bed.

Shasta Dam

Eventually I got up the next morning and while my legs were not happy about it, they did support me.  I packed up my car and locked up the cabin and headed in to Redding to find a whole pile of food to eat.  Pancakes, bacon, eggs, and hash browns from a Country waffles made for a nice breakfast (and lunch).

After filling up I drove out to Shasta Dam to catch a tour.

You can catch the resident ospreys in one the nests near the visitor’s center:

I like this sign because it reminds of something that would have appeared in a late-1990s / early-2000s video game set in the future.  And now we live in the future:

Shasta Dam is one of the largest in the country.  Not as tall as Hoover, but larger overall.

On this tour you do get to go through the generator room.

After my tour I loaded back up in the Civic and drove back home.  It was a fun little trip.  I think we’ll have to take a family trip up to the cabin some fall when it’s not too hot and maybe rent a 4WD vehicle to drive everyone up to the fire lookout to watch sunset.

 

Kyle’s Birthday 2018

July 16, 2018 10:45 pm

My birthday happened to fall on Saturday this year which is always nice.  I “helped” Heather and Corinne assemble birdhouse kits in the morning.  Which is to say I built a birdhouse for Corinne and helped Heather build hers.

After lunch we went over the library where they were having engineering projects for kids.

Heather got to play with a hammer (turns out all you really need for “engineering” to entertain kids is hammers, nails, and blocks of wood), played with some large blocks, built a maze, and worked on a raft.

Corinne, on the other hand, tripped on the sidewalk as soon as we got there and badly skinned up her knees.  She spent the time there in pain and crying.  So we ended up leaving earlier than planned and going home to open presents.  They both enjoy helping unwrap gifts.

We went out to dinner at a local Mexican restaurant and then home again for cake.  We didn’t have enough candles, so I had Jess use a binary format to describe my age.  What you can’t see well in this pictures is the holes poked in the cake between the candles to represent the zeros in 100001.

And if you want to talk on the phone in our house this is how it’s going to happen:

Home Board

March 11, 2018 7:19 pm

Okay, “Home Board” is a dumb name, but I don’t know what else to call it.  Now that we have that out of the way, let’s talk about this cool thing I built.

This is a 7.5″ e-ink display mounted inside a picture frame.  It’s hooked up to a Raspberry Pi and updates the weather and calendar information every 15 minutes.  During “special events” it displays an additional celebration message (see example below).

This is a product I’ve wanted for a long time, but no one made such a thing as far as I could find.  So I finally decided to make it myself.

As you can see, the back is a bit of a mess; but it’s all attached, so you only have to run the power cord.

It would be cleaner if I were using a newer Raspberry Pi. The display comes with a “hat” (zip-tied to the frame stand in this picture) that fits directly on the GPIO pins of the newer Raspberry Pi.  It doesn’t fit on the version 1 (which I’m using here), so I had to use the provided multi-colored wires and connect the pins myself.

Also, the newer RPis use microSD cards that don’t hang over the edge of the case (behind the power connectors).  And they have built-in Wi-Fi so there’d be no additional dongle (the blue glow at the bottom).

The 7.5″ screen was the largest e-ink display I could find.  Someone used to make a 10.2″ one, but it appears to be discontinued.  The refresh rate is terrible (about 15 seconds to change images, with lots of flashing throughout).  But for my purposes that’s fine.  I’m only updating it every 15 minutes.

Here’s a sample image of a birthday display:

I wanted a e-ink display for 2 reasons.  The first is that it doesn’t glow, so being on all night isn’t annoying. And the second is that it’s super low power.  Power is only needed while updating the display.  It pulls its power from the Raspberry Pi, which, at full draw, maxes out at ~2 watts.  Which means, assuming some loss in the power adapter, is less than $5 a year (I’m pretty sure I did that math right).

It’s awesome.

Parts

  1. Waveshare 7.5 inch e-ink 3-color display with Raspberry Pi connector.
  2. Raspberry Pi with case and power supply (I’m using a version 1, but the display works with 1, 2, or 3).
  3. 5×7″ Picture frame
  4. Some miscellaneous mounting hardware to attach Pi to back of frame

The total cost of hardware is about $125 (display, RPi, SD card, case, power supply, cord, frame, mounting hardware).

Software

  1. Weather Underground API (low-volume developer key is free)
  2. Google Calendar Python API
  3. Waveshare driver to interact with the display (included in my code, below)
  4. My custom written Python application that pulls the data together, generates the image, and sends it to the display.