Class DocumentUrlServiceContentTreeChangeNotificationHandler
Handles ContentTreeChangeNotification to persist URL segments to the database on the originating server. This fires post-commit (during scope disposal) before the cache instruction is delivered to other servers, ensuring URL segments are in the database before any server processes the instruction. URL aliases are persisted inside the content transaction by DocumentUrlAliasContentRefreshNotificationHandler.
Inheritance
Namespace: Umbraco.Cms.Core.Services
Assembly: Umbraco.Core.dll
Syntax
public class DocumentUrlServiceContentTreeChangeNotificationHandler : IDistributedCacheAsyncNotificationHandler<ContentTreeChangeNotification>, INotificationAsyncHandler<ContentTreeChangeNotification>, IDistributedCacheNotificationHandler, INotificationHandler
Constructors
View SourceDocumentUrlServiceContentTreeChangeNotificationHandler(IDocumentUrlService, IDocumentUrlAliasService)
Initializes a new instance of the DocumentUrlServiceContentTreeChangeNotificationHandler class.
Declaration
public DocumentUrlServiceContentTreeChangeNotificationHandler(IDocumentUrlService documentUrlService, IDocumentUrlAliasService documentUrlAliasService)
Parameters
| Type | Name | Description |
|---|---|---|
| IDocumentUrlService | documentUrlService | The document URL service. |
| IDocumentUrlAliasService | documentUrlAliasService | No longer used: aliases are persisted inside the content transaction by DocumentUrlAliasContentRefreshNotificationHandler. Kept for binary compatibility. |
Methods
View SourceHandleAsync(ContentTreeChangeNotification, CancellationToken)
Handles a notification.
Declaration
public Task HandleAsync(ContentTreeChangeNotification notification, CancellationToken cancellationToken)
Parameters
| Type | Name | Description |
|---|---|---|
| ContentTreeChangeNotification | notification | The notification. |
| CancellationToken | cancellationToken | The cancellation token. |
Returns
| Type | Description |
|---|---|
| Task | A System.Threading.Tasks.Task representing the asynchronous operation. |