Posts

Showing posts with the label Episerver Find

Handle Exceptions in Find

If it's repetitive, it can be automated. Think about the following requirements. Have you ever hoped there would be a better way to implement them? INotifyPropertyChanged Undo/redo Code contracts (preconditions) Logging Transaction handling Exception handling Thread dispatching Thread synchronization Immutable Authorization Audit Caching Exceptions in Find Generally we will be doing this         private SearchResults<DummyObject> GetResults()         {             try             {                 var query = client.Search<DummyObject>();                 var results = query.Take(10).StaticallyCacheFor(TimeSpan.FromMinutes(5)).GetResult();                 return results;             } ...