Because diagrams-as-code use text-based files, they can be stored and versioned in the same source control system as application code. Header-based API Gateway versioning with CloudFront Diagrams as codeĪfter diagrams are created, the next question is where to save them and how to keep them updated. The rectangle with the bent upper-right corner is a note containing additional useful information.įigure 5. The text inside guillemets («like this») indicate a stereotype, which refines the meaning of a model element. The dashed lines represent reply messages. Messages are arranged in time sequence from top to bottom. The horizontal arrows between participants are messages, with the arrowhead indicating message direction. The parallel vertical lines underneath these participants are lifelines. In Figure 2, User, Web Distribution, and Origin Request are each actors or system participants. Let’s investigate the system use case where the API is called without a header indicating the requested version using a Sequence Diagram. I use this diagram type for analysis and design purposes and to validate my assumptions about data flows in distributed architectures.
Sequence Diagrams model the ordered logic of usage scenarios in a consistent visual manner and capture detailed behaviors. Sequence Diagrams are part of a subset of behavior diagrams known as interaction diagrams, which emphasis control and data flow. High-level architecture diagram Sequence Diagrams It also demonstrates behavioral aspects from a Communication Diagram, which uses messages represented by arrows labeled with chronological numbers.įigure 1. It includes structural aspects from a high-level Deployment Diagram, which depicts network connections between AWS services.
User sends an HTTP request to CloudFront, including a version header.The numbered labels in Figure 1 correspond to the following text descriptions: Amazon CloudFront is a global content delivery network (CDN) service built for high-speed, low-latency performance, security, and developer you run functions that customize the content that CloudFront delivers. The architecture is based on Implementing header-based API Gateway versioning with Amazon CloudFront from the AWS Compute Blog, which uses the AWS to dynamically route the request to the targeted API version.Īmazon API Gateway is a fully managed service that makes it easier for developers to create, publish, maintain, monitor, and secure APIs at any scale. All diagrams in this post were rendered from a text-based domain specific language using a diagrams-as-code tool instead of being drawn with graphical diagramming software. Each diagram adds to the vocabulary and graphical notation of Sequence Diagrams, then shows how the diagram deepened understanding of the architecture. This post takes a sample architecture and iteratively builds out a set of Sequence Diagrams. Using Sequence Diagrams, you can explore additional usage scenarios and enrich your understanding of the distributed architecture while continuing to communicate visually. As the level of detail increases, so does the diagram’s size, density, and layout complexity. Architecture diagrams visually communicate and document the high-level design of a solution.