示例#1
0
 public AdoNetReminderTable(
     IServiceProvider serviceProvider,
     IOptions <ClusterOptions> clusterOptions,
     IOptions <AdoNetReminderTableOptions> storageOptions)
 {
     this.serviceProvider = serviceProvider;
     this.serviceId       = clusterOptions.Value.ServiceId;
     this.options         = storageOptions.Value;
 }
示例#2
0
 public AdoNetReminderTable(
     IGrainReferenceConverter grainReferenceConverter,
     IOptions <ClusterOptions> clusterOptions,
     IOptions <AdoNetReminderTableOptions> storageOptions)
 {
     this.grainReferenceConverter = grainReferenceConverter;
     this.serviceId = clusterOptions.Value.ServiceId.ToString();
     this.options   = storageOptions.Value;
 }
示例#3
0
 protected override IReminderTable CreateRemindersTable()
 {
     var options = new AdoNetReminderTableOptions
     {
         Invariant = this.GetAdoInvariant(),
         ConnectionString = this.connectionStringFixture.ConnectionString
     };
     return new AdoNetReminderTable(
         this.ClusterFixture.Services.GetRequiredService<IGrainReferenceConverter>(),
         this.siloOptions,
         Options.Create(options));
 }
        protected override IReminderTable CreateRemindersTable()
        {
            var options = new AdoNetReminderTableOptions
            {
                Invariant        = this.GetAdoInvariant(),
                ConnectionString = this.connectionStringFixture.ConnectionString
            };

            return(new AdoNetReminderTable(
                       this.ClusterFixture.Services,
                       this.clusterOptions,
                       Options.Create(options)));
        }
示例#5
0
        private static void ConvertToAdoNetReminderTableOptions <T>(Action <T> configureOptions, AdoNetReminderTableOptions options)
            where T : AdoNetReminderTableOptions, new()
        {
            var t = new T();

            configureOptions(t);
            options.Invariant        = t.Invariant;
            options.ConnectionString = t.ConnectionString;
        }