Beispiel #1
0
        public DependableConfiguration Activity <T>(Action <ActivityConfiguration> configurator)
        {
            var configuration = new ActivityConfiguration(typeof(T), _defaultActivityConfiguration);

            configurator(configuration);

            _activityConfiguration[typeof(T)] = configuration;

            return(this);
        }
        public ActivityConfiguration(Type type = null, ActivityConfiguration @default = null)
        {
            Type = type;

            if (@default == null)
            {
                MaxWorkers = Defaults.MaxWorkers;
                RetryDelay = Defaults.RetryDelay;
                RetryCount = Defaults.RetryCount;
                MaxQueueLength = Defaults.MaxQueueLength;
            }
            else
            {
                MaxWorkers = @default.MaxWorkers;
                RetryDelay = @default.RetryDelay;
                RetryCount = @default.RetryCount;
                MaxQueueLength = @default.MaxQueueLength;
            }
        }
        public ActivityConfiguration(Type type = null, ActivityConfiguration @default = null)
        {
            Type = type;

            if (@default == null)
            {
                MaxWorkers     = Defaults.MaxWorkers;
                RetryDelay     = Defaults.RetryDelay;
                RetryCount     = Defaults.RetryCount;
                MaxQueueLength = Defaults.MaxQueueLength;
            }
            else
            {
                MaxWorkers     = @default.MaxWorkers;
                RetryDelay     = @default.RetryDelay;
                RetryCount     = @default.RetryCount;
                MaxQueueLength = @default.MaxQueueLength;
            }
        }