Skip to content

Commit

Permalink
todo - Deprecated legacy backend (#2053)
Browse files Browse the repository at this point in the history
Signed-off-by: Andre Wanlin <awanlin@spotify.com>
  • Loading branch information
awanlin authored Nov 26, 2024
1 parent 14a35d5 commit b23745f
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 4 deletions.
5 changes: 5 additions & 0 deletions workspaces/todo/.changeset/fluffy-phones-tie.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'@backstage-community/plugin-todo-backend': patch
---

Deprecated `createRouter` and its router options in favour of the new backend system.
4 changes: 2 additions & 2 deletions workspaces/todo/plugins/todo-backend/report.api.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ import { ScmIntegrations } from '@backstage/integration';
import { ServiceRef } from '@backstage/backend-plugin-api';
import { UrlReaderService } from '@backstage/backend-plugin-api';

// @public (undocumented)
// @public @deprecated (undocumented)
export function createRouter(options: RouterOptions): Promise<express.Router>;

// @public (undocumented)
Expand Down Expand Up @@ -52,7 +52,7 @@ export type ReadTodosResult = {
items: TodoItem[];
};

// @public (undocumented)
// @public @deprecated (undocumented)
export interface RouterOptions {
// (undocumented)
todoService: TodoService;
Expand Down
10 changes: 8 additions & 2 deletions workspaces/todo/plugins/todo-backend/src/service/router.ts
Original file line number Diff line number Diff line change
Expand Up @@ -25,12 +25,18 @@ import {
} from '../lib/utils';
import { createOpenApiRouter } from '../schema/openapi.generated';

/** @public */
/**
* @deprecated Please migrate to the new backend system as this will be removed in the future.
*
* @public */
export interface RouterOptions {
todoService: TodoService;
}

/** @public */
/**
* @deprecated Please migrate to the new backend system as this will be removed in the future.
*
* @public */
export async function createRouter(
options: RouterOptions,
): Promise<express.Router> {
Expand Down

0 comments on commit b23745f

Please sign in to comment.