public CountersAggregator(EFCoreStorage storage)
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }

            _storage = storage;
        }
예제 #2
0
        public EFCoreJobQueueProvider(EFCoreStorage storage)
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }

            _storage = storage;
        }
        public ExpirationManager(EFCoreStorage storage)
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }

            _storage = storage;
        }
예제 #4
0
        public EFCoreJobQueueMonitoringApi(EFCoreStorage storage)
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }

            _storage = storage;
        }
예제 #5
0
        public EFCoreStorageConnection(EFCoreStorage storage)
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }

            _storage      = storage;
            _lockProvider = new EFCoreLockProvider(_storage);
        }
        public EFCoreLockProvider(
            [NotNull] EFCoreStorage storage)
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }

            _storage = storage;
        }
예제 #7
0
        public EFCoreStorageTransaction(
            EFCoreStorage storage)
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }

            _storage          = storage;
            _queue            = new Queue <Action <DbContext> >();
            _afterCommitQueue = new Queue <Action>();
        }
        public EFCoreFetchedJob(
            [NotNull] EFCoreStorage storage,
            [NotNull] HangfireQueuedJob queuedJob)
        {
            if (storage is null)
            {
                throw new ArgumentNullException(nameof(storage));
            }
            if (queuedJob is null)
            {
                throw new ArgumentNullException(nameof(queuedJob));
            }

            _storage   = storage;
            _queuedJob = queuedJob;
            var keepAliveInterval = new TimeSpan(storage.SlidingInvisibilityTimeout.Ticks / 5);

            _timer = new Timer(ExecuteKeepAliveQuery, null, keepAliveInterval, keepAliveInterval);
        }