Exemplo n.º 1
0
        internal static InvokeDataLossState FromBytes(BinaryReader br)
        {
            InvokeDataLossState state = new InvokeDataLossState();

            // Note: the type of command (an Enum serialized as Int32) was already read by caller
            state.Read(br);

            return(state);
        }
Exemplo n.º 2
0
        // test only
        internal override bool VerifyEquals(ActionStateBase other)
        {
            InvokeDataLossState state = other as InvokeDataLossState;

            if (state == null)
            {
                return(false);
            }

            if (!base.VerifyEquals(other))
            {
                return(false);
            }

            return(this.Info.VerifyEquals(state.Info));
        }
Exemplo n.º 3
0
        public InvokeDataLossAction(
            IReliableStateManager stateManager,
            IStatefulServicePartition partition,
            InvokeDataLossState state,
            PartitionSelector partitionSelector,
            DataLossMode dataLossMode,
            int dataLossCheckWaitDurationInSeconds,
            int dataLossCheckPollIntervalInSeconds,
            int replicaDropWaitDurationInSeconds,
            TimeSpan requestTimeout,
            TimeSpan operationTimeout)
            : base(stateManager, partition, state, requestTimeout, operationTimeout)
        {
            ThrowIf.Null(partitionSelector, "partitionSelector");

            this.PartitionSelector = partitionSelector;
            this.DataLossMode      = dataLossMode;
            this.DataLossCheckWaitDurationInSeconds = dataLossCheckWaitDurationInSeconds;
            this.DataLossCheckPollIntervalInSeconds = dataLossCheckPollIntervalInSeconds;
            this.ReplicaDropWaitDurationInSeconds   = replicaDropWaitDurationInSeconds;
        }