diff --git a/README.md b/README.md index 88814412099..7e9ff990d3f 100644 --- a/README.md +++ b/README.md @@ -506,13 +506,13 @@ For more information on the Circuit Breaker pattern in general see: Policy .Handle() .OrResult(null) - .Fallback(UserAvatar.Blank) + .Fallback(UserAvatar.Blank); // Specify a func to provide a substitute value, if execution faults. Policy .Handle() .OrResult(null) - .Fallback(() => UserAvatar.GetRandomAvatar()) // where: public UserAvatar GetRandomAvatar() { ... } + .Fallback(() => UserAvatar.GetRandomAvatar()); // where: public UserAvatar GetRandomAvatar() { ... } // Specify a substitute value or func, calling an action (eg for logging) if the fallback is invoked. Policy @@ -627,7 +627,7 @@ Policy // Configure variable timeout via a func provider. Policy - .Timeout(myTimeoutProvider)) // Func myTimeoutProvider + .Timeout(myTimeoutProvider) // Func myTimeoutProvider // Timeout, calling an action if the action times out Policy @@ -795,10 +795,10 @@ var cachePolicy = Policy.Cache(memoryCacheProvider, TimeSpan.FromMinutes(5)); // - https://github.com/App-vNext/Polly.Caching.IDistributedCache // Define a cache policy with absolute expiration at midnight tonight. -var cachePolicy = Policy.Cache(memoryCacheProvider, new AbsoluteTtl(DateTimeOffset.Now.Date.AddDays(1)); +var cachePolicy = Policy.Cache(memoryCacheProvider, new AbsoluteTtl(DateTimeOffset.Now.Date.AddDays(1))); // Define a cache policy with sliding expiration: items remain valid for another 5 minutes each time the cache item is used. -var cachePolicy = Policy.Cache(memoryCacheProvider, new SlidingTtl(TimeSpan.FromMinutes(5)); +var cachePolicy = Policy.Cache(memoryCacheProvider, new SlidingTtl(TimeSpan.FromMinutes(5))); // Define a cache Policy, and catch any cache provider errors for logging. var cachePolicy = Policy.Cache(myCacheProvider, TimeSpan.FromMinutes(5),