Skip to content

Conversation

@ebariaux
Copy link
Contributor

This is really a first go at it, lots of information missing but:

  • wanted to check if this is going in the right direction
  • need more investigation to go into more details in some topics

An effort to clean-up / improve the javadoc and the REST API doc should also be done in //.

@ebariaux ebariaux requested a review from a team November 26, 2025 08:43
@ebariaux ebariaux linked an issue Nov 26, 2025 that may be closed by this pull request
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces comprehensive architecture documentation for OpenRemote, focusing on the overall system architecture, event-driven mechanisms, and attribute event processing flows. The documentation provides a solid foundation for understanding the core components and their interactions within the OpenRemote manager.

Key Changes:

  • New overall architecture documentation explaining the Container, services, and asset-based context broker model
  • Detailed event-driven mechanism documentation with Mermaid class diagram showing key Event classes
  • Comprehensive AttributeEvent ingress and processing flow documentation covering MQTT, REST API, and WebSocket entry points

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@richturner richturner requested review from richturner and removed request for a team November 27, 2025 09:03
Comment on lines +15 to +16
The whole system is event driven. Different types of events can occur in the system, all inheriting from the root [Event](https://www.javadoc.io/doc/io.openremote/openremote-model/latest/org/openremote/model/event/Event.html) class.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some history/context. SharedEvent is the super type of any Event that is shared between the backend and frontend and historically and still mostly refers to communication over the Websocket API.

Websocket doesn't have a topic concept so we use a string prefix with colon to indicate the message type e.g. EVENT:

[AssetProcessingService.processAttributeEvent()](https://github.com/openremote/openremote/blob/151af17d0e502f0fa7a377cd34b8416350bc1794/manager/src/main/java/org/openremote/manager/asset/AssetProcessingService.java#L341) is really where all processing happens.

A lock is immediately taken on the asset (assetId based) and during this lock:
- [Asset](https://www.javadoc.io/doc/io.openremote/openremote-model/latest/org/openremote/model/asset/Asset.html) is retrieved from DB
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a major bottleneck for event processing

@richturner richturner merged commit 14b0a5f into main Dec 1, 2025
2 checks passed
@richturner richturner deleted the enhancement/architecture-doc branch December 1, 2025 08:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Document architecture

3 participants