Ejemplo n.º 1
0
        public static ConcurrentThreadState GetThreadUsage(Guid integrationId)
        {
            if (integrationId == Guid.Empty)
            {
                throw new Exception("Integration ID can not be empty.");
            }

            if (!threadsInUseByIntegrationId.ContainsKey(integrationId))
            {
                threadsInUseByIntegrationId[integrationId] = new ConcurrentThreadState(1);
            }

            return(threadsInUseByIntegrationId[integrationId]);
        }
Ejemplo n.º 2
0
        public ConcurrentThreadUsageChangedArgs(Integration integration, ConcurrentThreadState newConcurrentThreadState)
        {
            Integration = integration;

            NewConcurrentThreadState = newConcurrentThreadState;
        }