Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
27 changes: 5 additions & 22 deletions 15/umbraco-cms/reference/configuration/cache-settings.md
Original file line number Diff line number Diff line change
Expand Up @@ -184,29 +184,12 @@ Specifying the `SqlPageSize` will change the size of the paged SQL queries. The

## NuCacheSerializerType

The `NuCacheSerializerType` setting allows developers to specify the serialization format for NuCache content. This setting is particularly relevant for projects migrating from older versions of Umbraco that relied on JSON formats.
The `NuCacheSerializerType` setting allows developers to specify the serialization format for cached content.

To use JSON serialization instead of the default MessagePack:
The fastest and most compact format `MessagePack` is used by default.

### Using 'Program.cs'
An alternate `JSON` option was provided for backward compatibility for the Umbraco cache implementation used from Umbraco 8 to 14 (NuCache).

```csharp
builder.Services.Configure<NuCacheSettings>(options =>
{
options.NuCacheSerializerType = NuCacheSerializerType.JSON;
});
```
It is no longer supported with the cache implementation from Umbraco 15+ based on .NET's Hybrid cache.

### Using 'appsettings.json'

```csharp
{
"Umbraco": {
"CMS": {
"NuCache": {
"NuCacheSerializerType": "JSON"
}
}
}
}
```
The option is kept available only for a more readable format suitable for testing purposes.
29 changes: 6 additions & 23 deletions 16/umbraco-cms/reference/configuration/cache-settings.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
description: Information on the Cache settings section
description: Information on the Cache settings section
---

# Cache Settings
Expand Down Expand Up @@ -186,29 +186,12 @@ Specifying the `SqlPageSize` will change the size of the paged SQL queries. The

## NuCacheSerializerType

The `NuCacheSerializerType` setting allows developers to specify the serialization format for NuCache content. This setting is particularly relevant for projects migrating from older versions of Umbraco that relied on JSON formats.
The `NuCacheSerializerType` setting allows developers to specify the serialization format for cached content.

To use JSON serialization instead of the default MessagePack:
The fastest and most compact format `MessagePack` is used by default.

### Using 'Program.cs'
An alternate `JSON` option was provided for backward compatibility for the Umbraco cache implementation used from Umbraco 8 to 14 (NuCache).

```csharp
builder.Services.Configure<NuCacheSettings>(options =>
{
options.NuCacheSerializerType = NuCacheSerializerType.JSON;
});
```
It is no longer supported with the cache implementation from Umbraco 15+ based on .NET's Hybrid cache.

### Using 'appsettings.json'

```csharp
{
"Umbraco": {
"CMS": {
"NuCache": {
"NuCacheSerializerType": "JSON"
}
}
}
}
```
The option is kept available only for a more readable format suitable for testing purposes.