コード例 #1
0
ファイル: RemoveTenantDatabase.cs プロジェクト: ybdev/ravendb
        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)
            });
        }
コード例 #2
0
        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)
            });
        }
コード例 #3
0
ファイル: HttpServer.cs プロジェクト: urbanfly/ravendb
		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);
		}
コード例 #4
0
ファイル: HttpServer.cs プロジェクト: csainty/ravendb
		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);
		}
コード例 #5
0
ファイル: HttpServer.cs プロジェクト: Nakro/ravendb
		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);
		}