This is an automated email from the ASF dual-hosted git repository. joergrade pushed a commit to branch ISIS-3073 in repository https://gitbox.apache.org/repos/asf/isis.git
commit aabac8807023431d1d6195daf02f46d68d749d96 Author: Jörg Rade <joerg.r...@kuehne-nagel.com> AuthorDate: Wed Jun 22 18:27:20 2022 +0200 ISIS-3073 overview diagrams for metamodel & eventbus --- .../resources/pages/eventbus_lifecycle.adoc | 42 +++++++++ .../resources/pages/eventbus_terminology.adoc | 58 ++++++++++++ .../docs/modules/resources/pages/metamodel.adoc | 103 +++++++++++++++++++++ .../resources/pages/metamodel_terminology.adoc | 45 +++++++++ 4 files changed, 248 insertions(+) diff --git a/antora/components/docs/modules/resources/pages/eventbus_lifecycle.adoc b/antora/components/docs/modules/resources/pages/eventbus_lifecycle.adoc new file mode 100644 index 0000000000..8ef60c5441 --- /dev/null +++ b/antora/components/docs/modules/resources/pages/eventbus_lifecycle.adoc @@ -0,0 +1,42 @@ +# eventbus_lifecycle +.eventbus_lifecycle +[plantuml,file="eventbus_lifecycle.png"] +-- +@startuml + +(Event\nBus) as EB +(Event\nListener) as EL +EL --> EB : listens + +(<i>Object</i>\nLifecyleEvent) as LCE +LCE -> EB : published to +(Created\nEvent) as C +C -u-> LCE : is a +(Loaded\nEvent) as L +L -u-> LCE : is a + +(Persisting\nEvent) as PNG +PNG -u-> LCE : is a +(Persisted\nEvent) as PED +PED -u-> LCE : is a + +(Updating\nEvent) as UNG +UNG -u-> LCE : is a +(Updated\nEvent) as UED +UED -u-> LCE : is a + +(Removing\nEvent) as RNG +RNG -u-> LCE : is a + +(Factory\nService) as FS +FS -u-> C :emits +(Repository\nService) as RS +RS -u-> L :emits +RS -u-> PNG :emits +RS -u-> PED :emits +RS -u-> UNG :emits +RS -u-> UED :emits +RS -u-> RNG :emits + +@enduml +-- diff --git a/antora/components/docs/modules/resources/pages/eventbus_terminology.adoc b/antora/components/docs/modules/resources/pages/eventbus_terminology.adoc new file mode 100644 index 0000000000..6f96cd3180 --- /dev/null +++ b/antora/components/docs/modules/resources/pages/eventbus_terminology.adoc @@ -0,0 +1,58 @@ +# eventbus_terminology +.eventbus_terminology +[plantuml,file="eventbus_terminology.png"] +-- +@startuml + +skinparam nodesep 20 +'skinparam ranksep 1 + +together { + (Member) as MB + (Presentation) as PST +} + +(Domain\nObject) as DO +(Property) as P +(Action) as A +(Collection) as C +P -u-> MB : is a +A -u-> MB : is a +C -u-> MB : is a + +(Domain\nService) as DS +DO -d-> MB : has +DS -d--> A : has + +(Domain\nEvent) as DE +DE -d-> MB : can be \n declared \n for + +(Execution) as EX +P --> EX : change \n is an +A --> EX : invocation \n is an + +(Event\nBus) as EB +(Spring) as SPRING +SPRING .l.> EB : provides/\nmanages +EX -> EB : is broadcast as: \n * before event (executing) \n * after event (executed) + +(Event\nListener) as EL +EL --> EB : listens +EL -u-> MB : can modify/check: \nvisibility (hide), \nusability (disable), \nvalidity (validate) + +DO ->"title \n icon \n cssClass \n layout" PST +(UI\nEvent) as UIE +EL --> PST : modify +UIE --> EL : receive + +@enduml +-- + +We call the change of a DomainObject's Property or the invocation of a DomainObject's or DomainServices' Action an Execution. Executions are broadcast as events on the event-bus. The framework provides several publisher/subscriber models to listen for specific execution data (readonly). +In addition developers can declare Domain Events specific to Actions, Properties and Collections, that allow event listeners to modify visibility (whether is visible) or usability (whether can change). +In addition there are UI Events, that allow listeners to modify the viewer's use of title, icon, css-class and layout file. +The event-bus is provided/managed by Spring. + +event listener can check: visibility (hide), usability (disable), validity (validate) ... aka "see it, use it, do it". It can also listen to executing (before) and executed (after). + +UIEvent is not published on the EventBus, correct? \ No newline at end of file diff --git a/antora/components/docs/modules/resources/pages/metamodel.adoc b/antora/components/docs/modules/resources/pages/metamodel.adoc new file mode 100644 index 0000000000..f689babc5e --- /dev/null +++ b/antora/components/docs/modules/resources/pages/metamodel.adoc @@ -0,0 +1,103 @@ +# metamodel +.metamodel +[plantuml,file="metamodel.png"] +-- +@startuml +!include <logos/java> +!include <tupadr3/font-awesome/at> +!include <tupadr3/font-awesome/envira> +!include <office/Databases/database_cube> +!include <material/xml.puml> + +legend top +|= notation |= explanation | +| ""__underline__"" | DDD Pattern| +endlegend + +together { + rectangle "<$database_cube><$at>\n<<Annotation>>\nORM (JPA/JDO)" as PERS + rectangle "<$envira><$at>\n<<Annotation>>\nSpring" as SPRING + rectangle "<img:https://isis.apache.org/_/img/home/isis-logo-56x64.png><$at>\n<<Annotation>>\nApache Isis" as FW + rectangle "<img:https://isis.apache.org/_/img/home/isis-logo-56x64.png><$java>\n<<Supprting Methods>>\nApache Isis" as SM + rectangle "<$java><$ma_xml><$at>\n<<Annotation>>\nJAXB" as JAXB + + SPRING -[hidden]- PERS + PERS -[hidden]- FW + FW -[hidden]- SM + SM -[hidden]- JAXB + + note left of SPRING + * __Repository__ + * Name (@Named) + * Service (via FW @DomainService) + * Component (via FW @DomainObject) + end note + + note left of PERS + * Cardinality + * TableName + * Column + ** Name + ** Length + ** Type + end note + + note left of FW + * __Entitiy__ + ** Property + ** Collection + ** Action + * __Factory__ + * Layout + ** Property Sequence + (Table and Forms) + ** Action Sequence (Menu) + ** Styles (cssClass) + * ViewModel + * Mixin + end note + + note left of SM + * autoComplete…() + * choices…() + * default…() + * disable…() + * get…() + * hide…() + * iconName() + * set…() + * title() + * validate…() + end note + + note left of JAXB + * @XmlAccessorType + * @XmlJavaTypeAdapter + * @XmlRootElement + end note +} + +rectangle "<img:https://isis.apache.org/_/img/home/isis-logo-56x64.png>\nMetaModel" as MM + +SPRING -> MM +PERS -> MM +FW -> MM +SM -> MM +JAXB -> MM + +(MetaModelValidation) as MMV +MM <- MMV : perform \n consistency \n check + +rectangle "WicketViewer" as UI +database DB +interface "Restful\nObjects" as REST +MM -d-> UI : generate +MM -d-> DB : generate +MM -d-> REST : generate + +@enduml +-- +note left of UI +File | Edit | Help +end note + diff --git a/antora/components/docs/modules/resources/pages/metamodel_terminology.adoc b/antora/components/docs/modules/resources/pages/metamodel_terminology.adoc new file mode 100644 index 0000000000..fafec25620 --- /dev/null +++ b/antora/components/docs/modules/resources/pages/metamodel_terminology.adoc @@ -0,0 +1,45 @@ +# metamodel_terminology +.metamodel_terminology +[plantuml,file="metamodel_terminology.png"] +-- +@startuml + +skinparam nodesep 20 +skinparam ranksep 1 + +together { + (Domain\nObject) as DO + (Entity) as E + (View\nModel) as VM + DO <-d- VM : is a + DO <-d- E : is a + (Isis) as FW + FW .u.> VM : manages + (Persistence\nLayer) as PL + PL .u.> E : manages +} + +together { + (Member) as MB + (Property) as P + (Collection) as C + (Action) as A + P -u-> MB : is a + C -u-> MB : is a + A -u-> MB : is a +} +DO --> MB : has \n at \n least \n one + +(Mixin) as M +(Mixee) as ME + +M ..> MB : contributes +M -> ME : to +DO -> ME : can \n act \n as + +(Service) as S +(Domain\nService) as DS +DS -u-> S : is a +DS --> A : contribute \n according \n to <i>Nature</i> +@enduml +--