chore: switch from config to RootConfigService

Signed-off-by: Johan Haals <johan.haals@gmail.com>
This commit is contained in:
Johan Haals
2024-08-16 15:44:51 +02:00
parent 6bd6fdad12
commit f15d1fb1f1
2 changed files with 5 additions and 4 deletions
+2 -2
View File
@@ -4,12 +4,12 @@
```ts
import { AuthService } from '@backstage/backend-plugin-api';
import { Config } from '@backstage/config';
import { ConfigSchema } from '@backstage/config-loader';
import { DatabaseService } from '@backstage/backend-plugin-api';
import express from 'express';
import { HttpAuthService } from '@backstage/backend-plugin-api';
import { LoggerService } from '@backstage/backend-plugin-api';
import { RootConfigService } from '@backstage/backend-plugin-api';
// @public @deprecated (undocumented)
export function createRouter(options: RouterOptions): Promise<express.Router>;
@@ -20,7 +20,7 @@ export interface RouterOptions {
// (undocumented)
auth?: AuthService;
// (undocumented)
config: Config;
config: RootConfigService;
database?: DatabaseService;
disableConfigInjection?: boolean;
// (undocumented)
+3 -2
View File
@@ -18,8 +18,9 @@ import { notFoundHandler } from '@backstage/backend-common';
import {
DatabaseService,
resolvePackagePath,
RootConfigService,
} from '@backstage/backend-plugin-api';
import { AppConfig, Config } from '@backstage/config';
import { AppConfig } from '@backstage/config';
import helmet from 'helmet';
import express from 'express';
import Router from 'express-promise-router';
@@ -52,7 +53,7 @@ type Mime = { lookup(arg0: string): string };
* @deprecated Please migrate to the new backend system as this will be removed in the future.
*/
export interface RouterOptions {
config: Config;
config: RootConfigService;
logger: LoggerService;
auth?: AuthService;
httpAuth?: HttpAuthService;