Global Inbox
Introduction
The Global Inbox enables centralized task management across multiple applications by introducing two modules: the Global Inbox module and the Global Inbox Connector.
The Global Inbox module offers a centralized task inbox that aggregates workflow tasks from multiple applications, allowing users to view and manage all their tasks in a single overview.
Applications that want their workflow tasks to appear in the Global Inbox are called Publisher Applications. These applications use the Global Inbox Connector to publish task-related events. The connector is specifically designed for Mendix Workflows. Task updates are communicated via Mendix Business Events, that carry information about workflow changes such as task creation, assignment, updates, and completion.
The Global Inbox is designed to:
- Provide a single Task Inbox for tasks across multiple applications.
- Reduce complexity by consolidating tasks from different applications.
- Support real-time synchronization of task status, assignments, and workflow progress.
- Improve user productivity and visibility by centralizing task management.
While the architecture can support broader use cases, the current scope focuses on tasks generated by Mendix built-in workflows.
Features
- Consists of two Mendix modules: Global Inbox module and Global Inbox Connector
- Intended for Mendix Applications that use Mendix Workflows to manage workflows. Support for non-Mendix Workflows will be introduced at a later stage.
- Redirects users to Publisher Applications to act on the user task.
Prerequisites
- Mendix 11.6.0 or above
- Single Sign-On (SSO) is required for user authentication, as the System.User.Name attribute is used to match users across the Global Inbox and Publisher Applications. For security reasons, ensure that the username is not modifiable by the end user and is only set by the SSO provider.
Dependencies
- Mendix Business Events
- Mendix Event Broker
- Requires a license for apps running on Mendix Cloud
- Alternatively, you can use your own Kafka cluster
- Atlas Core (v4.0.0 or higher)
- Atlas Web Content (v4.0.0 or higher)
- Data Widgets
Architecture
The Global Inbox operates on an event-driven architecture:
The Global Inbox consists of the following components:
- Global Inbox: A module that contains the Global Task Inbox page, which aggregates workflow tasks from multiple Publisher Applications into a single overview. It serves as a centralized system that consumes business events and updates the Global Task Inbox accordingly. The page is read-only. Users cannot act on tasks directly. Users can only click on tasks to navigate to the corresponding page in the Publisher Application. It includes three tabs:
- My open tasks: It shows the tasks assigned to the current user.
- All open tasks: It shows a list of tasks the current user could pick up.
- Unassigned tasks: It shows all unassigned tasks.
- Global Inbox Connector: A module that can be imported into each Publisher Application and contains the functionality to publish task updates through Mendix Business Events. It is intended for Mendix Publisher Applications that use Mendix Workflows to manage workflows.
- Mendix Business Events: Events that carry information about user tasks and workflow changes, such as task creation, updates, or completion. All relevant information about Business Events can be found in the Mendix Business Events documentation. The Global Inbox owns the definition of the Business Events, and the Publisher Applications publishes them.
- Mendix Event Broker: The Event Broker is used to deliver all Business Events from Publisher Applications to the Global Inbox. You can use Mendix Event Broker (requires a license) or bring your own Kafka cluster.
Event Flow
The Global Inbox operates with the following event flow:
- Publisher App registration: Each publisher application registers with the Global Inbox by publishing a PublisherAppRegisteredEvent. This ensures the Global Inbox knows which apps are available to send task events.
- Task update and event publication: When a workflow or task is created, updated, or completed in a publisher application that includes the Global Inbox Connector, the connector publishes the following events:
- WorkflowUpdatedEvent – triggered when the workflow is updated.
- UserTaskUpdatedEvent – triggered when a user task is updated.
- UserTaskEndedEvent – triggered when a user task is completed or aborted.
- UserTaskOutcomeSelectedEvent – triggered when a user completes a task by selecting an outcome.
- Event consumption: The Global Inbox consumes these events and updates or creates the corresponding task entries in the central task list.
- Task visibility and navigation: Tasks become visible in the Global Inbox. Users can click a button to navigate directly to the corresponding task page in the Publisher Application to take action.
Setup Guide
Setting up Global Inbox
-
Import the Global Inbox module into the application that will serve as the central task overview. This application aggregates tasks from multiple Publisher Applications and provides a single interface where users can view all active tasks. It acts as the consumer of task events and maintains the consolidated task list.
-
Add the ACT_GlobalTaskInbox_Open microflow to your navigation. You can find it in GlobalInbox > UseMe > Microflows > ACT_GlobalTaskInbox_Open. This microflow opens the GlobalTaskInbox page and ensures that users are able to see their tasks.
If you want to customize the GlobalTaskInbox page, make sure to copy it with the ACT_GlobalTaskInbox_Open microflow to your own module, as this microflow includes the logic to link the app users to their user tasks. -
Add the User module roles to the required App roles.
-
Deploy and configure constants:
- The CleanupEventsAfterDays constant can be configured at: UseMe > Configuration > CleanupEventsAfterDays. All business events use their own entities to store data for consumption. For example, CBE_UserTaskUpdatedEvent stores data for the User Task Updated event. The CleanupEventsAfterDays setting is configurable and determines how long event data is retained. Data older than the specified number of days is automatically cleaned up. The default value is set to 30 days.
- The DueDateExpirationInDays constant defines the period in days for which the user tasks are to be considered almost due with visual indicators in the Global Task Inbox page. The default value is set to 2 days. You should set the value based on your business needs.
Setting up Global Inbox Connector
- Import the Global Inbox Connector module. This module is responsible for publishing workflow task events to the Global Inbox, enabling the central application to stay synchronized with task creation, updates, and completion occurring in the source applications.
- In the runtime settings of your app, configure the ASU_GlobalInboxConnector_Startup microflow for the after startup property. If there is already an after startup microflow set, add the ASU_GlobalInboxConnector_Startup microflow as an microflow call activity in the existing microflow.
- Add the User module roles to the required App roles.
- Deploy and configure constants:
- AppId: Must be a unique identifier for each publisher app. Do not change this identifier once configured.
- AppName: This value will be displayed in your Global Inbox as the publisher app name.
- AppBaseUrl: Must include the protocol (http:// or https://) and must not end with a trailing slash. It is used as the base URL when redirecting users to the publisher apps.
- When a user opens a task from the Global Inbox, they are redirected to the corresponding task page in the Publisher Application through a deeplink. Because the user entered the application through the Global Inbox instead of the normal navigation flow, developers must decide how the application should behave when the user completes the user task and/or closes the page. Developers can either change show page action in the deeplink microflow DL_WorkflowUserTask_ShowUserTaskPage to redirect to another page or adjust the default deeplink landing page in UseMe > Deeplink > Deeplink Landing Page to meet their business needs. If further customization is required, it is possible to adjust the logic for the outcome buttons in each of the task pages.
Setting up Business Events
Configure the Mendix Event Broker or your own Kafka cluster. Refer to the Mendix Event Broker documentation for relevant steps.
Local Setup
For local development and testing, the Event Broker can be deployed using the Local Setup Tool. For more information, see Deployment.
In both the Global Inbox and Global Inbox Connector modules, configure the following application constants:
- ServerUrl: the URL of the local broker instance
- ChannelName: the name of the event channel used for publishing and subscribing to Business Events
These settings ensure that Business Events are correctly routed between Publisher Applications and the Global Inbox during local testing.
Deployment
For deployment, the Global Inbox requires the Mendix Event Broker or an external Kafka cluster. For more information, see the Production Deployment section in Deploy a Business Event.
Ensure the Mendix Event Broker is enabled for all apps and environments, and deploy applications in the correct order: Global Inbox application must be running before the publisher applications.
Ensure the Global Inbox Connector constants are configured in each Publisher Application as part of the deployment process.
Security
Any user that can see a task in Publisher Application can see the same task in the Global Inbox. This is based on the System.User.Name attribute that is used as the unique identifier to link users across the applications. For this reason:
- Single Sign-On (SSO) is required for user authentication
- Users MUST have the same username (System.User.Name attribute) across the Global Inbox application and all Publisher Applications.
- The username should NOT be modifiable and should only be set by the SSO provider.
Limitations
- Global Inbox does not support Workflow Groups at the moment. This will be introduced at a later stage.
- The beta version of Global Inbox has limited support for error handling. Any exceptions that occur in a microflow after updating a user task (or other Workflow-related entity) in the same microflow (for example, updating the targeted users or due date) might result in data becoming out of sync. This is a temporary limitation that will be resolved in an upcoming version.
- Workflows and tasks that are modeled in the same app that includes the Global Inbox module are NOT available in the Global Inbox. The Global Inbox app only consumes and displays workflow instances from other Mendix applications.