Slide 1

Slide 1 text

qaware.de Down the Ivory Tower towards Agile Architecture Mario-Leander Reimer [email protected] @LeanderReimer

Slide 2

Slide 2 text

2 Mario-Leander Reimer Managing Director | CTO @LeanderReimer #cloudnativenerd #qaware #gernperDude

Slide 3

Slide 3 text

No content

Slide 4

Slide 4 text

1st commandment Thou shalt not use other databases than Oracle!

Slide 5

Slide 5 text

No content

Slide 6

Slide 6 text

6 QAware

Slide 7

Slide 7 text

7 QAware The Wild Agile West

Slide 8

Slide 8 text

QAware | 8 Agile Architecture

Slide 9

Slide 9 text

1st commandment Thou shalt sprint 2 weeks, no less or more!

Slide 10

Slide 10 text

10 QAware https://arc42.org/download arc42 based documentation addresses many important quality and architecture aspects. https://github.com/confluence-publisher/confluence-publisher

Slide 11

Slide 11 text

Holistic Software Product Quality is a lot of work! QAware | 11 Software Product Quality (ISO 25010) ● Modularity ● Reusability ● Analysability ● Modifiability ● Testability Maintainability ● Confidentiality ● Integrity ● Non-repudiation ● Authenticity ● Accountability Security ● Adaptability ● Installability ● Replaceability Portability ● Co-existence ● Interoperability Compatibility ● Maturity ● Availability ● Fault Tolerance ● Recoverability Reliability ● Time Behaviour ● Resource Utilization ● Capacity Efficiency ● Completeness ● Correctness ● Appropriateness Functional Suitability ● Operability ● Learnability ● UI Aesthetics ● Accessibility Usability Safety Deployability

Slide 12

Slide 12 text

Q42. A simple and pragmatic quality modell. QAware | 12 https://quality.arc42.org/

Slide 13

Slide 13 text

The required quality attributes can be found on all layers of your software architecture. 13 Domain Level Debt Technical Debt Technical Debt

Slide 14

Slide 14 text

14 QAware Architecture Diagrams

Slide 15

Slide 15 text

Diagrams as Code using C4: Context. Container. Component. Code. 15 https://c4model.com/

Slide 16

Slide 16 text

Diagrams as Code for Infrastrucure. 16 QAware https://diagrams.mingrammer.com/

Slide 17

Slide 17 text

17 Decisions

Slide 18

Slide 18 text

The Last Possible Moment != The Last Responsible Moment QAware | 18 ■ The Last Responsible Moment what you should aim for! ■ Useful questions for responsible decision making – Do we have to take the decision now? – Can we postpone the decision? – What are the consequences if we postpone? – When will the overall complexity become to high? – What are the alternatives? – What are the trade-offs of our decision? – Can we revert a decision? At which costs? ■ Have no fear of suboptimal decisions! Be brave! ■ Iterative development, TDD, refactorings, continuous integration and deployment, architecture fitness functions can help to address and reduce the risks involved

Slide 19

Slide 19 text

QAware | 19 https://cognitect.com/blog/2011/11/15/documenting-architecture-decisions

Slide 20

Slide 20 text

Architecture Decision Records (ADR) QAware | 20 https://www.thoughtworks.com/radar/techniques/lightweight-architecture-decision-records

Slide 21

Slide 21 text

The Anatomy of an Architecture Decision Record (ADR) QAware | 21 # Title ## Context ## Decision ## Status ## Consequences ■ Short text file; 1-2 pages long, one file per decision ■ Simple format like Markdown, Asciidoc, TXT, etc. Short noun phrase and number, e.g. ADR 5: AWS as preferred cloud provider Proposed, Accepted, Deprecated, Superseded Describes the forces at play: technology, political, project local. Value neutral, simple facts. Response to the forces with justification. Stated in full sentences, with active voice. "We will …" Describe context, after applying the decision. All consequences should be listed here, not just the "positive" ones.

Slide 22

Slide 22 text

Architecture fitness functions continuously validate the desired software quality attributes. 22 https://www.thoughtworks.com/de/radar/techniques/architectural-fitness-function

Slide 23

Slide 23 text

Fitness-function Driven Development QAware | 23 ■ Architecture is like a product with user journeys ■ Requirements are defined by all relevant stakeholders – Business – Compliance – Operations – Security – Infrastructure ■ Often these are exactly the „-illities“ and quality attributes ■ Acceptances criteria are the formulated using a BDD approach and framework ■ Fitness tests are executed and validated as part of CI/CD pipelines (continuously or ad hoc) https://www.thoughtworks.com/de/insights/articles/fitness-function-driven-development

Slide 24

Slide 24 text

Example: Code Quality QAware | 24

Slide 25

Slide 25 text

Example: Performance QAware | 25

Slide 26

Slide 26 text

Example: Security 26 describe "Security" do describe “Static Analysis” do it "should not have plaintext secrets in codebase" do expect(code.has_secrets_in_codebase()).to_not be(true) end end describe “Dynamic Analysis” do it "should not have any of the OWASP Top 10" do expect(zap.has_owasp_top_10_vulnerabilities()).to be(false) end end end

Slide 27

Slide 27 text

Example: Operability 27 QAware

Slide 28

Slide 28 text

The path from a conceptually clean architecture towards the big ball of mud is shorter than you think! QAware | 28

Slide 29

Slide 29 text

ArchUnit enables easy, automated testing of your software architecture in the form of simple unit tests. ■ https://www.archunit.org/ ■ Apache v2 licensed. Simple and extensible open source library for software architecture validation as code: Java and .NET/C# are supported. ■ All major build tools and unit test frameworks are support out-of-the-box. ■ The library provides a collection of predefined rules for recurring architecture validations: – Styles: rules to validate common architectures (e.g. layered, onion, hexagon) – Slices: detect “cycles” on various layers (e.g. classes, packages, modules) – General: collection of rules for good coding practices (e.g. naming, logging, exceptions) – UML: rules to validate the codebase with a given PlantUML architecture model – Freezing: allows the definition of a violation baseline, especially useful to manage the technical debts of legacy projects QAware | 29

Slide 30

Slide 30 text

Just a few lines of code allow to validate your architecture continuously and repeatedly with every build. 30 @AnalyzeClasses(packages = {"de.qaware.archunit.example.onion"}) public class OnionArchitectureFitnessTest { @ArchTest static final ArchRule onion_architecture_is_respected = onionArchitecture() .domainModels("..domain.model..") .domainServices("..domain.service..") .applicationServices("..application..") .adapter("cli", "..adapter.cli..") .adapter("persistence", "..adapter.persistence..") .adapter("rest", "..adapter.rest.."); }

Slide 31

Slide 31 text

31 QAware + Software Engineering Insights

Slide 32

Slide 32 text

Software Engineering Insights Architecture QAware | 32 Packages Package publish update Run deploy watch Deploy watch Dev GitOps Build push Checkout Build Test Quality Package Dev Test (E2E, NFA) trigger test Tests Quality Cockpit report PO report Build Status Code Quality Test Results fitness test

Slide 33

Slide 33 text

QAware | 33 Where wood is chopped, splinters must fall!

Slide 34

Slide 34 text

aim42 can be used to analyse and assess your debts and improve the software architecture in a structured way. QAware | 34 https://www.aim42.org/

Slide 35

Slide 35 text

“Too much cognitive load will become a bottleneck for fast flow and high productivity for many agile teams.” QAware | 35 ■ Intrinsic Cognitive Load Relates to fundamental aspects and knowledge in the problem space (e.g. used languages, APIs, frameworks) ■ Extraneous Cognitive Load Relates to the environment (e.g. console command, deployment, configuration) ■ Germane Cognitive Load Relates to specific aspects of the business domain (aka. „value added“ thinking)

Slide 36

Slide 36 text

Collaboration is key. Software architecture should be defined and worked on collaboratively within all teams and layers. QAware | 36 https://martinfowler.com/bliki/TeamTopologies.html Architecture Architecture

Slide 37

Slide 37 text

Beyond Agile Architecture. My personal book list for inspirations and new approaches. 37 QAware

Slide 38

Slide 38 text

qaware.de QAware GmbH Aschauer Straße 32 81549 München Tel. +49 89 232315-0 [email protected] twitter.com/qaware linkedin.com/company/qaware-gmbh xing.com/companies/qawaregmbh slideshare.net/qaware github.com/qaware Thanks!