“It is all about structure and vision.”

Why principles, pattern languages and patterns?

Lets start with the most general definition of the term “pattern language”:

“A pattern language is (at least) a collection of patterns that work together and admit “sequences” of patterns that solve problems larger than those of the individual patterns. (Bergin 2013, section “Format of a Pattern Language”)”

This means that pattern languages are a general and universal principle or methodology for problem solving. There does not only exist one single problem but many others in our daily life. But the probability that someone else has to handle ir (as the problem is reoccuring there is a need for a pattern or language) or already has handled the problem is high. Therefore there must exist one pattern language or one pattern to address every problem of these.

A language suggests a sequential application of patterns dependent on

  • the situation before applying a pattern
  • the problem before applying a pattern and
  • the forces which influence which pattern of alternatives are influenced by

addresses from large-scale to small-scale patterns.

  • despite of fact that wikis do relay on the same theory
  • focus on problem, not on content
  • focus on problem related referencing, not on content related referencing
  • structuring of single patterns
  • situation, problem, solution, resulting situation
  • conformance with problem solution methodology
  • effective

In many cases patterns are pattern lanugages itself. The identification of “Child Patterns” and its meta-data may evolve a pattern to a pattern language.

Principles have to be considered as forces for patterns.

Pattern languages and patterns are part of the “pattern theory” (Leitner 2015, section “The concept of the pattern”) developed by the architect, systems theorist and philosopher Christopher Alexander. The pattern languages and patterns are very practical. The basic concepts of the pattern theory are not. However my interpretation of the relation between pattern languages and patterns with these basic concepts is to live a more relaxed life and beeing able to spend more and enjoyable time with the people i love. This makes the pattern theory as a whole very practicable for me.

A “real world” example

Pattern languages and patterns are everyhwere. In most cases we apply patterns intuitively without thinking about it. While applying it we benefit from our experiences or information we read about a topic before. However we do not use all the power patterns provide if selecting and thinking about it explicitely.

The following pattern languages shall point out the existence and benefit from it in daily life. The basic meta-data for patterns are used: context, problem, forces, solution and resulting context. To point out that pattern languages must not include only other patterns the example proposes another (lower level) pattern language in addition to a pattern. This makes the challenge with pattern lanuages and patterns obvious: it is not challenging to collect and summarize patterns, but it may become very complex to structure several of them in a pattern language. Even if the pattern languages scope is just for a very limited context (see e.g. Unit Test Automation Pattern Language).

Grocery Shopping Pattern Language

Context:

You need to buy some grocery.

Problem:

You do not know how to structure your shopping tour to get all grocery “as effective” as possible.

Forces:
  • time you can spend
  • time you want spend
  • actual time -> time frame the shop is open
  • your mood (stress, relaxed)
Solution:

Depending on what “effective” means for you in this situation you cand apply on of the following patterns in the context of buying grocery. If you have much time, the store has open long enough, you want to spend much time

  • effective means fast: Fast Shopper Pattern
  • Anti-Cyclic Shopper Pattern
  • Bulls-Eye Shopper Pattern
  • Scanning Shopper Pattern
  • effective means relaxed: Vacation Shopper Pattern
Resulting context:
 

You have bought all grocery you required. Depending on the applyed pattern you eather

Fast Shopper Pattern

Context:You have little time and you may not spend more time than available.
Problem:You run out of time while shopping and you do not get all grocery you need.
Solution:Get your grocery as fast as possible.
Resulting context:
 You can apply either the “Bulls-Eye Shopper Pattern” or the “Scanning Shopper Pattern”.

Anti-Cyclic Shopper Pattern

Context:You are not forced to go shopping in a predefined time frame.
Solution:Go shopping when nobody else does.
Resulting context:
 You are more relaxed because you avoid “running the gauntlet” (other shoppers). You do not spend time in the waiting line for paying.

Bulls-Eye Shopper Pattern

Context:

You do know the store floor plan (e.g. from previous shopping tours) OR the grocery store areas are labeled (e.g. “cereals”).

Solution:
  • Think about where the grocery is located.
  • Think about a sequence of grocery which leads to an as short as possible walking route.
  • Go straight to the areas where your grocery is located by walking along your shopping tour specific walking pattern.
Resulting context:
 

You got your grocery as fast as possible. The probability to miss grocery is little. (Really!? Or is it better to use the “Grocery Delivery Pattern” instead!?)

Scanning Shopper Pattern

Context:

You do not know the store floor plan (e.g. from previous shopping tours) AND the grocery store areas are not labeled (e.g. “cereals”).

Solution:
  • Get an overview of the store floor plan.
  • Walk along an as short as possible walking path (e.g. row-wise from right to left).
  • Scan all the grocery.
  • Get the grocery if you find
Resulting context:
 

You get the grocery nearly as fast as with the “Bulls-Eye Shopper Pattern”. But you probably do not get all grocery because the store does not offer all of it.

Vacation Grocery Shopper Pattern

Context:You are on vacation and have much time.
Solution:Get the grocery as relaxed as possible: do not hurry, ignore people which apply the “Fast Shopper Pattern” or the “Bulls-Eye Shopper Pattern”.
Resulting context:
 You spend more time than required to get your grocery. But you are relaxed. Because you had a lot of time think about what you want you will have bought all the grocery required for sure.

The project history

From 2008 on the launcher of this website began to gain practical experience in the context of Embedded Software Development. The first notes have been created then and have been structured and maintained on local filesystems. From 2012 to 2014 the content has been published as ebook on the lean publishing platform https://leanpub.com/.

From the very first the idea has been to share knowledge in an interactive, structured, maintainable and sustainable manner. The first interactive version of the content arose on a local testserver as WordPress implementation and has been launched on “non-public” webhosting in 2014. Its public lauch on http://eswkms.org followed immediatelly. In February 2015 the ESWKMS has been migrated to TYPO3 to optimize issues regarding user management, versioning and publication management.

After over 6 months of experimenting with TYPO3 as full-featured content management system (CMS) its disadvantages (e.g. maintainance cost, complexity for users, etc.) outweighed its advantages (e.g. content management mechanisms, file management, etc.). To ensure best community interaction and a broad user community the ESWKMS has been migrated to https://github.org for project contribution in September 2015.

To make the project as valuable as possible the structuring of the content and the content itself has been optimized related to “pattern languages” and “patterns”. To reflect the evolution of the project regarding the content and its intend the project has been renamed from ESWKMS (Embedded Software Knowledge Management System) to ESWP3 (Embedded Software Principles, Procedures and Patterns). The content is published with readthedocs.org on http://eswp3.org. Feel free to contribute on https://github.com/fkromer/eswp3.