You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Implement optional back population on get operations (#292)
* Add GetAsync overload for back-population
Adds a `GetAsync<T>(string, bool)` overload to `ICacheStack` that allows the caller to specify if the cache entry should be back-populated to higher cache layers if it is resolved using a lower layer.
* Add unit tests for get with back propagation
* Update test names
* Add unit tests for null keys
Copy file name to clipboardExpand all lines: src/CacheTower/ICacheStack.cs
+20
Original file line number
Diff line number
Diff line change
@@ -50,12 +50,32 @@ public interface ICacheStack
50
50
/// The entry returned corresponds to the first cache layer that contains it.
51
51
/// <br/>
52
52
/// If no cache layer contains it, Null is returned.
53
+
/// <br/>
54
+
/// <br/>
55
+
/// Use <see cref="GetAsync{T}(string, bool)"/> to optionally perform back-population to upper cache layers if the entry is found in a lower cache layer.
53
56
/// </remarks>
54
57
/// <typeparam name="T">The type of value in the cache entry.</typeparam>
/// <param name="backPopulate"><see langword="true"/> to back-populate the entry to upper cache layers if it is found in a lower cache layer; otherwise, <see langword="false"/>.</param>
0 commit comments