private IPhotoHandler RouteTargetWithMailboxInLocalForest(PhotoRequest request, ADUser target) { if (this.TargetLikelyOnThisServer(request)) { return(new LocalServerFallbackToOtherServerPhotoRetrievalPipeline(this.configuration, this.clientInfo, this.recipientSession, this.xsoFactory, this.certificateValidationComponentId, this.serviceLocatorFactory, this.outgoingRequestProxyProvider, this.tracer)); } IPhotoServiceLocator serviceLocator = this.serviceLocatorFactory.CreateForLocalForest(request.PerformanceLogger); if (this.IsTargetMailboxOnThisServer(request, target, serviceLocator)) { return(this.RouteTargetOnThisServer()); } this.tracer.TraceDebug((long)this.GetHashCode(), "ROUTING: target mailbox is in LOCAL forest but OTHER server."); return(new LocalForestOtherServerPhotoRetrievalPipeline(this.configuration, this.certificateValidationComponentId, serviceLocator, this.recipientSession, this.outgoingRequestProxyProvider, this.tracer)); }
public LocalForestOtherServerPhotoRetrievalPipeline(PhotosConfiguration configuration, string certificateValidationComponentId, IPhotoServiceLocator serviceLocator, IRecipientSession recipientSession, IPhotoRequestOutboundWebProxyProvider outgoingRequestProxyProvider, ITracer upstreamTracer) { this.pipeline = new HttpPhotoHandler(configuration, this.CreateOutboundSender(certificateValidationComponentId, upstreamTracer), serviceLocator, outgoingRequestProxyProvider, upstreamTracer).Then(new ADPhotoHandler(new ADPhotoReader(upstreamTracer), recipientSession, upstreamTracer)); }
// Token: 0x060011A5 RID: 4517 RVA: 0x00049FA0 File Offset: 0x000481A0 public HttpPhotoHandler(PhotosConfiguration configuration, IPhotoRequestOutboundSender outboundRequestSender, IPhotoServiceLocator serviceLocator, IPhotoRequestOutboundWebProxyProvider outgoingRequestProxyProvider, ITracer upstreamTracer) { ArgumentValidator.ThrowIfNull("configuration", configuration); ArgumentValidator.ThrowIfNull("outboundRequestSender", outboundRequestSender); ArgumentValidator.ThrowIfNull("serviceLocator", serviceLocator); ArgumentValidator.ThrowIfNull("outgoingRequestProxyProvider", outgoingRequestProxyProvider); ArgumentValidator.ThrowIfNull("upstreamTracer", upstreamTracer); this.configuration = configuration; this.outboundRequestSender = outboundRequestSender; this.serviceLocator = serviceLocator; this.outgoingRequestProxyProvider = outgoingRequestProxyProvider; this.tracer = ExTraceGlobals.UserPhotosTracer.Compose(upstreamTracer); }
private bool IsTargetMailboxOnThisServer(PhotoRequest request, ADUser target, IPhotoServiceLocator serviceLocator) { bool result; using (new StopwatchPerformanceTracker("RouterCheckTargetMailboxOnThisServer", request.PerformanceLogger)) { using (new ADPerformanceTracker("RouterCheckTargetMailboxOnThisServer", request.PerformanceLogger)) { result = serviceLocator.IsServiceOnThisServer(serviceLocator.Locate(target)); } } return(result); }