Small trees sometimes have long roots. In the case of software development, what may seem like a little feature can need a lot of work. A third party partner requested a link to appear on the client user interface. This write-up aims to clarify what went into executing and deploying a simple link and why it is not as easy as it seems.
Adding a new column requires several steps:
- Adding a database migration into the API code base. The migration communicates the schema change to the entire development team, and across environments, and helps us maintain our development velocity.
- The data is loaded into our QA and Production environments. Over 200+ records needed updating in this particular instance.
- Our code currently depends on a stored procedure. It must be updated to return the new link column.
API changes need to occur when the link column is present in the database. There are two layers in our API: Data access and the web:
- The data access layer now needs to understand this data point exists. Our data model needs a link property.
- Our web layer takes the new data point and maps it to our representation. The representation is how we present our data to consumer clients.
When completed, we have touched six files and added 122 more lines. We should now be returning the required data. Clients will now be able to use this new data point on their end.
Now that the new data point is accessible, the client can take advantage of it. This change is simple as it only takes a single line addition to the user interface.
Deployment and Testing
With all the development work complete, we move into the deployment phase. Our environment on the API side includes a QA web host and a database. The code is reviewed, merged, and deployed. Once deployed, we test functionality. Completeness includes code and data together producing the expected behavior. The environment for the client is different, and also requires a separate deployment and testing cycle.
When we reach feature complete status, we have touched these resources:
- 3 Environments, which include dev, QA, and production.
- Developer databases, QA databases, and production databases
- API hosts in dev, QA, and production
- Client hosts in dev, QA, and production.
This change affects all environments. It also assumes it is the only change already in the pipeline. Once work is complete, we are left with just a link on a page. What may seem like a simple task at first, can take a lot of work to accomplish.
Software Developer and All Around Nice Guy
Cover image credit: https://www.flickr.com/photos/13606325@N08/