Skip to content

Commit caed744

Browse files
committed
Update architecture patterns
1 parent ac9bbb4 commit caed744

1 file changed

Lines changed: 25 additions & 1 deletion

File tree

README.md

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,8 @@
2020
- [Let it vanish](#let-it-vanish)
2121
- [I/O isolation](#io-isolation)
2222
- [State machines](#state-machines)
23+
- [Fail early](#fail-early)
24+
- [Single source shared parameters](#single-source-shared-parameters)
2325
- [Project bootstrapping](#project-bootstrapping)
2426
- [Infrastructure first](#infrastructure-first)
2527
- [Simulation](#simulation)
@@ -422,6 +424,28 @@ time you work on a service that changes its behavior in response to some command
422424
messages, for example using <http://wiki.ros.org/actionlib>, it is necessary to
423425
consider a finite state machine.
424426

427+
Fail early
428+
----------
429+
430+
Early failures usually have lower cost, for example, if you can detect a failure
431+
during source code compilation you are saving time on deployment and tests, if
432+
you can validate drone state before takeoff you can potentially avoid a crash,
433+
and so on.
434+
435+
Single source shared parameters
436+
-------------------------------
437+
438+
Parameters shared by different components of the stack should come from the same
439+
source. If they are stored in multiple independent locations, they are
440+
inevitably going to get out of sync, which, in turn, would lead to failures or
441+
poor performance. Extraction and distribution of shared parameters should not
442+
necessarily happen at runtime, on the contrary, it may be preferable to perform
443+
this during startup or build phases in order to comply with “fail early”
444+
principle.
445+
446+
For example, an URDF / SDF model of a robot can be the source of its total mass
447+
and geometric dimensions.
448+
425449
Project bootstrapping
426450
=====================
427451

@@ -446,7 +470,7 @@ Simulation
446470

447471
Simulation is a crucial component for testing your system. All code should
448472
always be validated in simulation before deployment to save time and reduce
449-
risks. For this reason simulation must be implemented as early as possible.
473+
risks. For this reason simulation must be implemented as soon as possible.
450474

451475
Integration tests
452476
-----------------

0 commit comments

Comments
 (0)