public override void AfterCommit(string key) { if (key.StartsWith(RavenDatabasesPrefix, StringComparison.OrdinalIgnoreCase) == false) { return; } TenantDatabaseModified.Invoke(this, new TenantDatabaseModified.Event { Database = Database, Name = key.Substring(RavenDatabasesPrefix.Length) }); }
public override void AfterCommit(string key, Raven.Json.Linq.RavenJObject document, Raven.Json.Linq.RavenJObject metadata, Guid etag) { if (key.StartsWith(RavenDatabasesPrefix, StringComparison.InvariantCultureIgnoreCase) == false) { return; } TenantDatabaseModified.Invoke(this, new TenantDatabaseModified.Event { Database = Database, Name = key.Substring(RavenDatabasesPrefix.Length) }); }
private void TenantDatabaseRemoved(object sender, TenantDatabaseModified.Event @event) { if (@event.Database != SystemDatabase) return; // we ignore anything that isn't from the root db CleanupDatabase(@event.Name, skipIfActive: false); }
private void TenantDatabaseRemoved(object sender, TenantDatabaseModified.Event @event) { if (@event.Database != DefaultResourceStore) return; // we ignore anything that isn't from the root db CleanupDatabase(@event.Name); }
private void TenantDatabaseRemoved(object sender, TenantDatabaseModified.Event @event) { if (@event.Database != SystemDatabase) return; // we ignore anything that isn't from the root db logger.Info("Shutting down database {0} because the tenant database has been updated or removed", @event.Name); CleanupDatabase(@event.Name, skipIfActive: false); }