Resigning From Your Day Job

Last week I wrapped up my employment at Policy Reporter. It was bittersweet to leave a company where I got to play such a big role. During my time we saw tremendous business growth, hired and formed a management team, and had a successful exit when Policy Reporter was acquired by TrailCard. I also had the privilege of hiring and growing an amazing Engineering team, working with a lot of incredible people, form new departments, re-building the technical foundations of the product, building new products, and creating a culture where everyone is respected, friendly, open to learning together, and always looking for ways to get better. As I was preparing to leave I was told the team embodies my value of us all becoming better humans (a deeply held belief and purpose of mine that I didn’t realize had seeped out). I’m sad to have left and I still miss engaging with my team daily.

So… why did I leave? For my situation it was really a choice of remaining and staying safe or leaving and taking a risk to start something new. It’s easy and safe to stay where you are, and often times that’s the right thing to do, but sometimes you know it’s time to move on. For me this was the right time to move on and start something new.

Resigning well doesn’t happen by accident and I propose the best way to do it is by starting to prepare to leave from your first day on the job. When I was hired I knew it would be very unlikely for me to work at the same company for the rest of my life. Also, the practice of making yourself replaceable is quite beneficial for both yourself and the company. What did this look like for me? I started with considering how I could minimize the disruption of my (potential) eventual departure to my colleagues and to the business. I took a number of steps over the years to make the transition more manageable. I documented processes, took detailed records of company equipment, documented roles and responsibilities. I setup the team so there is no single point of failure of expertise or ability to help in any area. I delegated responsibility away. When I still required oversight (where possible) I gave authority for others to make decisions if I was on vacation or unavailable. As best I could I tried to model what a good leader is. I set a high bar for quality and performance and I expect we deliver what we say we’re going to deliver, but I’m also going to care personally for my team members and be okay with it when life happens. This of course leads to the teams culture. As a leader, fostering a healthy culture is a high leverage way to build productive teams. Open communication and a healthy culture makes any challenge (or leadership change) much easier to handle. As they say, “Work hard. Have fun. No drama.” It’s not one thing you can do, but many things including adding redundancy, clear processes and systems, documented plans and joint understanding and buy-in to what is being done.

The part of leaving your employer that everyone thinks of is handing in your notice. This is a key milestone because the small act of me handing in my resignation notice sets in motion a lot of actions that are completely out of my control. Before your hand in your notice, you have time to consider your options. You can consider staying vs leaving. Write a pro/con list. Get advice from the people close to you. I took some time to mentally prepare for what happens next by envisioning the list of things that will (and did) happen, once I handed in my resignation notice. I knew my role would change completely (and it did). I was no longer responsible for leading new initiatives and leading the team, but instead my job was to use my remaining time to hand off responsibilities and set up my successor to be well, successful. I stopped making decisions including who my replacement would be, spending money, or setting priorities. In my case my successor had been chosen quite quickly and was familiar with the organization because the person was on my team, so that made things a lot easier. I no longer made decisions because it would be inappropriate to decide something shortly before I left, leaving others to deal with it (positive or negative). I had a very healthy transition and that gave plenty of time for discussions between me and my successor around context, history, and a chance to explain why some things were done a certain way (hindsight is always 20/20). I got to share what my philosophy had been and the trajectory we were on. Another expected thing that happened is that I started being uninvited from certain meetings (which was a nice change of pace). Then there were a lot of really meaningful conversations I had with my colleagues to say goodbye. On my last day I actually went into the office to return company equipment and clean up my desk which I hadn’t seen in a long time (pandemic resignation).

Wherever you’re at, consider two to three steps you could take this week to make your position more robust and to prepare for a possible future where you have a good departure from your employer.

Upgrade to Git

Remember when Subversion was the new tool that all the cool kids were flocking to? Well, Subversion is now the old and busted, and it’s time to move to Git.

It’s time to upgrade your Subversion repo (if your still using it) to Git because of the benefits you will gain from moving to a more flexible tool.

  1. Distributed: When you checkout (or clone in the git world) a repository, you are checking out all the files in the repository, which means you can work independently of others. You can commit and make changes on master, or another branch without imposing your incomplete changes on the rest of the team.
  2. Simple Merging: Compared to Subversion, merging is fun. Because its so easy, as a developer you are more inclined to make additional branches and use them as they should be used. This adds a lot of flexibility in where and when the changes are pushed to master.
  3. Speed: A subversion commit doesn’t end until all the files have been transferred to the remote server, with git, commits are completed instantly because you are committing to the local repository, not the remote one. Therefore, you don’t have to wait for actions to complete as they are almost instantaneous.

I could go on, but those are the big ones for me. Note: I’m not against other DVCS systems like Mercurial, Bazaar, but I chose Git because of it’s popularity and ability to handle the Linux kernel.

Download GIT now.

Cache Password Protected Website

I needed to write a simple web app to automatically cache a password protected tumblr admin account, so I wrote simple symfony app to do it. It was pretty simple to do because I could leverage the sfWebBrowserPlugin which provides most of the heavy work for simulating a browser and logging into the site.

While this project is setup to cache tumblr, you can easily modify it to cache any website. It’s built in PHP on the symfony framework.

Configure it by changing the apps/frontend/config/app.yml file to add in the blog name, email, and password, with these config parameters: app_tumblr_blog_name, app_tumblr_email, app_tumblr_password

To cache a page, run it via command line:

./symfony tumblr:cache

Source is on github: Cache Tumblr Admin

WordPress Needs a Default Caching Plugin

I find it curious that WordPress, one of the biggest and best blogging platforms currently around does not come default with a caching plugin. I think the WordPress developers should either include one of the excellent WordPress caching plugins, or build their own and then enable it by default. Users and blog hosts worldwide would have better page load performance and improved scalability.

This blog is build with WordPress, and in my first year of blogging, one of my posts received a lot of hits. Unfortunately, the default WordPress install I had setup wasn’t able to cope with the demand effectively. It was taking 2-5 seconds for visitors to load a page. That’s unreasonable for a simple blog and I’m sure I lost a lot of visitors because of it. So I looked into ways to make my blog load faster without paying extra for better hosting hardware. That’s when I found an excellent caching plugin called Hyper Cache.

With Hyper Cache, I made my blog page load from 2-5 seconds under heavy load, to down to less than a second,  under load the same load. The HTML itself only takes about 230ms to download, down from 4000ms, allowing the other resources to start downloading in a paralleled fashion much earlier. How is this possible? Well a caching mechanism works like this: The first time a page is requested, it will render it as normal, but what’s different is that it will save the rendered page in a special cache file. Then, subsequent visitors simply get handed this same cache file immediately, without much PHP processing required. It’s like skipping to the front of the line.

So we can see a cache has a huge effect on performance, and made a big difference to my blog, but what other benefits are there?

  • Many people won’t know what a cache is, or how to install one
  • Better experience for blog owners because they don’t have to learn how to install one after they experience poor site performance
  • Blog is more ready to handle getting slashdotted
  • Will ultimately give WordPress a much better image

In my opinion, well worth it. So WordPress team, please?

Sanitize User Input for XSS in PHP

The best way to sanitize any input from your user is to use the HTML Purifier library. HTML Purifier will remove any XSS from your code, produce valid HTML, and generally make you sleep just a bit safer at night. It doesn’t completely sanitize user input, and you still need to be careful with it before using it anywhere (such as an SQL statement), but it will remove all XSS attacks against your website.

Here’s a simple example of how to use it:

$purifier = new HTMLPurifier();
$purifier->purify($user_string);