search-backend: update changeset to minor and add migration steps

Signed-off-by: MT Lewis <mtlewis@users.noreply.github.com>
This commit is contained in:
MT Lewis
2022-01-25 13:17:08 +00:00
parent c7ce3076d9
commit bd895e5812
+22 -2
View File
@@ -1,5 +1,25 @@
---
'@backstage/plugin-search-backend': patch
'@backstage/plugin-search-backend': minor
---
Add support for filtering search results according to visibility.
**BREAKING** Added three additional required properties to `createRouter` to support filtering search results based on permissions. To make this change to an existing app, add the required parameters to the `createRouter` call in `packages/backend/src/plugins/search.ts`:
```diff
export default async function createPlugin({
logger,
+ permissions,
discovery,
config,
tokenManager,
}: PluginEnvironment) {
/* ... */
return await createRouter({
engine: indexBuilder.getSearchEngine(),
+ types: indexBuilder.getDocumentTypes(),
+ permissions,
+ config,
logger,
});
}
```