Quick Start
install the utter ruby gem on your system
generate an utter classic-style project
package an utter component as a gem
deploy an utter container component
Philosophy
Utter Extenstions are software artifacts in the form of gems that act as bounded context knowledge extenstions form the core, supporting, and generic domains.
Building a Software System often requires the utilization of knowledge from a number of different domains.
An Utter Domain-specific Microservice is sourcecode artifact that encapsulates a Domain-driven Design bounded context of knowledge including its core domain, as well as supporting, and generic domains; all via middleware extensions.
context is the setting in which a word or statment appears that determines its meaning.
bounded context is the conditions(rules) under which a particular model is defined and applicable.
Utter components are software artifacts that consume and produce messages.
Utter project contains: service.rb, context.rb, core/, supporting/, generic/.
isolated logical domain models (bounded contexts), isolated autonmous teams, isolated datastores.
focus on a specific core domain,
while incorporating knowledge from other supporting, and generic domains, via extensions.
-
Components act as a Pure Functions
clear ordering of what is going to happen,
very clear dependencies as they are pure functions (A pure function is a function where the return value is only determined by its input values, without observable side effects.),
very easy to test,
(Pure Functions are good!)
When a function performs any other “action”, apart from calculating its return value, the function is impure. It follows that a function which calls an impure function is impure as well. Impurity is contagious.
Referential Transparency: Any invocation of an Utter component(pure function) can always be replaced by its result.
(write domain extenstion example) There’s no difference between Math.cos(Math::PI) and -1; we can always replace the first with the second.
Localized State: A pure function can only access what you pass it, so it’s easy to see its dependencies. We don’t always write functions like this. When a function accesses some other program state, such as an instance or global variable, it is no longer pure.
-
Everything is a Component
Utter components keeps a low line count as they are context specific thus approachable by new hires mapping to an overall low cost.
Utter projects have high availability via modular, partial deployments of individual microservices.
Utter perceives a microservice project as a single service, a single domain, and a number of domain-extenstions.
The service could have a number of endpoints that are part of the whole system API in production when mounted.
The domain is an isolated bounded-context refined at well-balanced scale with respect to the whole system.
The objective of this domain isolation is to limit complexity of a solution,
via providing the means for the domain-experts to engage in providing the solution.
The domain could have a Domain-specific language (DSL) that aids in attaining experts' aid in tackling the domain challenges.
Domain-extenstions are the means for incorportating knowledge from domains(supporting, generic) in a packagable manner.
Usually your system will be composed out of a number of microservices. Each of those microservices shall contain a service component, a domain component, and a number of domain extenstion components.
Utter components are easily testable, with clear dependencies, and easy to understand as they follow a common functional interface structure.
Utter components are independently replaceable and independently upgradable.
Every component granularity is dictated via the role it acts, in relevance to the context in which it will be represented.
Sample Apps
-
Utter classic-style is best-suited to individuals for building whole domain-specific microservcies as single distributable gems, check sample.
-
Utter modular-style is best-suited to small teams for building independent domain-specific microservice components as multiple distributable gems, check sample.
Open Source
Can we do better? Utter is opensource, meaning if you like to adjust it for the betterment of your experiance, as well as others, you can simply start engaging via reading the source, forking it, or via submitting a feature request\reporting a bug to improve it, all contributions count!
License
MIT license
Community
Join the discussion at #utter on irc.freenode.net
Consulting\Training
hackspree.com
[add your company here]
Credits
Eric Evans - DDD & Microservices: At Last, Some Boundaries!
Mitchell Hashimoto - Rack Middleware as a General Purpose Abstraction
Rich Hickey - Simplicity Matters
Robert Cecil Martin - Architecture the Lost Years