Overview
The Atoti Limits Java auto-configuration module connects an Atoti Server instance (the “Connected Server”) to a running Atoti Limits server. It uses Spring Auto-configuration to bootstrap the required services and send a connection request to Atoti Limits. This module enables Atoti Limits to manage limits on data served by Atoti Server. Once connected, Atoti Limits can evaluate limits against the measures and hierarchies exposed by the Connected Server.Atoti Limits does not require the connected server to be an ActiveViam Business Solution, it
can be any instance of Atoti Server.
limits-auto-config-* modules. These modules are responsible for bootstrapping the Connected Server with any services required by Atoti Limits and for sending a connection request to Atoti Limits with required information.
Compatibility matrix
This table lists the versions of Atoti Server compatible with each Atoti Limits version. If you are using a solution, please check the underlying version of Atoti Server to see if your version of the solution is compatible.Prerequisites
The connected Atoti server must meet the requirements in What do you need before you connect?.How does the connection process work?
The Connected Server initiates the connection, and Atoti Limits then connects back to it:- When the Connected Server starts, it checks that Atoti Limits is available and sends it a connection request containing the details Atoti Limits needs to connect.
- Atoti Limits connects to the Connected Server and starts managing its limits.
You can start the two servers in either order.
How to integrate a Connected Server with Atoti Limits
Follow these steps to integrate a Connected Server with Atoti Limits.Step 1: Import the auto-configuration dependency in the Connected Server
Thelimits-auto-config-* Maven dependency must be added to the Connected Server project. The correct artifact depends on the version of Atoti Server in use.
Add the following dependency to the project pom.xml file:
Step 2: Configure the auto-configuration properties in the Connected Server
The auto-configuration module requires a set of properties to establish the connection. Configure these properties in theapplication.yml file on the Connected Server.
The full list of properties is available in the Auto-configuration properties section.
Not all properties are required, but they are all listed in the event that your Connected Server is
unable to derive the properties automatically.
How to secure the auto-configuration REST endpoints
The auto-configuration module adds several REST endpoints to the Connected Server, for example to receive connection requests and limit change events from Atoti Limits. Spring Security requires a filter chain for them. Either the application declares one itself, or it lets the auto-configuration module register one. Settinglimits.autoconfiguration.security.enabled to true on the Connected Server registers a dedicated
Spring Security filter chain for these endpoints, built with the Connected Server’s
MachineToMachineSecurityDsl like the Atoti Server ones. It handles JWT and HTTP Basic authentication, CORS
and CSRF the same way. Every request to these endpoints must be authenticated; no particular role is required.
OPTIONS requests (CORS preflight) are always permitted.
This property is false by default, so an application that does not set it keeps its existing security
configuration unchanged.
This chain requires a
MachineToMachineSecurityDsl bean, which the Atoti Server Spring Boot starter
(atoti-server-starter, Atoti Server 6.1 and later) provides. It is skipped on Connected Servers where that
class is not on the classpath.
The Atoti Limits service principal, set by
limits.autoconfiguration.service-principal, authenticates the
calls Atoti Limits makes to the Connected Server. UI users authenticate their own calls to the KPI drawer
endpoint.
Step 3: Configure the inter-server-event-service properties in Atoti Limits
The Atoti Limits server needs to know where to find the Connected Server. Set the following configuration properties in theapplication.yml file on the Atoti Limits server.
<Connected Server>is the name of the Connected Server and should be the same as the value (defined or auto-configured) oflimits.autoconfiguration.server-namein the connected server.<Connected Server URL>is the URL of the Connected Server and should be the same as the value (defined or auto-configured) oflimits.autoconfiguration.atoti-base-urlin the connected server.
Step 4: Start the servers
The order in which the servers start does not matter.Start the Limits server
Start the Limits server using the installation instructions. Limits will wait for a connection from the Atoti Server.Start the Connected Server
Start the Connected Server as normal. This should trigger a connection request.Troubleshooting
If the connection is unsuccessful, enabledebug logging for further investigation.