Skip cache refresher operations for content blueprints (#15633)
* Skip cache refresher operations for content blueprints * Fix JsonPayload deserialization error by adding a default constructor and property initializers * Obsolete JsonPayload constructor and update usages
This commit is contained in:
committed by
Bjarke Berg
parent
e7c53d4768
commit
25139dabe0
@@ -220,7 +220,16 @@ internal class PublishedSnapshotService : IPublishedSnapshotService
|
||||
// they require.
|
||||
using (_contentStore.GetScopedWriteLock(_scopeProvider))
|
||||
{
|
||||
NotifyLocked(new[] { new ContentCacheRefresher.JsonPayload(0, null, TreeChangeTypes.RefreshAll) }, out _, out _);
|
||||
NotifyLocked(
|
||||
new[]
|
||||
{
|
||||
new ContentCacheRefresher.JsonPayload()
|
||||
{
|
||||
ChangeTypes = TreeChangeTypes.RefreshAll
|
||||
}
|
||||
},
|
||||
out _,
|
||||
out _);
|
||||
}
|
||||
|
||||
using (_mediaStore.GetScopedWriteLock(_scopeProvider))
|
||||
@@ -885,6 +894,12 @@ internal class PublishedSnapshotService : IPublishedSnapshotService
|
||||
_logger.LogDebug("Notified {ChangeTypes} for content {ContentId}", payload.ChangeTypes, payload.Id);
|
||||
}
|
||||
|
||||
if (payload.Blueprint)
|
||||
{
|
||||
// Skip blueprints
|
||||
continue;
|
||||
}
|
||||
|
||||
if (payload.ChangeTypes.HasType(TreeChangeTypes.RefreshAll))
|
||||
{
|
||||
using (IScope scope = _scopeProvider.CreateScope())
|
||||
|
||||
Reference in New Issue
Block a user