A Service Exists When It Is Declared
The card in a service catalog is a rendering of the manifest, not a table somebody remembers to update. ๐ Hi, I'm Anton - a software engineer working mostly in PHP/Symfony and Go, currently carving a live PHP monolith into Go services. This block is about what a service is to everyone else : whose it is, who calls it, what it promises. This first part takes the plainest of those questions - whatโฆ
The source material discusses the concept of services in software engineering and how they are declared, maintained, and represented. It highlights a particular issue where the version of a service binary can be inaccurate due to a missing symbol in the build process, leading to discrepancies between the audit trail and the service version attribute.
The author, Anton, is a software engineer who discusses their experience in transforming a PHP monolith into Go services. They present a scenario where a service's manifest declares its components, such as daemons, handlers, databases, and queues, but this information is also documented separately in a hand-written description.
The discrepancy arises when the service's version is derived from the hand-written description, which can become outdated and stop being a source of truth. This leads to a breakdown in the information flow, as the hand-written description no longer exists, and the system relies solely on the manifest for accurate service declarations.
The author contrasts this issue with a service catalog or an internal developer portal, where services are entered as cards containing information like owner, links, dependencies, and maturity level. However, the author emphasizes that the service declaration is the source of truth, and any deviation from this declaration, whether in a separate system or hand-written descriptions, can lead to inconsistencies and errors.
To address this issue, the author suggests that the declaration should be the primary source of truth, with the service card derived from this declaration. The card should contain seven rows representing different aspects of the service, such as daemons, resources, environment variables, default metrics, and snapshot. The values in these rows are derived from the declaration and are automatically checked for drift using the build process.
By making the declaration the source of truth and ensuring that the service card is derived from it, the author aims to minimize the risk of discrepancies and maintain accurate and up-to-date information about the services in the system.
Written by urgent.news from Dev.to's reporting โ not their text. Machine-written โ may contain errors; check the original before relying on it.