design
VerifiedCore1.3.0Use when: When you are deciding how the system is put together: its parts, where data lives and what it talks to.
How the system is built, with no technology chosen: components, datastores, queues, interfaces, externals and the environments they run in. Enrichment packs (API detail, hosting, containers and the rest) attach to these nodes with details.
Add it
Open it in trumly cloud to start a project with this pack already in. In an existing project, open the editor's Packs tab, choose design, then Add. Nodes you change after adding are kept when the pack is upgraded.
From a known source. Reviewed by us, and the publisher is known.
Explore is a read-only demo in your browser: nothing to sign in to, and nothing is saved.
- Namespace
dsn--- Size
- 27 nodes
- Needs
- links@^1.0.0, define@^1.0.0
- Publisher
- trumly
- Versions
1.3.0·1.2.0·1.1.0·1.0.0- Checksum
d66218a977397226…
Examples 1
- The ops API as componentsA starting point
Two components, the database they share, a queue between them, the interface and where they run, each satisfying a requirement.
Show the 16 nodes
- Status shown
acceptance-criterionacceptance-criterion-status-shown - Operations staff
actoractor-ops-staff - Job volume stays modest
assumptionassumption-job-volume - View job status
capabilitycapability-view-job-status - Ops API service
componentcomponent-ops-api - Nightly report job
componentcomponent-ops-report - Job
conceptconcept-job - Data stays in UK/EU
constraintconstraint-uk-eu-data - Operations database
datastoredatastore-ops-db - Production
environmentenvironment-production - Timely visibility
goalgoal-timely-visibility - Ops API
interfaceinterface-ops-api - Job status age
metricmetric-status-freshness - Report recipients
questionquestion-report-recipients - Job events
queuequeue-job-events - Status is fresh
requirementrequirement-status-freshness
- Status shown
Patterns 4
Small fragments you lift into a project of your own. In the editor or through an agent, insert one under its root node.
- Decoupling queueA queue between a producer and a worker so the producer never waits and bursts are absorbed, with a place for messages that keep failing. Rename the nodes to your work, scale the workers, and link each component to a requirement and an environment.Hangs from a
queue. - Event hubA durable stream that producers append to and consumers read at their own pace, and can read again. Rename the nodes to your events, add a consumer for each reader, and link each component to a requirement and an environment.Hangs from a
hub. - MicroserviceOne service that owns its data, is reached only through its API, and announces what happened as events. Rename the nodes to your service, add the callers and listeners, and link each component to a requirement and an environment.Hangs from a
service. - Publish and subscribeOne publisher announces events on a topic and any number of subscribers each get a copy. Rename the nodes to your events, add a subscriber for each reader, and link each component to a requirement and an environment.Hangs from a
topic.
Planes 1
- Design
Types 6
- componentUse for a part of the system that does work and that someone owns: a service, an app, a scheduled job, a library or a function. Every component should satisfy a requirement.
- datastoreUse for somewhere data lives between runs: a database, a cache, an object store, a search index or a file area.
- environmentUse for a named place the system runs, such as production, staging or a developer's machine.
- externalUse for a system or service outside this design that it depends on or that depends on it, such as a payment provider or the company's sign-in service.
- interfaceUse for a boundary other things talk to: an API, an event feed, a file format or a command line.
- queueUse for a buffer or stream that carries messages between components without the sender waiting: a queue, a topic or an event stream.
Link types 6
- consumes
Use to say that something relies on an interface, queue, external service or piece of configuration to do its job. - publishes
component → queueUse to say which component puts messages on a queue. - reads
component → datastoreUse to say which component reads data from a datastore. - subscribes
component → queueUse to say which component takes messages from a queue. - uses
actor, external → component, interfaceUse to say who or what calls on a component or interface: a person in a role, or an outside system. - writes
component → datastoreUse to say which component changes data in a datastore.
Calculated values 1
- environment-handle
{code}The short code of an environment, from its code field.
Rules 13
- ErrorEvery component has an owner
- WarningEvery component runs in an environment
- WarningEvery component satisfies at least one requirement
- ErrorEvery datastore has an owner
- WarningEvery datastore is written by a component
- ErrorDependencies do not form a loop
- WarningEvery environment hosts something
- ErrorEvery external names who owns it
- ErrorEvery interface is exposed by a component
- ErrorEvery interface names its protocol
- WarningEvery accepted must-have requirement is satisfied by a design node
- WarningEvery queue has a publisher and a subscriber
- WarningEvery service is used, depended on or exposes something