Component Diagram

This page presents the architecture views of the RDMC Creation Workflow platform across four levels of detail: Context, Container, Components, and Code. For architectural terminology, see Project Structure. For layer responsibilities, system overview, and the component inventory, see Architecture.

Architecture Views

All components run inside one process and share one database. The architecture is shown in four levels (Context, Container, Components, and Code), from the overall system down to the code. The component diagram breaks the application down into its internal packages grouped by architectural layer.

Level

Meaning in the Platform

Context

The platform as a single system, its users, and the external systems around it.

Container

The main building blocks of the platform and the data storage they share.

Components

The individual components of the application, grouped by architectural layer.

Code

The folder and file structure that every component shares.

Context

        %%{init: {"c4": {"width": 220, "c4ShapeMargin": 15}}}%%
C4Context
    Boundary(ctx_border, "System Context Overview") {
        Boundary(users_row, "RDMC Users") {
            Person(participant, "Participant", "Creates research containers")
            Person(organiser, "Organizer", "Configures the workflow")
            Person(visitor, "Visitor", "Views published containers")
        }

        Boundary(sys_row, "Main System") {
            System_Ext(left_spacer, ".", ".")
            System(rdmc, "RDMC Prototype", "Manages research containers")
            System_Ext(right_spacer, ".", ".")
        }

        Boundary(ext_row, "External Platforms") {
            System_Ext(publ, "Publication Platforms", "Publish containers")
            System_Ext(exec, "Reusable Execution Environment", "Runs container jobs")
            System_Ext(metas, "Metadata Services", "Semantic annotation")
            System_Ext(right_spacer, ".")
            System_Ext(eval, "Artifact Evaluation", "Artifact review")
        }
    }

    Rel(participant, rdmc, "")
    Rel(organiser, rdmc, "")
    Rel(visitor, rdmc, "")

    Rel(rdmc, publ, "")
    Rel(rdmc, exec, "")
    Rel(rdmc, metas, "")
    Rel(rdmc, eval, "")

    UpdateElementStyle(left_spacer, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(right_spacer, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")

    UpdateLayoutConfig($c4ShapeInRow="6", $c4BoundaryInRow="1")
    

Container

        %%{init: {"c4": {"width": 190, "c4ShapeMargin": 15}}}%%
C4Container
    Boundary(cnt_border, "Container Runtime View") {
        System_Ext(p1, ".", ".")
        System_Ext(p2, ".", ".")
        Person(user, "RDMC User", "Browser or REST client")

        System_Boundary(rdmc_sys, "RDMC Prototype") {
            Boundary(entry_zone, "Entry") {
                System_Ext(p3, ".", ".")
                Container(web_ui, "Web Interface", "", "Wizard, viewer, administration")
                System_Ext(p4, ".", ".")
                Container(rest_api, "REST API", "", "Creates containers programmatically")
            }

            Boundary(core_zone, "Core and Persistence") {
                System_Ext(p5, ".", ".")
                System_Ext(p6, ".", ".")
                Container(core, "RDMC Creation", "", "Container Wizard")
                ContainerDb(shared_db, "Shared Database", "", "Data saved through rdmc")
            }

            Boundary(srv_zone, "Service Layer") {
                Container(svc_pub, "Publishing", "", "Publication and search registration")
                Container(svc_ree, "REE", "", "Execution environment")
                System_Ext(p7, ".", ".")
                Container(svc_sign, "Signing", "", "Signing RDMC")
                Container(svc_ae, "Artifact Evaluation", "", "Review and evaluation")
            }
        }
    }

    Rel(user, web_ui, "")
    Rel(user, rest_api, "")

    Rel(web_ui, core, "")
    Rel(rest_api, core, "")

    Rel(core, shared_db, "")
    Rel(core, svc_pub, "")
    Rel(core, svc_ree, "")
    Rel(core, svc_sign, "")
    Rel(core, svc_ae, "")

    UpdateElementStyle(p1, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(p2, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(p3, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(p4, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(p5, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(p6, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(p7, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")

    UpdateLayoutConfig($c4ShapeInRow="7", $c4BoundaryInRow="1")
    

Components

        %%{init: {"c4": {"width": 165, "c4ShapeMargin": 8}}}%%
C4Component
    Container_Boundary(cmp_border, "RDMC Application") {

        Boundary(l_sec, "Security Layer") {
            System_Ext(q12, ".", ".")
            System_Ext(q13, ".", ".")
            System_Ext(q14, ".", ".")
            System_Ext(q15, ".", ".")
            Component(auth, "rdmc_auth", "", "Login and permissions")
        }

        Boundary(l_int, "<br>Integration &<br>Persistence Layer") {
            System_Ext(q1, ".", ".")
            ComponentDb(db, "Shared Database", "", "Data saved through rdmc")
            Component(api, "rdmc_workflow_api", "", "REST API for containers")
        }

        Boundary(l_ui, "UI Layer") {
            System_Ext(q3, ".", ".")
            System_Ext(q4, ".", ".")
            System_Ext(q5, ".", ".")
            System_Ext(q6, ".", ".")
            System_Ext(q7, ".", ".")
            Component(view, "viewer", "", "Read-only container viewer")
            Component(mgmt, "rdmc_management", "", "Organizer administration")
        }

        Boundary(l_biz, "Business Layer") {
            System_Ext(q8, ".", ".")
            System_Ext(q9, ".", ".")
            System_Ext(q10, ".", ".")
            Component(meta, "rdmc_metadata", "", "Metadata and manifest")
            Component(core, "rdmc", "", "Container Wizard")
            Component(conf, "rdmc_configuration", "", "Workflow configuration")
        }

        Boundary(l_srv, "Service Layer") {
            System_Ext(q11, ".", ".")
            Component(mb, "metabase", "", "Semantic annotation proxy")
            Component(ae, "artifact_evaluation", "", "Review and evaluation")
            Component(ree, "ree_service", "", "Execution environment client")
            Component(sign, "rdmc_sign", "", "Signing")
            Component(pub, "rdmc_publish", "", "Publishes to repositories")
            Component(search, "search_portal", "", "Search portal registration")
        }
    }

    Rel(mgmt, conf, "")
    Rel(view, core, "")
    Rel(api, core, "")

    Rel(core, auth, "")
    Rel(core, conf, "")
    Rel(core, meta, "")
    Rel(core, db, "")

    Rel(core, ree, "")
    Rel(core, sign, "")
    Rel(core, pub, "")
    Rel(core, ae, "")
    Rel(pub, search, "")
    Rel(meta, mb, "")

    UpdateElementStyle(q1, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q2, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q3, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q4, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q5, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q6, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q7, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q8, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q9, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q10, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q11, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q12, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q13, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q14, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")
    UpdateElementStyle(q15, $bgColor="transparent", $fontColor="transparent", $borderColor="transparent")

    UpdateLayoutConfig($c4ShapeInRow="9", $c4BoundaryInRow="5")
    

Code

        flowchart TB
    subgraph COMP["Component Code Structure"]
        VIEWS["<b>views.py</b><br/>Entry points"]:::hub

        URLS["<b>urls.py</b><br/>URL routing"]:::code
        HAND["<b>handlers/</b><br/>Complete workflows"]:::code
        HELP["<b>helpers/</b><br/>Reusable support logic"]:::code
        MODELS["<b>models.py</b><br/>Data models"]:::code
        TPL["<b>templates/</b><br/>HTML templates"]:::code
        INIT["<b>__init__.py</b><br/>Package marker"]:::code

        MIG["<b>migrations/</b><br/>Schema migrations"]:::code
        STAT["<b>static/</b><br/>CSS, JS, images"]:::code
    end

    URLS --- VIEWS
    HAND --- VIEWS
    HELP --- VIEWS
    MODELS --- VIEWS
    TPL --- VIEWS
    INIT --- VIEWS

    MODELS --- HAND
    MODELS --- HELP

    HAND --- HELP
    MODELS --- MIG
    STAT --- TPL

    classDef hub fill:#438dd5,stroke:#2e6295,color:#fff
    classDef code fill:#c9e4ff,stroke:#5d82a8,color:#000
    style COMP fill:none,stroke:#888,stroke-dasharray: 5 5