public EventPublisher(IEventingRepoFactory repoFactory, DateTimeProvider dtProvider, TimeSpan cacheDuration, InvokeOptions invokeOptions) { _repoFactory = repoFactory; _dtProvider = dtProvider; _cacheDuration = cacheDuration; _invokeOptions = invokeOptions; }
public EventingRepoFactoryFixture() : base() { var useMySql = (this.Configuration["UseMySql"] == "true"); // Can be set from environment variable Console.WriteLine("Running tests on " + (useMySql ? "MySQL" : "MS SQL Server")); var connectionString = this.Configuration.GetConnectionString(useMySql ? "Resonance.MySql" : "Resonance.MsSql"); if (useMySql) { RepoFactory = new MySqlEventingRepoFactory(connectionString); using (var conn = new MySqlConnection(connectionString)) { conn.Open(); CleanDb(conn); } } else { RepoFactory = new MsSqlEventingRepoFactory(connectionString); using (var conn = new SqlConnection(connectionString)) { conn.Open(); CleanDb(conn); } } }
public EventPublisher(IEventingRepoFactory repoFactory, DateTimeProvider dtProvider, TimeSpan cacheDuration) : this(repoFactory, dtProvider, cacheDuration, InvokeOptions.Default) { }
public EventPublisher(IEventingRepoFactory repoFactory, DateTimeProvider dtProvider) : this(repoFactory, dtProvider, TimeSpan.FromSeconds(30)) { }
public EventPublisher(IEventingRepoFactory repoFactory) : this(repoFactory, DateTimeProvider.Repository) { }
public EventConsumer(IEventingRepoFactory repoFactory, TimeSpan cacheDuration, InvokeOptions invokeOptions) { _repoFactory = repoFactory; _cacheDuration = cacheDuration; _invokeOptions = invokeOptions; }
public EventConsumer(IEventingRepoFactory repoFactory, TimeSpan cacheDuration) : this(repoFactory, cacheDuration, InvokeOptions.Default) { }
public EventConsumer(IEventingRepoFactory repoFactory) : this(repoFactory, TimeSpan.FromSeconds(30)) { }