Exemple #1
0
        private static IList <BackEndServer> GetBackEndServerListForOrganization(OrganizationId organizationId, int maxServers)
        {
            ADUser defaultOrganizationMailbox = HttpProxyBackEndHelper.GetDefaultOrganizationMailbox(organizationId, null);

            if (defaultOrganizationMailbox == null || defaultOrganizationMailbox.Database == null)
            {
                ExTraceGlobals.CafeTracer.TraceError <OrganizationId>(0L, "[BackEndLocator.GetBackEndServerByOrganization] Cannot find organization mailbox for organization {1}", organizationId);
                throw new AdUserNotFoundException(ServerStrings.ADUserNotFound);
            }
            return(BackEndLocator.GetBackEndServerListForDatabase(defaultOrganizationMailbox.Database, organizationId, defaultOrganizationMailbox.PrimarySmtpAddress, maxServers));
        }
Exemple #2
0
 public static IList <BackEndServer> GetBackEndServerList(MiniRecipient miniRecipient, int maxServers)
 {
     if (miniRecipient == null)
     {
         throw new ArgumentNullException("miniRecipient");
     }
     return(BackEndLocator.CallWithExceptionHandling <IList <BackEndServer> >(() => BackEndLocator.GetBackEndServerListForDatabase(miniRecipient.Database, miniRecipient.OrganizationId, miniRecipient.PrimarySmtpAddress, maxServers)));
 }