# jolapsh/notification-app architecture

> Architecture diagram of the GitHub repository jolapsh/notification-app, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2025-06-17). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/jolapsh/notification-app
- Repository: https://github.com/jolapsh/notification-app

## Overview

##### Project type and purpose
- This is a single‐module Java console application (built with Maven).
- Its sole purpose is to print a time‐of‐day–dependent greeting (“Good morning”, “Good evening”, etc.) in the user’s locale.

##### File structure
- Top level:
- pom.xml (Maven build config)
- .travis.yml & .circleci/config.yml (CI pipelines)
- src/main/java/application (entry point & core logic)
- src/main/java/util (utility classes)
- src/main/resources (logging config + message bundles)
- src/test (unit tests)
- No separate frontend/backend layers—this is a single JVM process with modular packages.
- Presence of log4j2.xml implies a logging sub‐system. message_*.properties implies internationalization (i18n).

##### README for additional insights
- Confirms it’s a console app that selects a greeting based on system time and locale.
- Build & run via Maven.

## Diagram (Mermaid)

```mermaid
flowchart TB
    %% External Systems
    subgraph "External Systems"
        Clock(("System Clock")):::external
        Locale(("System Locale")):::external
    end

    %% Application Layer
    subgraph "Application Layer"
        MessageApp["MessageApp"]:::business
        KeyMessage["KeyMessage"]:::business
    end

    %% Utility Layer
    subgraph "Utility Layer"
        TimeUtil["TimeUtil"]:::utility
    end

    %% Resources
    subgraph "Resources"
        PropsEn((message_en.properties)):::resources
        PropsRu((message_ru.properties)):::resources
    end

    %% Logging
    subgraph "Logging Subsystem"
        LogConfig((log4j2.xml)):::logging
        Log4j2["Log4j2"]:::logging
    end

    %% Project Configuration
    subgraph "Project Config"
        POM["pom.xml"]:::config
        Travis[".travis.yml"]:::config
        CircleCI[".circleci/config.yml"]:::config
    end

    %% Output
    STDOUT(("STDOUT")):::external

    %% Data Flows
    Clock -->|"currentTime"| TimeUtil
    TimeUtil -->|"currentHour"| MessageApp
    MessageApp -->|"messageKey"| KeyMessage
    Locale -->|"locale"| KeyMessage
    KeyMessage -->|"get message from ResourceBundle"| PropsEn
    KeyMessage -->|"get message from ResourceBundle"| PropsRu
    PropsEn -->|"localizedMessage"| MessageApp
    PropsRu -->|"localizedMessage"| MessageApp
    MessageApp -->|"println"| STDOUT

    %% Logging Events
    MessageApp -.->|"log events"| Log4j2
    TimeUtil -.->|"log events"| Log4j2
    KeyMessage -.->|"log events"| Log4j2

    %% Click Events
    click MessageApp "https://github.com/jolapsh/notification-app/blob/master/src/main/java/application/MessageApp.java"
    click KeyMessage "https://github.com/jolapsh/notification-app/blob/master/src/main/java/application/KeyMessage.java"
    click TimeUtil "https://github.com/jolapsh/notification-app/blob/master/src/main/java/util/TimeUtil.java"
    click LogConfig "https://github.com/jolapsh/notification-app/blob/master/src/main/resources/log4j2.xml"
    click PropsEn "https://github.com/jolapsh/notification-app/blob/master/src/main/resources/message_en.properties"
    click PropsRu "https://github.com/jolapsh/notification-app/blob/master/src/main/resources/message_ru.properties"
    click POM "https://github.com/jolapsh/notification-app/blob/master/pom.xml"
    click Travis "https://github.com/jolapsh/notification-app/blob/master/.travis.yml"
    click CircleCI "https://github.com/jolapsh/notification-app/blob/master/.circleci/config.yml"

    %% Styles
    classDef business fill:#cce5ff,stroke:#3399ff,color:#000;
    classDef utility fill:#e6ffe6,stroke:#33cc33,color:#000;
    classDef resources fill:#ffe6cc,stroke:#ff9933,color:#000;
    classDef logging fill:#f2f2f2,stroke:#999999,color:#000;
    classDef external fill:#fff0b3,stroke:#ffcc00,color:#000;
    classDef config fill:#f0f0f0,stroke:#666666,color:#000;
```
