コード例 #1
0
        /// <summary>Creates and initializes a silo in the current app domain.</summary>
        /// <param name="name">Name of this silo.</param>
        /// <param name="siloBuilderFactoryType">Type of silo builder factory.</param>
        /// <param name="config">Silo config data to be used for this silo.</param>
        public AppDomainSiloHost(string name, Type siloBuilderFactoryType, ClusterConfiguration config)
        {
            var          builderFactory = (ISiloBuilderFactory)Activator.CreateInstance(siloBuilderFactoryType);
            ISiloBuilder builder        = builderFactory.CreateSiloBuilder(name, config);

            builder.ConfigureServices((services) => services.AddSingleton <TestHooksSystemTarget>());
            this.silo = builder.Build();
            InitializeTestHooksSystemTarget();
            this.AppDomainTestHook = new AppDomainTestHooks(this.silo);
        }
コード例 #2
0
 public new void TestFixtureTearDown()
 {
     _silo.Dispose();
     _silo = null;
 }
コード例 #3
0
 public new void TestFixtureSetUp()
 {
     _silo = Create();
 }
コード例 #4
0
 public TestHooksSystemTarget(ISilo silo, ILocalSiloDetails siloDetails, ILoggerFactory loggerFactory)
     : base(Constants.TestHooksSystemTargetId, siloDetails.SiloAddress, loggerFactory)
 {
     this.silo = silo;
     consistentRingProvider = this.silo.Services.GetRequiredService <IConsistentRingProvider>();
 }
コード例 #5
0
 public AppDomainTestHooks(ISilo silo)
 {
     this.silo = silo;
 }