TL;DR notes from articles I read today.
- Remove unreachable code, code that doesn’t do anything and code that was put to set up for future features that never materialised.
- Fix hard coding by creating a dynamic interface to allow the value to be changed.
- Overuse of inheritance creates tightly coupled, non-flexible code. Focus on composition to solve this.
- Refactor overly complex comments by extracting methods or variables.
- Refactor data clumps by creating a new parameter object or extracting the class.
Full post here, 5 mins read
- Dogfooding is the practice of using your own product. It is a great approach to test the product with real-world usage and it helps with quality control.
- When it comes to APIs, dogfooding is excellent to ensure great UX. The more you use your own API, the more usable you make it for your customers.
- Dogfood APIs via testing because it will force you to use the API for the first time & find out first usability issues.
- Blogging or documenting the API puts you in the position of a first time user of a specific API. Creating significant new features is another way of dogfooding.
- It best to write APIs from the user’s point of view, and dogfooding your API is one easy way to understand this point of view.
Full post here, 8 mins read
- Monitoring/visibility, reliability & software delivery - focus on these three things that help in improving the quality of production.
- Monitoring four signals - latency, request rate, saturation, and error & success rate - is helpful in catching potential problems.
- Analyzing which components can fail and how their failure can affect the system should be an important step in building new services or refactoring current ones.
- Running end-to-end tests on staging and production is crucial.
- Continuous delivery workflow is extremely important to reduce operational overheads and to enable faster delivery.
Full post here, 4 mins read