コード例 #1
0
        internal ServiceConfiguration(ICodePackageActivationContext activationContext, TraceWriterWrapper trace)
        {
            this.activationContext = Guard.IsNotNull(activationContext, nameof(activationContext));
            this.trace             = Guard.IsNotNull(trace, nameof(trace));

            this.RefreshConfigurationCache();
        }
コード例 #2
0
        public FabricHealthClientWrapper(TraceWriterWrapper trace, string serviceTypeName, Guid partitionId, long replicaId)
        {
            this.traceWriter  = Guard.IsNotNull(trace, nameof(trace));
            this.healthClient = this.GetNewHealthClientInstance();

            this.serviceTypeName = Guard.IsNotNullOrEmpty(serviceTypeName, nameof(serviceTypeName));
            this.partitionId     = partitionId;
            this.replicaId       = replicaId;
        }
コード例 #3
0
ファイル: ClusterEntity.cs プロジェクト: zmyer/service-fabric
 internal ClusterEntity(
     FabricHealthClientWrapper healthClient,
     HealthDataConsumer consumer,
     TraceWriterWrapper traceWriter,
     IServiceConfiguration config,
     EntityFilterRepository filterRepository)
     : base(healthClient, consumer, traceWriter, config, filterRepository)
 {
     this.ClusterName = Guard.IsNotNullOrEmpty(this.Config.ClusterName, nameof(this.Config.ClusterName));
 }
コード例 #4
0
 internal HealthDataService(
     HealthDataProducer producer,
     TraceWriterWrapper traceWriter,
     IServiceConfiguration config,
     EntityFilterRepository filterRepository)
 {
     this.Producer         = Guard.IsNotNull(producer, nameof(producer));
     this.Trace            = Guard.IsNotNull(traceWriter, nameof(traceWriter));
     this.Config           = Guard.IsNotNull(config, nameof(config));
     this.FilterRepository = Guard.IsNotNull(filterRepository, nameof(filterRepository));
 }
コード例 #5
0
 protected Entity(
     FabricHealthClientWrapper healthClient,
     HealthDataConsumer consumer,
     TraceWriterWrapper traceWriter,
     IServiceConfiguration config,
     EntityFilterRepository filters)
 {
     this.HealthClient = Guard.IsNotNull(healthClient, nameof(healthClient));
     this.Consumer     = Guard.IsNotNull(consumer, nameof(consumer));
     this.TraceWriter  = Guard.IsNotNull(traceWriter, nameof(traceWriter));
     this.Config       = Guard.IsNotNull(config, nameof(config));
     this.Filters      = Guard.IsNotNull(filters, nameof(filters));
 }
コード例 #6
0
 internal ApplicationEntity(
     FabricHealthClientWrapper healthClient,
     HealthDataConsumer consumer,
     string clusterName,
     Uri applicationUri,
     TraceWriterWrapper traceWriter,
     IServiceConfiguration config,
     EntityFilterRepository filterRepository)
     : base(healthClient, consumer, traceWriter, config, filterRepository)
 {
     this.ClusterName    = Guard.IsNotNullOrEmpty(clusterName, nameof(clusterName));
     this.applicationUri = Guard.IsNotNull(applicationUri, nameof(applicationUri));
 }
コード例 #7
0
        internal HealthDataProducer(
            FabricHealthClientWrapper healthClient,
            HealthDataConsumer consumer,
            TraceWriterWrapper traceWriter,
            IServiceConfiguration config,
            EntityFilterRepository filterRepository)
        {
            this.healthClient     = Guard.IsNotNull(healthClient, nameof(healthClient));
            this.consumer         = Guard.IsNotNull(consumer, nameof(consumer));
            this.traceWriter      = Guard.IsNotNull(traceWriter, nameof(traceWriter));
            this.config           = Guard.IsNotNull(config, nameof(config));
            this.filterRepository = Guard.IsNotNull(filterRepository, nameof(filterRepository));
            this.stopwatch        = new Stopwatch();

            this.stack = new Stack <IEntity>();
        }
コード例 #8
0
 internal PartitionEntity(
     FabricHealthClientWrapper healthClient,
     HealthDataConsumer consumer,
     string clusterName,
     string applicationName,
     string serviceName,
     Guid partitionId,
     TraceWriterWrapper traceWriter,
     IServiceConfiguration config,
     EntityFilterRepository filterRepository)
     : base(healthClient, consumer, traceWriter, config, filterRepository)
 {
     this.ClusterName     = Guard.IsNotNullOrEmpty(clusterName, nameof(clusterName));
     this.ApplicationName = Guard.IsNotNullOrEmpty(applicationName, nameof(applicationName));
     this.ServiceName     = Guard.IsNotNullOrEmpty(serviceName, nameof(serviceName));
     this.PartitionId     = partitionId;
 }
コード例 #9
0
 internal DeployedServicePackageEntity(
     FabricHealthClientWrapper healthClient,
     HealthDataConsumer consumer,
     string clusterName,
     Uri applicationUri,
     string serviceManifestName,
     string nodeName,
     TraceWriterWrapper traceWriter,
     IServiceConfiguration config,
     EntityFilterRepository filterRepository)
     : base(healthClient, consumer, traceWriter, config, filterRepository)
 {
     this.ClusterName         = Guard.IsNotNullOrEmpty(clusterName, nameof(clusterName));
     this.NodeName            = Guard.IsNotNullOrEmpty(nodeName, nameof(nodeName));
     this.applicationUri      = Guard.IsNotNull(applicationUri, nameof(applicationUri));
     this.ServiceManifestName = Guard.IsNotNullOrEmpty(serviceManifestName, nameof(serviceManifestName));
 }
コード例 #10
0
 protected PrimaryElectionService(StatefulServiceContext serviceContext, TraceWriterWrapper traceWriter)
     : base(serviceContext, new NullStateProviderReplica(traceWriter))
 {
 }
コード例 #11
0
 public NullStateProviderReplica(TraceWriterWrapper traceWriter)
 {
     this.trace = Guard.IsNotNull(traceWriter, nameof(traceWriter));
 }