---
title: "Configuring the xConnect service"
slug: "configuring-the-xconnect-service"
abstract: "Overview of the configuration settings that affect the xConnect Search and xConnect Collection services."
---
# Configuring the xConnect service

This topic describes the configuration settings that affect the  [xConnect Search](https://doc.sitecore.com/xp/en/developers/104/platform-administration-and-architecture/xconnect-collection-search-service.html) and  [xConnect Collection](https://doc.sitecore.com/xp/en/developers/104/platform-administration-and-architecture/xconnect-collection-service.html) services. All configuration files are located in the `C:\path\to\xconnect\App_data\Config` folder.

> [!important]
> The xConnect Collection and Search service does not use all of the configuration settings available in the `\App_data\Config` sub-folder - for example, the indexer does not use the settings in the SearchIndexer sub-folder.

<details>
<summary><h2>sc.Xdb.Collection.RepositorySettings.xml</h2></summary>

The following settings control how many records are returned to the indexer by the repository and underlying data provider.

File Path: `C:\path\to\xconnect\App_data\Config\Sitecore\Collection\sc.Xdb.Collection.RepositorySettings.xml`

| Setting | Description |
| --- | --- |
| `ContactsReturnedFromDataProviderChunkSize` | Determines number of contacts returned by the underlying data provider. Increase to reduce number of queries to the underlying data provider. |
| `ContactsReturnedChunkSize` | Determines chunk size of contacts returned by the repository. If `ContactsReturnedFromDataProviderChunkSize` is set to 1000 and `ContactsReturnedChunkSize` is set to 100, only 100 contacts are expanded in memory at one time. Increase or decrease to control memory usage independently of query size. |
| `InteractionsReturnedChunkSize` | Determines chunk size of interactions returned by the repository and underlying data provider. Increase to reduce number of queries to the underlying data provider. |
| `DeviceProfilesReturnedChunkSize` | Determines chunk size of device profiles returned by the repository and underlying data provider. Increase to reduce number of queries to the underlying data provider. |

> [!note]
> Depending on how data is distributed across shards, a request for 1000 contacts to the data provider may result in multiple queries across multiple shards.

</details>

<details>
<summary><h2>sc.XConnect.CollectionService.xml</h2></summary>

The following settings control how often and how many times an operation is retried. These settings also apply to calculated facets.

**File Path**: `C:\path\to\xconnect\App_data\Config\Sitecore\Collection\sc.XConnect.CollectionService.xml`

| Setting | Description |
| --- | --- |
| `SlotTime` | The slot time used when pausing. xConnect uses an expotential backoff strategy by default, which means that repeated retries are spaced out at random intervals (using `SlotTime` as a base) to avoid congestion. Can be increased if you experience high response times. |
| `MaxRetries` | Determines the maximum number of times an operation will retry before failing. |

</details>