# fva-net/maxs-logger-java architecture

> Architecture diagram of the GitHub repository fva-net/maxs-logger-java, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-08-01). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/fva-net/maxs-logger-java
- Repository: https://github.com/fva-net/maxs-logger-java

## Overview

#### Purpose and packaging

`maxs-logger-java` is a Java 17/Maven library, not an application: consuming software uses it to produce MAXS `.maxs` XML log files. Its public operational entry point is `src/main/java/de/fva_net/maxs/logger/MaxsLogger.java`; routine implementations integrate through `src/main/java/de/fva_net/maxs/logger/MaxsLoggableRoutine.java`. Maven packaging, dependencies, and release coordinates are defined in `pom.xml`.

#### Logging façade and control boundary

`MaxsLogger` accepts logging requests, associates them with a loggable routine/context, and orchestrates validation plus XML notification output. `MaxsLoggableRoutine` is the principal extension boundary for REXS/model-side code: callers implement or supply routine metadata rather than coupling their domain models directly to XML persistence. Relevant paths:
- `src/main/java/de/fva_net/maxs/logger/MaxsLogger.java`
- `src/main/java/de/fva_net/maxs/logger/MaxsLoggableRoutine.java`

#### Message classification

`MaxsMessageType` defines the supported severity/category vocabulary (such as INFO, WARNING, and ERROR) used when creating notifications. This separates caller intent from the serialized XML representation and gives the logger a constrained message-type contract.
- `src/main/java/de/fva_net/maxs/logger/MaxsMessageType.java`

#### XML notification domain model

The logger serializes through dedicated XML-oriented DTOs rather than exposing file-format details to callers. `Notification` represents one logged event; `Item` represents associated attributes/items; `KernelNotifications` acts as the document-level notification collection/root. These types carry the required and non-zero attribute validation implied by the MAXS format.
- `src/main/java/de/fva_net/maxs/logger/xml/Notification.java`
- `src/main/java/de/fva_net/maxs/logger/xml/Item.java`
- `src/main/java/de/fva_net/maxs/logger/xml/KernelNotifications.java`

#### Primary flow and persistence

A consumer invokes `MaxsLogger` with a severity, message, routine/context, and optional structured attributes. The logger maps the request into `Notification` and `Item` objects, validates format-required fields, aggregates notifications in `KernelNotifications`, then writes an XML document to a `.maxs` file. The key boundary is between the public logger API and the XML schema model: callers work with logging semantics, while XML classes own serialized structure.
- `src/main/java/de/fva_net/maxs/logger/MaxsLogger.java`
- `src/main/java/de/fva_net/maxs/logger/xml/KernelNotifications.java`
- `src/main/java/de/fva_net/maxs/logger/xml/Notification.java`

#### Runtime, integration, and delivery

Runtime requirements are a Java 17+ JVM and local filesystem access for `.maxs` output. The library is built and published through Maven; GitHub Actions provide build and release automation under `.github/workflows/`. Its material external integration is REXS model-component usage through the routine abstraction, rather than a network service or server runtime.
- `pom.xml`
- `.github/workflows/build.yml`
- `.github/workflows/release.yml`

Main entry points: [`src/main/java/de/fva_net/maxs/logger/MaxsLogger.java`](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/MaxsLogger.java) (MaxsLogger), [`src/main/java/de/fva_net/maxs/logger/xml/KernelNotifications.java`](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/xml/KernelNotifications.java) (KernelNotifications), [`src/main/java/de/fva_net/maxs/logger/xml/Notification.java`](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/xml/Notification.java) (Notification), [`pom.xml`](https://github.com/fva-net/maxs-logger-java/blob/main/pom.xml) (Maven package)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_public_api["Public API"]
  node_logger["MaxsLogger<br/>logger facade<br/>[MaxsLogger.java]"]
  node_routine["MaxsLoggableRoutine<br/>extension contract"]
  node_message_type["MaxsMessageType<br/>severity contract"]
end

subgraph group_xml_model["MAXS XML Model"]
  node_notification["Notification<br/>XML DTO<br/>[Notification.java]"]
  node_item["Item<br/>XML DTO<br/>[Item.java]"]
  node_kernel_notifications["KernelNotifications<br/>XML document root"]
end

subgraph group_delivery["Build &amp; Delivery"]
  node_maven["Maven package<br/>build definition<br/>[pom.xml]"]
  node_build_workflow["Build workflow<br/>CI workflow<br/>[build.yml]"]
  node_release_workflow["Release workflow<br/>[release.yml]"]
end

node_consumer["Consuming software<br/>integration"]
node_rexs_model["REXS model code<br/>integration"]
node_maxs_file[".maxs XML file<br/>output artifact"]
node_jvm_filesystem["Java 17 JVM &amp; filesystem<br/>runtime"]

node_consumer -->|"logs through"| node_logger
node_rexs_model -->|"implements or supplies"| node_routine
node_consumer -->|"provides context"| node_routine
node_logger -->|"associates routine"| node_routine
node_consumer -->|"selects severity"| node_message_type
node_logger -->|"classifies notifications"| node_message_type
node_logger -->|"maps request to"| node_notification
node_logger -->|"maps attributes to"| node_item
node_notification -->|"contains attributes"| node_item
node_logger -->|"aggregates into"| node_kernel_notifications
node_kernel_notifications -->|"contains"| node_notification
node_kernel_notifications -->|"serializes XML"| node_maxs_file
node_logger -->|"runs and writes via"| node_jvm_filesystem
node_maven -->|"packages library"| node_logger
node_build_workflow -->|"builds"| node_maven
node_release_workflow -->|"publishes"| node_maven

click node_logger "https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/MaxsLogger.java"
click node_routine "https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/MaxsLoggableRoutine.java"
click node_message_type "https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/MaxsMessageType.java"
click node_notification "https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/xml/Notification.java"
click node_item "https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/xml/Item.java"
click node_kernel_notifications "https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/xml/KernelNotifications.java"
click node_maven "https://github.com/fva-net/maxs-logger-java/blob/main/pom.xml"
click node_build_workflow "https://github.com/fva-net/maxs-logger-java/blob/main/.github/workflows/build.yml"
click node_release_workflow "https://github.com/fva-net/maxs-logger-java/blob/main/.github/workflows/release.yml"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_logger,node_routine,node_message_type toneBlue
class node_notification,node_item,node_kernel_notifications toneAmber
class node_maven,node_build_workflow,node_release_workflow toneMint
class node_consumer,node_rexs_model,node_maxs_file,node_jvm_filesystem toneNeutral
```

## Components

### Public API

Logging semantics exposed to consuming software.

- [MaxsLogger](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/MaxsLogger.java): logger facade · Accepts requests and orchestrates validation and XML output. · `src/main/java/de/fva_net/maxs/logger/MaxsLogger.java`
- [MaxsLoggableRoutine](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/MaxsLoggableRoutine.java): extension contract · Decouples caller domain models from XML persistence. · `src/main/java/de/fva_net/maxs/logger/MaxsLoggableRoutine.java`
- [MaxsMessageType](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/MaxsMessageType.java): severity contract · Constrained INFO, WARNING, and ERROR vocabulary. · `src/main/java/de/fva_net/maxs/logger/MaxsMessageType.java`

### MAXS XML Model

DTOs that own the serialized notification structure.

- [Notification](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/xml/Notification.java): XML DTO · Represents one logged event with format validation. · `src/main/java/de/fva_net/maxs/logger/xml/Notification.java`
- [Item](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/xml/Item.java): XML DTO · Represents structured notification attributes. · `src/main/java/de/fva_net/maxs/logger/xml/Item.java`
- [KernelNotifications](https://github.com/fva-net/maxs-logger-java/blob/main/src/main/java/de/fva_net/maxs/logger/xml/KernelNotifications.java): XML document root · Aggregates notifications for one MAXS document. · `src/main/java/de/fva_net/maxs/logger/xml/KernelNotifications.java`

### Build & Delivery

Maven packaging and CI release automation.

- [Maven package](https://github.com/fva-net/maxs-logger-java/blob/main/pom.xml): build definition · Defines Java 17 build, dependencies, and release coordinates. · `pom.xml`
- [Build workflow](https://github.com/fva-net/maxs-logger-java/blob/main/.github/workflows/build.yml): CI workflow · `.github/workflows/build.yml`
- [Release workflow](https://github.com/fva-net/maxs-logger-java/blob/main/.github/workflows/release.yml): release workflow · `.github/workflows/release.yml`

### Other components

- **Consuming software**: integration · Uses the library to produce MAXS log files.
- **REXS model code**: integration · Supplies routine metadata through the extension boundary.
- **.maxs XML file**: output artifact · Serialized MAXS notification document.
- **Java 17 JVM & filesystem**: runtime · Executes the library and provides local file output.

## Connections

- Consuming software → MaxsLogger: logs through
- REXS model code → MaxsLoggableRoutine: implements or supplies
- Consuming software → MaxsLoggableRoutine: provides context
- MaxsLogger → MaxsLoggableRoutine: associates routine
- Consuming software → MaxsMessageType: selects severity
- MaxsLogger → MaxsMessageType: classifies notifications
- MaxsLogger → Notification: maps request to
- MaxsLogger → Item: maps attributes to
- Notification → Item: contains attributes
- MaxsLogger → KernelNotifications: aggregates into
- KernelNotifications → Notification: contains
- KernelNotifications → .maxs XML file: serializes XML
- MaxsLogger → Java 17 JVM & filesystem: runs and writes via
- Maven package → MaxsLogger: packages library
- Build workflow → Maven package: builds
- Release workflow → Maven package: publishes
