> ## Documentation Index
> Fetch the complete documentation index at: https://docs.activeviam.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Add custom persistence services

> How to add custom persistence services in Atoti Limits by implementing the required persistence service interfaces as primary Spring beans, with a table of required and optional services and their purposes

## Overview

Atoti Limits lets you extend the persistence services. To do this, you need to import your
implementation of the appropriate [persistence service](../../persistence/services) and mark it
as primary.
See [Importing Spring Beans into the Project](..#importing-spring-beans-into-the-project)
for details on how to do this.

Your implementation(s) must meet the requirements outlined below.

## Requirements

<table><thead><tr><th>Service</th><th>Description</th><th>Required</th><th>Reason</th></tr></thead><tbody><tr><td><a href="../../persistence/services/persistence-services-sub-interfaces">IPreferredLimitsAppPersistenceService</a></td><td>The persistence service used throughout Atoti Limits</td><td>Yes</td><td>This service powers the REST services used by the Atoti Limits UI.</td></tr><tr><td><a href="../../persistence/services/persistence-services-sub-interfaces">ILimitsAppDatastorePersistenceService</a></td><td>The persistence service used to interact with the Atoti Datastore</td><td>Yes</td><td>This service powers the Atoti Limits cube.</td></tr><tr><td><a href="../../persistence/services/persistence-services-sub-interfaces">ILimitsAppJpaDatabasePersistenceService</a></td><td>The persistence service used to interact with an external database</td><td>No</td><td>N/A</td></tr></tbody></table>

<Note>
  To meet all requirements, you may have one persistence service that extends
  both `ILimitsAppDatastorePersistenceService` and `IPreferredLimitsAppPersistenceService`.
</Note>
