Example #1
0
 internal void OnPostAuthorizeRequest(HttpContextBase context)
 {
     Diagnostics.SendWatsonReportOnUnhandledException(delegate()
     {
         if (!this.isEnabled)
         {
             return;
         }
         IAddressFinderDiagnostics addressFinderDiagnostics = this.GetDiagnostics(context);
         IAddressFinder addressFinder = this.addressFinderFactory.CreateAddressFinder(HttpProxyGlobals.ProtocolType, context.Request.Url.AbsolutePath);
         if (addressFinder != null)
         {
             AddressFinderSource source   = new AddressFinderSource(context.Items, context.Request.Headers, context.Request.QueryString, context.Request.Url, context.Request.ApplicationPath, context.Request.FilePath, context.Request.Cookies);
             IRoutingKey[] value          = addressFinder.Find(source, addressFinderDiagnostics);
             context.Items["RoutingKeys"] = value;
         }
         else
         {
             ExTraceGlobals.VerboseTracer.TraceDebug <string, Uri, ProtocolType>((long)this.GetHashCode(), "[AddressFinderModule::OnPostAuthorizeRequest]: addressFinder is null: Method {0}; Url {1}; Protocol {2};", context.Request.HttpMethod, context.Request.Url, HttpProxyGlobals.ProtocolType);
             addressFinderDiagnostics.AddErrorInfo("addressFinder is null");
         }
         addressFinderDiagnostics.LogRoutingKeys();
     }, new Diagnostics.LastChanceExceptionHandler(this.LastChanceExceptionHandler));
 }