// Token: 0x06001687 RID: 5767 RVA: 0x000800A0 File Offset: 0x0007E2A0
        internal static void GetComplianceMaxExpansionDGRecipientsAndNestedDGs(OrganizationId organizationId, out uint complianceMaxExpansionDGRecipients, out uint complianceMaxExpansionNestedDGs)
        {
            IThrottlingPolicy throttlingPolicy = RecipientDLExpansionEventBasedAssistantHelper.GetThrottlingPolicy(organizationId);

            complianceMaxExpansionDGRecipients = (throttlingPolicy.ComplianceMaxExpansionDGRecipients.IsUnlimited ? uint.MaxValue : throttlingPolicy.ComplianceMaxExpansionDGRecipients.Value);
            ExTraceGlobals.FaultInjectionTracer.TraceTest <uint>(3162910013U, ref complianceMaxExpansionDGRecipients);
            complianceMaxExpansionNestedDGs = (throttlingPolicy.ComplianceMaxExpansionNestedDGs.IsUnlimited ? uint.MaxValue : throttlingPolicy.ComplianceMaxExpansionNestedDGs.Value);
            ExTraceGlobals.FaultInjectionTracer.TraceTest <uint>(4236651837U, ref complianceMaxExpansionNestedDGs);
        }
 // Token: 0x06001678 RID: 5752 RVA: 0x0007EC98 File Offset: 0x0007CE98
 protected override void HandleEventInternal(MapiEvent mapiEvent, MailboxSession itemStore, StoreObject item, List <KeyValuePair <string, object> > customDataToLog)
 {
     if (this.InternalIsEventInteresting(mapiEvent) && itemStore != null && item != null)
     {
         MessageItem messageItem = item as MessageItem;
         if (messageItem == null)
         {
             RecipientDLExpansionEventBasedAssistant.Tracer.TraceWarning((long)this.GetHashCode(), "The item being processed is not a message item.");
             return;
         }
         RecipientDLExpansionEventBasedAssistant.Tracer.TraceDebug <Guid, StoreObjectId, string>((long)this.GetHashCode(), "Processing mailbox guid: {0} and message id: {1} with subject: '{2}'", itemStore.MailboxGuid, messageItem.StoreObjectId, messageItem.Subject);
         StorageGlobals.EventLogger.LogEvent(StorageEventLogConstants.Tuple_RecipientDLExpansionIsProcessing, null, new object[]
         {
             messageItem.StoreObjectId,
             messageItem.Subject,
             itemStore.MailboxGuid
         });
         bool flag  = false;
         bool flag2 = true;
         try
         {
             ADUser adUser = DirectoryHelper.ReadADRecipient(itemStore.MailboxOwner.MailboxInfo.MailboxGuid, itemStore.MailboxOwner.MailboxInfo.IsArchive, itemStore.GetADRecipientSession(true, ConsistencyMode.IgnoreInvalid)) as ADUser;
             bool   flag3  = this.IsFlightingFeatureEnabled(adUser) || RecipientDLExpansionEventBasedAssistantHelper.IsRecipientDLExpansionTestHookEnabled();
             RecipientDLExpansionEventBasedAssistantHelper.GetComplianceMaxExpansionDGRecipientsAndNestedDGs(itemStore.OrganizationId, out this.maxDGExpansionRecipients, out this.maxExpansionNestedDGs);
             if (flag3 && this.maxDGExpansionRecipients != 0U)
             {
                 flag2 = false;
                 this.PerformDLExpansionOnItemRecipients(itemStore, messageItem, ref flag2);
             }
             else
             {
                 RecipientDLExpansionEventBasedAssistant.Tracer.TraceDebug <StoreObjectId, Guid, OrganizationId>((long)this.GetHashCode(), "Per tenant configuration or flighting framework, DL expansion is disabled, skip processing message id: {0}, mailbox guid: {1}, tenant: {2}", messageItem.StoreObjectId, itemStore.MailboxGuid, itemStore.OrganizationId);
                 StorageGlobals.EventLogger.LogEvent(StorageEventLogConstants.Tuple_RecipientDLExpansionSkipped, null, new object[]
                 {
                     messageItem.StoreObjectId,
                     itemStore.MailboxGuid,
                     itemStore.OrganizationId
                 });
             }
         }
         catch (Exception ex)
         {
             RecipientDLExpansionEventBasedAssistant.Tracer.TraceError((long)this.GetHashCode(), "Exception when updating the item with id: {0}, mailbox guid: {1}, tenant: {2}.\n\nThe exception is : {3}", new object[]
             {
                 messageItem.StoreObjectId,
                 itemStore.MailboxGuid,
                 itemStore.OrganizationId,
                 ex
             });
             StorageGlobals.EventLogger.LogEvent(StorageEventLogConstants.Tuple_RecipientDLExpansionFailed, null, new object[]
             {
                 messageItem.StoreObjectId,
                 itemStore.MailboxGuid,
                 itemStore.OrganizationId,
                 ex
             });
             this.PublishMonitoringResults(itemStore, ex);
             flag = true;
             if (!(ex is StorageTransientException) && !(ex is StoragePermanentException))
             {
                 throw;
             }
         }
         if (!flag && !flag2)
         {
             this.PublishMonitoringResults(itemStore, null);
         }
     }
 }