-
Notifications
You must be signed in to change notification settings - Fork 17
Architecture
Musicott is the desktop GUI layer of a three-project ecosystem. It boots Spring Boot in non-web mode, renders its UI with JavaFX, and delegates all domain and persistence work to two libraries maintained alongside it.
See the Glossary for the meaning of terms used on this page.
| Project | Role |
|---|---|
| lirp | Lightweight Reactive Persistence — event-sourced repositories that serialize to JSON and SQLite. |
| music-commons | Persistence-agnostic music domain: audio items, playlists, artists, waveforms, and their JavaFX-observable wrappers. |
| Musicott | This project — the JavaFX desktop app: views, services, events, and Spring/JavaFX wiring. |
Audio library state lives in a local SQLite database (audioItems.db) for fast import
and startup at large library sizes; playlists and the waveform cache are kept as plain
JSON files. All three are stored under ~/.config/musicott/.
Spring provides dependency injection and configuration; JavaFX provides the GUI. The two
are bridged by javafx-weaver-spring: FXML
controllers are annotated @Controller and @FxmlView, and FxWeaver resolves each FXML
file while injecting Spring dependencies into its controller.
Components do not hold direct references to one another. Instead they publish and subscribe
to Spring ApplicationEvents through the ApplicationEventPublisher. A controller publishes
an event (for example, a play request); listeners annotated with @EventListener react to it.
On launch a branded splash window appears immediately, while Spring Boot and the library load run on a background thread. Once the main scene is built, the splash fades out and the main window is shown — with an 800 ms minimum display gate so the splash never merely flickers.