remove PluginDatabaseManager and PluginEndpointDiscovery
Signed-off-by: Fredrik Adelöw <freben@gmail.com>
This commit is contained in:
@@ -14,11 +14,11 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import { DatabaseManager } from '@backstage/backend-common';
|
||||
import {
|
||||
DatabaseManager,
|
||||
PluginDatabaseManager,
|
||||
} from '@backstage/backend-common';
|
||||
import { resolvePackagePath } from '@backstage/backend-plugin-api';
|
||||
DatabaseService,
|
||||
resolvePackagePath,
|
||||
} from '@backstage/backend-plugin-api';
|
||||
import { ConfigReader } from '@backstage/config';
|
||||
import { Knex } from 'knex';
|
||||
|
||||
@@ -32,10 +32,10 @@ const migrationsDir = resolvePackagePath(
|
||||
* asked for, and runs migrations.
|
||||
*/
|
||||
export class AuthDatabase {
|
||||
readonly #database: PluginDatabaseManager;
|
||||
readonly #database: DatabaseService;
|
||||
#promise: Promise<Knex> | undefined;
|
||||
|
||||
static create(database: PluginDatabaseManager): AuthDatabase {
|
||||
static create(database: DatabaseService): AuthDatabase {
|
||||
return new AuthDatabase(database);
|
||||
}
|
||||
|
||||
@@ -60,7 +60,7 @@ export class AuthDatabase {
|
||||
});
|
||||
}
|
||||
|
||||
private constructor(database: PluginDatabaseManager) {
|
||||
private constructor(database: DatabaseService) {
|
||||
this.#database = database;
|
||||
}
|
||||
|
||||
|
||||
@@ -14,12 +14,10 @@
|
||||
* limitations under the License.
|
||||
*/
|
||||
|
||||
import {
|
||||
PluginEndpointDiscovery,
|
||||
TokenManager,
|
||||
} from '@backstage/backend-common';
|
||||
import { TokenManager } from '@backstage/backend-common';
|
||||
import {
|
||||
AuthService,
|
||||
DiscoveryService,
|
||||
HttpAuthService,
|
||||
LoggerService,
|
||||
} from '@backstage/backend-plugin-api';
|
||||
@@ -47,7 +45,7 @@ export function bindProviderRouters(
|
||||
baseUrl: string;
|
||||
config: Config;
|
||||
logger: LoggerService;
|
||||
discovery: PluginEndpointDiscovery;
|
||||
discovery: DiscoveryService;
|
||||
auth: AuthService;
|
||||
httpAuth: HttpAuthService;
|
||||
tokenManager?: TokenManager;
|
||||
|
||||
Reference in New Issue
Block a user