diff --git a/.changeset/afraid-ghosts-watch.md b/.changeset/afraid-ghosts-watch.md deleted file mode 100644 index b277baaff1..0000000000 --- a/.changeset/afraid-ghosts-watch.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-search-backend-module-elasticsearch': patch ---- - -Fix never resolved indexer promise. diff --git a/.changeset/afraid-needles-divide.md b/.changeset/afraid-needles-divide.md deleted file mode 100644 index 6db7f449b0..0000000000 --- a/.changeset/afraid-needles-divide.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/create-app': patch ---- - -Removed `packages/backend/src/types.ts` from the template as it is unused. It was mistakenly left in after moving the template to the new backend system. diff --git a/.changeset/blue-hotels-shake.md b/.changeset/blue-hotels-shake.md deleted file mode 100644 index 3d55aacffa..0000000000 --- a/.changeset/blue-hotels-shake.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -'@backstage/plugin-scaffolder-common': patch -'@backstage/plugin-scaffolder-react': patch -'@backstage/plugin-scaffolder': patch ---- - -Capturing more event clicks for scaffolder diff --git a/.changeset/brave-apples-move.md b/.changeset/brave-apples-move.md new file mode 100644 index 0000000000..7a1fa86a56 --- /dev/null +++ b/.changeset/brave-apples-move.md @@ -0,0 +1,5 @@ +--- +'@backstage/backend-app-api': patch +--- + +Fixed a potential crash when passing an object with a `null` prototype as log meta. diff --git a/.changeset/brave-carrots-glow.md b/.changeset/brave-carrots-glow.md deleted file mode 100644 index b4493bf4f6..0000000000 --- a/.changeset/brave-carrots-glow.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-node': minor ---- - -Added `LocationAnalyzer` type, moved from `@backstage/plugin-catalog-backend`. diff --git a/.changeset/breezy-badgers-train.md b/.changeset/breezy-badgers-train.md new file mode 100644 index 0000000000..8f747b8602 --- /dev/null +++ b/.changeset/breezy-badgers-train.md @@ -0,0 +1,5 @@ +--- +'@backstage/cli-node': patch +--- + +Upgraded @yarnpkg/parsers to stable 3.0 diff --git a/.changeset/bright-pumpkins-rule.md b/.changeset/bright-pumpkins-rule.md deleted file mode 100644 index 07de4f313c..0000000000 --- a/.changeset/bright-pumpkins-rule.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -Allow overriding `NotificationsPage` page properties diff --git a/.changeset/calm-plums-wink.md b/.changeset/calm-plums-wink.md new file mode 100644 index 0000000000..edb991f616 --- /dev/null +++ b/.changeset/calm-plums-wink.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-techdocs': patch +--- + +mkdocs-material have updated their CSS variable template, and a few are unset in Backstage. This patch adds the missing variables to ensure coverage. diff --git a/.changeset/chatty-cycles-unite.md b/.changeset/chatty-cycles-unite.md deleted file mode 100644 index 93dffbb143..0000000000 --- a/.changeset/chatty-cycles-unite.md +++ /dev/null @@ -1,9 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend-module-github': patch -'@backstage/core-compat-api': patch -'@backstage/create-app': patch -'@backstage/plugin-api-docs': patch -'@backstage/plugin-catalog': patch ---- - -Update local development dependencies. diff --git a/.changeset/chilly-adults-sing.md b/.changeset/chilly-adults-sing.md deleted file mode 100644 index 82f4cb88b2..0000000000 --- a/.changeset/chilly-adults-sing.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend': patch ---- - -Add lifecycle monitoring for the catalog processing diff --git a/.changeset/chilly-fireants-roll.md b/.changeset/chilly-fireants-roll.md deleted file mode 100644 index 93c05fecb7..0000000000 --- a/.changeset/chilly-fireants-roll.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-home': patch ---- - -Use relative time when displaying visits from the same day diff --git a/.changeset/chilly-shoes-doubt.md b/.changeset/chilly-shoes-doubt.md deleted file mode 100644 index 978600f5b4..0000000000 --- a/.changeset/chilly-shoes-doubt.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-msgraph': patch ---- - -Fixed disabling of user photo fetching. Previously, the config value wasn't propagated properly, so user photos was still being fetched despite disabled by config. diff --git a/.changeset/cli-postpack-schmostschmack.md b/.changeset/cli-postpack-schmostschmack.md deleted file mode 100644 index 2500c89a8c..0000000000 --- a/.changeset/cli-postpack-schmostschmack.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/cli': patch ---- - -The `build-workspace` command no longer manually runs `yarn postpack`, relying instead on the fact that running `yarn pack` will automatically invoke the `postpack` script. No action is necessary if you are running the latest version of yarn 1, 3, or 4. diff --git a/.changeset/cold-cougars-float.md b/.changeset/cold-cougars-float.md deleted file mode 100644 index 1ddc78a34b..0000000000 --- a/.changeset/cold-cougars-float.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-unprocessed': patch -'@backstage/backend-dynamic-feature-service': patch -'@backstage/plugin-search-backend-module-catalog': patch ---- - -Updated `README.md` to point to `packages/backend` instead of `packages/backend-next`. diff --git a/.changeset/cold-rats-leave.md b/.changeset/cold-rats-leave.md deleted file mode 100644 index 6fe28d6371..0000000000 --- a/.changeset/cold-rats-leave.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend': patch ---- - -Fix issue with the log format not being respected when logging from actions diff --git a/.changeset/cool-elephants-march.md b/.changeset/cool-elephants-march.md deleted file mode 100644 index 2396f9553d..0000000000 --- a/.changeset/cool-elephants-march.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend-module-gitea': patch ---- - -Allow defining `repoVisibility` field for the action `publish:gitea` diff --git a/.changeset/create-app-1714476054.md b/.changeset/create-app-1714476054.md deleted file mode 100644 index b50d431d4b..0000000000 --- a/.changeset/create-app-1714476054.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/create-app': patch ---- - -Bumped create-app version. diff --git a/.changeset/create-app-1715088359.md b/.changeset/create-app-1715088359.md deleted file mode 100644 index b50d431d4b..0000000000 --- a/.changeset/create-app-1715088359.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/create-app': patch ---- - -Bumped create-app version. diff --git a/.changeset/cuddly-chairs-kick.md b/.changeset/cuddly-chairs-kick.md deleted file mode 100644 index ebb53b8e26..0000000000 --- a/.changeset/cuddly-chairs-kick.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-app-api': patch ---- - -Add ability to configure the Node.js HTTP Server when configuring the root HTTP Router service diff --git a/.changeset/curly-shirts-flow.md b/.changeset/curly-shirts-flow.md deleted file mode 100644 index b9a73809ba..0000000000 --- a/.changeset/curly-shirts-flow.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/repo-tools': patch ---- - -Update the paths logic in the api reports command to support complex subpaths diff --git a/.changeset/curvy-planes-flash.md b/.changeset/curvy-planes-flash.md deleted file mode 100644 index 0d3368e53d..0000000000 --- a/.changeset/curvy-planes-flash.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-bitbucket-server': patch ---- - -Allow skipping archived repositories (`skipArchivedRepos` flag) on Bitbucket. diff --git a/.changeset/cyan-eagles-hammer.md b/.changeset/cyan-eagles-hammer.md deleted file mode 100644 index dfe6f0bc62..0000000000 --- a/.changeset/cyan-eagles-hammer.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-notifications-backend-module-email': patch -'@backstage/plugin-notifications-backend': patch ---- - -Fixed email processor `esm` issue and config reading diff --git a/.changeset/cyan-suns-shave.md b/.changeset/cyan-suns-shave.md deleted file mode 100644 index 09e51d9548..0000000000 --- a/.changeset/cyan-suns-shave.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-unprocessed': patch ---- - -Correctly convert owner to string in case owner has not been provided diff --git a/.changeset/dirty-chairs-march.md b/.changeset/dirty-chairs-march.md deleted file mode 100644 index c4e22657a6..0000000000 --- a/.changeset/dirty-chairs-march.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend-module-gitlab': patch ---- - -Add merge method and squash option for project creation diff --git a/.changeset/dry-sloths-impress.md b/.changeset/dry-sloths-impress.md deleted file mode 100644 index 6bd5ba4156..0000000000 --- a/.changeset/dry-sloths-impress.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/catalog-model': minor ---- - -Introduce a domain attribute to the domain entity to allow a hierarchy of domains to exist. diff --git a/.changeset/early-starfishes-hammer.md b/.changeset/early-starfishes-hammer.md deleted file mode 100644 index abe17e85a2..0000000000 --- a/.changeset/early-starfishes-hammer.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend': minor ---- - -Deprecated the `LocationAnalyzer` type, which has been moved to `@backstage/plugin-catalog-node`. diff --git a/.changeset/eighty-apricots-kneel.md b/.changeset/eighty-apricots-kneel.md deleted file mode 100644 index a9cabaf378..0000000000 --- a/.changeset/eighty-apricots-kneel.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@techdocs/cli': patch ---- - -Fix cookie endpoint mock for `serve` diff --git a/.changeset/eighty-bats-stare.md b/.changeset/eighty-bats-stare.md deleted file mode 100644 index 6ebb2e9265..0000000000 --- a/.changeset/eighty-bats-stare.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-techdocs': patch ---- - -Update path in Readme for Plugin Techdocs to show the correct setup information. diff --git a/.changeset/eleven-pandas-divide.md b/.changeset/eleven-pandas-divide.md deleted file mode 100644 index 912d34570a..0000000000 --- a/.changeset/eleven-pandas-divide.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-gitlab': patch ---- - -Added events support for `GitlabDiscoveryEntityProvider` and `GitlabOrgDiscoveryEntityProvider`. diff --git a/.changeset/empty-beers-relax.md b/.changeset/empty-beers-relax.md deleted file mode 100644 index bbfcef0933..0000000000 --- a/.changeset/empty-beers-relax.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-common': patch ---- - -Added `HarnessURLReader` with `readUrl` support. diff --git a/.changeset/few-vans-cross.md b/.changeset/few-vans-cross.md deleted file mode 100644 index d7a12f6c10..0000000000 --- a/.changeset/few-vans-cross.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-common': patch ---- - -Plugins created through the `legacyPlugin` helper are now able to authenticate requests from plugins that are fully implemented using the new backend system. This fixes the `Key for the ES256 algorithm must be one of type KeyObject or CryptoKey. Received an instance of Uint8Array` error. diff --git a/.changeset/fix-stackoverflow.md b/.changeset/fix-stackoverflow.md deleted file mode 100644 index 6ce9f15737..0000000000 --- a/.changeset/fix-stackoverflow.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-incremental-ingestion': patch ---- - -Fix plugin/incremental-ingestion 'Maximum call stack size exceeded' error when ingest large entities. diff --git a/.changeset/flat-countries-clap.md b/.changeset/flat-countries-clap.md deleted file mode 100644 index 9c962b04a3..0000000000 --- a/.changeset/flat-countries-clap.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/repo-tools': minor ---- - -Adds 2 new commands `repo schema openapi diff` and `package schema openapi diff`. `repo schema openapi diff` is intended to power a new breaking changes check on pull requests and the package level command allows plugin developers to quickly see new API breaking changes. They're intended to be used in complement with the existing `repo schema openapi verify` command to validate your OpenAPI spec against a variety of things. diff --git a/.changeset/fluffy-hotels-wait.md b/.changeset/fluffy-hotels-wait.md deleted file mode 100644 index a578f2fb4a..0000000000 --- a/.changeset/fluffy-hotels-wait.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/cli': patch ---- - -Both the target and types library have been bumped from ES2021 to ES2022 in `@backstage/cli/config/tsconfig.json`. diff --git a/.changeset/four-adults-mix.md b/.changeset/four-adults-mix.md new file mode 100644 index 0000000000..5013166dc6 --- /dev/null +++ b/.changeset/four-adults-mix.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-notifications': patch +--- + +Do not always show scrollbars in notification description diff --git a/.changeset/four-cooks-serve.md b/.changeset/four-cooks-serve.md deleted file mode 100644 index 864807cc49..0000000000 --- a/.changeset/four-cooks-serve.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-notifications-backend': patch -'@backstage/plugin-notifications-node': patch ---- - -Support for filtering entities from notification recipients after resolving them from the recipients diff --git a/.changeset/fresh-crews-impress.md b/.changeset/fresh-crews-impress.md deleted file mode 100644 index 18f98f1dd9..0000000000 --- a/.changeset/fresh-crews-impress.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-app-api': patch ---- - -Move the JWKS registration outside of the lifecycle middleware diff --git a/.changeset/funny-bees-taste.md b/.changeset/funny-bees-taste.md deleted file mode 100644 index a9b2d84997..0000000000 --- a/.changeset/funny-bees-taste.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -The user can newly mark all unread messages as read at one click. diff --git a/.changeset/fuzzy-seahorses-tell.md b/.changeset/fuzzy-seahorses-tell.md deleted file mode 100644 index f184e9ce95..0000000000 --- a/.changeset/fuzzy-seahorses-tell.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/core-components': patch ---- - -Fixed an internal circular import that broke Jest mocks. diff --git a/.changeset/giant-donkeys-talk.md b/.changeset/giant-donkeys-talk.md deleted file mode 100644 index 62af2eb7e8..0000000000 --- a/.changeset/giant-donkeys-talk.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications-backend-module-email': patch ---- - -Support relative links in notifications sent via email diff --git a/.changeset/gold-waves-bake.md b/.changeset/gold-waves-bake.md deleted file mode 100644 index 2883b7b967..0000000000 --- a/.changeset/gold-waves-bake.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/cli': patch ---- - -Add support for `versions:migrate` to do code changes. Can be skipped with `--no-code-changes` diff --git a/.changeset/gorgeous-cameras-cross.md b/.changeset/gorgeous-cameras-cross.md deleted file mode 100644 index 50d7ddb2d7..0000000000 --- a/.changeset/gorgeous-cameras-cross.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-techdocs-addons-test-utils': patch ---- - -Fix bug in TechDocsAddonTester when jest.resetAllMocks is called between tests diff --git a/.changeset/green-adults-push.md b/.changeset/green-adults-push.md deleted file mode 100644 index 3edc21c385..0000000000 --- a/.changeset/green-adults-push.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/cli': patch ---- - -Add preserveModules to rollup, which allows better async loading and tree-shaking in webpack diff --git a/.changeset/green-boxes-rescue.md b/.changeset/green-boxes-rescue.md deleted file mode 100644 index 146695a320..0000000000 --- a/.changeset/green-boxes-rescue.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications-backend-module-email': patch ---- - -Allow sending notifications by email with the new notifications module diff --git a/.changeset/grumpy-toes-tap.md b/.changeset/grumpy-toes-tap.md deleted file mode 100644 index ff3fbbf2df..0000000000 --- a/.changeset/grumpy-toes-tap.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-devtools-backend': patch ---- - -Added discovery property to the readme documentation to ensure that it will build when setting it up as new to a Backstage instance diff --git a/.changeset/happy-radios-kiss.md b/.changeset/happy-radios-kiss.md deleted file mode 100644 index 1097c832d8..0000000000 --- a/.changeset/happy-radios-kiss.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend': minor ---- - -The `/alpha` plugin export has had its implementation of the `catalogAnalysisExtensionPoint` updated to reflect the new API. diff --git a/.changeset/healthy-dots-ring.md b/.changeset/healthy-dots-ring.md deleted file mode 100644 index 005e7e6616..0000000000 --- a/.changeset/healthy-dots-ring.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend': patch -'@backstage/plugin-scaffolder-node': patch ---- - -Scaffolder workspace serialization diff --git a/.changeset/healthy-shirts-roll.md b/.changeset/healthy-shirts-roll.md deleted file mode 100644 index aec74a1181..0000000000 --- a/.changeset/healthy-shirts-roll.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-signals-backend': patch ---- - -Improved signal lifecycle management and added server side pinging of connections diff --git a/.changeset/heavy-trainers-fly.md b/.changeset/heavy-trainers-fly.md deleted file mode 100644 index 48560b7ddd..0000000000 --- a/.changeset/heavy-trainers-fly.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-common': patch ---- - -Added config prop `ensureSchemaExists` to support postgres instances where user can create schemas but not databases. diff --git a/.changeset/hip-carrots-drive.md b/.changeset/hip-carrots-drive.md deleted file mode 100644 index 5852916b74..0000000000 --- a/.changeset/hip-carrots-drive.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-app-api': patch ---- - -The default `TokenManager` implementation no longer requires keys to be configured in production, but it will throw an errors when generating or authenticating tokens. The default `AuthService` implementation will now also provide additional context if such an error is throw when falling back to using the `TokenManager` service to generate tokens for outgoing requests. diff --git a/.changeset/hot-forks-train.md b/.changeset/hot-forks-train.md deleted file mode 100644 index a5300085b6..0000000000 --- a/.changeset/hot-forks-train.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -Allow showing notifications as snackbars in the UI diff --git a/.changeset/itchy-gorillas-hope.md b/.changeset/itchy-gorillas-hope.md deleted file mode 100644 index cd285161ff..0000000000 --- a/.changeset/itchy-gorillas-hope.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/create-app': patch ---- - -Removed the Tech Radar and GitHub Actions plugins from the template, which have been moved to the community plugins repository. diff --git a/.changeset/itchy-spoons-cry.md b/.changeset/itchy-spoons-cry.md new file mode 100644 index 0000000000..20877e8087 --- /dev/null +++ b/.changeset/itchy-spoons-cry.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-app-backend': patch +--- + +Restore the support of external config schema in the router of the `app-backend` plugin, which was broken in release `1.26.0`. +This support is critical for dynamic frontend plugins to have access to their config values. diff --git a/.changeset/kind-toes-scream.md b/.changeset/kind-toes-scream.md deleted file mode 100644 index d634f17ce4..0000000000 --- a/.changeset/kind-toes-scream.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/cli': patch ---- - -The `versions:bump` command will no longer exit with a non-zero status if the version bump fails due to forbidden duplicate package installations. It will now also provide more information about how to troubleshoot such an error. The set of forbidden duplicates has also been expanded to include all `@backstage/*-app-api` packages. diff --git a/.changeset/late-planes-fix.md b/.changeset/late-planes-fix.md deleted file mode 100644 index a57d7ec1d4..0000000000 --- a/.changeset/late-planes-fix.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-search-backend-node': patch -'@backstage/plugin-search-backend': patch ---- - -Add lifecycle monitoring for the search index registry diff --git a/.changeset/late-students-live.md b/.changeset/late-students-live.md new file mode 100644 index 0000000000..6a7c203e9e --- /dev/null +++ b/.changeset/late-students-live.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-techdocs': patch +--- + +Fixed bug in CopyToClipboardButton component where positioning of the "Copy to clipboard" button in techdocs code snippets was broken in some cases diff --git a/.changeset/lazy-phones-worry.md b/.changeset/lazy-phones-worry.md deleted file mode 100644 index 2c64f81f2c..0000000000 --- a/.changeset/lazy-phones-worry.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/frontend-app-api': minor ---- - -Extensions in app-config now always affect ordering. Previously, only when enabling disabled extensions did they rise to the top. diff --git a/.changeset/little-rockets-live.md b/.changeset/little-rockets-live.md deleted file mode 100644 index 767fda917e..0000000000 --- a/.changeset/little-rockets-live.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -'@backstage/plugin-auth-backend-module-aws-alb-provider': patch -'@backstage/plugin-auth-backend-module-github-provider': patch -'@backstage/plugin-auth-backend': patch ---- - -fix: Move config declarations to appropriate auth backend modules diff --git a/.changeset/loud-frogs-eat.md b/.changeset/loud-frogs-eat.md deleted file mode 100644 index dd1ab978f1..0000000000 --- a/.changeset/loud-frogs-eat.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend-module-gitlab': patch ---- - -Add examples for `gitlab:repo:push` scaffolder action & improve related tests diff --git a/.changeset/loud-pumpkins-bow.md b/.changeset/loud-pumpkins-bow.md new file mode 100644 index 0000000000..a55c97e19a --- /dev/null +++ b/.changeset/loud-pumpkins-bow.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-scaffolder-react': patch +--- + +Links that are rendered in the markdown in the `ScaffolderField` component are now opened in new tabs. diff --git a/.changeset/loud-timers-flow.md b/.changeset/loud-timers-flow.md deleted file mode 100644 index d7d0d96970..0000000000 --- a/.changeset/loud-timers-flow.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-app-api': patch ---- - -Remove explicit `alg` check for user tokens in `verifyToken` diff --git a/.changeset/loud-vans-greet.md b/.changeset/loud-vans-greet.md deleted file mode 100644 index 732413174b..0000000000 --- a/.changeset/loud-vans-greet.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-app-api': patch ---- - -Internal refactor to only create one external token handler diff --git a/.changeset/lovely-games-cry.md b/.changeset/lovely-games-cry.md deleted file mode 100644 index 5209b93496..0000000000 --- a/.changeset/lovely-games-cry.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-auth-react': patch ---- - -When using `CookieAuthRefreshProvider` or `useCookieAuthRefresh`, a 404 response from the cookie endpoint will now be treated as if cookie auth is disabled and is not needed. diff --git a/.changeset/lovely-hats-pay.md b/.changeset/lovely-hats-pay.md new file mode 100644 index 0000000000..117f50e5db --- /dev/null +++ b/.changeset/lovely-hats-pay.md @@ -0,0 +1,5 @@ +--- +'@backstage/theme': patch +--- + +Internal refactor to fix an issue where the MUI 5 `v5-` class prefixing gets removed by tree shaking. diff --git a/.changeset/lucky-news-guess.md b/.changeset/lucky-news-guess.md deleted file mode 100644 index 9c2cc4e8b0..0000000000 --- a/.changeset/lucky-news-guess.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend-module-bitbucket-server': patch ---- - -Add examples for `publish:bitbucketServer:pull-request` scaffolder action & improve related tests diff --git a/.changeset/mean-ravens-dance.md b/.changeset/mean-ravens-dance.md deleted file mode 100644 index 061e12cd9e..0000000000 --- a/.changeset/mean-ravens-dance.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -'@backstage/backend-common': minor ---- - -Internal refactor of the database code. - -**BREAKING**: The helper functions `createDatabaseClient` and `ensureDatabaseExists` have been removed from the public interface, since they have no usage within the repository and never were suitable for calling from the outside. Please consider using `coreServices.database` or `DatabaseManager` directly wherever possible instead. diff --git a/.changeset/metal-years-rhyme.md b/.changeset/metal-years-rhyme.md deleted file mode 100644 index 9c6daebdac..0000000000 --- a/.changeset/metal-years-rhyme.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-techdocs-backend': patch -'@backstage/plugin-techdocs': patch ---- - -The `techdocs.builder` config is now optional and it will default to `local`. diff --git a/.changeset/new-poets-promise.md b/.changeset/new-poets-promise.md deleted file mode 100644 index 206bf3e0d8..0000000000 --- a/.changeset/new-poets-promise.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend-module-notifications': patch ---- - -Add a new scaffolder action to allow sending notifications from templates diff --git a/.changeset/itchy-keys-wonder.md b/.changeset/nine-ties-type.md similarity index 59% rename from .changeset/itchy-keys-wonder.md rename to .changeset/nine-ties-type.md index 879dc096a4..abb0661724 100644 --- a/.changeset/itchy-keys-wonder.md +++ b/.changeset/nine-ties-type.md @@ -3,4 +3,4 @@ '@backstage/backend-app-api': patch --- -Redact `meta` fields too with the logger +Fixing issue with log meta fields possibly being circular refs diff --git a/.changeset/orange-numbers-think.md b/.changeset/orange-numbers-think.md deleted file mode 100644 index 21dc7ce76b..0000000000 --- a/.changeset/orange-numbers-think.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-search-backend-module-catalog': patch ---- - -Fix wiring of the module exported at the `/alpha` path, which was causing authentication failures. diff --git a/.changeset/perfect-beers-explode.md b/.changeset/perfect-beers-explode.md deleted file mode 100644 index 3045ca7f12..0000000000 --- a/.changeset/perfect-beers-explode.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -Increase default and allow modifying notification snackbar auto hide duration diff --git a/.changeset/perfect-points-hope.md b/.changeset/perfect-points-hope.md deleted file mode 100644 index cfc42f77a3..0000000000 --- a/.changeset/perfect-points-hope.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-auth-backend-module-oidc-provider': patch ---- - -Add nonce to authorize request to be added in ID token diff --git a/.changeset/pink-years-peel.md b/.changeset/pink-years-peel.md deleted file mode 100644 index 339889f27e..0000000000 --- a/.changeset/pink-years-peel.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-github': patch ---- - -GitHub push events now schedule a refresh on entities that have a `refresh_key` matching the `catalogPath` config itself. -This allows to support a `catalogPath` configuration that uses glob patterns. diff --git a/.changeset/pre.json b/.changeset/pre.json deleted file mode 100644 index 4a813e4e19..0000000000 --- a/.changeset/pre.json +++ /dev/null @@ -1,395 +0,0 @@ -{ - "mode": "pre", - "tag": "next", - "initialVersions": { - "example-app": "0.2.96", - "@backstage/app-defaults": "1.5.4", - "example-app-next": "0.0.10", - "app-next-example-plugin": "0.0.10", - "example-backend": "0.2.97", - "@backstage/backend-app-api": "0.7.0", - "@backstage/backend-common": "0.21.7", - "@backstage/backend-defaults": "0.2.17", - "@backstage/backend-dev-utils": "0.1.4", - "@backstage/backend-dynamic-feature-service": "0.2.9", - "example-backend-next": "0.0.25", - "@backstage/backend-openapi-utils": "0.1.10", - "@backstage/backend-plugin-api": "0.6.17", - "@backstage/backend-tasks": "0.5.22", - "@backstage/backend-test-utils": "0.3.7", - "@backstage/catalog-client": "1.6.4", - "@backstage/catalog-model": "1.4.5", - "@backstage/cli": "0.26.3", - "@backstage/cli-common": "0.1.13", - "@backstage/cli-node": "0.2.5", - "@backstage/codemods": "0.1.48", - "@backstage/config": "1.2.0", - "@backstage/config-loader": "1.8.0", - "@backstage/core-app-api": "1.12.4", - "@backstage/core-compat-api": "0.2.4", - "@backstage/core-components": "0.14.4", - "@backstage/core-plugin-api": "1.9.2", - "@backstage/create-app": "0.5.14", - "@backstage/dev-utils": "1.0.31", - "e2e-test": "0.2.15", - "@backstage/e2e-test-utils": "0.1.1", - "@backstage/errors": "1.2.4", - "@backstage/eslint-plugin": "0.1.7", - "@backstage/frontend-app-api": "0.6.4", - "@backstage/frontend-plugin-api": "0.6.4", - "@backstage/frontend-test-utils": "0.1.6", - "@backstage/integration": "1.10.0", - "@backstage/integration-aws-node": "0.1.12", - "@backstage/integration-react": "1.1.26", - "@backstage/release-manifests": "0.0.11", - "@backstage/repo-tools": "0.8.0", - "@techdocs/cli": "1.8.9", - "techdocs-cli-embedded-app": "0.2.95", - "@backstage/test-utils": "1.5.4", - "@backstage/theme": "0.5.3", - "@backstage/types": "1.1.1", - "@backstage/version-bridge": "1.0.8", - "@backstage/plugin-adr": "0.6.17", - "@backstage/plugin-adr-backend": "0.4.14", - "@backstage/plugin-adr-common": "0.2.22", - "@backstage/plugin-airbrake": "0.3.34", - "@backstage/plugin-airbrake-backend": "0.3.14", - "@backstage/plugin-allure": "0.1.50", - "@backstage/plugin-analytics-module-ga": "0.2.4", - "@backstage/plugin-analytics-module-ga4": "0.2.4", - "@backstage/plugin-analytics-module-newrelic-browser": "0.1.4", - "@backstage/plugin-apache-airflow": "0.2.24", - "@backstage/plugin-api-docs": "0.11.4", - "@backstage/plugin-api-docs-module-protoc-gen-doc": "0.1.6", - "@backstage/plugin-apollo-explorer": "0.2.0", - "@backstage/plugin-app-backend": "0.3.65", - "@backstage/plugin-app-node": "0.1.17", - "@backstage/plugin-app-visualizer": "0.1.5", - "@backstage/plugin-auth-backend": "0.22.4", - "@backstage/plugin-auth-backend-module-atlassian-provider": "0.1.9", - "@backstage/plugin-auth-backend-module-aws-alb-provider": "0.1.9", - "@backstage/plugin-auth-backend-module-azure-easyauth-provider": "0.1.0", - "@backstage/plugin-auth-backend-module-bitbucket-provider": "0.1.0", - "@backstage/plugin-auth-backend-module-cloudflare-access-provider": "0.1.0", - "@backstage/plugin-auth-backend-module-gcp-iap-provider": "0.2.12", - "@backstage/plugin-auth-backend-module-github-provider": "0.1.14", - "@backstage/plugin-auth-backend-module-gitlab-provider": "0.1.14", - "@backstage/plugin-auth-backend-module-google-provider": "0.1.14", - "@backstage/plugin-auth-backend-module-guest-provider": "0.1.3", - "@backstage/plugin-auth-backend-module-microsoft-provider": "0.1.12", - "@backstage/plugin-auth-backend-module-oauth2-provider": "0.1.14", - "@backstage/plugin-auth-backend-module-oauth2-proxy-provider": "0.1.10", - "@backstage/plugin-auth-backend-module-oidc-provider": "0.1.8", - "@backstage/plugin-auth-backend-module-okta-provider": "0.0.10", - "@backstage/plugin-auth-backend-module-pinniped-provider": "0.1.11", - "@backstage/plugin-auth-backend-module-vmware-cloud-provider": "0.1.9", - "@backstage/plugin-auth-node": "0.4.12", - "@backstage/plugin-auth-react": "0.1.0", - "@backstage/plugin-azure-devops": "0.4.3", - "@backstage/plugin-azure-devops-backend": "0.6.4", - "@backstage/plugin-azure-devops-common": "0.4.1", - "@backstage/plugin-azure-sites": "0.1.23", - "@backstage/plugin-azure-sites-backend": "0.3.4", - "@backstage/plugin-azure-sites-common": "0.1.3", - "@backstage/plugin-badges": "0.2.58", - "@backstage/plugin-badges-backend": "0.4.0", - "@backstage/plugin-bazaar": "0.2.26", - "@backstage/plugin-bazaar-backend": "0.3.15", - "@backstage/plugin-bitbucket-cloud-common": "0.2.18", - "@backstage/plugin-bitrise": "0.1.61", - "@backstage/plugin-catalog": "1.19.0", - "@backstage/plugin-catalog-backend": "1.21.1", - "@backstage/plugin-catalog-backend-module-aws": "0.3.12", - "@backstage/plugin-catalog-backend-module-azure": "0.1.37", - "@backstage/plugin-catalog-backend-module-backstage-openapi": "0.2.0", - "@backstage/plugin-catalog-backend-module-bitbucket-cloud": "0.2.4", - "@backstage/plugin-catalog-backend-module-bitbucket-server": "0.1.31", - "@backstage/plugin-catalog-backend-module-gcp": "0.1.18", - "@backstage/plugin-catalog-backend-module-gerrit": "0.1.34", - "@backstage/plugin-catalog-backend-module-github": "0.6.0", - "@backstage/plugin-catalog-backend-module-github-org": "0.1.12", - "@backstage/plugin-catalog-backend-module-gitlab": "0.3.15", - "@backstage/plugin-catalog-backend-module-incremental-ingestion": "0.4.22", - "@backstage/plugin-catalog-backend-module-ldap": "0.5.33", - "@backstage/plugin-catalog-backend-module-msgraph": "0.5.25", - "@backstage/plugin-catalog-backend-module-openapi": "0.1.35", - "@backstage/plugin-catalog-backend-module-puppetdb": "0.1.23", - "@backstage/plugin-catalog-backend-module-scaffolder-entity-model": "0.1.15", - "@backstage/plugin-catalog-backend-module-unprocessed": "0.4.4", - "@backstage/plugin-catalog-common": "1.0.22", - "@backstage/plugin-catalog-graph": "0.4.4", - "@backstage/plugin-catalog-import": "0.10.10", - "@backstage/plugin-catalog-node": "1.11.1", - "@backstage/plugin-catalog-react": "1.11.3", - "@backstage/plugin-catalog-unprocessed-entities": "0.2.3", - "@backstage/plugin-catalog-unprocessed-entities-common": "0.0.1", - "@backstage/plugin-cicd-statistics": "0.1.36", - "@backstage/plugin-cicd-statistics-module-gitlab": "0.1.30", - "@backstage/plugin-circleci": "0.3.34", - "@backstage/plugin-cloudbuild": "0.5.1", - "@backstage/plugin-code-climate": "0.1.34", - "@backstage/plugin-code-coverage": "0.2.27", - "@backstage/plugin-code-coverage-backend": "0.2.31", - "@backstage/plugin-codescene": "0.1.26", - "@backstage/plugin-config-schema": "0.1.54", - "@backstage/plugin-cost-insights": "0.12.23", - "@backstage/plugin-cost-insights-common": "0.1.2", - "@backstage/plugin-devtools": "0.1.13", - "@backstage/plugin-devtools-backend": "0.3.3", - "@backstage/plugin-devtools-common": "0.1.9", - "@backstage/plugin-dynatrace": "10.0.3", - "@backstage/plugin-entity-feedback": "0.2.17", - "@backstage/plugin-entity-feedback-backend": "0.2.14", - "@backstage/plugin-entity-feedback-common": "0.1.3", - "@backstage/plugin-entity-validation": "0.1.19", - "@backstage/plugin-events-backend": "0.3.4", - "@backstage/plugin-events-backend-module-aws-sqs": "0.3.3", - "@backstage/plugin-events-backend-module-azure": "0.2.3", - "@backstage/plugin-events-backend-module-bitbucket-cloud": "0.2.3", - "@backstage/plugin-events-backend-module-gerrit": "0.2.3", - "@backstage/plugin-events-backend-module-github": "0.2.3", - "@backstage/plugin-events-backend-module-gitlab": "0.2.3", - "@backstage/plugin-events-backend-test-utils": "0.1.27", - "@backstage/plugin-events-node": "0.3.3", - "@internal/plugin-todo-list": "1.0.26", - "@internal/plugin-todo-list-backend": "1.0.26", - "@internal/plugin-todo-list-common": "1.0.18", - "@backstage/plugin-explore": "0.4.20", - "@backstage/plugin-explore-backend": "0.0.27", - "@backstage/plugin-explore-common": "0.0.2", - "@backstage/plugin-explore-react": "0.0.38", - "@backstage/plugin-firehydrant": "0.2.18", - "@backstage/plugin-fossa": "0.2.66", - "@backstage/plugin-gcalendar": "0.3.27", - "@backstage/plugin-gcp-projects": "0.3.50", - "@backstage/plugin-git-release-manager": "0.3.46", - "@backstage/plugin-github-actions": "0.6.15", - "@backstage/plugin-github-deployments": "0.1.65", - "@backstage/plugin-github-issues": "0.4.1", - "@backstage/plugin-github-pull-requests-board": "0.2.0", - "@backstage/plugin-gitops-profiles": "0.3.49", - "@backstage/plugin-gocd": "0.1.40", - "@backstage/plugin-graphiql": "0.3.7", - "@backstage/plugin-graphql-voyager": "0.1.16", - "@backstage/plugin-home": "0.7.3", - "@backstage/plugin-home-react": "0.1.12", - "@backstage/plugin-ilert": "0.2.23", - "@backstage/plugin-jenkins": "0.9.9", - "@backstage/plugin-jenkins-backend": "0.4.4", - "@backstage/plugin-jenkins-common": "0.1.25", - "@backstage/plugin-kafka": "0.3.34", - "@backstage/plugin-kafka-backend": "0.3.15", - "@backstage/plugin-kubernetes": "0.11.9", - "@backstage/plugin-kubernetes-backend": "0.17.0", - "@backstage/plugin-kubernetes-cluster": "0.0.10", - "@backstage/plugin-kubernetes-common": "0.7.5", - "@backstage/plugin-kubernetes-node": "0.1.11", - "@backstage/plugin-kubernetes-react": "0.3.4", - "@backstage/plugin-lighthouse": "0.4.19", - "@backstage/plugin-lighthouse-backend": "0.4.10", - "@backstage/plugin-lighthouse-common": "0.1.5", - "@backstage/plugin-linguist": "0.1.19", - "@backstage/plugin-linguist-backend": "0.5.15", - "@backstage/plugin-linguist-common": "0.1.2", - "@backstage/plugin-microsoft-calendar": "0.1.16", - "@backstage/plugin-newrelic": "0.3.49", - "@backstage/plugin-newrelic-dashboard": "0.3.9", - "@backstage/plugin-nomad": "0.1.15", - "@backstage/plugin-nomad-backend": "0.1.19", - "@backstage/plugin-notifications": "0.2.0", - "@backstage/plugin-notifications-backend": "0.2.0", - "@backstage/plugin-notifications-common": "0.0.3", - "@backstage/plugin-notifications-node": "0.1.3", - "@backstage/plugin-octopus-deploy": "0.2.16", - "@backstage/plugin-opencost": "0.2.9", - "@backstage/plugin-org": "0.6.24", - "@backstage/plugin-org-react": "0.1.23", - "@backstage/plugin-pagerduty": "0.7.6", - "@backstage/plugin-periskop": "0.1.32", - "@backstage/plugin-periskop-backend": "0.2.15", - "@backstage/plugin-permission-backend": "0.5.41", - "@backstage/plugin-permission-backend-module-allow-all-policy": "0.1.14", - "@backstage/plugin-permission-common": "0.7.13", - "@backstage/plugin-permission-node": "0.7.28", - "@backstage/plugin-permission-react": "0.4.22", - "@backstage/plugin-playlist": "0.2.8", - "@backstage/plugin-playlist-backend": "0.3.21", - "@backstage/plugin-playlist-common": "0.1.15", - "@backstage/plugin-proxy-backend": "0.4.15", - "@backstage/plugin-puppetdb": "0.1.17", - "@backstage/plugin-rollbar": "0.4.34", - "@backstage/plugin-rollbar-backend": "0.1.62", - "@backstage/plugin-scaffolder": "1.19.3", - "@backstage/plugin-scaffolder-backend": "1.22.4", - "@backstage/plugin-scaffolder-backend-module-azure": "0.1.9", - "@backstage/plugin-scaffolder-backend-module-bitbucket": "0.2.7", - "@backstage/plugin-scaffolder-backend-module-bitbucket-cloud": "0.1.7", - "@backstage/plugin-scaffolder-backend-module-bitbucket-server": "0.1.7", - "@backstage/plugin-scaffolder-backend-module-confluence-to-markdown": "0.2.18", - "@backstage/plugin-scaffolder-backend-module-cookiecutter": "0.2.41", - "@backstage/plugin-scaffolder-backend-module-gerrit": "0.1.9", - "@backstage/plugin-scaffolder-backend-module-gitea": "0.1.7", - "@backstage/plugin-scaffolder-backend-module-github": "0.2.7", - "@backstage/plugin-scaffolder-backend-module-gitlab": "0.3.3", - "@backstage/plugin-scaffolder-backend-module-rails": "0.4.34", - "@backstage/plugin-scaffolder-backend-module-sentry": "0.1.25", - "@backstage/plugin-scaffolder-backend-module-yeoman": "0.3.0", - "@backstage/plugin-scaffolder-common": "1.5.1", - "@backstage/plugin-scaffolder-node": "0.4.3", - "@backstage/plugin-scaffolder-node-test-utils": "0.1.3", - "@backstage/plugin-scaffolder-react": "1.8.4", - "@backstage/plugin-search": "1.4.10", - "@backstage/plugin-search-backend": "1.5.7", - "@backstage/plugin-search-backend-module-catalog": "0.1.22", - "@backstage/plugin-search-backend-module-elasticsearch": "1.4.0", - "@backstage/plugin-search-backend-module-explore": "0.1.21", - "@backstage/plugin-search-backend-module-pg": "0.5.26", - "@backstage/plugin-search-backend-module-stack-overflow-collator": "0.1.10", - "@backstage/plugin-search-backend-module-techdocs": "0.1.22", - "@backstage/plugin-search-backend-node": "1.2.21", - "@backstage/plugin-search-common": "1.2.11", - "@backstage/plugin-search-react": "1.7.10", - "@backstage/plugin-sentry": "0.5.19", - "@backstage/plugin-shortcuts": "0.3.23", - "@backstage/plugin-signals": "0.0.5", - "@backstage/plugin-signals-backend": "0.1.3", - "@backstage/plugin-signals-node": "0.1.3", - "@backstage/plugin-signals-react": "0.0.3", - "@backstage/plugin-sonarqube": "0.7.16", - "@backstage/plugin-sonarqube-backend": "0.2.19", - "@backstage/plugin-sonarqube-react": "0.1.15", - "@backstage/plugin-splunk-on-call": "0.4.23", - "@backstage/plugin-stack-overflow": "0.1.29", - "@backstage/plugin-stack-overflow-backend": "0.2.21", - "@backstage/plugin-stackstorm": "0.1.15", - "@backstage/plugin-tech-insights": "0.3.26", - "@backstage/plugin-tech-insights-backend": "0.5.31", - "@backstage/plugin-tech-insights-backend-module-jsonfc": "0.1.49", - "@backstage/plugin-tech-insights-common": "0.2.12", - "@backstage/plugin-tech-insights-node": "0.6.0", - "@backstage/plugin-tech-radar": "0.7.3", - "@backstage/plugin-techdocs": "1.10.4", - "@backstage/plugin-techdocs-addons-test-utils": "1.0.31", - "@backstage/plugin-techdocs-backend": "1.10.4", - "@backstage/plugin-techdocs-module-addons-contrib": "1.1.9", - "@backstage/plugin-techdocs-node": "1.12.3", - "@backstage/plugin-techdocs-react": "1.2.3", - "@backstage/plugin-todo": "0.2.38", - "@backstage/plugin-todo-backend": "0.3.16", - "@backstage/plugin-user-settings": "0.8.5", - "@backstage/plugin-user-settings-backend": "0.2.16", - "@backstage/plugin-vault": "0.1.29", - "@backstage/plugin-vault-backend": "0.4.10", - "@backstage/plugin-vault-node": "0.1.10", - "@backstage/plugin-xcmetrics": "0.2.52", - "@backstage/plugin-catalog-backend-module-gitlab-org": "0.0.0", - "@backstage/plugin-notifications-backend-module-email": "0.0.0", - "example-backend-legacy": "0.2.98-next.1", - "@backstage/plugin-scaffolder-backend-module-notifications": "0.0.0" - }, - "changesets": [ - "afraid-needles-divide", - "blue-hotels-shake", - "brave-carrots-glow", - "bright-pumpkins-rule", - "chatty-cycles-unite", - "chilly-adults-sing", - "chilly-fireants-roll", - "chilly-shoes-doubt", - "cold-cougars-float", - "cold-rats-leave", - "cool-elephants-march", - "create-app-1714476054", - "create-app-1715088359", - "cuddly-chairs-kick", - "curly-shirts-flow", - "curvy-planes-flash", - "cyan-eagles-hammer", - "cyan-suns-shave", - "dirty-chairs-march", - "dry-sloths-impress", - "early-starfishes-hammer", - "eighty-apricots-kneel", - "eighty-bats-stare", - "eleven-pandas-divide", - "empty-beers-relax", - "fix-stackoverflow", - "flat-countries-clap", - "fluffy-hotels-wait", - "four-cooks-serve", - "fresh-crews-impress", - "funny-bees-taste", - "fuzzy-seahorses-tell", - "giant-donkeys-talk", - "gold-waves-bake", - "gorgeous-cameras-cross", - "green-adults-push", - "green-boxes-rescue", - "grumpy-toes-tap", - "happy-radios-kiss", - "healthy-dots-ring", - "healthy-shirts-roll", - "heavy-trainers-fly", - "hip-carrots-drive", - "hot-forks-train", - "itchy-gorillas-hope", - "itchy-keys-wonder", - "kind-toes-scream", - "late-planes-fix", - "lazy-phones-worry", - "little-rockets-live", - "loud-frogs-eat", - "loud-timers-flow", - "loud-vans-greet", - "lovely-games-cry", - "lucky-news-guess", - "mean-ravens-dance", - "metal-years-rhyme", - "new-poets-promise", - "orange-numbers-think", - "perfect-beers-explode", - "perfect-points-hope", - "pink-years-peel", - "proud-comics-love", - "proud-doors-cheat", - "purple-parents-sin", - "purple-waves-smile", - "quick-cats-argue", - "quiet-boxes-build", - "rare-fireants-tickle", - "real-crabs-obey", - "renovate-0d0bd5c", - "rich-adults-float", - "selfish-pigs-glow", - "selfish-walls-visit", - "sharp-glasses-live", - "shy-students-clap", - "silent-wombats-hang", - "six-scissors-smile", - "sixty-bears-camp", - "slimy-kids-behave", - "smart-avocados-invent", - "smooth-garlics-behave", - "sour-socks-approve", - "stupid-onions-know", - "sweet-zoos-clap", - "swift-humans-hunt", - "tall-ads-shave", - "tame-jars-double", - "tasty-apes-learn", - "tasty-moles-jog", - "tasty-rats-explain", - "thick-llamas-itch", - "thick-terms-rush", - "thirty-mangos-travel", - "tough-eggs-wink", - "tricky-cougars-shout", - "unlucky-days-play", - "unlucky-rivers-collect", - "warm-fans-promise", - "wet-files-pretend", - "wild-seahorses-grin", - "young-guests-reflect", - "young-olives-drop" - ] -} diff --git a/.changeset/proud-comics-love.md b/.changeset/proud-comics-love.md deleted file mode 100644 index 6891bf937b..0000000000 --- a/.changeset/proud-comics-love.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-catalog-react': minor -'@backstage/plugin-catalog': minor ---- - -Updated the presentation API to return a promise, in addition to the snapshot and observable that were there before. This makes it much easier to consume the API in a non-React context. diff --git a/.changeset/proud-doors-cheat.md b/.changeset/proud-doors-cheat.md deleted file mode 100644 index 55ab7878d4..0000000000 --- a/.changeset/proud-doors-cheat.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/theme': patch ---- - -Fixed bug where scrollbars don't pick up the theme when in dark mode diff --git a/.changeset/purple-parents-sin.md b/.changeset/purple-parents-sin.md deleted file mode 100644 index 4de90893ef..0000000000 --- a/.changeset/purple-parents-sin.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-backstage-openapi': patch ---- - -Fix incorrect dependency import. diff --git a/.changeset/purple-waves-smile.md b/.changeset/purple-waves-smile.md deleted file mode 100644 index 44da72ea70..0000000000 --- a/.changeset/purple-waves-smile.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-auth-backend-module-guest-provider': patch ---- - -Error if used outside of a development environment without explicit allowance diff --git a/.changeset/quick-cats-argue.md b/.changeset/quick-cats-argue.md deleted file mode 100644 index 956f038f34..0000000000 --- a/.changeset/quick-cats-argue.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -'@backstage/backend-test-utils': patch -'@backstage/backend-defaults': patch -'@backstage/plugin-events-node': patch ---- - -added `eventsServiceFactory` to `defaultServiceFactories` to resolve issue where different instances of the EventsServices could be used diff --git a/.changeset/quiet-boxes-build.md b/.changeset/quiet-boxes-build.md deleted file mode 100644 index c6f802d5b0..0000000000 --- a/.changeset/quiet-boxes-build.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-api-docs': patch ---- - -Fix dark mode text color inside tables in `description:` from OpenAPI definitions diff --git a/.changeset/rare-fireants-tickle.md b/.changeset/rare-fireants-tickle.md deleted file mode 100644 index 8668d4c287..0000000000 --- a/.changeset/rare-fireants-tickle.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/core-components': patch ---- - -Added optional `initialShowDropDown` prop to `SidebarSubmenuItem` to internally manage the initial display state of the dropdown items. diff --git a/.changeset/real-crabs-obey.md b/.changeset/real-crabs-obey.md deleted file mode 100644 index 9a52f0e5a6..0000000000 --- a/.changeset/real-crabs-obey.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-search-backend-module-explore': patch ---- - -Migrate search collator to use the new auth services. diff --git a/.changeset/renovate-0d0bd5c.md b/.changeset/renovate-0d0bd5c.md deleted file mode 100644 index ac3fe697f9..0000000000 --- a/.changeset/renovate-0d0bd5c.md +++ /dev/null @@ -1,11 +0,0 @@ ---- -'@backstage/plugin-home-react': patch -'@backstage/plugin-home': patch -'@backstage/plugin-scaffolder-react': patch -'@backstage/plugin-scaffolder': patch ---- - -Updated dependency `@rjsf/utils` to `5.18.2`. -Updated dependency `@rjsf/core` to `5.18.2`. -Updated dependency `@rjsf/material-ui` to `5.18.2`. -Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. diff --git a/.changeset/rich-adults-float.md b/.changeset/rich-adults-float.md deleted file mode 100644 index 5a9746b8f5..0000000000 --- a/.changeset/rich-adults-float.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-github': patch ---- - -Updated to use the new `catalogAnalysisExtensionPoint` API. diff --git a/.changeset/selfish-pigs-glow.md b/.changeset/selfish-pigs-glow.md deleted file mode 100644 index c7808c0283..0000000000 --- a/.changeset/selfish-pigs-glow.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-auth-backend': patch -'@backstage/plugin-auth-node': patch ---- - -Allow overriding default ownership resolving with the new `AuthOwnershipResolutionExtensionPoint` diff --git a/.changeset/selfish-walls-visit.md b/.changeset/selfish-walls-visit.md deleted file mode 100644 index 64c87a64f5..0000000000 --- a/.changeset/selfish-walls-visit.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/core-components': patch ---- - -Add `alignGauge` prop to the `GaugeCard`, and a small size version. When `alignGauge` is `'bottom'` the gauge will vertically align the gauge in the cards, even when the card titles span across multiple lines. -Add `alignContent` prop to the `InfoCard`, defaulting to `'normal'` with the option of `'bottom'` which vertically aligns the content to the bottom of the card. diff --git a/.changeset/seven-geese-raise.md b/.changeset/seven-geese-raise.md new file mode 100644 index 0000000000..3d6e2347b9 --- /dev/null +++ b/.changeset/seven-geese-raise.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-search-backend-node': patch +'@backstage/plugin-search-backend': patch +--- + +Split backend search plugin startup into "init" and "start" stages to ensure necessary initialization has happened before startup diff --git a/.changeset/sharp-glasses-live.md b/.changeset/sharp-glasses-live.md deleted file mode 100644 index 000f49fc47..0000000000 --- a/.changeset/sharp-glasses-live.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/cli': patch ---- - -Allow passing a `--require` argument through to the Node process during `package start` diff --git a/.changeset/shy-students-clap.md b/.changeset/shy-students-clap.md deleted file mode 100644 index 0e6244f21d..0000000000 --- a/.changeset/shy-students-clap.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-gitlab-org': patch ---- - -Added a new `catalog-backend-module-gitlab-org` module which adds the `GitlabOrgDiscoveryEntityProvider` to the catalog's providers using the new backend system. diff --git a/.changeset/silent-wombats-hang.md b/.changeset/silent-wombats-hang.md deleted file mode 100644 index 85bda32007..0000000000 --- a/.changeset/silent-wombats-hang.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend-module-msgraph': patch ---- - -Handle fetching huge amounts of users from Azure without crashing diff --git a/.changeset/six-scissors-smile.md b/.changeset/six-scissors-smile.md deleted file mode 100644 index 7680edbba6..0000000000 --- a/.changeset/six-scissors-smile.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/core-components': patch ---- - -The `SignInPage` guest provider will now fall back to legacy guest auth if the backend request fails, allowing guest auth without a running backend. diff --git a/.changeset/sixty-bears-camp.md b/.changeset/sixty-bears-camp.md deleted file mode 100644 index f7a11482a7..0000000000 --- a/.changeset/sixty-bears-camp.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-scaffolder': patch ---- - -Fixed a bug where the `MultiEntityPicker` was not able to be set as required diff --git a/.changeset/slimy-fans-raise.md b/.changeset/slimy-fans-raise.md new file mode 100644 index 0000000000..782ef4bc82 --- /dev/null +++ b/.changeset/slimy-fans-raise.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-techdocs': patch +--- + +Fix weird opening behaviour of the component. diff --git a/.changeset/slimy-kids-behave.md b/.changeset/slimy-kids-behave.md deleted file mode 100644 index 5e635878ff..0000000000 --- a/.changeset/slimy-kids-behave.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/cli': patch ---- - -Fixed an issue causing the `repo fix` command to set an incorrect `workspace` property using Windows diff --git a/.changeset/smart-avocados-invent.md b/.changeset/smart-avocados-invent.md deleted file mode 100644 index c71b6fef37..0000000000 --- a/.changeset/smart-avocados-invent.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-dynamic-feature-service': patch ---- - -Updates the `scanRoot` method in the `PluginScanner` class to specifically ignore the `lost+found` directory, which is a system-generated directory used for file recovery on Unix-like systems. Skipping this directory avoids unnecessary errors. diff --git a/.changeset/smooth-garlics-behave.md b/.changeset/smooth-garlics-behave.md deleted file mode 100644 index ed972ae164..0000000000 --- a/.changeset/smooth-garlics-behave.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-common': patch ---- - -Added option to `ServerTokenManager.fromConfig` that allows it to be instantiated in production without any configured keys. diff --git a/.changeset/sour-socks-approve.md b/.changeset/sour-socks-approve.md deleted file mode 100644 index db40806280..0000000000 --- a/.changeset/sour-socks-approve.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend': minor ---- - -Emit well known relationships for the Domain entity kind. diff --git a/.changeset/stupid-onions-know.md b/.changeset/stupid-onions-know.md deleted file mode 100644 index 3d028557be..0000000000 --- a/.changeset/stupid-onions-know.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -Empty descriptions are not rendered to improve the look&feel. diff --git a/.changeset/sweet-zoos-clap.md b/.changeset/sweet-zoos-clap.md deleted file mode 100644 index 8c76f4abd7..0000000000 --- a/.changeset/sweet-zoos-clap.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-backend': patch ---- - -Fixed bug in stitching queue gauge that included entities that are scheduled in the future. diff --git a/.changeset/swift-humans-hunt.md b/.changeset/swift-humans-hunt.md deleted file mode 100644 index b96b3e41bc..0000000000 --- a/.changeset/swift-humans-hunt.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog': patch ---- - -Avoiding pre-loading display total count undefined for table counts diff --git a/.changeset/tall-ads-shave.md b/.changeset/tall-ads-shave.md deleted file mode 100644 index 17d58452eb..0000000000 --- a/.changeset/tall-ads-shave.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications-backend': patch ---- - -Add possibility to generate random notifications on the fly in local development diff --git a/.changeset/tame-jars-double.md b/.changeset/tame-jars-double.md deleted file mode 100644 index 8af92a2d72..0000000000 --- a/.changeset/tame-jars-double.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-scaffolder-backend-module-gitlab': minor ---- - -Add examples for `gitlab:projectVariable:create` scaffolder action & improve related tests diff --git a/.changeset/tasty-apes-learn.md b/.changeset/tasty-apes-learn.md deleted file mode 100644 index 7a4545cf10..0000000000 --- a/.changeset/tasty-apes-learn.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -Fix to show web notifications even when browser is on foreground. Fix duplicate notifications with multiple tabs. diff --git a/.changeset/tasty-moles-jog.md b/.changeset/tasty-moles-jog.md deleted file mode 100644 index f28b77337e..0000000000 --- a/.changeset/tasty-moles-jog.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/cli': patch ---- - -Add previously-missing semicolon in file templated by `backstage-cli new --select plugin`. diff --git a/.changeset/tasty-rats-explain.md b/.changeset/tasty-rats-explain.md deleted file mode 100644 index b97ee28fef..0000000000 --- a/.changeset/tasty-rats-explain.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/integration': minor ---- - -Added `HarnessIntegration` via the `ScmIntegrations` interface. diff --git a/.changeset/thick-llamas-itch.md b/.changeset/thick-llamas-itch.md deleted file mode 100644 index 17d4fb23b6..0000000000 --- a/.changeset/thick-llamas-itch.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -Allow defining `className` and additional properties for `NotificationsSideBarItem` diff --git a/.changeset/thick-terms-rush.md b/.changeset/thick-terms-rush.md deleted file mode 100644 index fb12f11f7e..0000000000 --- a/.changeset/thick-terms-rush.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-kubernetes-react': patch ---- - -add the namespace label to CronJobDrawer & IngressDrawer. diff --git a/.changeset/thirty-mangos-travel.md b/.changeset/thirty-mangos-travel.md deleted file mode 100644 index 2281cc06b6..0000000000 --- a/.changeset/thirty-mangos-travel.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-search': patch ---- - -Added `aria-label` attribute to DialogTitle element and set `aria-modal` attribute to `true` for improved accessibility in the search modal. diff --git a/.changeset/tough-eggs-wink.md b/.changeset/tough-eggs-wink.md deleted file mode 100644 index 52644e3620..0000000000 --- a/.changeset/tough-eggs-wink.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-catalog-node': minor ---- - -Breaking change to `/alpha` API where the `catalogAnalysisExtensionPoint` has been reworked. The `addLocationAnalyzer` method has been renamed to `addScmLocationAnalyzer`, and a new `setLocationAnalyzer` method has been added which allows the full `LocationAnalyzer` implementation to be overridden. diff --git a/.changeset/tricky-cougars-shout.md b/.changeset/tricky-cougars-shout.md deleted file mode 100644 index eed14c9eb8..0000000000 --- a/.changeset/tricky-cougars-shout.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-search-backend-module-explore': patch ---- - -Update README.md to point to explore plugin in community-plugins repository. diff --git a/.changeset/unlucky-days-play.md b/.changeset/unlucky-days-play.md deleted file mode 100644 index b847ebd2fc..0000000000 --- a/.changeset/unlucky-days-play.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -Fix infinite loop in the notification title counter diff --git a/.changeset/unlucky-rivers-collect.md b/.changeset/unlucky-rivers-collect.md deleted file mode 100644 index c5ec865658..0000000000 --- a/.changeset/unlucky-rivers-collect.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications-backend': patch ---- - -Updated documentation for sending messages by external services. diff --git a/.changeset/warm-fans-promise.md b/.changeset/warm-fans-promise.md deleted file mode 100644 index a8a8f8a2c7..0000000000 --- a/.changeset/warm-fans-promise.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -The rendered size of a notification is limited for very long descriptions. diff --git a/.changeset/wet-files-pretend.md b/.changeset/wet-files-pretend.md deleted file mode 100644 index 8f77a5bc0b..0000000000 --- a/.changeset/wet-files-pretend.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-org': patch ---- - -Fix ownership card sometimes locking up for complex org structures diff --git a/.changeset/wild-doors-cheat.md b/.changeset/wild-doors-cheat.md new file mode 100644 index 0000000000..c302dde467 --- /dev/null +++ b/.changeset/wild-doors-cheat.md @@ -0,0 +1,5 @@ +--- +'@backstage/cli': patch +--- + +Fix `versions:check --fix` when `yarn.lock` has multiple joint versions in the same section diff --git a/.changeset/wild-seahorses-grin.md b/.changeset/wild-seahorses-grin.md deleted file mode 100644 index 94b30a6839..0000000000 --- a/.changeset/wild-seahorses-grin.md +++ /dev/null @@ -1,6 +0,0 @@ ---- -'@backstage/plugin-search-backend-module-techdocs': patch -'@backstage/plugin-search-backend-module-catalog': patch ---- - -Allow the `tokenManager` parameter to be optional when instantiating collator diff --git a/.changeset/young-camels-return.md b/.changeset/young-camels-return.md new file mode 100644 index 0000000000..efdd822788 --- /dev/null +++ b/.changeset/young-camels-return.md @@ -0,0 +1,5 @@ +--- +'@backstage/cli': patch +--- + +Bump `esbuild` target for package builds to `ES2022`. diff --git a/.changeset/young-guests-reflect.md b/.changeset/young-guests-reflect.md deleted file mode 100644 index 355c38bc21..0000000000 --- a/.changeset/young-guests-reflect.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/plugin-notifications': patch ---- - -Add option to set the notification as read automatically when the notification link is opened diff --git a/.changeset/young-olives-drop.md b/.changeset/young-olives-drop.md deleted file mode 100644 index 4058293be8..0000000000 --- a/.changeset/young-olives-drop.md +++ /dev/null @@ -1,5 +0,0 @@ ---- -'@backstage/backend-plugin-api': patch ---- - -Removed explicit `toString()` method from `ServiceRef` type. diff --git a/.github/workflows/api-breaking-changes.yml b/.github/workflows/api-breaking-changes.yml index 84161e3010..5f456a9b0b 100644 --- a/.github/workflows/api-breaking-changes.yml +++ b/.github/workflows/api-breaking-changes.yml @@ -18,7 +18,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: # Fetch the commit that's merged into the base rather than the target ref # This will let us diff only the contents of the PR, without fetching more history diff --git a/.github/workflows/automate_changeset_feedback.yml b/.github/workflows/automate_changeset_feedback.yml index ef1a258239..6ac327bcd6 100644 --- a/.github/workflows/automate_changeset_feedback.yml +++ b/.github/workflows/automate_changeset_feedback.yml @@ -27,7 +27,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: # Fetch the commit that's merged into the base rather than the target ref # This will let us diff only the contents of the PR, without fetching more history diff --git a/.github/workflows/automate_merge_message.yml b/.github/workflows/automate_merge_message.yml index dd8895a752..56ab3283ac 100644 --- a/.github/workflows/automate_merge_message.yml +++ b/.github/workflows/automate_merge_message.yml @@ -28,7 +28,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: ref: '${{ github.event.pull_request.merge_commit_sha }}' diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index c538ec8957..45d2363a36 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -32,7 +32,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js ${{ matrix.node-version }} uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 @@ -68,7 +68,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js ${{ matrix.node-version }} uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 @@ -187,6 +187,15 @@ jobs: --health-retries 5 ports: - 3306/tcp + redis: + image: redis + options: >- + --health-cmd "redis-cli ping" + --health-interval 10s + --health-timeout 5s + --health-retries 5 + ports: + - 6379/tcp env: CI: true @@ -197,7 +206,7 @@ jobs: INTEGRATION_TEST_AZURE_TOKEN: ${{ secrets.INTEGRATION_TEST_AZURE_TOKEN }} steps: - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: fetch master branch run: git fetch origin master @@ -231,6 +240,7 @@ jobs: BACKSTAGE_TEST_DATABASE_POSTGRES16_CONNECTION_STRING: postgresql://postgres:postgres@localhost:${{ job.services.postgres16.ports[5432] }} BACKSTAGE_TEST_DATABASE_POSTGRES12_CONNECTION_STRING: postgresql://postgres:postgres@localhost:${{ job.services.postgres12.ports[5432] }} BACKSTAGE_TEST_DATABASE_MYSQL8_CONNECTION_STRING: mysql://root:root@localhost:${{ job.services.mysql8.ports[3306] }}/ignored + BACKSTAGE_TEST_CACHE_REDIS_CONNECTION_STRING: redis://localhost:${{ job.services.redis.ports[6379] }} # We run the test cases before verifying the specs to prevent any failing tests from causing errors. - name: verify openapi specs against test cases diff --git a/.github/workflows/deploy_docker-image.yml b/.github/workflows/deploy_docker-image.yml index d5f5eee35e..19c58a8a60 100644 --- a/.github/workflows/deploy_docker-image.yml +++ b/.github/workflows/deploy_docker-image.yml @@ -25,7 +25,7 @@ jobs: egress-policy: audit - name: checkout - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: path: backstage ref: ${{ github.event.client_payload.version && env.RELEASE_VERSION || github.ref }} diff --git a/.github/workflows/deploy_microsite.yml b/.github/workflows/deploy_microsite.yml index 037fb27e8d..2554e3eeb8 100644 --- a/.github/workflows/deploy_microsite.yml +++ b/.github/workflows/deploy_microsite.yml @@ -28,7 +28,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js 18.x uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 diff --git a/.github/workflows/deploy_nightly.yml b/.github/workflows/deploy_nightly.yml index ab8ea3c773..6ec5b03d56 100644 --- a/.github/workflows/deploy_nightly.yml +++ b/.github/workflows/deploy_nightly.yml @@ -19,7 +19,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js 18.x uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 diff --git a/.github/workflows/deploy_packages.yml b/.github/workflows/deploy_packages.yml index 44222275ad..444f3f825d 100644 --- a/.github/workflows/deploy_packages.yml +++ b/.github/workflows/deploy_packages.yml @@ -65,7 +65,7 @@ jobs: INTEGRATION_TEST_AZURE_TOKEN: ${{ secrets.INTEGRATION_TEST_AZURE_TOKEN }} steps: - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js ${{ matrix.node-version }} uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 @@ -148,7 +148,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js ${{ matrix.node-version }} uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 diff --git a/.github/workflows/scorecard.yml b/.github/workflows/scorecard.yml index 8a069d476d..0b883dd75a 100644 --- a/.github/workflows/scorecard.yml +++ b/.github/workflows/scorecard.yml @@ -34,7 +34,7 @@ jobs: egress-policy: audit - name: 'Checkout code' - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: persist-credentials: false diff --git a/.github/workflows/sync_code-formatting.yml b/.github/workflows/sync_code-formatting.yml index 7f10ae60df..dce7217201 100644 --- a/.github/workflows/sync_code-formatting.yml +++ b/.github/workflows/sync_code-formatting.yml @@ -14,7 +14,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: # Fetch changes to previous commit - required for 'only_changed' in Prettier action fetch-depth: 0 diff --git a/.github/workflows/sync_dependabot-changesets.yml b/.github/workflows/sync_dependabot-changesets.yml index 7c8e634fb8..ddd60750d1 100644 --- a/.github/workflows/sync_dependabot-changesets.yml +++ b/.github/workflows/sync_dependabot-changesets.yml @@ -16,7 +16,7 @@ jobs: egress-policy: audit - name: Checkout - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: fetch-depth: 2 ref: ${{ github.head_ref }} diff --git a/.github/workflows/sync_release-manifest.yml b/.github/workflows/sync_release-manifest.yml index 7fe8817731..c971be522f 100644 --- a/.github/workflows/sync_release-manifest.yml +++ b/.github/workflows/sync_release-manifest.yml @@ -21,7 +21,7 @@ jobs: run: npm install semver@7.3.5 fs-extra@10.0.0 @manypkg/get-packages@1.1.1 - name: Checkout - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: path: backstage # 'v' prefix is added here for the tag, we keep it out of the manifest logic @@ -29,7 +29,7 @@ jobs: # Checkout backstage/versions into /backstage/versions, which is where store the output - name: Checkout versions - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: repository: backstage/versions path: backstage/versions diff --git a/.github/workflows/sync_renovate-changesets.yml b/.github/workflows/sync_renovate-changesets.yml index e1c5656d08..9d031812ea 100644 --- a/.github/workflows/sync_renovate-changesets.yml +++ b/.github/workflows/sync_renovate-changesets.yml @@ -16,7 +16,7 @@ jobs: egress-policy: audit - name: Checkout - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: fetch-depth: 2 ref: ${{ github.head_ref }} diff --git a/.github/workflows/sync_snyk-github-issues.yml b/.github/workflows/sync_snyk-github-issues.yml index 1948807215..2ea3fcd5a1 100644 --- a/.github/workflows/sync_snyk-github-issues.yml +++ b/.github/workflows/sync_snyk-github-issues.yml @@ -16,7 +16,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js 18.x uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 diff --git a/.github/workflows/sync_snyk-monitor.yml b/.github/workflows/sync_snyk-monitor.yml index 43c613b641..e6b274c395 100644 --- a/.github/workflows/sync_snyk-monitor.yml +++ b/.github/workflows/sync_snyk-monitor.yml @@ -29,7 +29,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: Monitor and Synchronize Snyk Policies uses: snyk/actions/node@8349f9043a8b7f0f3ee8885bf28f0b388d2446e8 # master with: diff --git a/.github/workflows/sync_version-packages.yml b/.github/workflows/sync_version-packages.yml index ed69fd3c24..884bcf3d95 100644 --- a/.github/workflows/sync_version-packages.yml +++ b/.github/workflows/sync_version-packages.yml @@ -18,7 +18,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: fetch-depth: 20000 fetch-tags: true diff --git a/.github/workflows/uffizzi-build.yml b/.github/workflows/uffizzi-build.yml index eab0a61e46..5ab208590a 100644 --- a/.github/workflows/uffizzi-build.yml +++ b/.github/workflows/uffizzi-build.yml @@ -31,7 +31,7 @@ jobs: egress-policy: audit - name: checkout - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: setup-node uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 @@ -89,7 +89,7 @@ jobs: egress-policy: audit - name: Checkout git repo - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: Render Compose File run: | # update image after the build above diff --git a/.github/workflows/verify_accessibility.yml b/.github/workflows/verify_accessibility.yml index 2c0e10c118..75415f7961 100644 --- a/.github/workflows/verify_accessibility.yml +++ b/.github/workflows/verify_accessibility.yml @@ -24,7 +24,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: Use Node.js 18.x uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 with: diff --git a/.github/workflows/verify_codeql.yml b/.github/workflows/verify_codeql.yml index f028147b85..0c30218d72 100644 --- a/.github/workflows/verify_codeql.yml +++ b/.github/workflows/verify_codeql.yml @@ -47,7 +47,7 @@ jobs: egress-policy: audit - name: Checkout repository - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: # We must fetch at least the immediate parents so that if this is # a pull request then we can checkout the head. diff --git a/.github/workflows/verify_docs-quality.yml b/.github/workflows/verify_docs-quality.yml index 21d3563b57..f784608493 100644 --- a/.github/workflows/verify_docs-quality.yml +++ b/.github/workflows/verify_docs-quality.yml @@ -16,7 +16,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 # Vale does not support file excludes, so we use the script to generate a list of files instead # The action also does not allow args or a local config file to be passed in, so the files array diff --git a/.github/workflows/verify_e2e-kubernetes.yml b/.github/workflows/verify_e2e-kubernetes.yml index ffaa7971e6..9763cbd085 100644 --- a/.github/workflows/verify_e2e-kubernetes.yml +++ b/.github/workflows/verify_e2e-kubernetes.yml @@ -26,7 +26,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js ${{ matrix.node-version }} uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 diff --git a/.github/workflows/verify_e2e-linux.yml b/.github/workflows/verify_e2e-linux.yml index 6ff3b9eecf..b9229263ae 100644 --- a/.github/workflows/verify_e2e-linux.yml +++ b/.github/workflows/verify_e2e-linux.yml @@ -45,7 +45,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: Configure Git run: | diff --git a/.github/workflows/verify_e2e-techdocs.yml b/.github/workflows/verify_e2e-techdocs.yml index ad0950392f..31d9d8b06a 100644 --- a/.github/workflows/verify_e2e-techdocs.yml +++ b/.github/workflows/verify_e2e-techdocs.yml @@ -34,7 +34,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0 with: python-version: '3.9' diff --git a/.github/workflows/verify_e2e-windows.yml b/.github/workflows/verify_e2e-windows.yml index 7a823a85e1..064baf700e 100644 --- a/.github/workflows/verify_e2e-windows.yml +++ b/.github/workflows/verify_e2e-windows.yml @@ -42,7 +42,7 @@ jobs: git config --global core.autocrlf false git config --global core.eol lf - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: Configure Git run: | diff --git a/.github/workflows/verify_fossa.yml b/.github/workflows/verify_fossa.yml index 4c9b1516a2..152fe9f185 100644 --- a/.github/workflows/verify_fossa.yml +++ b/.github/workflows/verify_fossa.yml @@ -19,7 +19,7 @@ jobs: egress-policy: audit - name: Checkout - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: Install Fossa run: "curl -H 'Cache-Control: no-cache' https://raw.githubusercontent.com/fossas/fossa-cli/master/install.sh | bash" diff --git a/.github/workflows/verify_microsite.yml b/.github/workflows/verify_microsite.yml index 724fac7fef..48d7da218d 100644 --- a/.github/workflows/verify_microsite.yml +++ b/.github/workflows/verify_microsite.yml @@ -28,7 +28,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js 18.x uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 diff --git a/.github/workflows/verify_microsite_accessibility.yml b/.github/workflows/verify_microsite_accessibility.yml index af2364e743..9728bf57c6 100644 --- a/.github/workflows/verify_microsite_accessibility.yml +++ b/.github/workflows/verify_microsite_accessibility.yml @@ -19,7 +19,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: Use Node.js 18.x uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 diff --git a/.github/workflows/verify_storybook.yml b/.github/workflows/verify_storybook.yml index 3cdb0de344..9a59b7b071 100644 --- a/.github/workflows/verify_storybook.yml +++ b/.github/workflows/verify_storybook.yml @@ -32,7 +32,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 with: fetch-depth: 0 # Required to retrieve git history diff --git a/.github/workflows/verify_windows.yml b/.github/workflows/verify_windows.yml index 0c54cfb287..cd7a9b62ae 100644 --- a/.github/workflows/verify_windows.yml +++ b/.github/workflows/verify_windows.yml @@ -33,7 +33,7 @@ jobs: with: egress-policy: audit - - uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4 + - uses: actions/checkout@44c2b7a8a4ea60a981eaca3cf939b5f4305c123b # v4.1.5 - name: use node.js ${{ matrix.node-version }} uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # v4.0.2 diff --git a/ADOPTERS.md b/ADOPTERS.md index 4a6f726fcd..2bb76a199e 100644 --- a/ADOPTERS.md +++ b/ADOPTERS.md @@ -154,7 +154,7 @@ _You can do this by using the [Adopter form](https://info.backstage.spotify.com/ | [Lendingkart](https://www.lendingkart.com/) | [Dinesh Rajpoot](mailto:dinesh.rajpoot@lendingkart.com) | Service catalog, Software templates to enforce best practices and tech insights to track mandates & migrations. | | [Meltwater](https://underthehood.meltwater.com) | [@spier](https://github.com/spier), [@remen](https://github.com/remen) | Improving developer experience by centralizing documentation and internal APIs. Goal: Foster InnerSource collaboration and speed up onboarding time in our 500+ people Product & Engineering org. | | [Doctolib](https://doctolib.engineering/) | [@djiit](https://github.com/djiit) | Rails modularization effort awareness, tech organization discoverability. Improving the daily workflows and collaboration processes of our engineers. | -| [Twilio](https://www.twilio.com) | [Kyle Smith](https://github.com/knksmith57) | Developer portal, universal software catalog, and centralized taxonomy platform. | +| [Twilio](https://www.twilio.com) | [Alec Jacobs](https://github.com/alecjacobs5401) | Developer portal, universal software catalog, and centralized taxonomy platform. | | [OVHcloud](https://www.ovhcloud.com/fr/) | [Jean-Philippe Blary](https://github.com/blaryjp), [Arnaud Bauer](mailto:arnaud.bauer@ovhcloud.com), [Flavien Chantelot](https://github.com/Dorn-) | We're providing Backstage to our collaborators to ease their daily jobs, and let them extends it using plugins. | | [Procter & Gamble](https://us.pg.com/) | [Binita Nayak](https://github.com/binitan), | P&G leverages Backstage to build internal developer portal to ensure developers' happiness. This developer portal shall act as single source of information needed by development teams to seamlessly create, find and maintain their software components/resources/documentation. | | [SANS Institute](https://www.sans.org) | [Christopher Klewin](mailto:cklewin@sans.org) | Developer portal for centralized visibility, reporting, and tooling across multiple organizations. | diff --git a/OWNERS.md b/OWNERS.md index d8967ca873..f2e2cb7cf1 100644 --- a/OWNERS.md +++ b/OWNERS.md @@ -187,6 +187,7 @@ Scope: The Scaffolder frontend and backend plugins, and related tooling. | Miklós Kiss | Roadie.io | [kissmikijr](https://github.com/kissmikijr) | `Miklos#7416` | | Patrick Jungermann | Bonial International GmbH | [pjungermann](https://github.com/pjungermann) | `pjungermann#6933` | | Phil Kuang | FactSet Research Systems | [kuangp](https://github.com/kuangp) | `pkuang#3202` | +| Sebastian Poxhofer | N26 | [secustor](https://github.com/secustor) | `secustor` | | Taras Mankovski | Frontside | [taras](https://github.com/taras) | `tarasm#1256` | ## Emeritus Core Maintainers diff --git a/SECURITY.md b/SECURITY.md index 5866fff2b4..8de1307356 100644 --- a/SECURITY.md +++ b/SECURITY.md @@ -66,7 +66,7 @@ The insecure example above should instead be written like this: ```ts // THIS IS GOOD, DO THIS -import { resolveSafeChildPath } from '@backstaghe/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-common'; import fs from 'fs-extra'; function writeTemporaryFile(tmpDir: string, name: string, content: string) { diff --git a/beps/0001-notifications-system/README.md b/beps/0001-notifications-system/README.md index 4b4f3b0532..150abec9d6 100644 --- a/beps/0001-notifications-system/README.md +++ b/beps/0001-notifications-system/README.md @@ -380,10 +380,39 @@ interface SignalApi { - Render dynamic values with various different React elements such as the `EntityRefLink` for entity references (for example `{{ user:default/john.doe }}`) in the notification payload - Handle `link` values that use route references. For example instead hard-coding link to `/catalog/default/component/artist-web` it should be possible to use `catalogPlugin.catalogEntity` route reference as a link of the notification. This should also allow using parameters to be passed to the route reference. Links to external systems are still supported. - Add support for `analyticsApi` to notification actions like marking notifications done, saved or opening links in the notifications -- Add support for user settings to control how notifications are shown to the user and which notifications user wants to receive. This should also include support for different `NotificationProcessor`s that can send notification to external systems - Add a sound to be played when notification is received - Add i18n internationalization support for the notification payload +### User specific notification settings + +To allow the users more fine-grained control of notifications, user must have an option to unsubscribe from specific origins, topics and channels. + +By default, all notifications are enabled for the user in all notification channels. Frontend plugin provides an user interface to change these settings for example as described in the following image: + +![user notification settings UI example](./UserNotificationSettings.png) + +Each notification processor with `send` functionality will be listed as a separate channel among the Backstage internal notification channel `Web`. For this, each notification processor must implement a function to get a human readable name to be rendered in the frontend. + +User must be able to save these settings to the notification database, and they are be checked each time a new notification is sent to the user. + +Disabling a notification from specific origin or topic in the `Web` channel will not remove the old notifications being visible in the frontend from that source but instead, it only prevents new notifications being sent. + +For performance reasons the notification settings will ignore all broadcast notifications and those will be sent to all users despite their origin or channel. + +```ts +export type NotificationSetting = { + origin: string; + topic?: string; + channels: Record; +}; + +export type UserNotificationSettings = { + settings: NotificationSetting[]; +}; +``` + +The backend plugin returns user notification settings for all known origins, topics and channels it knows of. As new origins, topics and channels will get added, also the notification settings list will get longer. This allows an easy way to add new notification origins, topics and channels without need to change the notification plugin. If the user is missing notification setting from specific origin/topic/channel, the backend considers it as enabled. + ## Release Plan The notification and signal plugins are released as two new plugins in the Backstage ecosystem. They will both start out in an experimental state. diff --git a/beps/0001-notifications-system/UserNotificationSettings.png b/beps/0001-notifications-system/UserNotificationSettings.png new file mode 100644 index 0000000000..de9a5881b4 Binary files /dev/null and b/beps/0001-notifications-system/UserNotificationSettings.png differ diff --git a/contrib/docs/tutorials/authenticate-api-requests.md b/contrib/docs/tutorials/authenticate-api-requests.md index 838aaffef6..8c858bea0f 100644 --- a/contrib/docs/tutorials/authenticate-api-requests.md +++ b/contrib/docs/tutorials/authenticate-api-requests.md @@ -3,8 +3,7 @@ > [!CAUTION] > This entire guide MUST NOT BE USED by users of Backstage 1.26 and > newer. If you have applied the changes in this guide, you need to remove them -> again as you upgrade to recent versions of Backstage. When [the new auth -> changes](https://github.com/backstage/backstage/tree/master/beps/0003-auth-architecture-evolution) +> again as you upgrade to recent versions of Backstage. When [the new auth changes](https://github.com/backstage/backstage/tree/master/beps/0003-auth-architecture-evolution) > landed backends became natively secured through the framework, and the > instructions outlined in here can interfere with the backend functioning > correctly. diff --git a/contrib/docs/tutorials/aws-deployment.md b/contrib/docs/tutorials/aws-deployment.md index 6edbb73f9d..d43d8aefb0 100644 --- a/contrib/docs/tutorials/aws-deployment.md +++ b/contrib/docs/tutorials/aws-deployment.md @@ -1,11 +1,9 @@ # Deploying Backstage on AWS using ECR and EKS -Backstage documentation shows how to build a [Docker -image](https://backstage.io/docs/deployment/docker); this +Backstage documentation shows how to build a [Docker image](https://backstage.io/docs/deployment/docker); this tutorial shows how to deploy that Docker image to AWS using Elastic Container Registry (ECR) and Elastic Kubernetes Service (EKS). Amazon also supports -deployments with Helm, covered in the [Helm -Kubernetes](../../kubernetes/basic_kubernetes_example_with_helm) example. +deployments with Helm, covered in the [Helm Kubernetes](../../kubernetes/basic_kubernetes_example_with_helm) example. The basic workflow for this method is to build a Backstage Docker image, upload the new version to a container registry, and update a Kubernetes deployment with @@ -13,8 +11,7 @@ the new image. ## Create a container registry -To create an Elastic Container Registry on AWS, go to the [AWS ECR -console](https://console.aws.amazon.com/ecr/repositories). +To create an Elastic Container Registry on AWS, go to the [AWS ECR console](https://console.aws.amazon.com/ecr/repositories). Click `Create repository` and give the repository a name, like `backstage`. @@ -35,8 +32,7 @@ Go to [AWS IAM console](https://console.aws.amazon.com/iam/home) and select ## Publish a Backstage build -Follow the [Docker -image](https://backstage.io/docs/deployment/docker) +Follow the [Docker image](https://backstage.io/docs/deployment/docker) documentation to build a new Backstage Docker image: ```shell @@ -56,8 +52,7 @@ Default region name: Now you can use the AWS CLI to push the built image to the ECR repository. It's a good practice to use a specific version tag as well as `latest` when pushing; -more about [Semver tagging -here](https://medium.com/@mccode/using-semantic-versioning-for-docker-image-tags-dfde8be06699). +more about [Semver tagging here](https://medium.com/@mccode/using-semantic-versioning-for-docker-image-tags-dfde8be06699). Go to the [AWS ECR console](https://console.aws.amazon.com/ecr/repositories) and click on your repository, then `View push commands`. This will show the @@ -83,12 +78,10 @@ Kubernetes deployment based on this image. Creating an Elastic Kubernetes Service (EKS) cluster is beyond the scope of this document, but it can be as easy as `eksctl create cluster` documented in the -[AWS EKS getting started -guide](https://docs.aws.amazon.com/eks/latest/userguide/getting-started-eksctl.html), +[AWS EKS getting started guide](https://docs.aws.amazon.com/eks/latest/userguide/getting-started-eksctl.html), which uses a Cloudformation template to create the necessary resources. -To deploy the Docker image to EKS, follow the [Kubernetes -guide](https://backstage.io/docs/deployment/k8s#creating-the-backstage-instance) +To deploy the Docker image to EKS, follow the [Kubernetes guide](https://backstage.io/docs/deployment/k8s#creating-the-backstage-instance) but set the Backstage deployment `image` to the ECR repository URL: ```yaml @@ -110,8 +103,7 @@ spec: ... ``` -Create the [Service -descriptor](https://backstage.io/docs/deployment/k8s#creating-a-backstage-service) +Create the [Service descriptor](https://backstage.io/docs/deployment/k8s#creating-a-backstage-service) as well, and apply these Kubernetes definitions to the EKS cluster to complete the Backstage deployment: @@ -120,16 +112,14 @@ $ kubectl apply -f kubernetes/backstage.yaml $ kubectl apply -f kubernetes/backstage-service.yaml ``` -Now you can see your Backstage workload running from the [EKS -console](https://console.aws.amazon.com/eks/home). +Now you can see your Backstage workload running from the [EKS console](https://console.aws.amazon.com/eks/home). ## Further steps ### Exposing Backstage with a load balancer To make the service useful, we need to expose the workload with a load balancer. -Follow the [Application load balancing on -EKS](https://docs.aws.amazon.com/eks/latest/userguide/alb-ingress.html) guide to +Follow the [Application load balancing on EKS](https://docs.aws.amazon.com/eks/latest/userguide/alb-ingress.html) guide to set up a Load Balancer controller and Kubernetes ingress to your application. This is ultimately a `kubectl apply` with an ingress definition: diff --git a/docs/assets/software-catalog/software-model-entities.drawio.svg b/docs/assets/software-catalog/software-model-entities.drawio.svg index d087583245..122f58b065 100644 --- a/docs/assets/software-catalog/software-model-entities.drawio.svg +++ b/docs/assets/software-catalog/software-model-entities.drawio.svg @@ -1,4 +1,4 @@ - + -
Domain
(e.g.  domain
models, metrics, KPIs, business purpose)
Domain...
partOf
partOf
System
Collection of entities that cooperate to perform some function
System...
dependsOn
dependsOn
partOf
partOf
Resource
(e.g. SQL Database, S3 bucket, ...)
Resource...
consumesAPI
consumesAPI
API
(e.g. OpenAPI, gRPC API, Avro, Dataset, ...)
API...
providesAPI
providesAPI
partOf
partOf
Component
(e.g. backend service, data pipeline ...)
Component...
partOf
partOf
dependsOn
dependsOn
Kind: Group
Kind: Group
Kind: User
Kind: User
OwnerOf
OwnerOf
OwnedBy
OwnedBy
Service
Service
website
website
website
website
Types
Types
service
service
website
website
library
library
asyncapi
asyncapi
graphql
graphql
grpc
grpc
Types
Types
openapi
openapi
business-unit
business-unit
product-area
product-area
root
root
Types
Types
team
team
s3-bucket
s3-bucket
cluster
cluster
Types
Types
database
database
Kind: Template
Parameters rendered in the
frontend and the steps executed in  the scaffolding process
Kind: Template...
Kind: Location
a marker that references other places to look for catalog data
Kind: Location...
memberOf
memberOf
hasMember
hasMember
parentOf
parentOf
childOf
childOf
Text is not SVG - cannot display
\ No newline at end of file +
Domain
(e.g.  domain
models, metrics, KPIs, business purpose)
partOf
System
Collection of entities that cooperate to perform some function
dependsOn
partOf
Resource
(e.g. SQL Database, S3 bucket, ...)
consumesAPI
API
(e.g. OpenAPI, gRPC API, Avro, Dataset, ...)
providesAPI
partOf
Component
(e.g. backend service, data pipeline ...)
partOf
dependsOn
Kind: Group
Kind: User
OwnerOf
OwnedBy
Service
website
website
Types
service
website
library
asyncapi
graphql
grpc
Types
openapi
business-unit
product-area
root
Types
team
s3-bucket
cluster
Types
database
Kind: Template
Parameters rendered in the
frontend and the steps executed in  the scaffolding process
Kind: Location
a marker that references other places to look for catalog data
memberOf
hasMember
parentOf
childOf
subdomainOf
\ No newline at end of file diff --git a/docs/assets/software-templates/template-start-over.png b/docs/assets/software-templates/template-start-over.png new file mode 100644 index 0000000000..67d9caff34 Binary files /dev/null and b/docs/assets/software-templates/template-start-over.png differ diff --git a/docs/assets/software-templates/template-task-list.png b/docs/assets/software-templates/template-task-list.png new file mode 100644 index 0000000000..dc2bbfa310 Binary files /dev/null and b/docs/assets/software-templates/template-task-list.png differ diff --git a/docs/auth/atlassian/provider.md b/docs/auth/atlassian/provider.md index d6f19ee791..c8db009805 100644 --- a/docs/auth/atlassian/provider.md +++ b/docs/auth/atlassian/provider.md @@ -71,7 +71,11 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `usernameMatchingUserEntityName`: Matches the username from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. diff --git a/docs/auth/cloudflare/access.md b/docs/auth/cloudflare/access.md index 9df816c39f..52d9fdfc21 100644 --- a/docs/auth/cloudflare/access.md +++ b/docs/auth/cloudflare/access.md @@ -170,6 +170,5 @@ backend.add(customAuth); The body of the sign-in resolver is up to you to write! The example code above is just a copy of what `emailMatchingUserEntityProfileEmail` does. The `info` parameter contains all of the results of the sign-in attempt so far. The `ctx` -context [has several useful -functions](https://backstage.io/docs/reference/plugin-auth-node.authresolvercontext/) +context [has several useful functions](https://backstage.io/docs/reference/plugin-auth-node.authresolvercontext/) for issuing tokens in various ways. diff --git a/docs/auth/github/provider.md b/docs/auth/github/provider.md index 2c3aaeaf7d..1604b607ff 100644 --- a/docs/auth/github/provider.md +++ b/docs/auth/github/provider.md @@ -43,13 +43,12 @@ auth: # enterpriseInstanceUrl: ${AUTH_GITHUB_ENTERPRISE_INSTANCE_URL} signIn: resolvers: - # typically you would pick one of these - - resolver: emailMatchingUserEntityProfileEmail - - resolver: emailLocalPartMatchingUserEntityName + # Matches the GitHub username with the Backstage user entity name. + # See https://backstage.io/docs/auth/github/provider#resolvers for more resolvers. - resolver: usernameMatchingUserEntityName ``` -The GitHub provider is a structure with three configuration keys: +The GitHub provider is a structure with these configuration keys: - `clientId`: The client ID that you generated on GitHub, e.g. `b59241722e3c3b4816e2` @@ -60,6 +59,9 @@ The GitHub provider is a structure with three configuration keys: initiating an OAuth flow, e.g. `https://your-intermediate-service.com/handler`. Only needed if Backstage is not the immediate receiver (e.g. one OAuth app for many backstage instances). +- `signIn`: The configuration for the sign-in process, including the **resolvers** + that should be used to match the user from the auth provider with the user + entity in the Backstage catalog (typically a single resolver is sufficient). ### Resolvers @@ -69,7 +71,11 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `usernameMatchingUserEntityName`: Matches the username from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. diff --git a/docs/auth/gitlab/provider.md b/docs/auth/gitlab/provider.md index ff6a341667..f5613582fd 100644 --- a/docs/auth/gitlab/provider.md +++ b/docs/auth/gitlab/provider.md @@ -70,7 +70,11 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `usernameMatchingUserEntityName`: Matches the username from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. diff --git a/docs/auth/google/gcp-iap-auth.md b/docs/auth/google/gcp-iap-auth.md index 709ef2b521..7e6178154c 100644 --- a/docs/auth/google/gcp-iap-auth.md +++ b/docs/auth/google/gcp-iap-auth.md @@ -50,7 +50,11 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `emailMatchingUserEntityAnnotation`: Matches the email address from the auth provider with the User entity where the value of the `google.com/email` annotation matches. If no match is found it will throw a `NotFoundError`. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. diff --git a/docs/auth/google/provider.md b/docs/auth/google/provider.md index f2d2e8524e..f7802d43f7 100644 --- a/docs/auth/google/provider.md +++ b/docs/auth/google/provider.md @@ -64,7 +64,11 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `emailMatchingUserEntityAnnotation`: Matches the email address from the auth provider with the User entity where the value of the `google.com/email` annotation matches. If no match is found it will throw a `NotFoundError`. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. diff --git a/docs/auth/identity-resolver.md b/docs/auth/identity-resolver.md index 406f789630..4140276df8 100644 --- a/docs/auth/identity-resolver.md +++ b/docs/auth/identity-resolver.md @@ -5,8 +5,7 @@ description: An introduction to Backstage user identities and sign-in resolvers --- :::info -This documentation is written for [the new backend -system](../backend-system/index.md) which is the default since Backstage +This documentation is written for [the new backend system](../backend-system/index.md) which is the default since Backstage [version 1.24](../releases/v1.24.0.md). If you are still on the old backend system, you may want to read [its own article](./identity-resolver--old.md) instead, and [consider migrating](../backend-system/building-backends/08-migrating.md)! @@ -31,15 +30,13 @@ testing purposes and quickly getting started locally, but is not safe for use in production and that particular provider will refuse to work there. Because of this, one of the early things you want to do when standing up your -Backstage instance is to choose a production ready auth provider. See [the auth -overview page](./index.md) for a full list of providers and how to install and +Backstage instance is to choose a production ready auth provider. See [the auth overview page](./index.md) for a full list of providers and how to install and configure them. ## Backstage User Identity A user identity within Backstage is built up from two main pieces of -information: a user [entity -reference](../features/software-catalog/references.md), and a set of ownership +information: a user [entity reference](../features/software-catalog/references.md), and a set of ownership references. When a user signs in, a Backstage token is generated which is then used to identify the user within the Backstage ecosystem. @@ -194,8 +191,7 @@ backend.add(import('@backstage/plugin-auth-backend-module-github-provider')); backend.add(customAuth); ``` -Check out [the naming patterns -article](../backend-system/architecture/07-naming-patterns.md) for what rules +Check out [the naming patterns article](../backend-system/architecture/07-naming-patterns.md) for what rules apply regarding how to form valid IDs. In this example we also put the module declaration directly in `packages/backend/src/index.ts` but that's just for simplicity. You can place it anywhere you like, including in other packages, and @@ -244,8 +240,7 @@ async signInResolver(info, ctx) { If you throw an error in the sign in resolver function, the sign in attempt is immediately rejected, and the error details are presented in the user interface. -The `ctx` context [has several useful -functions](https://backstage.io/docs/reference/plugin-auth-node.authresolvercontext/) +The `ctx` context [has several useful functions](https://backstage.io/docs/reference/plugin-auth-node.authresolvercontext/) for issuing tokens in various ways. ### Custom Ownership Resolution diff --git a/docs/auth/index.md b/docs/auth/index.md index f6282264e4..f925e52917 100644 --- a/docs/auth/index.md +++ b/docs/auth/index.md @@ -10,12 +10,16 @@ configure Backstage to have any number of authentication providers, but only one of these will typically be used for sign-in, with the rest being used to provide access to external resources. -> NOTE: Identity management and the Sign-In page in Backstage is NOT a method for blocking -> access for unauthorized users. The identity system only serves to provide a personalized -> experience and access to a Backstage Identity Token, which can be passed to backend plugins. -> This also means that your Backstage backend APIs are by default unauthenticated. -> Thus, if your Backstage instance is exposed to the Internet, anyone can access -> information in the Backstage. You can learn more [here](../overview/threat-model.md#integrator-responsibilities). +:::note Note + +Identity management and the Sign-In page in Backstage is NOT a method for blocking +access for unauthorized users. The identity system only serves to provide a personalized +experience and access to a Backstage Identity Token, which can be passed to backend plugins. +This also means that your Backstage backend APIs are by default unauthenticated. +Thus, if your Backstage instance is exposed to the Internet, anyone can access +information in the Backstage. You can learn more [here](../overview/threat-model.md#integrator-responsibilities). + +::: ## Built-in Authentication Providers @@ -141,8 +145,12 @@ const app = createApp({ }); ``` -> NOTE: You can configure sign-in to use a redirect flow with no pop-up by adding -> `enableExperimentalRedirectFlow: true` to the root of your `app-config.yaml` +:::note Note + +You can configure sign-in to use a redirect flow with no pop-up by adding +`enableExperimentalRedirectFlow: true` to the root of your `app-config.yaml` + +::: ## Sign-In with Proxy Providers diff --git a/docs/auth/microsoft/provider.md b/docs/auth/microsoft/provider.md index 5c4707c151..b96f175183 100644 --- a/docs/auth/microsoft/provider.md +++ b/docs/auth/microsoft/provider.md @@ -84,7 +84,11 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `emailMatchingUserEntityAnnotation`: Matches the email address from the auth provider with the User entity where the value of the `microsoft.com/email` annotation matches. If no match is found it will throw a `NotFoundError`. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. @@ -103,6 +107,5 @@ hosts: - `login.microsoftonline.com`, to get and exchange authorization codes and access tokens - `graph.microsoft.com`, to fetch user profile information (as seen - in [this source - code](https://github.com/seanfisher/passport-microsoft/blob/0456aa9bce05579c18e77f51330176eb26373658/lib/strategy.js#L93-L95)). + in [this source code](https://github.com/seanfisher/passport-microsoft/blob/0456aa9bce05579c18e77f51330176eb26373658/lib/strategy.js#L93-L95)). If this host is unreachable, users may see an `Authentication failed, failed to fetch user profile` error when they attempt to log in. diff --git a/docs/auth/oauth2-proxy/provider.md b/docs/auth/oauth2-proxy/provider.md index aded90a1e7..8745f32297 100644 --- a/docs/auth/oauth2-proxy/provider.md +++ b/docs/auth/oauth2-proxy/provider.md @@ -40,7 +40,11 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `forwardedUserMatchingUserEntityName`: Matches the value in the `x-forwarded-user` header from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. diff --git a/docs/auth/okta/provider.md b/docs/auth/okta/provider.md index 0c15746cfd..6fe7a8b992 100644 --- a/docs/auth/okta/provider.md +++ b/docs/auth/okta/provider.md @@ -75,7 +75,11 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `emailMatchingUserEntityAnnotation`: Matches the email address from the auth provider with the User entity where the value of the `okta.com/email` annotation matches. If no match is found it will throw a `NotFoundError`. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. diff --git a/docs/auth/service-to-service-auth.md b/docs/auth/service-to-service-auth.md index c1d6643769..c08411aca5 100644 --- a/docs/auth/service-to-service-auth.md +++ b/docs/auth/service-to-service-auth.md @@ -6,8 +6,7 @@ description: This section describes service to service authentication works, bot --- :::info -This documentation is written for [the new backend -system](../backend-system/index.md) which is the default since Backstage +This documentation is written for [the new backend system](../backend-system/index.md) which is the default since Backstage [version 1.24](../releases/v1.24.0.md). If you are still on the old backend system, you may want to read [its own article](./service-to-service-auth--old.md) instead, and [consider migrating](../backend-system/building-backends/08-migrating.md)! diff --git a/docs/auth/vmware-cloud/provider.md b/docs/auth/vmware-cloud/provider.md index 0ff928ab7f..dd7c32f700 100644 --- a/docs/auth/vmware-cloud/provider.md +++ b/docs/auth/vmware-cloud/provider.md @@ -12,14 +12,11 @@ Cloud Console and within a Backstage app required to enable this capability. ## Create an OAuth App in the VMware Cloud Console 1. Log in to the [VMware Cloud Console](https://console.cloud.vmware.com). -1. Navigate to [Identity & Access Management > OAuth - Apps](https://console.cloud.vmware.com/csp/gateway/portal/#/consumer/usermgmt/oauth-apps) - and click the [Owned - Apps](https://console.cloud.vmware.com/csp/gateway/portal/#/consumer/usermgmt/oauth-apps/owned-apps/view) +1. Navigate to [Identity & Access Management > OAuth Apps](https://console.cloud.vmware.com/csp/gateway/portal/#/consumer/usermgmt/oauth-apps) + and click the [Owned Apps](https://console.cloud.vmware.com/csp/gateway/portal/#/consumer/usermgmt/oauth-apps/owned-apps/view) tab -- if you are not an Organization Owner or Administrator but only a Member, you will not see this nav entry unless the **Developer** check box is - selected for your role (see the [Organization roles and - permissions](https://docs.vmware.com/en/VMware-Cloud-services/services/Using-VMware-Cloud-Services/GUID-C11D3AAC-267C-4F16-A0E3-3EDF286EBE53.html#organization-roles-and-permissions-0) + selected for your role (see the [Organization roles and permissions](https://docs.vmware.com/en/VMware-Cloud-services/services/Using-VMware-Cloud-Services/GUID-C11D3AAC-267C-4F16-A0E3-3EDF286EBE53.html#organization-roles-and-permissions-0) docs for details). 1. Click **Create App**, choose 'Web/Mobile app' and click **Continue**. 1. Use default settings except: @@ -161,8 +158,7 @@ auth: ``` Where `APP_ID` refers to the ID retrieved when creating the OAuth App, and -`ORG_ID` is the [long ID of the -Organization](https://docs.vmware.com/en/VMware-Cloud-services/services/Using-VMware-Cloud-Services/GUID-CF9E9318-B811-48CF-8499-9419997DC1F8.html#view-the-organization-id-1) +`ORG_ID` is the [long ID of the Organization](https://docs.vmware.com/en/VMware-Cloud-services/services/Using-VMware-Cloud-Services/GUID-CF9E9318-B811-48CF-8499-9419997DC1F8.html#view-the-organization-id-1) in VMware Cloud for which you wish to enable sign-in. Note that VMware Cloud requires OAuth Apps to use @@ -180,6 +176,10 @@ This provider includes several resolvers out of the box that you can use: - `emailLocalPartMatchingUserEntityName`: Matches the [local part](https://en.wikipedia.org/wiki/Email_address#Local-part) of the email address from the auth provider with the User entity that has a matching `name`. If no match is found it will throw a `NotFoundError`. - `vmwareCloudSignInResolvers`: Matches the email address from the auth provider with the User entity that has a matching `spec.profile.email`. If no match is found it will sign in the user without associating with a catalog user. -> Note: The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: If these resolvers do not fit your needs you can build a custom resolver, this is covered in the [Building Custom Resolvers](../identity-resolver.md#building-custom-resolvers) section of the Sign-in Identities and Resolvers documentation. diff --git a/docs/backend-system/building-backends/01-index.md b/docs/backend-system/building-backends/01-index.md index 4caa6fd524..44aa0c7e28 100644 --- a/docs/backend-system/building-backends/01-index.md +++ b/docs/backend-system/building-backends/01-index.md @@ -6,8 +6,12 @@ sidebar_label: Overview description: Building backends using the new backend system --- -> NOTE: If you have an existing backend that is not yet using the new backend -> system, see [migrating](./08-migrating.md). +:::note Note + +If you have an existing backend that is not yet using the new backend +system, see [migrating](./08-migrating.md). + +::: This section covers how to set up and customize your own Backstage backend. It covers some aspects of how backend instances fit into the larger system, but for a more in-depth explanation of the role of backends in the backend system, see [the architecture section](../architecture/02-backends.md). diff --git a/docs/backend-system/building-backends/08-migrating.md b/docs/backend-system/building-backends/08-migrating.md index 0fbb368449..ae41193b11 100644 --- a/docs/backend-system/building-backends/08-migrating.md +++ b/docs/backend-system/building-backends/08-migrating.md @@ -201,10 +201,14 @@ const legacyPlugin = makeLegacyPlugin( After this, your backend will know how to instantiate your thing on demand and place it in the legacy plugin environment. -> NOTE: If you happen to be dealing with a service ref that does NOT have a -> default implementation, but rather has a separate service factory, then you -> will also need to import that factory and pass it to the `services` array -> argument of `createBackend`. +:::note Note + +If you happen to be dealing with a service ref that does NOT have a +default implementation, but rather has a separate service factory, then you +will also need to import that factory and pass it to the `services` array +argument of `createBackend`. + +::: ## Cleaning Up the Plugins Folder @@ -216,10 +220,14 @@ maintained by the Backstage maintainers, you may find that they have already been migrated to the new backend system. This section describes some specific such migrations you can make. -> NOTE: For each of these, note that your backend still needs to have a -> dependency (e.g. in `packages/backend/package.json`) to those plugin packages, -> and they still need to be configured properly in your app-config. Those -> mechanisms still work just the same as they used to in the old backend system. +:::note Note + +For each of these, note that your backend still needs to have a +dependency (e.g. in `packages/backend/package.json`) to those plugin packages, +and they still need to be configured properly in your app-config. Those +mechanisms still work just the same as they used to in the old backend system. + +::: ### The App Plugin @@ -452,7 +460,7 @@ catalog: /* highlight-add-end */ ``` -To migrate `GithubMultiOrgEntityProvider` and `GithubOrgEntityProvider` to the new backend system, add a reference to `@backstage/plugin-catalog-backend-module-github-org`. +To migrate `GithubMultiOrgEntityProvider` or `GithubOrgEntityProvider` to the new backend system, add a reference to `@backstage/plugin-catalog-backend-module-github-org`. ```ts title="packages/backend/src/index.ts" backend.add(import('@backstage/plugin-catalog-backend/alpha')); @@ -461,20 +469,79 @@ backend.add(import('@backstage/plugin-catalog-backend-module-github-org')); /* highlight-add-end */ ``` -If you were providing a `schedule` in code, this now needs to be set via configuration. -All other Github configuration in `app-config.yaml` remains the same. +##### GithubOrgEntityProvider + +If you were using `GithubOrgEntityProvider` you might have been configured in code like this: + +```ts title="packages/backend/src/plugins/catalog.ts" +// The org URL below needs to match a configured integrations.github entry +// specified in your app-config. +builder.addEntityProvider( + GithubOrgEntityProvider.fromConfig(env.config, { + id: 'production', + orgUrl: 'https://github.com/backstage', + logger: env.logger, + schedule: env.scheduler.createScheduledTaskRunner({ + frequency: { minutes: 60 }, + timeout: { minutes: 15 }, + }), + }), +); +``` + +This now needs to be set via configuration. The options defined above are now set in `app-config.yaml` instead as shown below: ```yaml title="app-config.yaml" catalog: + /* highlight-add-start */ providers: githubOrg: - yourProviderId: - # ... - /* highlight-add-start */ + - id: production + githubUrl: 'https://github.com', + orgs: ['backstage'] schedule: frequency: PT30M - timeout: PT3M - /* highlight-add-end */ + timeout: PT15M + /* highlight-add-end */ +``` + +##### GithubMultiOrgEntityProvider + +If you were using `GithubMultiOrgEntityProvider` you might have been configured in code like this: + +```ts title="packages/backend/src/plugins/catalog.ts" +// The GitHub URL below needs to match a configured integrations.github entry +// specified in your app-config. +builder.addEntityProvider( + GithubMultiOrgEntityProvider.fromConfig(env.config, { + id: 'production', + githubUrl: 'https://github.com', + // Set the following to list the GitHub orgs you wish to ingest from. You can + // also omit this option to ingest all orgs accessible by your GitHub integration + orgs: ['org-a', 'org-b'], + logger: env.logger, + schedule: env.scheduler.createScheduledTaskRunner({ + frequency: { minutes: 60 }, + timeout: { minutes: 15 }, + }), + }), +); +``` + +This now needs to be set via configuration. The options defined above are now set in `app-config.yaml` instead as shown below: + +```yaml title="app-config.yaml" +catalog: + /* highlight-add-start */ + providers: + githubOrg: + - id: production + githubUrl: 'https://github.com', + orgs: ['org-a', 'org-b'], + schedule: + frequency: PT30M + timeout: PT15M + /* highlight-add-end */ ``` If you were providing transformers, these can be configured by extending `githubOrgEntityProviderTransformsExtensionPoint` @@ -821,7 +888,11 @@ auth: - resolver: emailMatchingUserEntityAnnotation ``` -> Note: the resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. +:::note Note + +The resolvers will be tried in order, but will only be skipped if they throw a `NotFoundError`. + +::: #### Auth Plugin Modules and Their Resolvers @@ -1078,7 +1149,11 @@ backend.add(import('@backstage/plugin-search-backend/alpha')); /* highlight-add-end */ ``` -> Note: this will use the Lunr search engine which stores its index in memory +:::note Note + +This will use the Lunr search engine which stores its index in memory. + +::: #### Search Engines @@ -1167,7 +1242,11 @@ backend.add( /* highlight-add-end */ ``` -> Note: The above example includes a default allow-all policy. If that is not what you want, do not add the second line and instead investigate one of the options below. +:::note Note + +The above example includes a default allow-all policy. If that is not what you want, do not add the second line and instead investigate one of the options below. + +::: #### Custom Permission Policy diff --git a/docs/backend-system/building-plugins-and-modules/01-index.md b/docs/backend-system/building-plugins-and-modules/01-index.md index 168646afab..1aa8b140ed 100644 --- a/docs/backend-system/building-plugins-and-modules/01-index.md +++ b/docs/backend-system/building-plugins-and-modules/01-index.md @@ -73,8 +73,7 @@ items. Backend modules are used to extend [plugins](../architecture/04-plugins.md) or other modules with additional features or change existing behavior. They must always be installed in the same backend instance as the plugin or module that they extend, and may only extend a single plugin and modules from that plugin at a time. -Modules interact with their target plugin or module using the [extension -points](../architecture/05-extension-points.md) registered by the plugin, while also being +Modules interact with their target plugin or module using the [extension points](../architecture/05-extension-points.md) registered by the plugin, while also being able to depend on the [services](../architecture/03-services.md) of the target plugin. That last point is worth reiterating: injected `plugin` scoped services will be the exact @@ -157,8 +156,7 @@ the database. They will run on the same logical database instance as the target plugin, so care must be taken to choose table names that do not risk colliding with those of the plugin. A recommended naming pattern is `__`, for example the `@backstage/backend-tasks` package creates -tables named `backstage_backend_tasks__
`. If you use the default [`Knex` -migration facilities](https://knexjs.org/guide/migrations.html), you will also +tables named `backstage_backend_tasks__
`. If you use the default [`Knex` migration facilities](https://knexjs.org/guide/migrations.html), you will also want to make sure that it uses similarly prefixed migration state tables for its internal bookkeeping needs, so they do not collide with the main ones used by the plugin itself. You can do this as follows: @@ -179,8 +177,7 @@ There are several ways of configuring and customizing plugins and modules. Whenever you want to allow modules to configure your plugin dynamically, for example in the way that the catalog backend lets catalog modules inject additional entity providers, you can use the extension points mechanism. This is -described in detail with code examples in [the extension points architecture -article](../architecture/05-extension-points.md), while the following is a more +described in detail with code examples in [the extension points architecture article](../architecture/05-extension-points.md), while the following is a more slim example of how to implement an extension point for a plugin: ```ts @@ -249,7 +246,5 @@ export const examplePlugin = createBackendPlugin({ }); ``` -Before adding custom configuration options, make sure to read [the configuration -docs](../../conf/index.md), in particular the section on [defining configuration -for your own plugins](../../conf/defining.md) which explains how to establish a +Before adding custom configuration options, make sure to read [the configuration docs](../../conf/index.md), in particular the section on [defining configuration for your own plugins](../../conf/defining.md) which explains how to establish a configuration schema for your specific plugin. diff --git a/docs/backend-system/building-plugins-and-modules/02-testing.md b/docs/backend-system/building-plugins-and-modules/02-testing.md index f8af2bcabe..8a2dd0414d 100644 --- a/docs/backend-system/building-plugins-and-modules/02-testing.md +++ b/docs/backend-system/building-plugins-and-modules/02-testing.md @@ -21,8 +21,7 @@ collective term for backend [plugins](../architecture/04-plugins.md) and The function returns an HTTP server instance which can be used together with e.g. `supertest` to easily test the actual REST service surfaces of plugins who -register routes with [the HTTP router service -API](../core-services/01-index.md). +register routes with [the HTTP router service API](../core-services/01-index.md). ```ts import { mockServices, startTestBackend } from '@backstage/backend-test-utils'; diff --git a/docs/deployment/docker.md b/docs/deployment/docker.md index 9ec5460a88..f16a2ad13e 100644 --- a/docs/deployment/docker.md +++ b/docs/deployment/docker.md @@ -141,8 +141,12 @@ browser at `http://localhost:7007` ## Multi-stage Build -> NOTE: The `.dockerignore` is different in this setup, read on for more -> details. +:::note Note + +The `.dockerignore` is different in this setup, read on for more +details. + +::: This section describes how to set up a multi-stage Docker build that builds the entire project within Docker. This is typically slower than a host build, but is @@ -293,10 +297,14 @@ browser at `http://localhost:7007` ## Separate Frontend -> NOTE: This is an optional step, and you will lose out on the features of the -> `@backstage/plugin-app-backend` plugin. Most notably the frontend configuration -> will no longer be injected by the backend, you will instead need to use the -> correct configuration when building the frontend bundle. +:::note Note + +This is an optional step, and you will lose out on the features of the +`@backstage/plugin-app-backend` plugin. Most notably the frontend configuration +will no longer be injected by the backend, you will instead need to use the +correct configuration when building the frontend bundle. + +::: It is sometimes desirable to serve the frontend separately from the backend, either from a separate image or for example a static file serving provider. The diff --git a/docs/deployment/index.md b/docs/deployment/index.md index da2c29ba23..0524e71db8 100644 --- a/docs/deployment/index.md +++ b/docs/deployment/index.md @@ -13,8 +13,12 @@ This documentation shows common examples that may be useful when deploying Backstage for the first time, or for those without established deployment practices. -> Note: The _easiest_ way to explore Backstage is to visit the -> [live demo site](https://demo.backstage.io). +:::note Note + +The _easiest_ way to explore Backstage is to visit the +[live demo site](https://demo.backstage.io). + +::: At Spotify, we deploy software generally by: diff --git a/docs/deployment/k8s.md b/docs/deployment/k8s.md index 00bf7464e3..46ba273e14 100644 --- a/docs/deployment/k8s.md +++ b/docs/deployment/k8s.md @@ -107,10 +107,14 @@ $ echo -n "backstage" | base64 YmFja3N0YWdl ``` -> Note: Secrets are base64-encoded, but not encrypted. Be sure to enable -> [Encryption at Rest](https://kubernetes.io/docs/tasks/administer-cluster/encrypt-data/) -> for the cluster. For storing secrets in Git, consider -> [SealedSecrets or other solutions](https://learnk8s.io/kubernetes-secrets-in-git). +:::note Note + +Secrets are base64-encoded, but not encrypted. Be sure to enable +[Encryption at Rest](https://kubernetes.io/docs/tasks/administer-cluster/encrypt-data/) +for the cluster. For storing secrets in Git, consider +[SealedSecrets or other solutions](https://learnk8s.io/kubernetes-secrets-in-git). + +::: The secrets can now be applied to the Kubernetes cluster: diff --git a/docs/features/kubernetes/configuration.md b/docs/features/kubernetes/configuration.md index 064f7c803c..0002e51160 100644 --- a/docs/features/kubernetes/configuration.md +++ b/docs/features/kubernetes/configuration.md @@ -198,8 +198,7 @@ in namespace `NAMESPACE` and it has adequate [permissions](#role-based-access-control), here are some sample procedures to procure a long-lived service account token for use with this provider: -- On versions of Kubernetes [prior to - 1.24](https://github.com/kubernetes/kubernetes/blob/master/CHANGELOG/CHANGELOG-1.24.md#no-really-you-must-read-this-before-you-upgrade-1), +- On versions of Kubernetes [prior to 1.24](https://github.com/kubernetes/kubernetes/blob/master/CHANGELOG/CHANGELOG-1.24.md#no-really-you-must-read-this-before-you-upgrade-1), you could get an (automatically-generated) token for a service account with: ```sh @@ -209,8 +208,7 @@ procure a long-lived service account token for use with this provider: | base64 --decode ``` -- For Kubernetes 1.24+, as described in [this - guide](https://kubernetes.io/docs/concepts/configuration/secret/#service-account-token-secrets), +- For Kubernetes 1.24+, as described in [this guide](https://kubernetes.io/docs/concepts/configuration/secret/#service-account-token-secrets), you can obtain a long-lived token by creating a secret: ```sh @@ -235,8 +233,7 @@ procure a long-lived service account token for use with this provider: If a cluster has `authProvider: serviceAccount` and the `serviceAccountToken` field is omitted, Backstage will ignore the configured URL and certificate data, instead attempting to access the Kubernetes API via an in-cluster client as in -[this -example](https://github.com/kubernetes-client/javascript/blob/master/examples/in-cluster.js). +[this example](https://github.com/kubernetes-client/javascript/blob/master/examples/in-cluster.js). ##### `clusters.\*.oidcTokenProvider` (optional) diff --git a/docs/features/kubernetes/proxy.md b/docs/features/kubernetes/proxy.md index 4ccc2d22b1..2da797d8ef 100644 --- a/docs/features/kubernetes/proxy.md +++ b/docs/features/kubernetes/proxy.md @@ -7,12 +7,10 @@ description: Interacting with the Kubernetes API in Backstage plugins [Contributors](https://backstage.io/docs/overview/glossary#backstage-user-profiles) wanting to create developer portal experiences based on data from Kubernetes (e.g. for -interacting with [Custom -Resources](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/) +interacting with [Custom Resources](https://kubernetes.io/docs/concepts/extend-kubernetes/api-extension/custom-resources/) beyond the default behaviors of the existing Kubernetes plugin) can leverage the Kubernetes backend plugin's proxy endpoint to allow them to make arbitrary -requests to the [REST -API](https://kubernetes.io/docs/reference/using-api/api-concepts/). +requests to the [REST API](https://kubernetes.io/docs/reference/using-api/api-concepts/). Here is a snippet fetching namespaces using the `KubernetesBackendClient` library @@ -31,8 +29,7 @@ await kubernetesApi.proxy(CLUSTER_NAME, '/api/v1/namespaces'); The proxy will interpret the [`Backstage-Kubernetes-Cluster`](https://backstage.io/docs/reference/plugin-kubernetes-backend.header_kubernetes_cluster) header as the name of the cluster to target. This name will be compared to each cluster -returned by all the configured [cluster -locators](https://backstage.io/docs/features/kubernetes/configuration#clusterlocatormethods) +returned by all the configured [cluster locators](https://backstage.io/docs/features/kubernetes/configuration#clusterlocatormethods) -- the first cluster whose [`name` field](https://backstage.io/docs/features/kubernetes/configuration#clustersname) matches the value in the header will be targeted. @@ -48,12 +45,10 @@ The proxy expects a `KubernetesAuthTranslator` to be provided that is used to de ## Authentication The proxy has no provisions for mTLS, so it cannot be used to connect to -clusters using the [x509 Client -Certs](https://kubernetes.io/docs/reference/access-authn-authz/authentication/#x509-client-certs) +clusters using the [x509 Client Certs](https://kubernetes.io/docs/reference/access-authn-authz/authentication/#x509-client-certs) authentication strategy.\ The current `/proxy` Implementation expects a -[Bearer -token](https://kubernetes.io/docs/reference/access-authn-authz/authentication/#putting-a-bearer-token-in-a-request) +[Bearer token](https://kubernetes.io/docs/reference/access-authn-authz/authentication/#putting-a-bearer-token-in-a-request) to be provided as a `Backstage-Kubernetes-Authorization` header for a target cluster. This token will be used as the `Authorization` header when forwarding a request to a target cluster. ## How to disable the proxy endpoint via PermissionPolicy @@ -104,8 +99,7 @@ even if a valid ID token was attached that a cluster would authorize. ## Other known limitations -The proxy as it was released in [Backstage -1.9](https://github.com/backstage/backstage/blob/master/docs/releases/v1.9.0-changelog.md#patch-changes-15) +The proxy as it was released in [Backstage 1.9](../../releases/v1.9.0-changelog.md#patch-changes-15) has a known bug: - [#15901](https://github.com/backstage/backstage/issues/15901) - it cannot diff --git a/docs/features/software-catalog/index.md b/docs/features/software-catalog/index.md index c98d6911b4..a65bfb4a44 100644 --- a/docs/features/software-catalog/index.md +++ b/docs/features/software-catalog/index.md @@ -40,8 +40,7 @@ browse the catalog at `http://localhost:3000`. ## Adding components to the catalog -The source of truth for the components in your software catalog are [metadata -YAML files](descriptor-format.md) stored in source control (GitHub, GitHub +The source of truth for the components in your software catalog are [metadata YAML files](descriptor-format.md) stored in source control (GitHub, GitHub Enterprise, GitLab, ...). Repositories can include one or multiple metadata files. Usually the metadata file is located in the repository root. This is not a formal requirement & metadata files can be placed anywhere in the repository. diff --git a/docs/features/software-catalog/system-model.md b/docs/features/software-catalog/system-model.md index af359bb18a..ee7270a960 100644 --- a/docs/features/software-catalog/system-model.md +++ b/docs/features/software-catalog/system-model.md @@ -120,6 +120,9 @@ product or use-case, share the same entity types in their APIs, and integrate well with each other. Other domains could be “Content Ingestion”, “Ads” or “Search”. +In case of a large organization, it might make sense to further group domains +in a hierarchy, where a domain can be a subdomain of another domain. + ## Other ### Location diff --git a/docs/features/software-templates/index.md b/docs/features/software-templates/index.md index d0c1bea9b2..9642214ede 100644 --- a/docs/features/software-templates/index.md +++ b/docs/features/software-templates/index.md @@ -103,3 +103,17 @@ from `backstage/packages/app/src/App.tsx`: ``` After the change, you should no longer see the button. + +## Previewing and Executing Previous Template Tasks + +Each execution of a template is treated as a unique task, identifiable by its own unique ID. To view a list of previously executed template tasks, navigate to the "Create" page and access the "Task List" from the context menu (represented by the vertical ellipsis, or 'kebab menu', icon in the upper right corner). + +![Template Task List](../../assets/software-templates/template-task-list.png) + +If you wish to re-run a previously executed template, navigate to the template tasks page. Locate the desired task and select the "Start Over" option from the context menu. + +![Template Start Over](../../assets/software-templates/template-start-over.png) + +This action will initiate a new execution of the selected template, pre-populated with the same parameters as the previous run, but these parameters can be edited before re-execution. + +In the event of a failed template execution, the "Start Over" option can be used to re-execute the template. The parameters from the original run will be pre-filled, but they can be adjusted as needed before retrying the template. diff --git a/docs/frontend-system/architecture/05-extension-overrides.md b/docs/frontend-system/architecture/05-extension-overrides.md index 21028627bc..41702e6823 100644 --- a/docs/frontend-system/architecture/05-extension-overrides.md +++ b/docs/frontend-system/architecture/05-extension-overrides.md @@ -22,10 +22,10 @@ In order to override an app extension, you must create a new extension and add i In the example below, we create a file that exports custom extensions for the app's `light` and `dark` themes: -```tsx title="packages/app/src/themes.ts" +```tsx title="packages/app/src/themes.tsx" import { createThemeExtension, - createExtensionOverrides + createExtensionOverrides, } from '@backstage/frontend-plugin-api'; import { apertureThemes } from './themes'; import { ApertureLightIcon, ApertureDarkIcon } from './icons'; @@ -59,8 +59,8 @@ const apertureDarkTheme = createThemeExtension({ }); // Creating an extension overrides preset -export createExtensionOverrides({ - extensions: [apertureLightTheme, apertureDarkTheme] +export default createExtensionOverrides({ + extensions: [apertureLightTheme, apertureDarkTheme], }); ``` @@ -96,8 +96,11 @@ We recommend that plugin developers share the extension IDs in their plugin docu Imagine you have a plugin with the ID `'search'`, and the plugin provides a page extension that you want to fully override with your own custom component. To do so, you need to create your page extension with an explicit `namespace` option that matches that of the plugin that you want to override, in this case `'search'`. If the existing extension also has an explicit `name` you'd need to set the `name` of your override extension to the same value as well. -```tsx title="packages/app/src/search.ts" -import { createPageExtension } from '@backstage/frontend-plugin-api'; +```tsx title="packages/app/src/search.tsx" +import { + createPageExtension, + createExtensionOverrides, +} from '@backstage/frontend-plugin-api'; // Creating a custom search page extension const customSearchPage = createPageExtension({ @@ -108,7 +111,7 @@ const customSearchPage = createPageExtension({ loader: () => import('./SearchPage').then(m => m.), }); -export createExtensionOverrides({ +export default createExtensionOverrides({ extensions: [customSearchPage] }); ``` @@ -137,7 +140,7 @@ Sometimes you just need to quickly create a new extension and not overwrite an a Imagine you want to create a page that is currently only used by your application, like an Institutional page, for example. You can use overrides to extend the Backstage app to render it. To do so, simply create a page extension and pass it to the app as an override: -```tsx title="packages/app/src/App.ts" +```tsx title="packages/app/src/App.tsx" import { createApp } from '@backstage/frontend-app-api'; import { createPageExtension, diff --git a/docs/integrations/github/locations.md b/docs/integrations/github/locations.md index 7d3ce632d6..ae83b38e1e 100644 --- a/docs/integrations/github/locations.md +++ b/docs/integrations/github/locations.md @@ -28,9 +28,11 @@ integrations: token: ${GHE_TOKEN} ``` -> Note: A public GitHub provider is added automatically at startup for -> convenience, so you only need to list it if you want to supply a -> [token](https://docs.github.com/en/github/authenticating-to-github/creating-a-personal-access-token). +:::note Note + +A public GitHub provider is added automatically at startup for convenience, so you only need to list it if you want to supply a [token](https://docs.github.com/en/github/authenticating-to-github/creating-a-personal-access-token). + +::: Directly under the `github` key is a list of provider configurations, where you can list the various GitHub-compatible providers you want to be able to fetch diff --git a/docs/integrations/github/org--old.md b/docs/integrations/github/org--old.md index 2f1b39a1f8..3d1639a924 100644 --- a/docs/integrations/github/org--old.md +++ b/docs/integrations/github/org--old.md @@ -308,8 +308,7 @@ const githubOrgProvider = GithubOrgEntityProvider.fromConfig(env.config, { }); ``` -Once you have imported the emails you can resolve users in your [sign-in -resolver](../../auth/github/provider.md) using the catalog entity search via email +Once you have imported the emails you can resolve users in your [sign-in resolver](../../auth/github/provider.md) using the catalog entity search via email ```typescript title="packages/backend/src/plugins/auth.ts" ctx.signInWithCatalogUser({ diff --git a/docs/integrations/github/org.md b/docs/integrations/github/org.md index 0b33cfa184..06b4e07daa 100644 --- a/docs/integrations/github/org.md +++ b/docs/integrations/github/org.md @@ -45,7 +45,7 @@ Next add the basic configuration to `app-config.yaml` catalog: providers: githubOrg: - id: github + id: production githubUrl: https://github.com orgs: ['organization-1', 'organization-2', 'organization-3'] schedule: @@ -90,7 +90,7 @@ Directly under the `githubOrg` is a list of configurations, each entry is a stru - `id`: A stable id for this provider. Entities from this provider will be associated with this ID, so you should take care not to change it over time since that may lead to orphaned entities and/or conflicts. - `githubUrl`: The target that this provider should consume -- `orgs` (optional): The list of the GitHub orgs to consume. By default wil consume all accessible orgs on the given GitHub instance (support for GitHub App integration only). +- `orgs` (optional): The list of the GitHub orgs to consume. If you only list a single org the generated group entities will use the `default` namespace, otherwise they will use the org name as the namespace. By default the provider will consume all accessible orgs on the given GitHub instance (support for GitHub App integration only). - `schedule`: The refresh schedule to use, matches the structure of [`TaskScheduleDefinitionConfig`](https://backstage.io/docs/reference/backend-tasks.taskscheduledefinitionconfig/) ### Events Support diff --git a/docs/integrations/gitlab/locations.md b/docs/integrations/gitlab/locations.md index a71fc9bcba..f5995a3ac1 100644 --- a/docs/integrations/gitlab/locations.md +++ b/docs/integrations/gitlab/locations.md @@ -19,9 +19,11 @@ integrations: token: ${GITLAB_TOKEN} ``` -> Note: A public GitLab provider is added automatically at startup for -> convenience, so you only need to list it if you want to supply a -> [token](https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html). +:::note Note + +A public GitLab provider is added automatically at startup for convenience, so you only need to list it if you want to supply a [token](https://docs.gitlab.com/ee/user/profile/personal_access_tokens.html). + +::: Directly under the `gitlab` key is a list of provider configurations, where you can list the GitLab providers you want to fetch data from. Each entry is a diff --git a/docs/overview/roadmap.md b/docs/overview/roadmap.md index 8e3d73ded6..1a41eedd63 100644 --- a/docs/overview/roadmap.md +++ b/docs/overview/roadmap.md @@ -6,93 +6,87 @@ description: Roadmap of Backstage ## The Backstage Roadmap -Backstage is currently under rapid development. This page details the project's -public roadmap, the result of ongoing collaboration between the core maintainers -and the broader Backstage community. +Backstage is still under rapid development, and this page details the project's +public roadmap. This not a complete list of all work happening in and around the +project, it only highlights the highest priority initiatives worked on by the +core maintainers. -The Backstage roadmap lays out both [“what's next”](#whats-next) and ["future -work"](#future-work). With "next" we mean features planned for release within -the ongoing quarter from July through September 2022. With "future" we mean -features on the radar, but not yet scheduled. +## 2024 Fall Roadmap -| [What's next](#whats-next) | [Future work](#future-work) | -| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------- | -| [Backend Services (MVP)](#backend-services-mvp)
[Backstage Security Audit](#backstage-security-audit)
[Backstage Threat Model](#backstage-threat-model)
[Software Catalog pagination](#software-catalog-pagination)
[More SIGs](#more-sigs) | Ease of onboarding
Composable Homepage 1.0
Creator experience
GraphQL
Telemetry | +The initiatives listed below are planned for release within the next half-year, starting in May 2024. The roadmap is updated every 6 months, and the next update is planned for November 2024. -The long-term roadmap (12 - 36 months) is not detailed in the public roadmap. -Third-party contributions are also not currently included in the roadmap. Let us -know about any ongoing developments and we're happy to include them here as -well. +### Backend System 1.0 -## What's next +The goal of this initiative is the stable 1.0 release of the [new backend system](../backend-system/index.md). +This includes ensuring that all documentation is up to date, and includes API +reviews and refactoring efforts to ensure that what is released is both stable +and evolvable. You can follow along with this work in the [meta issue](https://github.com/backstage/backstage/issues/24493). -The feature set below is planned for the ongoing quarter, and grouped by theme. -The list order doesn't necessarily reflect priority, and the development/release -cycle will vary based on maintainer schedules. +As part of this initiative, there will also be an exploration on how to +simplify extension of backend services. It is not currently possible to augment +backend services through declarative integration, they are instead only +customizable through complete replacement. This also limits the ability to +modularize services and scale ownership of the implementations. The goal is to +provide a more flexible and scalable way to extend backend services. -### Backend Services (MVP) +### New Frontend System - Ready for Adoption -To better scale and maintain the Backstage instances, a backend services system -is planned to be introduced as part of the software architecture. This layer of -backend services will help in decoupling the various modules (e.g. Catalog and -Scaffolder) from the frontend experience. +The [new fronted system](../frontend-system/index.md) still needs more work, and +the next milestone is to improve it to the point where there is enough +confidence in the design to start encouraging adoption in the community. You can +follow along with this work in the [meta issue](https://github.com/backstage/backstage/issues/19545). +This milestone also includes reaching and executing [rollout phase 2](https://github.com/backstage/backstage/issues/19545#issuecomment-1766069146). -After the experimentation and design happened in the past quarter, soon we plan to release a first version to start providing the first benefits to adopters and developers. +Once the initial milestone is reached, the goal is to also build out broader +support for the new frontend system in the core plugins. ### Backstage Security Audit -This is the continuation of the initiative started in the previous quarters. This -quarter will see the publication of the report describing the outcome of the -audit, together the first fixes and the development of some of the changes -required to address the vulnerabilities. +This is the second security audit of the Backstage project. It is done together, +and with the support of the [Cloud Native Computing Foundation (CNCF)](https://www.cncf.io/). +This time the audit will in particular focus on the recently introduced +[authentication system](https://github.com/backstage/backstage/tree/master/beps/0003-auth-architecture-evolution), +but also cover other parts of the project. -This initiative is the first of a broader Security Strategy for Backstage. The -purpose of the Security Audit is to involve third-party companies in auditing -the platform. The benefit for the adopters is clear: we want Backstage to be as -secure as possible, and we want to make it reliable through a specific -initiative. +### Plugin Metadata -This initiative is done together with, and with the support of, the [Cloud -Native Computing Foundation (CNCF)](https://www.cncf.io/). +The goal of this initiative is to provide better machine readable metadata for +Backstage packages, available both at runtime, at build-time and as part of +package registries. We want to surface information such as what packages make up +a particular plugin, what features it provides, and more generally laying the +foundation for an evolvable plugin metadata system. -### Backstage Threat Model +### MUI v5 Green-light -This is another (relevant) initiative planned to make Backstage a secure product for the adopters. The goals of this initiative are: +Material-UI v4 is still the officially supported version of MUI in Backstage. +While we have heard that adopters have had success using MUI 5, this is still an +untested path with known bugs. The goal of this initiative is to iron out any +remaining issues or gaps, and then provide a green light for migration to MUI 5. -1. Understand where security investment and attention is needed. -2. Guide the upcoming security audit. -3. Communicate expectations to Backstage adopters and inform and attract security researchers. +### Configuration Improvements -The planned artifacts are: +This initiative aims to improve the configuration experience and reliability in +Backstage. Areas for improvement include the way that configuration schema is +loaded, the way that plugins access configuration that is not owned by them, how +plugins read configuration, and how configuration visibility is handled. -- Concise high level threat model that will be included as part of the Backstage security documentation. -- Granular threat model created in conjunction with the security audit to inform further security investment areas for Backstage. +### Versioned Documentation -### Software Catalog pagination +The goal of this initiative is to provide versioned documentation at +[backstage.io](https://backstage.io). This lets us provide documentation that is +both up-to-date while at the same time not ahead of the latest release. -Today adopters with a big catalog (with several thousands of software components) might not have an ideal end-user experience when viewing the `/catalog` page. The issue is related to how the entities are fetched by the frontend. In order to provide a better end-user experience the pagination of the catalog’s entities needs to be enforced. Some experimentation is already completed but in this quarter we plan to continue, and hopefully complete, this relevant enhancement. +### Rework Pull Request & Issue Process -### More SIGs +Our current review and issue triage process is centered around either core- or +project area maintainers. The goal of this initiative is to make it simpler for +more members of the community to be involved and contribute to this process. -In the last quarter we launched the [Catalog SIG (Special Interest Group)](https://github.com/backstage/community/tree/main/sigs/sig-catalog) to better coordinate the increasing number of contributions to the project. We think that this is the proper path to follow to engage more with the contributors. For this reason we will launch other SIGs dedicated to the most interesting topics for the community. +### Catalog Observability -## Future work - -The following feature list doesn't represent a commitment to develop, and the -list order doesn't reflect any priority or importance, but these features are on -the maintainers' radar, with clear interest expressed by the community. - -- **Ease of onboarding:** A faster (with less development) and easier setup of - Backstage and the most relevant/adopted plugins. -- **Composable Homepage 1.0:** Driving this to 1.0 by adding some composable - components. -- **Creator experience:** Provide a better Backstage user experience through - visual guidelines and templates, especially navigation across plug-ins and - portal functionalities. -- **[GraphQL](https://graphql.org/) support:** Introduce the ability to query - Backstage backend services with a standard query language for APIs. -- **Telemetry:** To efficiently generate logging and metrics in such a way that - adopters can get insights so that Backstage can be monitored and improved. +The goal of this initiative is to provide better tools for debugging catalog +ingestion issues and to more generally reduce friction for setting up and +maintaining the software catalog. ## How to influence the roadmap diff --git a/docs/overview/threat-model.md b/docs/overview/threat-model.md index 442d51985c..da97f3fc83 100644 --- a/docs/overview/threat-model.md +++ b/docs/overview/threat-model.md @@ -14,21 +14,28 @@ The Backstage trust model is divided into three groups with different trust leve An **internal user** is an authenticated user that generally belongs to the organization of a particular Backstage deployment. These users are trusted to the extent that they are not expected to compromise the availability of Backstage, but they are not trusted to not compromise data confidentiality or integrity. -An **integrator** is a user responsible for configuring and maintaining an instance of Backstage. Integrators are fully trusted, since they operate the system and database and therefore have root access to the host system. Additional measures can be taken by adopters of Backstage in order to restrict or observe the access of this group, but that falls outside of the current scope of Backstage. +An **operator** is a user responsible for configuring and maintaining an instance of Backstage. Operators are fully trusted, since they operate the system and database and therefore have root access to the host system. Additional measures can be taken by adopters of Backstage in order to restrict or observe the access of this group, but that falls outside of the current scope of Backstage. -Another group of de facto integrators is internal and external code contributors. When installing Backstage plugins you should vet them just like any other package from an external source. While it’s possible to limit the impact of for example a supply chain attack by splitting the deployment into separate services with different plugins, the Backstage project itself does not aim to prevent these kinds of attacks or in any other way sandbox or limit the access of plugins. +A **builder** is an internal or external code contributor and end up having a similar level of access as operators. When installing Backstage plugins you should vet them just like any other package from an external source. While it’s possible to limit the impact of for example a supply chain attack by splitting the deployment into separate services with different plugins, the Backstage project itself does not aim to prevent these kinds of attacks or in any other way sandbox or limit the access of plugins. An **external user** is a user that does not belong to the other two groups, for example a malicious actor outside of the organization. The security model of Backstage currently assumes that this group does not have any direct access to Backstage, and it is the responsibility of each adopter of Backstage to make sure this is the case. -## Integrator Responsibilities +## Operator Responsibilities -As an integrator of Backstage you yourself are responsible for protecting your Backstage installation from external and unauthorized access. The sign-in system in Backstage does not exist to limit access, only to inform the system of the identity of the user. There are some plugins that have more fine-grained access control through the permissions system, but the primary purpose of that system is to restrict access to resources for internal users rather than Backstage as a whole. A common and recommended way to protect a Backstage deployment from unauthorized access is to deploy it behind an authenticating proxy such as AWS’s ALB, GCP’s IAP, or Cloudflare Access. +:::info +This section assumes that you are using the +[new backend system](../backend-system/index.md) and at least Backstage release [version 1.24](../releases/v1.24.0.md). Before that Backstage did not come with built-in protection against unauthorized access and you were required to deploy it in a protected environment. +::: -Other responsibilities include protecting the integrity of configuration files as it may otherwise be possible to introduce vulnerable configurations, as well as the confidentiality of configured secrets related to Backstage as these typically include authentication details to third party systems. +Backstage is primarily designed to be deployed in a protected environment rather than being exposed to the public internet. From a confidentiality and integrity perspective, Backstage is designed to protect against unauthorized access to data and to ensure that data is not tampered with. However, Backstage does not provide more than rudimentary protection against denial of service attacks, and it is the responsibility of the operator to ensure that the Backstage deployment is protected against such attacks. A common and recommended way to protect a Backstage deployment from unauthorized access is to deploy it behind an authenticating proxy such as AWS’s ALB, GCP’s IAP, or Cloudflare Access. -The integrator is ultimately responsible for auditing usage of internal and external plugins as these run on the host system and have access to configuration and secrets. When installing plugins from sources like NPM, you should vet these in the same way that you would vet any other package installed from that source. +Users that are signed-in in to Backstage generally have full access to all information and actions. If more fine-grained control is required, the [permissions system](../permissions/overview.md) should be enabled and configured to restrict access as necessary. -The integrator is also responsible for maintaining the resolved NPM dependencies of their Backstage project. This involves ensuring that `yarn.lock` receives updated versions of packages that have vulnerabilities, when those fixed versions are in range of what the Backstage packages request in their respective `package.json` files. This is commonly done by employing automated tooling such as [Dependabot](https://dependabot.com/), [Snyk](https://snyk.io/), and/or [Renovate](https://docs.renovatebot.com/) on your own repository. When fixed versions exist that are _not_ in range of what Backstage packages request, or when larger operations such as switching out an entire dependency for another one is required, maintainers collaborate with contributors to try to address those dependency declarations in the main project as soon as possible. +An operator is responsible for protecting the integrity of configuration files as it may otherwise be possible to introduce vulnerable configurations, as well as the confidentiality of configured secrets related to Backstage as these typically include authentication details to third party systems. + +The operator is ultimately responsible for auditing usage of internal and external plugins as these run on the host system and have access to configuration and secrets. When installing plugins from sources like NPM, you should vet these in the same way that you would vet any other package installed from that source. + +The operator is also responsible for maintaining the resolved NPM dependencies of their Backstage project. This involves ensuring that `yarn.lock` receives updated versions of packages that have vulnerabilities, when those fixed versions are in range of what the Backstage packages request in their respective `package.json` files. This is commonly done by employing automated tooling such as [Dependabot](https://dependabot.com/), [Snyk](https://snyk.io/), and/or [Renovate](https://docs.renovatebot.com/) on your own repository. When fixed versions exist that are _not_ in range of what Backstage packages request, or when larger operations such as switching out an entire dependency for another one is required, maintainers collaborate with contributors to try to address those dependency declarations in the main project as soon as possible. ## Common Backend Configuration @@ -44,21 +51,23 @@ Note that the `UrlReader` system operates with a service context and is not inte Backstage provides authentication of users through the `auth` plugin, which primarily acts as an authorization server for different OAuth 2.0 provider integrations. These integrations can both serve the purpose of signing users into Backstage, as well as providing delegated access to external resources, and are all subject to the common concerns of implementing secure OAuth 2.0 authorization servers. All auth provider integrations are disabled by default, and need to be enabled through configuration in order to be used. For each Backstage installation it is recommended to only enable the minimal set of providers that are in use by that instance. -It is not within scope of the `auth` backend to protect against unauthorized access, that is something that needs to be handled at a deployment level. See the [Integrator Responsibilities](#integrator-responsibilities) section for more information. - In order to use an auth provider to sign in users into Backstage, it needs to be configured with an [Identity resolver](https://backstage.io/docs/auth/identity-resolver), which is a custom callback implemented in code. The identity resolver is a sensitive part of configuring Backstage and it is important that it always resolves user identities correctly, based on information provided by the authentication provider. There are a number of built-in identity resolvers that can simplify configuration, and it is important that these all resolve users in a secure way, regardless of how they are used. +Backstage also supports authentication through an authenticating reverse proxy such as [AWS ALB](https://aws.amazon.com/elasticloadbalancing/application-load-balancer/), where the user identity is read from the incoming proxied decorated request. The following proxy auth providers verify the signature of incoming requests, and are therefore safe to deploy with direct access by users: `awsAlb`, `cfAccess`, and `gcpIap`. Providers like `oauth2Proxy` do not verify the incoming request and can therefore be spoofed by a malicious internal user to supply the `auth` backend with forged identity information. It’s therefore highly recommended to restrict access to the `oauth2Proxy` endpoints, or use a different provider. + As part of signing in with an identity resolver, a Backstage Token is issued containing the resolved user identity. The tokens are asymmetrically signed JSON Web Tokens, with the public keys available to any service that wishes to verify a token. The signing keys are rotated continuously and are unique to each installation of Backstage, meaning that Backstage Tokens are not shared across installations. The token contains claims for the user identity and ownership information, which can be used to determine what Backstage resources are owned by that user or group. It is important that this token can not be forged outside of the `auth` plugin, with the exception of other plugins deployed in the same backend service or sharing the same database. For a high-security deployment, the `auth` backend should therefore be deployed in a separate service with its own database. The token is used to prove the identity of the user within the Backstage system, and is used throughout Backstage plugins to control access. It is important that the ownership resolution logic is consistent across the entire Backstage ecosystem, with no possibility of misinterpreting the ownership information. -For cross-backend communication, the Backstage Token is typically forwarded or, in strict backend-to-backend communication without a user party, the backend itself issues a service token based on a pre-shared secret which is then validated on the receiving end. There are no unique service identities tied to these tokens at this point, meaning the tokens can be used across all services in a Backstage installation. This is something that we aim to improve in the future. +One of the claims in a user token is the User Identity Proof or `uip`. This is an additional signature of the token that allows for offline token transformation. By replacing the original signature with the `uip` the token is still proof of a user identity, but it no longer acts as a full access token and will be rejected by most plugin endpoints. Plugins can explicitly allow use of this limited token where required, but this should only be used when necessary when a full token is not available, and ideally just for read-only access. Use-cases for limited users tokens include cookie authentication of static assets, storage of user identity proofs in a database, and similar. -Backstage also supports authentication through a proxy where the user identity is read from the incoming request from the proxy, which has been decorated by an authenticating reverse proxy such as [AWS ALB](https://aws.amazon.com/elasticloadbalancing/application-load-balancer/). The following proxy auth providers verify the signature of incoming requests, and are therefore safe to deploy with direct access by users: `awsAlb`, `cfAccess`, and `gcpIap`. Providers like `oauth2Proxy` does not verify the incoming request and can therefore be spoofed by a malicious internal user to supply the `auth` backend with forged identity information. It’s therefore highly recommended to restrict access to the `oauth2Proxy` endpoints, or use a different provider. +The communication across backend plugins uses a similar authentication scheme to the user authentication. Each backend plugin generates and publishes its own set of keys that it uses to sign its tokens, and the public keys are shared with all other plugins for verification. The expected location of each plugin's published JWKS is determined by the `DiscoveryService` implementation in the backend, which means that it is vital for any custom implementation of that service to be careful with user input. The tokens signed by each plugin contain both the source and target plugin ID, which means that the token can not be reused to access other plugins. + +When forwarding a user identity in a call across backend plugins only the limited user token with `uip` is used, wrapped in a new service token that is signed by the calling plugin. This means that the receiving plugin can trust the user identity, but it is not able to make further calls on behalf of the user except for with the plugins that it is authorized to call. That is except for any endpoints in other plugins that accept limited user tokens, which is a reason to avoid accepting them when possible. ## Catalog -Integrators should configure [catalog rules](https://backstage.io/docs/features/software-catalog/configuration#catalog-rules) to limit the allowed entity kinds that users can define. In general it is best to restrict definition of User, Group, and Template entities so that internal users cannot register additional ones. Template entities define actions that are executed on the backend hosts, and while the goal is for these actions to be secure regardless of input, it is still a more sensitive context and it is recommended that you protect it with additional checks. It is very important to not allow registration of User and Group entities if you ingest and rely on these as organizational data in your catalog. Doing so could otherwise open up for the ability to impersonate users and confuse group membership information. You should always ingest organizational data using a statically configured catalog location or an entity provider reading from a trusted source. The entities emitted directly by an entity provider are always trusted and rules are not applied to them, but any entities produced further down the chain are still subject to the rules. +Operators should configure [catalog rules](https://backstage.io/docs/features/software-catalog/configuration#catalog-rules) to limit the allowed entity kinds that users can define. In general it is best to restrict definition of User, Group, and Template entities so that internal users cannot register additional ones. Template entities define actions that are executed on the backend hosts, and while the goal is for these actions to be secure regardless of input, it is still a more sensitive context and it is recommended that you protect it with additional checks. It is very important to not allow registration of User and Group entities if you ingest and rely on these as organizational data in your catalog. Doing so could otherwise open up for the ability to impersonate users and confuse group membership information. You should always ingest organizational data using a statically configured catalog location or an entity provider reading from a trusted source. The entities emitted directly by an entity provider are always trusted and rules are not applied to them, but any entities produced further down the chain are still subject to the rules. The Catalog does not aim to protect against resource exhaustion attacks in its default setup. If you need to prevent your internal users from being able to register large amounts of entities, then it is recommended to disable entity registration and use a different approach for discovering entities. One way to mitigate any resource exhaustion attacks is to only allow the catalog to read from trusted SCM sources that have an audit trail. Catalog currently lacks limits for entity hierarchy depth and entity size, which we hope to address in the future. @@ -68,11 +77,11 @@ By default all internal users are allowed to create and delete entities. If this By default, Scaffolding jobs execute directly on the host machine, including any actions defined in the template. Because the Scaffolder templates are considered a more sensitive area it is recommended to control access to create and update templates to trusted parties. Template execution is intended to be secure regardless of input, but we still recommend this additional layer of protection. The string templating is executed in a [node VM sandbox](https://github.com/laverdet/isolated-vm) to mitigate the possibility of remote code execution attacks. -The Scaffolder often has elevated permissions to for example create repositories in a Github organization. The integrator should therefore be cautious of Scaffolder Templates that for example delete or update existing resources as the user input is typically user defined and can therefore delete or modify resources maliciously or by mistake. +The Scaffolder often has elevated permissions to for example create repositories in a Github organization. The operator should therefore be cautious of Scaffolder Templates that for example delete or update existing resources as the user input is typically user defined and can therefore delete or modify resources maliciously or by mistake. One strategy that allows you to reduce the access that the Scaffolder service has is to rely on user credentials when executing actions. For example, a GitHub App integration could be configured with read-only permissions, with a separate user OAuth token used to create repositories. This requires that your users have access to create repositories in the first place. -The integrator should audit installed scaffolding actions just like any other plugin package. It is also important to verify that installed actions fall in line with your own security requirements, as some actions might be intended for more relaxed environments. +The operator should audit installed scaffolding actions just like any other plugin package. It is also important to verify that installed actions fall in line with your own security requirements, as some actions might be intended for more relaxed environments. By default all internal users are allowed to execute templates in the scaffolder. If this does not fit your organization's needs it is recommended to enable and configure the [permission](https://backstage.io/docs/permissions/overview) system to restrict these operations. diff --git a/docs/permissions/plugin-authors/03-adding-a-resource-permission-check.md b/docs/permissions/plugin-authors/03-adding-a-resource-permission-check.md index 76c1a85e24..b3aeb13a68 100644 --- a/docs/permissions/plugin-authors/03-adding-a-resource-permission-check.md +++ b/docs/permissions/plugin-authors/03-adding-a-resource-permission-check.md @@ -144,7 +144,11 @@ export const rules = { isOwner }; `makeCreatePermissionRule` is a helper used to ensure that rules created for this plugin use consistent types for the resource and query. -> Note: To support custom rules defined by Backstage integrators, you must export `createTodoListPermissionRule` from the backend package and provide some way for custom rules to be passed in before the backend starts, likely via `createRouter`. +:::note Note + +To support custom rules defined by Backstage integrators, you must export `createTodoListPermissionRule` from the backend package and provide some way for custom rules to be passed in before the backend starts, likely via `createRouter`. + +::: We have created a new `isOwner` rule, which is going to be automatically used by the permission framework whenever a conditional response is returned in response to an authorized request with an attached `resourceRef`. Specifically, the `apply` function is used to understand whether the passed resource should be authorized or not. diff --git a/docs/plugins/analytics.md b/docs/plugins/analytics.md index 52a859b5e9..10a7421057 100644 --- a/docs/plugins/analytics.md +++ b/docs/plugins/analytics.md @@ -69,8 +69,7 @@ installed, may be captured. | `discover` | The title of the search result that was clicked on | The `value` is the result rank. A `to` attribute is also provided. | | `not-found` | The path of the resource that resulted in a not found page | Fired by at least TechDocs. | -If there is an event you'd like to see captured, please [open an -issue](https://github.com/backstage/backstage/issues/new?assignees=&labels=enhancement&template=feature_template.md&title=[Analytics%20Event]:%20THE+EVENT+TO+CAPTURE) describing the event you want to see and the questions it +If there is an event you'd like to see captured, please [open an issue](https://github.com/backstage/backstage/issues/new?assignees=&labels=enhancement&template=feature_template.md&title=[Analytics%20Event]:%20THE+EVENT+TO+CAPTURE) describing the event you want to see and the questions it would help you answer. Or jump to [Capturing Events](#capturing-events) to learn how to contribute the instrumentation yourself! diff --git a/docs/releases/v1.12.0-changelog.md b/docs/releases/v1.12.0-changelog.md index df25020aee..49ff79d19a 100644 --- a/docs/releases/v1.12.0-changelog.md +++ b/docs/releases/v1.12.0-changelog.md @@ -60,8 +60,7 @@ This change makes the dependence explicit, and removes the burden on OAuth2-based providers which require an ID token (e.g. this is done by various - default [auth - handlers](https://backstage.io/docs/auth/identity-resolver/#authhandler)) to add + default [auth handlers](https://backstage.io/docs/auth/identity-resolver/#authhandler)) to add `openid` to their default scopes. _That_ could carry another indirect benefit: by removing `openid` from the default scopes for a provider, grants for resource-specific access tokens can avoid requesting excess ID token-related diff --git a/docs/releases/v1.12.0-next.2-changelog.md b/docs/releases/v1.12.0-next.2-changelog.md index 7a64ec5f84..ed4c5683ba 100644 --- a/docs/releases/v1.12.0-next.2-changelog.md +++ b/docs/releases/v1.12.0-next.2-changelog.md @@ -25,8 +25,7 @@ This change makes the dependence explicit, and removes the burden on OAuth2-based providers which require an ID token (e.g. this is done by various - default [auth - handlers](https://backstage.io/docs/auth/identity-resolver/#authhandler)) to add + default [auth handlers](https://backstage.io/docs/auth/identity-resolver/#authhandler)) to add `openid` to their default scopes. _That_ could carry another indirect benefit: by removing `openid` from the default scopes for a provider, grants for resource-specific access tokens can avoid requesting excess ID token-related diff --git a/docs/releases/v1.15.0.md b/docs/releases/v1.15.0.md index 336fe7520b..c7ef6b33f9 100644 --- a/docs/releases/v1.15.0.md +++ b/docs/releases/v1.15.0.md @@ -27,8 +27,7 @@ native dependency, and as such needs to be built during `yarn` installation, on the exact architecture that it then executes on. For those who compile and run Backstage on stripped-down environments, you will want to ensure that you have the build basics present, e.g. `build-essential` or similar corresponding to -your operating system of choice. The `isolated-vm` repo has [some further -information](https://github.com/laverdet/isolated-vm#requirements) about the +your operating system of choice. The `isolated-vm` repo has [some further information](https://github.com/laverdet/isolated-vm#requirements) about the build environment requirements. There is a [CVE-2022-39266](https://www.cve.org/CVERecord?id=CVE-2022-39266) @@ -65,8 +64,7 @@ covers of your catalog instance, finding those pesky unprocessed entities that may be stuck in limbo because of an otherwise tricky-to-debug validation issue or similar. -Check out [the plugin’s -README](https://github.com/backstage/backstage/blob/master/plugins/catalog-unprocessed-entities/README.md) +Check out [the plugin’s README](https://github.com/backstage/backstage/blob/master/plugins/catalog-unprocessed-entities/README.md) for details and installation instructions. Contributed by [@alde](https://github.com/alde) in @@ -176,8 +174,7 @@ Contributed by [@sblausten](https://github.com/sblausten) in We recommend that you keep your Backstage project up to date with this latest release. For more guidance on how to upgrade, check out the documentation for -[keeping Backstage -updated](https://backstage.io/docs/getting-started/keeping-backstage-updated). +[keeping Backstage updated](https://backstage.io/docs/getting-started/keeping-backstage-updated). ## Links and References @@ -185,11 +182,9 @@ Below you can find a list of links and references to help you learn about and start using this new release. - [Backstage official website](https://backstage.io/), - [documentation](https://backstage.io/docs/), and [getting started - guide](https://backstage.io/docs/getting-started/) + [documentation](https://backstage.io/docs/), and [getting started guide](https://backstage.io/docs/getting-started/) - [GitHub repository](https://github.com/backstage/backstage) -- Backstage's [versioning and support - policy](https://backstage.io/docs/overview/versioning-policy) +- Backstage's [versioning and support policy](https://backstage.io/docs/overview/versioning-policy) - [Community Discord](https://discord.gg/backstage-687207715902193673) for discussions and support - [Changelog](https://github.com/backstage/backstage/tree/master/docs/releases/v1.15.0-changelog.md) diff --git a/docs/releases/v1.27.0-changelog.md b/docs/releases/v1.27.0-changelog.md new file mode 100644 index 0000000000..28e52caa7b --- /dev/null +++ b/docs/releases/v1.27.0-changelog.md @@ -0,0 +1,1949 @@ +# Release v1.27.0 + +Upgrade Helper: [https://backstage.github.io/upgrade-helper/?to=1.27.0](https://backstage.github.io/upgrade-helper/?to=1.27.0) + +## @backstage/backend-common@0.22.0 + +### Minor Changes + +- ed83f85: Internal refactor of the database code. + + **BREAKING**: The helper functions `createDatabaseClient` and `ensureDatabaseExists` have been removed from the public interface, since they have no usage within the repository and never were suitable for calling from the outside. Please consider using `coreServices.database` or `DatabaseManager` directly wherever possible instead. + +### Patch Changes + +- 2cc750d: Added `HarnessURLReader` with `readUrl` support. +- 57f692e: Preparing for a stable new backend system release, we are deprecating utilities in the `backend-common` that are not used by the core framework, such as the isomorphic `Git` class. As we will no longer support the isomorphic `Git` utility in the framework packages, we recommend plugins that start maintaining their own implementation of this class. +- 0ec0796: Plugins created through the `legacyPlugin` helper are now able to authenticate requests from plugins that are fully implemented using the new backend system. This fixes the `Key for the ES256 algorithm must be one of type KeyObject or CryptoKey. Received an instance of Uint8Array` error. +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- ccc8851: Added config prop `ensureSchemaExists` to support postgres instances where user can create schemas but not databases. +- f66bbb4: Only create a single actual connection to memcache/redis, even in cases where many `CacheService` instances are made +- ba0b8b4: Added option to `ServerTokenManager.fromConfig` that allows it to be instantiated in production without any configured keys. +- Updated dependencies + - @backstage/backend-app-api@0.7.3 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/integration@1.11.0 + +## @backstage/catalog-model@1.5.0 + +### Minor Changes + +- 79025f3: Introduce a domain attribute to the domain entity to allow a hierarchy of domains to exist. + +## @backstage/frontend-app-api@0.7.0 + +### Minor Changes + +- ddddecb: Extensions in app-config now always affect ordering. Previously, only when enabling disabled extensions did they rise to the top. + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/frontend-plugin-api@0.6.5 + +## @backstage/integration@1.11.0 + +### Minor Changes + +- 2cc750d: Added `HarnessIntegration` via the `ScmIntegrations` interface. + +## @backstage/repo-tools@0.9.0 + +### Minor Changes + +- 683870a: Adds 2 new commands `repo schema openapi diff` and `package schema openapi diff`. `repo schema openapi diff` is intended to power a new breaking changes check on pull requests and the package level command allows plugin developers to quickly see new API breaking changes. They're intended to be used in complement with the existing `repo schema openapi verify` command to validate your OpenAPI spec against a variety of things. + +### Patch Changes + +- 9ae9bb2: Update the paths logic in the api reports command to support complex subpaths +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + +## @backstage/plugin-catalog@1.20.0 + +### Minor Changes + +- 8834daf: Updated the presentation API to return a promise, in addition to the snapshot and observable that were there before. This makes it much easier to consume the API in a non-React context. + +### Patch Changes + +- 131e5cb: Fix broken links in README. +- 5d99272: Update local development dependencies. +- 4118530: Avoiding pre-loading display total count undefined for table counts +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-search-react@1.7.11 + +## @backstage/plugin-catalog-backend@1.22.0 + +### Minor Changes + +- f2a2a83: Deprecated the `LocationAnalyzer` type, which has been moved to `@backstage/plugin-catalog-node`. +- f2a2a83: The `/alpha` plugin export has had its implementation of the `catalogAnalysisExtensionPoint` updated to reflect the new API. +- 8d14475: Emit well known relationships for the Domain entity kind. + +### Patch Changes + +- 131e5cb: Fix broken links in README. +- c6cb568: Add lifecycle monitoring for the catalog processing +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 8479a0b: Fixed bug in stitching queue gauge that included entities that are scheduled in the future. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-search-backend-module-catalog@0.1.24 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + - @backstage/integration@1.11.0 + - @backstage/backend-openapi-utils@0.1.11 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/plugin-catalog-import@0.11.0 + +### Minor Changes + +- e1174b0: `EntityListComponent` uses `entityPresentationApi` instead of `humanizeEntityRef` to display Entity + +### Patch Changes + +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-node@1.12.0 + +### Minor Changes + +- f2a2a83: Added `LocationAnalyzer` type, moved from `@backstage/plugin-catalog-backend`. +- f2a2a83: Breaking change to `/alpha` API where the `catalogAnalysisExtensionPoint` has been reworked. The `addLocationAnalyzer` method has been renamed to `addScmLocationAnalyzer`, and a new `setLocationAnalyzer` method has been added which allows the full `LocationAnalyzer` implementation to be overridden. + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/plugin-catalog-react@1.12.0 + +### Minor Changes + +- 8834daf: Updated the presentation API to return a promise, in addition to the snapshot and observable that were there before. This makes it much easier to consume the API in a non-React context. + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-scaffolder@1.20.0 + +### Minor Changes + +- 4268696: `MultiEntityPicker` uses `EntityDisplayName` instead of `humanizeEntityRef` to display entity. + +### Patch Changes + +- 9156654: Capturing more event clicks for scaffolder +- 131e5cb: Fix broken links in README. +- 0040ec2: Updated dependency `@rjsf/utils` to `5.18.2`. + Updated dependency `@rjsf/core` to `5.18.2`. + Updated dependency `@rjsf/material-ui` to `5.18.2`. + Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. +- 762141c: Fixed a bug where the `MultiEntityPicker` was not able to be set as required +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/plugin-scaffolder-react@1.8.5 + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-scaffolder-backend-module-gitlab@0.4.0 + +### Minor Changes + +- 18f736f: Add examples for `gitlab:projectVariable:create` scaffolder action & improve related tests + +### Patch Changes + +- 8fa8a00: Add merge method and squash option for project creation +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- ffc73ec: Add examples for `gitlab:repo:push` scaffolder action & improve related tests +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/app-defaults@1.5.5 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + +## @backstage/backend-app-api@0.7.3 + +### Patch Changes + +- 4cd5ff0: Add ability to configure the Node.js HTTP Server when configuring the root HTTP Router service + +- e8199b1: Move the JWKS registration outside of the lifecycle middleware + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. + +- dc8c5dd: The default `TokenManager` implementation no longer requires keys to be configured in production, but it will throw an errors when generating or authenticating tokens. The default `AuthService` implementation will now also provide additional context if such an error is throw when falling back to using the `TokenManager` service to generate tokens for outgoing requests. + +- 025641b: Redact `meta` fields too with the logger + +- 09f8988: Remove explicit `alg` check for user tokens in `verifyToken` + +- 5863e02: Internal refactor to only create one external token handler + +- a1dc547: Added support for camel case CSP directives in app-config. For example: + + ```yaml + backend: + csp: + upgradeInsecureRequests: false + ``` + +- 329cc34: Added logging of all plugins being initialized, periodic status, and completion. + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/backend-defaults@0.2.18 + +### Patch Changes + +- 7e5a50d: added `eventsServiceFactory` to `defaultServiceFactories` to resolve issue where different instances of the EventsServices could be used +- Updated dependencies + - @backstage/backend-app-api@0.7.3 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/backend-dynamic-feature-service@0.2.10 + +### Patch Changes + +- b192752: Updated `README.md` to point to `packages/backend` instead of `packages/backend-next`. +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- b611fd0: Updates the `scanRoot` method in the `PluginScanner` class to specifically ignore the `lost+found` directory, which is a system-generated directory used for file recovery on Unix-like systems. Skipping this directory avoids unnecessary errors. +- Updated dependencies + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/backend-app-api@0.7.3 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-app-node@0.1.18 + - @backstage/plugin-events-backend@0.3.5 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/backend-openapi-utils@0.1.11 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + +## @backstage/backend-plugin-api@0.6.18 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 1fedf0c: Removed explicit `toString()` method from `ServiceRef` type. +- Updated dependencies + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/backend-tasks@0.5.23 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + +## @backstage/backend-test-utils@0.3.8 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 7e5a50d: added `eventsServiceFactory` to `defaultServiceFactories` to resolve issue where different instances of the EventsServices could be used +- Updated dependencies + - @backstage/backend-app-api@0.7.3 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/catalog-client@1.6.5 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + +## @backstage/cli@0.26.5 + +### Patch Changes + +- b8f1fc2: The `build-workspace` command no longer manually runs `yarn postpack`, relying instead on the fact that running `yarn pack` will automatically invoke the `postpack` script. No action is necessary if you are running the latest version of yarn 1, 3, or 4. +- fcd3462: Both the target and types library have been bumped from ES2021 to ES2022 in `@backstage/cli/config/tsconfig.json`. +- 0cc5ed3: Add support for `versions:migrate` to do code changes. Can be skipped with `--no-code-changes` +- f97ad04: Add preserveModules to rollup, which allows better async loading and tree-shaking in webpack +- 2a6f10d: The `versions:bump` command will no longer exit with a non-zero status if the version bump fails due to forbidden duplicate package installations. It will now also provide more information about how to troubleshoot such an error. The set of forbidden duplicates has also been expanded to include all `@backstage/*-app-api` packages. +- c5d7b40: Allow passing a `--require` argument through to the Node process during `package start` +- cc3c518: Fixed an issue causing the `repo fix` command to set an incorrect `workspace` property using Windows +- 812dff0: Add previously-missing semicolon in file templated by `backstage-cli new --select plugin`. +- f185603: Fixed the dynamic import of vite. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/eslint-plugin@0.1.8 + - @backstage/integration@1.11.0 + +## @backstage/core-app-api@1.12.5 + +### Patch Changes + +- 1bed9a3: The Backstage identity session expiration check will no longer fall back to using the provider expiration. This was introduced to smooth out the rollout of Backstage release 1.18, and is no longer needed. + +## @backstage/core-compat-api@0.2.5 + +### Patch Changes + +- 5d99272: Update local development dependencies. +- Updated dependencies + - @backstage/frontend-plugin-api@0.6.5 + +## @backstage/core-components@0.14.7 + +### Patch Changes + +- e42779e: Properly log the `errorInfo` in `ErrorBoundary` +- 5223c4c: Fixed an internal circular import that broke Jest mocks. +- 71e4229: Added optional `initialShowDropDown` prop to `SidebarSubmenuItem` to internally manage the initial display state of the dropdown items. +- a2ee4df: Add `alignGauge` prop to the `GaugeCard`, and a small size version. When `alignGauge` is `'bottom'` the gauge will vertically align the gauge in the cards, even when the card titles span across multiple lines. + Add `alignContent` prop to the `InfoCard`, defaulting to `'normal'` with the option of `'bottom'` which vertically aligns the content to the bottom of the card. +- 5b7b49b: The `SignInPage` guest provider will now fall back to legacy guest auth if the backend request fails, allowing guest auth without a running backend. +- 359376a: Removing react-text-truncate with css styles. +- Updated dependencies + - @backstage/theme@0.5.4 + +## @backstage/create-app@0.5.15 + +### Patch Changes + +- c066c88: Removed `packages/backend/src/types.ts` from the template as it is unused. It was mistakenly left in after moving the template to the new backend system. +- 5d99272: Update local development dependencies. +- 0478509: Bumped create-app version. +- d85dd88: Bumped create-app version. +- 8105aad: Removed the Tech Radar and GitHub Actions plugins from the template, which have been moved to the community plugins repository. + +## @backstage/dev-utils@1.0.32 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/app-defaults@1.5.5 + - @backstage/integration-react@1.1.27 + +## @backstage/eslint-plugin@0.1.8 + +### Patch Changes + +- 65ec043: add some `pickers` fixes + +## @backstage/frontend-plugin-api@0.6.5 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + +## @backstage/frontend-test-utils@0.1.7 + +### Patch Changes + +- Updated dependencies + - @backstage/frontend-app-api@0.7.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/test-utils@1.5.5 + +## @backstage/integration-react@1.1.27 + +### Patch Changes + +- Updated dependencies + - @backstage/integration@1.11.0 + +## @techdocs/cli@1.8.11 + +### Patch Changes + +- 1a0e009: Fix cookie endpoint mock for `serve` +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-techdocs-node@1.12.4 + +## @backstage/test-utils@1.5.5 + +### Patch Changes + +- Updated dependencies + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + +## @backstage/theme@0.5.4 + +### Patch Changes + +- f1462df: Fixed bug where scrollbars don't pick up the theme when in dark mode + +## @backstage/plugin-api-docs@0.11.5 + +### Patch Changes + +- 5d99272: Update local development dependencies. +- 725ff0b: Fix dark mode text color inside tables in `description:` from OpenAPI definitions +- Updated dependencies + - @backstage/plugin-catalog@1.20.0 + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-app-backend@0.3.66 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-app-node@0.1.18 + +## @backstage/plugin-app-node@0.1.18 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + +## @backstage/plugin-app-visualizer@0.1.6 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/frontend-plugin-api@0.6.5 + +## @backstage/plugin-auth-backend@0.22.5 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 4a0577e: fix: Move config declarations to appropriate auth backend modules +- ea9262b: Allow overriding default ownership resolving with the new `AuthOwnershipResolutionExtensionPoint` +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-backend-module-aws-alb-provider@0.1.10 + - @backstage/plugin-auth-backend-module-github-provider@0.1.15 + - @backstage/plugin-auth-backend-module-oidc-provider@0.1.9 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-auth-backend-module-atlassian-provider@0.1.10 + - @backstage/plugin-auth-backend-module-azure-easyauth-provider@0.1.1 + - @backstage/plugin-auth-backend-module-bitbucket-provider@0.1.1 + - @backstage/plugin-auth-backend-module-cloudflare-access-provider@0.1.1 + - @backstage/plugin-auth-backend-module-gcp-iap-provider@0.2.13 + - @backstage/plugin-auth-backend-module-gitlab-provider@0.1.15 + - @backstage/plugin-auth-backend-module-google-provider@0.1.15 + - @backstage/plugin-auth-backend-module-microsoft-provider@0.1.13 + - @backstage/plugin-auth-backend-module-oauth2-provider@0.1.15 + - @backstage/plugin-auth-backend-module-oauth2-proxy-provider@0.1.11 + - @backstage/plugin-auth-backend-module-okta-provider@0.0.11 + +## @backstage/plugin-auth-backend-module-atlassian-provider@0.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-aws-alb-provider@0.1.10 + +### Patch Changes + +- 4a0577e: fix: Move config declarations to appropriate auth backend modules +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-backend@0.22.5 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-azure-easyauth-provider@0.1.1 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-bitbucket-provider@0.1.1 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-cloudflare-access-provider@0.1.1 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-gcp-iap-provider@0.2.13 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-github-provider@0.1.15 + +### Patch Changes + +- 4a0577e: fix: Move config declarations to appropriate auth backend modules +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-gitlab-provider@0.1.15 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-google-provider@0.1.15 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-guest-provider@0.1.4 + +### Patch Changes + +- 07d8cca: Error if used outside of a development environment without explicit allowance +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-microsoft-provider@0.1.13 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-oauth2-provider@0.1.15 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-oauth2-proxy-provider@0.1.11 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-oidc-provider@0.1.9 + +### Patch Changes + +- dd53bf3: Add nonce to authorize request to be added in ID token +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-backend@0.22.5 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-okta-provider@0.0.11 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-pinniped-provider@0.1.12 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-backend-module-vmware-cloud-provider@0.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-auth-node@0.4.13 + +### Patch Changes + +- ea9262b: Allow overriding default ownership resolving with the new `AuthOwnershipResolutionExtensionPoint` +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/catalog-client@1.6.5 + +## @backstage/plugin-auth-react@0.1.2 + +### Patch Changes + +- c297afd: When using `CookieAuthRefreshProvider` or `useCookieAuthRefresh`, a 404 response from the cookie endpoint will now be treated as if cookie auth is disabled and is not needed. +- Updated dependencies + - @backstage/core-components@0.14.7 + +## @backstage/plugin-bitbucket-cloud-common@0.2.19 + +### Patch Changes + +- d76cb29: Updated dependency `ts-morph` to `^22.0.0`. +- Updated dependencies + - @backstage/integration@1.11.0 + +## @backstage/plugin-catalog-backend-module-aws@0.3.13 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/integration@1.11.0 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-kubernetes-common@0.7.6 + +## @backstage/plugin-catalog-backend-module-azure@0.1.38 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/integration@1.11.0 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-backend-module-backstage-openapi@0.2.1 + +### Patch Changes + +- f3f0281: Fix incorrect dependency import. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/backend-openapi-utils@0.1.11 + +## @backstage/plugin-catalog-backend-module-bitbucket-cloud@0.2.5 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-bitbucket-cloud-common@0.2.19 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-backend-module-bitbucket-server@0.1.32 + +### Patch Changes + +- 062ffb1: Allow skipping archived repositories (`skipArchivedRepos` flag) on Bitbucket. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/integration@1.11.0 + +## @backstage/plugin-catalog-backend-module-gcp@0.1.19 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-kubernetes-common@0.7.6 + +## @backstage/plugin-catalog-backend-module-gerrit@0.1.35 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/integration@1.11.0 + +## @backstage/plugin-catalog-backend-module-github@0.6.1 + +### Patch Changes + +- 0b50143: GitHub push events now schedule a refresh on entities that have a `refresh_key` matching the `catalogPath` config itself. + This allows to support a `catalogPath` configuration that uses glob patterns. + +- f2a2a83: Updated to use the new `catalogAnalysisExtensionPoint` API. + +- 5bdeaa7: Added `alwaysUseDefaultNamespace` option to `GithubMultiOrgEntityProvider`. + + If set to true, the provider will use `default` as the namespace for all group entities. Groups with the same name across different orgs will be considered the same group. + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-backend-module-github-org@0.1.13 + +### Patch Changes + +- 5bdeaa7: Fixed an issue where the `catalog-backend-module-github-org` would not correctly create groups using `default` as namespace in case a single organization was configured. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-catalog-backend-module-github@0.6.1 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-catalog-backend-module-gitlab@0.3.15 + +### Patch Changes + +- a70377d: Added events support for `GitlabDiscoveryEntityProvider` and `GitlabOrgDiscoveryEntityProvider`. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + - @backstage/integration@1.11.0 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-backend-module-gitlab-org@0.0.1 + +### Patch Changes + +- a70377d: Added a new `catalog-backend-module-gitlab-org` module which adds the `GitlabOrgDiscoveryEntityProvider` to the catalog's providers using the new backend system. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-catalog-backend-module-gitlab@0.3.15 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-catalog-backend-module-incremental-ingestion@0.4.23 + +### Patch Changes + +- 8c1ab9e: Fix plugin/incremental-ingestion 'Maximum call stack size exceeded' error when ingest large entities. +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-catalog-backend-module-ldap@0.5.34 + +### Patch Changes + +- 7699967: Remove dependency to Winston Logger and use Backstage LoggerService instead +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-backend-module-msgraph@0.5.26 + +### Patch Changes + +- 49eab29: Fixed disabling of user photo fetching. Previously, the config value wasn't propagated properly, so user photos was still being fetched despite disabled by config. +- 6e370e6: Handle fetching huge amounts of users from Azure without crashing +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-backend-module-openapi@0.1.36 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/integration@1.11.0 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-backend-module-puppetdb@0.1.24 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + +## @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.16 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-catalog-backend-module-unprocessed@0.4.5 + +### Patch Changes + +- b192752: Updated `README.md` to point to `packages/backend` instead of `packages/backend-next`. +- 6f5a3a3: Correctly convert owner to string in case owner has not been provided +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-catalog-common@1.0.23 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + +## @backstage/plugin-catalog-graph@0.4.5 + +### Patch Changes + +- 39564b3: Allow multiple edges with different type (e.g. `ownedBy` and `applicationOwnerBy`) to have the same source and target node. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + +## @backstage/plugin-catalog-unprocessed-entities@0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + +## @backstage/plugin-config-schema@0.1.55 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + +## @backstage/plugin-devtools@0.1.14 + +### Patch Changes + +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/frontend-plugin-api@0.6.5 + +## @backstage/plugin-devtools-backend@0.3.4 + +### Patch Changes + +- 036feca: Added discovery property to the readme documentation to ensure that it will build when setting it up as new to a Backstage instance +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/plugin-events-backend@0.3.5 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-events-backend-module-aws-sqs@0.3.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-events-backend-module-azure@0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-events-backend-module-bitbucket-cloud@0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-events-backend-module-gerrit@0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-events-backend-module-github@0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-events-backend-module-gitlab@0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-events-backend-test-utils@0.1.28 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-events-node@0.3.4 + +## @backstage/plugin-events-node@0.3.4 + +### Patch Changes + +- 7e5a50d: added `eventsServiceFactory` to `defaultServiceFactories` to resolve issue where different instances of the EventsServices could be used +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + +## @backstage/plugin-home@0.7.4 + +### Patch Changes + +- 2196d3e: Use relative time when displaying visits from the same day +- 0040ec2: Updated dependency `@rjsf/utils` to `5.18.2`. + Updated dependency `@rjsf/core` to `5.18.2`. + Updated dependency `@rjsf/material-ui` to `5.18.2`. + Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/plugin-home-react@0.1.13 + - @backstage/core-app-api@1.12.5 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + +## @backstage/plugin-home-react@0.1.13 + +### Patch Changes + +- 0040ec2: Updated dependency `@rjsf/utils` to `5.18.2`. + Updated dependency `@rjsf/core` to `5.18.2`. + Updated dependency `@rjsf/material-ui` to `5.18.2`. + Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. +- Updated dependencies + - @backstage/core-components@0.14.7 + +## @backstage/plugin-kubernetes@0.11.10 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/plugin-kubernetes-react@0.3.5 + - @backstage/plugin-kubernetes-common@0.7.6 + +## @backstage/plugin-kubernetes-backend@0.17.1 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-kubernetes-common@0.7.6 + - @backstage/plugin-kubernetes-node@0.1.12 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/plugin-kubernetes-cluster@0.0.11 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/plugin-kubernetes-react@0.3.5 + - @backstage/plugin-kubernetes-common@0.7.6 + +## @backstage/plugin-kubernetes-common@0.7.6 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + +## @backstage/plugin-kubernetes-node@0.1.12 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-kubernetes-common@0.7.6 + +## @backstage/plugin-kubernetes-react@0.3.5 + +### Patch Changes + +- 3102a99: add the namespace label to CronJobDrawer & IngressDrawer. +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-kubernetes-common@0.7.6 + +## @backstage/plugin-notifications@0.2.1 + +### Patch Changes + +- e6bf85f: Allow overriding `NotificationsPage` page properties +- f730c0b: The user can newly mark all unread messages as read at one click. +- bfcb2f1: Allow showing notifications as snackbars in the UI +- e49a810: Show all notifications by default to match the sidebar item status +- 42eaf63: Increase default and allow modifying notification snackbar auto hide duration +- a42a19b: Empty descriptions are not rendered to improve the look&feel. +- 1bc3b86: Fix to show web notifications even when browser is on foreground. Fix duplicate notifications with multiple tabs. +- f793112: Allow defining `className` and additional properties for `NotificationsSideBarItem` +- e1c7d6e: Fix infinite loop in the notification title counter +- fcda449: The rendered size of a notification is limited for very long descriptions. +- f6633ca: Add option to set the notification as read automatically when the notification link is opened +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + +## @backstage/plugin-notifications-backend@0.2.1 + +### Patch Changes + +- d541ff6: Fixed email processor `esm` issue and config reading +- 295c05d: Support for filtering entities from notification recipients after resolving them from the recipients +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- cba628a: Add possibility to generate random notifications on the fly in local development +- ee09dfc: Updated documentation for sending messages by external services. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-notifications-node@0.1.4 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-signals-node@0.1.4 + +## @backstage/plugin-notifications-backend-module-email@0.0.1 + +### Patch Changes + +- d541ff6: Fixed email processor `esm` issue and config reading +- e538b10: Support relative links in notifications sent via email +- dbf2696: Allow sending notifications by email with the new notifications module +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-notifications-node@0.1.4 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/catalog-client@1.6.5 + +## @backstage/plugin-notifications-node@0.1.4 + +### Patch Changes + +- 295c05d: Support for filtering entities from notification recipients after resolving them from the recipients +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-signals-node@0.1.4 + +## @backstage/plugin-org@0.6.25 + +### Patch Changes + +- 99e6105: Fix ownership card sometimes locking up for complex org structures +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-org-react@0.1.24 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/catalog-client@1.6.5 + +## @backstage/plugin-permission-backend@0.5.42 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/plugin-permission-backend-module-allow-all-policy@0.1.15 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/plugin-permission-node@0.7.29 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-proxy-backend@0.4.16 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + +## @backstage/plugin-scaffolder-backend@1.22.6 + +### Patch Changes + +- 131e5cb: Fix broken links in README. +- 025641b: Fix issue with the log format not being respected when logging from actions +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- e4b50ab: Scaffolder workspace serialization +- 025641b: Redact `meta` fields too with the logger +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-scaffolder-backend-module-github@0.2.8 + - @backstage/plugin-scaffolder-backend-module-gitea@0.1.8 + - @backstage/plugin-scaffolder-backend-module-gitlab@0.4.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-scaffolder-backend-module-bitbucket-server@0.1.8 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.16 + - @backstage/plugin-permission-node@0.7.29 + - @backstage/plugin-scaffolder-backend-module-azure@0.1.10 + - @backstage/plugin-scaffolder-backend-module-bitbucket@0.2.8 + - @backstage/plugin-scaffolder-backend-module-bitbucket-cloud@0.1.8 + - @backstage/plugin-scaffolder-backend-module-gerrit@0.1.10 + +## @backstage/plugin-scaffolder-backend-module-azure@0.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-bitbucket@0.2.8 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/plugin-scaffolder-backend-module-bitbucket-server@0.1.8 + - @backstage/integration@1.11.0 + - @backstage/plugin-scaffolder-backend-module-bitbucket-cloud@0.1.8 + +## @backstage/plugin-scaffolder-backend-module-bitbucket-cloud@0.1.8 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-bitbucket-server@0.1.8 + +### Patch Changes + +- 24dd655: Add examples for `publish:bitbucketServer:pull-request` scaffolder action & improve related tests +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-confluence-to-markdown@0.2.19 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-cookiecutter@0.2.42 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-gerrit@0.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-gitea@0.1.8 + +### Patch Changes + +- 554af73: Allow defining `repoVisibility` field for the action `publish:gitea` +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-github@0.2.8 + +### Patch Changes + +- 5d99272: Update local development dependencies. +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 52ab241: Adding support to change the default commit author for `publish:github:pull-request` +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-notifications@0.0.1 + +### Patch Changes + +- 503d769: Add a new scaffolder action to allow sending notifications from templates +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/plugin-notifications-node@0.1.4 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + +## @backstage/plugin-scaffolder-backend-module-rails@0.4.35 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-backend-module-sentry@0.1.26 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + +## @backstage/plugin-scaffolder-backend-module-yeoman@0.3.1 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/plugin-scaffolder-node-test-utils@0.1.4 + +## @backstage/plugin-scaffolder-common@1.5.2 + +### Patch Changes + +- 9156654: Capturing more event clicks for scaffolder +- Updated dependencies + - @backstage/catalog-model@1.5.0 + +## @backstage/plugin-scaffolder-node@0.4.4 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- e4b50ab: Scaffolder workspace serialization +- f633efa: To remove the dependency on the soon-to-be-deprecated `backend-common` package, this package now maintains its own isomorphic Git class implementation. +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/integration@1.11.0 + +## @backstage/plugin-scaffolder-node-test-utils@0.1.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-test-utils@0.3.8 + - @backstage/plugin-scaffolder-node@0.4.4 + +## @backstage/plugin-scaffolder-react@1.8.5 + +### Patch Changes + +- 9156654: Capturing more event clicks for scaffolder +- 0040ec2: Updated dependency `@rjsf/utils` to `5.18.2`. + Updated dependency `@rjsf/core` to `5.18.2`. + Updated dependency `@rjsf/material-ui` to `5.18.2`. + Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/catalog-client@1.6.5 + +## @backstage/plugin-search@1.4.11 + +### Patch Changes + +- 0501243: Added `aria-label` attribute to DialogTitle element and set `aria-modal` attribute to `true` for improved accessibility in the search modal. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/plugin-search-react@1.7.11 + +## @backstage/plugin-search-backend@1.5.8 + +### Patch Changes + +- c6cb568: Add lifecycle monitoring for the search index registry +- Updated dependencies + - @backstage/repo-tools@0.9.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/backend-openapi-utils@0.1.11 + - @backstage/plugin-permission-node@0.7.29 + +## @backstage/plugin-search-backend-module-catalog@0.1.24 + +### Patch Changes + +- b192752: Updated `README.md` to point to `packages/backend` instead of `packages/backend-next`. +- d5fff66: Fix wiring of the module exported at the `/alpha` path, which was causing authentication failures. +- 5dc5f4f: Allow the `tokenManager` parameter to be optional when instantiating collator +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-search-backend-module-elasticsearch@1.4.1 + +### Patch Changes + +- 5252ee1: Fix never resolved indexer promise. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-search-backend-node@1.2.22 + +## @backstage/plugin-search-backend-module-explore@0.1.24 + +### Patch Changes + +- ca6e2e0: Migrate search collator to use the new auth services. +- 5d99272: Update README.md to point to explore plugin in community-plugins repository. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-search-backend-node@1.2.22 + +## @backstage/plugin-search-backend-module-pg@0.5.27 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-search-backend-node@1.2.22 + +## @backstage/plugin-search-backend-module-stack-overflow-collator@0.1.11 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-search-backend-node@1.2.22 + +## @backstage/plugin-search-backend-module-techdocs@0.1.23 + +### Patch Changes + +- 5dc5f4f: Allow the `tokenManager` parameter to be optional when instantiating collator +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-techdocs-node@1.12.4 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-search-backend-node@1.2.22 + +### Patch Changes + +- c6cb568: Add lifecycle monitoring for the search index registry +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + +## @backstage/plugin-search-react@1.7.11 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + - @backstage/frontend-plugin-api@0.6.5 + +## @backstage/plugin-signals@0.0.6 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + +## @backstage/plugin-signals-backend@0.1.4 + +### Patch Changes + +- 845d56a: Improved signal lifecycle management and added server side pinging of connections +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-signals-node@0.1.4 + +## @backstage/plugin-signals-node@0.1.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + +## @backstage/plugin-techdocs@1.10.5 + +### Patch Changes + +- d2cc139: Update path in Readme for Plugin Techdocs to show the correct setup information. +- 5863cf7: The `techdocs.builder` config is now optional and it will default to `local`. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-auth-react@0.1.2 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/integration@1.11.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-search-react@1.7.11 + - @backstage/plugin-techdocs-react@1.2.4 + +## @backstage/plugin-techdocs-addons-test-utils@1.0.32 + +### Patch Changes + +- 2f13862: Fix bug in TechDocsAddonTester when jest.resetAllMocks is called between tests +- Updated dependencies + - @backstage/plugin-catalog@1.20.0 + - @backstage/plugin-techdocs@1.10.5 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/core-app-api@1.12.5 + - @backstage/integration-react@1.1.27 + - @backstage/test-utils@1.5.5 + - @backstage/plugin-search-react@1.7.11 + - @backstage/plugin-techdocs-react@1.2.4 + +## @backstage/plugin-techdocs-backend@1.10.5 + +### Patch Changes + +- 5863cf7: The `techdocs.builder` config is now optional and it will default to `local`. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-techdocs-node@1.12.4 + - @backstage/integration@1.11.0 + - @backstage/plugin-search-backend-module-techdocs@0.1.23 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + +## @backstage/plugin-techdocs-module-addons-contrib@1.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/integration@1.11.0 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-techdocs-react@1.2.4 + +## @backstage/plugin-techdocs-node@1.12.4 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/integration@1.11.0 + +## @backstage/plugin-techdocs-react@1.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + +## @backstage/plugin-user-settings@0.8.6 + +### Patch Changes + +- 131e5cb: Fix broken links in README. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/frontend-plugin-api@0.6.5 + +## @backstage/plugin-user-settings-backend@0.2.17 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + +## example-app@0.2.97 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-react@1.8.5 + - @backstage/plugin-scaffolder@1.20.0 + - @backstage/plugin-user-settings@0.8.6 + - @backstage/plugin-catalog@1.20.0 + - @backstage/plugin-notifications@0.2.1 + - @backstage/plugin-api-docs@0.11.5 + - @backstage/plugin-home@0.7.4 + - @backstage/cli@0.26.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-techdocs@1.10.5 + - @backstage/plugin-catalog-import@0.11.0 + - @backstage/frontend-app-api@0.7.0 + - @backstage/plugin-auth-react@0.1.2 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/plugin-catalog-graph@0.4.5 + - @backstage/plugin-search@1.4.11 + - @backstage/plugin-org@0.6.25 + - @backstage/app-defaults@1.5.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-catalog-unprocessed-entities@0.2.4 + - @backstage/plugin-devtools@0.1.14 + - @backstage/plugin-kubernetes@0.11.10 + - @backstage/plugin-kubernetes-cluster@0.0.11 + - @backstage/plugin-search-react@1.7.11 + - @backstage/plugin-signals@0.0.6 + - @backstage/plugin-techdocs-module-addons-contrib@1.1.10 + - @backstage/plugin-techdocs-react@1.2.4 + +## example-app-next@0.0.11 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-react@1.8.5 + - @backstage/plugin-scaffolder@1.20.0 + - @backstage/plugin-user-settings@0.8.6 + - @backstage/plugin-catalog@1.20.0 + - @backstage/plugin-notifications@0.2.1 + - @backstage/core-compat-api@0.2.5 + - @backstage/plugin-api-docs@0.11.5 + - @backstage/plugin-home@0.7.4 + - @backstage/cli@0.26.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-techdocs@1.10.5 + - @backstage/plugin-catalog-import@0.11.0 + - @backstage/frontend-app-api@0.7.0 + - @backstage/plugin-auth-react@0.1.2 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/plugin-catalog-graph@0.4.5 + - @backstage/plugin-search@1.4.11 + - @backstage/plugin-org@0.6.25 + - @backstage/app-defaults@1.5.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-app-visualizer@0.1.6 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-catalog-unprocessed-entities@0.2.4 + - @backstage/plugin-kubernetes@0.11.10 + - @backstage/plugin-kubernetes-cluster@0.0.11 + - @backstage/plugin-search-react@1.7.11 + - @backstage/plugin-signals@0.0.6 + - @backstage/plugin-techdocs-module-addons-contrib@1.1.10 + - @backstage/plugin-techdocs-react@1.2.4 + +## app-next-example-plugin@0.0.11 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/frontend-plugin-api@0.6.5 + +## example-backend@0.0.26 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-backend@1.22.6 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/plugin-scaffolder-backend-module-github@0.2.8 + - @backstage/plugin-catalog-backend-module-unprocessed@0.4.5 + - @backstage/plugin-search-backend-module-catalog@0.1.24 + - @backstage/plugin-notifications-backend@0.2.1 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-auth-backend@0.22.5 + - @backstage/plugin-app-backend@0.3.66 + - @backstage/plugin-devtools-backend@0.3.4 + - @backstage/plugin-signals-backend@0.1.4 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/plugin-search-backend@1.5.8 + - @backstage/plugin-auth-backend-module-github-provider@0.1.15 + - @backstage/plugin-techdocs-backend@1.10.5 + - @backstage/plugin-catalog-backend-module-backstage-openapi@0.2.1 + - @backstage/plugin-auth-backend-module-guest-provider@0.1.4 + - @backstage/backend-defaults@0.2.18 + - @backstage/plugin-search-backend-module-explore@0.1.24 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-search-backend-module-techdocs@0.1.23 + - @backstage/plugin-catalog-backend-module-openapi@0.1.36 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.16 + - @backstage/plugin-kubernetes-backend@0.17.1 + - @backstage/plugin-permission-backend@0.5.42 + - @backstage/plugin-permission-backend-module-allow-all-policy@0.1.15 + - @backstage/plugin-permission-node@0.7.29 + - @backstage/plugin-proxy-backend@0.4.16 + +## example-backend-legacy@0.2.98 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-search-backend-module-elasticsearch@1.4.1 + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-scaffolder-backend@1.22.6 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/plugin-catalog-backend-module-unprocessed@0.4.5 + - @backstage/plugin-search-backend-module-catalog@0.1.24 + - @backstage/plugin-scaffolder-backend-module-gitlab@0.4.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-search-backend-module-pg@0.5.27 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-auth-backend@0.22.5 + - @backstage/plugin-app-backend@0.3.66 + - @backstage/plugin-devtools-backend@0.3.4 + - @backstage/plugin-signals-backend@0.1.4 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/plugin-search-backend@1.5.8 + - @backstage/plugin-techdocs-backend@1.10.5 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-search-backend-module-explore@0.1.24 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/integration@1.11.0 + - @backstage/plugin-search-backend-module-techdocs@0.1.23 + - example-app@0.2.97 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.16 + - @backstage/plugin-events-backend@0.3.5 + - @backstage/plugin-kubernetes-backend@0.17.1 + - @backstage/plugin-permission-backend@0.5.42 + - @backstage/plugin-permission-node@0.7.29 + - @backstage/plugin-proxy-backend@0.4.16 + - @backstage/plugin-scaffolder-backend-module-confluence-to-markdown@0.2.19 + - @backstage/plugin-scaffolder-backend-module-rails@0.4.35 + - @backstage/plugin-signals-node@0.1.4 + +## e2e-test@0.2.16 + +### Patch Changes + +- Updated dependencies + - @backstage/create-app@0.5.15 + +## techdocs-cli-embedded-app@0.2.96 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog@1.20.0 + - @backstage/cli@0.26.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-techdocs@1.10.5 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/app-defaults@1.5.5 + - @backstage/integration-react@1.1.27 + - @backstage/test-utils@1.5.5 + - @backstage/plugin-techdocs-react@1.2.4 + +## @internal/plugin-todo-list@1.0.27 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + +## @internal/plugin-todo-list-backend@1.0.27 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 diff --git a/docs/releases/v1.27.0.md b/docs/releases/v1.27.0.md new file mode 100644 index 0000000000..123d9663ad --- /dev/null +++ b/docs/releases/v1.27.0.md @@ -0,0 +1,83 @@ +--- +id: v1.27.0 +title: v1.27.0 +description: Backstage Release v1.27.0 +--- + +These are the release notes for the v1.27.0 release of [Backstage](https://backstage.io/). + +A huge thanks to the whole team of maintainers and contributors as well as the amazing Backstage Community for the hard work in getting this release developed and done. + +## Highlights + +### Backend System Deprecations + +As part of the [work towards a stable 1.0 release of the new backend system](https://github.com/backstage/backstage/issues/24493), we will deprecate and move or remove several utilities from `@backstage/backend-common`. This release contains a few of these deprecations, with more to be expected in the future. The long-term goal is to completely deprecate and remove the `@backstage/backend-common` package. + +### Hierarchical Domains + +The Backstage System Model has been tweaked with the addition of a hierarchy of `Domain` entities. The change includes a new `spec.subdomainOf` property on the `Domain` entity, which can be used to express that a domain has a `partOf` (and conversely, `hasPart`) relation toward another domain. + +Contributed by [@dawngerpony](https://github.com/dawngerpony) and [@janogonzalez](https://github.com/janogonzalez) in [#17125](https://github.com/backstage/backstage/pull/17125). + +### Scaffolder workspace serialization + +Added experimental support for serialization of workspaces in the scaffolder. By serializing the workspace, it is possible to re-run the task in a non-sticky way. This means that the task can be restored and retried on a different scaffolder task worker. + +To enable this feature, set the `EXPERIMENTAL_workspaceSerialization` option to `true` in the `scaffolder` section of the `app-config.yaml` file: + +```yaml +scaffolder: + EXPERIMENTAL_workspaceSerialization: true +``` + +Contributed by [@acierto](https://github.com/acierto) in [#24570](https://github.com/backstage/backstage/pull/24570). + +### Scaffolder `notification:send` action + +The new `notification:send` action allows sending notifications from templates. This can be used to send notifications to users when executing a template. Please note that the notifications system is still under development. + +To install this action, add the new module to your backend: + +```diff ++ backend.add(import('@backstage/plugin-scaffolder-backend-module-notifications')); +``` + +Contributed by [@drodil](https://github.com/drodil) in [#24588](https://github.com/backstage/backstage/pull/24588). + +### Backend Authentication + +The requirement to configure a secret for backend authentication in production has been removed. It is now only needed if you rely on the [legacy authentication mechanism](https://backstage.io/docs/auth/service-to-service-auth#external-callers-legacy). If you don’t configure any secrets you will also not be able to generate tokens with the `TokenManager` service, although use of this service is discouraged as it has been replaced by the `AuthService`. + +### User Authentication + +The `auth` backend plugin now provides an `authOwnershipResolutionExtensionPoint` that lets you override the default ownership resolution used by sign-in resolvers. This allows you to customize this logic for all sign-in resolvers without replacing them. + +Contributed by [@drodil](https://github.com/drodil) in [#22765](https://github.com/backstage/backstage/pull/22765). + +### Events support for GitLab Entity and Org Discovery + +The `GitlabDiscoveryEntityProvider` and `GitlabOrgDiscoveryEntityProvider` can now be configured to receive events from GitLab. This allows for the automatic discovery of entities in Backstage when groups or users are created or updated in GitLab. + +Contributed by [@elaine-mattos](https://github.com/elaine-mattos) in [#23373](https://github.com/backstage/backstage/pull/23373). + +## Security Fixes + +This release does not contain any security fixes. + +## Upgrade path + +We recommend that you keep your Backstage project up to date with this latest release. For more guidance on how to upgrade, check out the documentation for [keeping Backstage updated](https://backstage.io/docs/getting-started/keeping-backstage-updated). + +## Links and References + +Below you can find a list of links and references to help you learn about and start using this new release. + +- [Backstage official website](https://backstage.io/), [documentation](https://backstage.io/docs/), and [getting started guide](https://backstage.io/docs/getting-started/) +- [GitHub repository](https://github.com/backstage/backstage) +- Backstage's [versioning and support policy](https://backstage.io/docs/overview/versioning-policy) +- [Community Discord](https://discord.gg/backstage-687207715902193673) for discussions and support +- [Changelog](https://github.com/backstage/backstage/tree/master/docs/releases/v1.27.0-changelog.md) +- Backstage [Demos](https://backstage.io/demos), [Blog](https://backstage.io/blog), [Roadmap](https://backstage.io/docs/overview/roadmap) and [Plugins](https://backstage.io/plugins) + +Sign up for our [newsletter](https://info.backstage.spotify.com/newsletter_subscribe) if you want to be informed about what is happening in the world of Backstage. diff --git a/docs/releases/v1.3.0-changelog.md b/docs/releases/v1.3.0-changelog.md index 641fd8422a..e3cdd75024 100644 --- a/docs/releases/v1.3.0-changelog.md +++ b/docs/releases/v1.3.0-changelog.md @@ -883,8 +883,7 @@ ### Patch Changes - 8f7b1835df: Updated dependency `msw` to `^0.41.0`. -- 811ff4bcf4: Updated `swagger-ui-react` to 4.11.1 in order to address a [XSS - vulnerability](https://github.com/advisories/GHSA-hqq7-2q2v-82xq) in `@braintree/sanitize-url` +- 811ff4bcf4: Updated `swagger-ui-react` to 4.11.1 in order to address a [XSS vulnerability](https://github.com/advisories/GHSA-hqq7-2q2v-82xq) in `@braintree/sanitize-url` - Updated dependencies - @backstage/plugin-catalog@1.3.0 - @backstage/plugin-catalog-react@1.1.1 diff --git a/docs/releases/v1.6.0-changelog.md b/docs/releases/v1.6.0-changelog.md index 0308c5fd3d..0532243cbf 100644 --- a/docs/releases/v1.6.0-changelog.md +++ b/docs/releases/v1.6.0-changelog.md @@ -24,9 +24,7 @@ - 1fe6823bb5: Updated dependency `eslint-plugin-jest` to `^27.0.0`. Note that this major update to the Jest plugin contains some breaking changes. - This means that some of your tests may start seeing some new lint errors. [Read - about them - here](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md#2700-2022-08-28). + This means that some of your tests may start seeing some new lint errors. [Read about them here](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md#2700-2022-08-28). These are mostly possible to fix automatically. You can try to run `yarn backstage-cli repo lint --fix` in your repo root to have most or all of them corrected. diff --git a/docs/releases/v1.6.0-next.1-changelog.md b/docs/releases/v1.6.0-next.1-changelog.md index 3a1dc8f1b7..e749e32c98 100644 --- a/docs/releases/v1.6.0-next.1-changelog.md +++ b/docs/releases/v1.6.0-next.1-changelog.md @@ -7,9 +7,7 @@ - 1fe6823bb5: Updated dependency `eslint-plugin-jest` to `^27.0.0`. Note that this major update to the Jest plugin contains some breaking changes. - This means that some of your tests may start seeing some new lint errors. [Read - about them - here](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md#2700-2022-08-28). + This means that some of your tests may start seeing some new lint errors. [Read about them here](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md#2700-2022-08-28). These are mostly possible to fix automatically. You can try to run `yarn backstage-cli repo lint --fix` in your repo root to have most or all of them corrected. diff --git a/docs/releases/v1.7.0-changelog.md b/docs/releases/v1.7.0-changelog.md index 3653484952..47fd8463d6 100644 --- a/docs/releases/v1.7.0-changelog.md +++ b/docs/releases/v1.7.0-changelog.md @@ -926,8 +926,7 @@ Migrating to the stable version of `react-router` is optional for the time being. But if you want to do the same for your existing repository, please - follow [this - guide](https://backstage.io/docs/tutorials/react-router-stable-migration). + follow [this guide](https://backstage.io/docs/tutorials/react-router-stable-migration). - e05e0f021b: Update versions of packages used in the create-app template, to match those in the main repo diff --git a/docs/releases/v1.7.0-next.0-changelog.md b/docs/releases/v1.7.0-next.0-changelog.md index 57b3c64f6f..41d3ebd55f 100644 --- a/docs/releases/v1.7.0-next.0-changelog.md +++ b/docs/releases/v1.7.0-next.0-changelog.md @@ -319,8 +319,7 @@ Migrating to the stable version of `react-router` is optional for the time being. But if you want to do the same for your existing repository, please - follow [this - guide](https://backstage.io/docs/tutorials/react-router-stable-migration). + follow [this guide](https://backstage.io/docs/tutorials/react-router-stable-migration). - e05e0f021b: Update versions of packages used in the create-app template, to match those in the main repo diff --git a/docs/releases/v1.7.0.md b/docs/releases/v1.7.0.md index 56eda8b20d..edd5cbb591 100644 --- a/docs/releases/v1.7.0.md +++ b/docs/releases/v1.7.0.md @@ -22,24 +22,20 @@ backend needs to be supplied with a location analyzer for this use case to continue to function. If you want to make use of this feature, check out the installation instructions -in [the -changelog](https://github.com/backstage/backstage/blob/master/plugins/catalog-import/CHANGELOG.md#090). +in [the changelog](https://github.com/backstage/backstage/blob/master/plugins/catalog-import/CHANGELOG.md#090). Contributed by [@kissmikijr](https://github.com/kissmikijr) in [#13800](https://github.com/backstage/backstage/pull/13800) ### Permission Rule Changes -When defining permission rules, it's now necessary to provide a [Zod -Schema](https://github.com/colinhacks/zod) that specifies the parameters the +When defining permission rules, it's now necessary to provide a [Zod Schema](https://github.com/colinhacks/zod) that specifies the parameters the rule expects. This has been added to help better describe the parameters in the response of the metadata endpoint and to validate the parameters before a rule is executed. The signatures of the rule methods (`apply` and `toQuery`) have changed slightly as well. -You can read more about this in [the permissions -documentation](https://backstage.io/docs/permissions/overview) and [the -changelog](https://github.com/backstage/backstage/blob/master/plugins/permission-node/CHANGELOG.md#070). +You can read more about this in [the permissions documentation](https://backstage.io/docs/permissions/overview) and [the changelog](https://github.com/backstage/backstage/blob/master/plugins/permission-node/CHANGELOG.md#070). ### Migration: `jest` v29 @@ -64,8 +60,7 @@ Newly created Backstage repositories now use the stable version 6 of Migrating to the stable version of `react-router` is optional for the time being; Backstage has support for both versions. But if you want to do the same -for your existing repository, please follow [this -guide](https://backstage.io/docs/tutorials/react-router-stable-migration). +for your existing repository, please follow [this guide](https://backstage.io/docs/tutorials/react-router-stable-migration). Support for the beta version will be removed in a later release. ### Support for `__mocks__` and `__testUtils__` directories @@ -100,8 +95,7 @@ This release does not contain any security fixes. We recommend that you keep your Backstage project up to date with this latest release. For more guidance on how to upgrade, check out the documentation for -[keeping Backstage -updated](https://backstage.io/docs/getting-started/keeping-backstage-updated). +[keeping Backstage updated](https://backstage.io/docs/getting-started/keeping-backstage-updated). ## Links and References @@ -109,11 +103,9 @@ Below you can find a list of links and references to help you learn about and start using this new release. - [Backstage official website](https://backstage.io/), - [documentation](https://backstage.io/docs/), and [getting started - guide](https://backstage.io/docs/getting-started/) + [documentation](https://backstage.io/docs/), and [getting started guide](https://backstage.io/docs/getting-started/) - [GitHub repository](https://github.com/backstage/backstage) -- Backstage's [versioning and support - policy](https://backstage.io/docs/overview/versioning-policy) +- Backstage's [versioning and support policy](https://backstage.io/docs/overview/versioning-policy) - [Community Discord](https://discord.gg/backstage-687207715902193673) for discussions and support - [Changelog](https://github.com/backstage/backstage/tree/master/docs/releases/v1.7.0-changelog.md) - Backstage [Demos](https://backstage.io/demos), diff --git a/docs/tutorials/setup-opentelemetry.md b/docs/tutorials/setup-opentelemetry.md index c49eef26a2..30dde79db8 100644 --- a/docs/tutorials/setup-opentelemetry.md +++ b/docs/tutorials/setup-opentelemetry.md @@ -65,13 +65,19 @@ You can now start your Backstage instance as usual, using `yarn dev`. ## Production Setup -In your `Dockerfile` add the `--require` flag which points to the `instrumentation.js` file +In your `Dockerfile`, copy `instrumentation.js` file into the root of the working directory. + +```Dockerfile +COPY --chown=${NOT_ROOT_USER}:${NOT_ROOT_USER} packages/backend/src/instrumentation.js ./ +``` + +And then add the `--require` flag that points to the file to the CMD array. ```Dockerfile // highlight-remove-next-line CMD ["node", "packages/backend", "--config", "app-config.yaml"] // highlight-add-next-line -CMD ["node", "--require", "./src/instrumentation.js", "packages/backend", "--config", "app-config.yaml"] +CMD ["node", "--require", "./instrumentation.js", "packages/backend", "--config", "app-config.yaml"] ``` If you need to disable/configure some OpenTelemetry feature there are lots of [environment variables](https://opentelemetry.io/docs/specs/otel/configuration/sdk-environment-variables/) which you can tweak. diff --git a/microsite/docusaurus.config.ts b/microsite/docusaurus.config.ts index 5f6dfd3bc6..b7b98bf9e5 100644 --- a/microsite/docusaurus.config.ts +++ b/microsite/docusaurus.config.ts @@ -216,7 +216,7 @@ const config: Config = { position: 'left', }, { - to: 'docs/releases/v1.26.0', + to: 'docs/releases/v1.27.0', label: 'Releases', position: 'left', }, diff --git a/microsite/sidebars.json b/microsite/sidebars.json index f2fc4afdaa..bfb9215705 100644 --- a/microsite/sidebars.json +++ b/microsite/sidebars.json @@ -1,6 +1,7 @@ { "releases": { "Release Notes": [ + "releases/v1.27.0", "releases/v1.26.0", "releases/v1.25.0", "releases/v1.24.0", diff --git a/microsite/yarn.lock b/microsite/yarn.lock index 3ca3e2837a..572a8fe5fd 100644 --- a/microsite/yarn.lock +++ b/microsite/yarn.lock @@ -4334,9 +4334,9 @@ __metadata: linkType: hard "clsx@npm:^2.0.0": - version: 2.1.0 - resolution: "clsx@npm:2.1.0" - checksum: 43fefc29b6b49c9476fbce4f8b1cc75c27b67747738e598e6651dd40d63692135dc60b18fa1c5b78a2a9ba8ae6fd2055a068924b94e20b42039bd53b78b98e1d + version: 2.1.1 + resolution: "clsx@npm:2.1.1" + checksum: acd3e1ab9d8a433ecb3cc2f6a05ab95fe50b4a3cfc5ba47abb6cbf3754585fcb87b84e90c822a1f256c4198e3b41c7f6c391577ffc8678ad587fc0976b24fd57 languageName: node linkType: hard diff --git a/package.json b/package.json index 8611c9d59b..53c87544af 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "root", - "version": "1.27.0-next.2", + "version": "1.27.0", "private": true, "repository": { "type": "git", diff --git a/packages/app-defaults/CHANGELOG.md b/packages/app-defaults/CHANGELOG.md index 15f1c5bd67..5ab386f512 100644 --- a/packages/app-defaults/CHANGELOG.md +++ b/packages/app-defaults/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/app-defaults +## 1.5.5 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + ## 1.5.5-next.1 ### Patch Changes diff --git a/packages/app-defaults/package.json b/packages/app-defaults/package.json index d5955d863e..27533f2b9f 100644 --- a/packages/app-defaults/package.json +++ b/packages/app-defaults/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/app-defaults", - "version": "1.5.5-next.1", + "version": "1.5.5", "description": "Provides the default wiring of a Backstage App", "backstage": { "role": "web-library" diff --git a/packages/app-next-example-plugin/CHANGELOG.md b/packages/app-next-example-plugin/CHANGELOG.md index fa7d0f3107..356ed1f378 100644 --- a/packages/app-next-example-plugin/CHANGELOG.md +++ b/packages/app-next-example-plugin/CHANGELOG.md @@ -1,5 +1,13 @@ # app-next-example-plugin +## 0.0.11 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/frontend-plugin-api@0.6.5 + ## 0.0.11-next.1 ### Patch Changes diff --git a/packages/app-next-example-plugin/package.json b/packages/app-next-example-plugin/package.json index 55dd01aea5..e601961ef6 100644 --- a/packages/app-next-example-plugin/package.json +++ b/packages/app-next-example-plugin/package.json @@ -1,6 +1,6 @@ { "name": "app-next-example-plugin", - "version": "0.0.11-next.1", + "version": "0.0.11", "description": "Backstage internal example plugin", "backstage": { "role": "frontend-plugin" diff --git a/packages/app-next/CHANGELOG.md b/packages/app-next/CHANGELOG.md index 890f1ca20b..3f03cac54f 100644 --- a/packages/app-next/CHANGELOG.md +++ b/packages/app-next/CHANGELOG.md @@ -1,5 +1,44 @@ # example-app-next +## 0.0.11 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-react@1.8.5 + - @backstage/plugin-scaffolder@1.20.0 + - @backstage/plugin-user-settings@0.8.6 + - @backstage/plugin-catalog@1.20.0 + - @backstage/plugin-notifications@0.2.1 + - @backstage/core-compat-api@0.2.5 + - @backstage/plugin-api-docs@0.11.5 + - @backstage/plugin-home@0.7.4 + - @backstage/cli@0.26.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-techdocs@1.10.5 + - @backstage/plugin-catalog-import@0.11.0 + - @backstage/frontend-app-api@0.7.0 + - @backstage/plugin-auth-react@0.1.2 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/plugin-catalog-graph@0.4.5 + - @backstage/plugin-search@1.4.11 + - @backstage/plugin-org@0.6.25 + - @backstage/app-defaults@1.5.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-app-visualizer@0.1.6 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-catalog-unprocessed-entities@0.2.4 + - @backstage/plugin-kubernetes@0.11.10 + - @backstage/plugin-kubernetes-cluster@0.0.11 + - @backstage/plugin-search-react@1.7.11 + - @backstage/plugin-signals@0.0.6 + - @backstage/plugin-techdocs-module-addons-contrib@1.1.10 + - @backstage/plugin-techdocs-react@1.2.4 + ## 0.0.11-next.2 ### Patch Changes diff --git a/packages/app-next/package.json b/packages/app-next/package.json index d7b286e0fa..d5f69915a9 100644 --- a/packages/app-next/package.json +++ b/packages/app-next/package.json @@ -1,6 +1,6 @@ { "name": "example-app-next", - "version": "0.0.11-next.2", + "version": "0.0.11", "private": true, "repository": { "type": "git", diff --git a/packages/app-next/src/App.tsx b/packages/app-next/src/App.tsx index 83b921aea1..c911a01258 100644 --- a/packages/app-next/src/App.tsx +++ b/packages/app-next/src/App.tsx @@ -80,7 +80,7 @@ TODO: const homePageExtension = createExtension({ name: 'myhomepage', - attachTo: { id: 'home', input: 'props' }, + attachTo: { id: 'page:home', input: 'props' }, output: { children: coreExtensionData.reactElement, title: titleExtensionDataRef, diff --git a/packages/app/CHANGELOG.md b/packages/app/CHANGELOG.md index 3b8d6ca936..fa01c31fd6 100644 --- a/packages/app/CHANGELOG.md +++ b/packages/app/CHANGELOG.md @@ -1,5 +1,42 @@ # example-app +## 0.2.97 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-react@1.8.5 + - @backstage/plugin-scaffolder@1.20.0 + - @backstage/plugin-user-settings@0.8.6 + - @backstage/plugin-catalog@1.20.0 + - @backstage/plugin-notifications@0.2.1 + - @backstage/plugin-api-docs@0.11.5 + - @backstage/plugin-home@0.7.4 + - @backstage/cli@0.26.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-techdocs@1.10.5 + - @backstage/plugin-catalog-import@0.11.0 + - @backstage/frontend-app-api@0.7.0 + - @backstage/plugin-auth-react@0.1.2 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/plugin-catalog-graph@0.4.5 + - @backstage/plugin-search@1.4.11 + - @backstage/plugin-org@0.6.25 + - @backstage/app-defaults@1.5.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-catalog-unprocessed-entities@0.2.4 + - @backstage/plugin-devtools@0.1.14 + - @backstage/plugin-kubernetes@0.11.10 + - @backstage/plugin-kubernetes-cluster@0.0.11 + - @backstage/plugin-search-react@1.7.11 + - @backstage/plugin-signals@0.0.6 + - @backstage/plugin-techdocs-module-addons-contrib@1.1.10 + - @backstage/plugin-techdocs-react@1.2.4 + ## 0.2.97-next.2 ### Patch Changes diff --git a/packages/app/package.json b/packages/app/package.json index 13466e1b41..9978c6fcb4 100644 --- a/packages/app/package.json +++ b/packages/app/package.json @@ -1,6 +1,6 @@ { "name": "example-app", - "version": "0.2.97-next.2", + "version": "0.2.97", "backstage": { "role": "frontend" }, diff --git a/packages/backend-app-api/CHANGELOG.md b/packages/backend-app-api/CHANGELOG.md index 733a19d81e..96259c80da 100644 --- a/packages/backend-app-api/CHANGELOG.md +++ b/packages/backend-app-api/CHANGELOG.md @@ -1,5 +1,32 @@ # @backstage/backend-app-api +## 0.7.3 + +### Patch Changes + +- 4cd5ff0: Add ability to configure the Node.js HTTP Server when configuring the root HTTP Router service +- e8199b1: Move the JWKS registration outside of the lifecycle middleware +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- dc8c5dd: The default `TokenManager` implementation no longer requires keys to be configured in production, but it will throw an errors when generating or authenticating tokens. The default `AuthService` implementation will now also provide additional context if such an error is throw when falling back to using the `TokenManager` service to generate tokens for outgoing requests. +- 025641b: Redact `meta` fields too with the logger +- 09f8988: Remove explicit `alg` check for user tokens in `verifyToken` +- 5863e02: Internal refactor to only create one external token handler +- a1dc547: Added support for camel case CSP directives in app-config. For example: + + ```yaml + backend: + csp: + upgradeInsecureRequests: false + ``` + +- 329cc34: Added logging of all plugins being initialized, periodic status, and completion. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-permission-node@0.7.29 + ## 0.7.2-next.1 ### Patch Changes diff --git a/packages/backend-app-api/package.json b/packages/backend-app-api/package.json index f188b4aa51..414a4333e7 100644 --- a/packages/backend-app-api/package.json +++ b/packages/backend-app-api/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/backend-app-api", - "version": "0.7.3-next.1", + "version": "0.7.3", "description": "Core API used by Backstage backend apps", "backstage": { "role": "node-library" @@ -83,6 +83,7 @@ "path-to-regexp": "^6.2.1", "selfsigned": "^2.0.0", "stoppable": "^1.1.0", + "triple-beam": "^1.4.1", "uuid": "^9.0.0", "winston": "^3.2.1", "winston-transport": "^4.5.0" diff --git a/packages/backend-app-api/src/http/readHelmetOptions.test.ts b/packages/backend-app-api/src/http/readHelmetOptions.test.ts index bc31404634..97daef359a 100644 --- a/packages/backend-app-api/src/http/readHelmetOptions.test.ts +++ b/packages/backend-app-api/src/http/readHelmetOptions.test.ts @@ -47,7 +47,8 @@ describe('readHelmetOptions', () => { csp: { key: ['value'], 'img-src': false, - 'script-src-attr': ['custom'], + scriptSrcAttr: ['custom'], + 'object-src': ['asd'], }, }); expect(readHelmetOptions(config)).toEqual({ @@ -58,7 +59,7 @@ describe('readHelmetOptions', () => { 'base-uri': ["'self'"], 'font-src': ["'self'", 'https:', 'data:'], 'frame-ancestors': ["'self'"], - 'object-src': ["'none'"], + 'object-src': ['asd'], 'script-src': ["'self'", "'unsafe-eval'"], 'style-src': ["'self'", 'https:', "'unsafe-inline'"], 'script-src-attr': ['custom'], diff --git a/packages/backend-app-api/src/http/readHelmetOptions.ts b/packages/backend-app-api/src/http/readHelmetOptions.ts index 0555bdef00..510fdd9586 100644 --- a/packages/backend-app-api/src/http/readHelmetOptions.ts +++ b/packages/backend-app-api/src/http/readHelmetOptions.ts @@ -18,6 +18,7 @@ import { Config } from '@backstage/config'; import helmet from 'helmet'; import { HelmetOptions } from 'helmet'; import { ContentSecurityPolicyOptions } from 'helmet/dist/types/middlewares/content-security-policy'; +import kebabCase from 'lodash/kebabCase'; /** * Attempts to read Helmet options from the backend configuration object. @@ -97,10 +98,11 @@ export function applyCspDirectives( if (directives) { for (const [key, value] of Object.entries(directives)) { + const kebabCaseKey = kebabCase(key); if (value === false) { - delete result[key]; + delete result[kebabCaseKey]; } else { - result[key] = value; + result[kebabCaseKey] = value; } } } diff --git a/packages/backend-app-api/src/logging/WinstonLogger.test.ts b/packages/backend-app-api/src/logging/WinstonLogger.test.ts index d025719d9a..4b608f8e57 100644 --- a/packages/backend-app-api/src/logging/WinstonLogger.test.ts +++ b/packages/backend-app-api/src/logging/WinstonLogger.test.ts @@ -14,12 +14,10 @@ * limitations under the License. */ -import { TransformableInfo } from 'logform'; +import { format } from 'logform'; import { WinstonLogger } from './WinstonLogger'; - -function msg(info: TransformableInfo): TransformableInfo { - return { message: info.message, level: info.level, stack: info.stack }; -} +import Transport from 'winston-transport'; +import { MESSAGE } from 'triple-beam'; describe('WinstonLogger', () => { it('creates a winston logger instance with default options', () => { @@ -33,49 +31,66 @@ describe('WinstonLogger', () => { expect(childLogger).toBeInstanceOf(WinstonLogger); }); - it('redacter should redact and escape regex', () => { - const redacter = WinstonLogger.redacter(); - const log = { - level: 'error', - message: 'hello (world)', - stack: 'hello (world) from this file', - }; - expect(redacter.format.transform(msg(log))).toEqual(msg(log)); - redacter.add(['hello\n']); - expect(redacter.format.transform(msg(log))).toEqual( - msg({ - ...log, - message: '[REDACTED] (world)', - stack: '[REDACTED] (world) from this file', - }), - ); - redacter.add(['(world']); - expect(redacter.format.transform(msg(log))).toEqual( - msg({ - ...log, - message: '[REDACTED] [REDACTED])', - stack: '[REDACTED] [REDACTED]) from this file', + it('should redact and escape regex', () => { + const mockTransport = new Transport({ + log: jest.fn(), + logv: jest.fn(), + }); + + const logger = WinstonLogger.create({ + format: format.json(), + transports: [mockTransport], + }); + + logger.addRedactions(['hello (world']); + + logger.error('hello (world) from this file'); + + expect(mockTransport.log).toHaveBeenCalledWith( + expect.objectContaining({ + [MESSAGE]: JSON.stringify({ + level: 'error', + message: '[REDACTED]) from this file', + }), }), + expect.any(Function), ); }); - it('redacter should redact nested object', () => { - const redacter = WinstonLogger.redacter(); - const log = { - level: 'error', - message: { - nested: 'hello (world) from nested object', - }, - }; + it('should redact nested object', () => { + const mockTransport = new Transport({ + log: jest.fn(), + logv: jest.fn(), + }); - redacter.add(['hello']); - expect(redacter.format.transform(msg(log))).toEqual( - msg({ - ...log, - message: { - nested: '[REDACTED] (world) from nested object', - }, + const logger = WinstonLogger.create({ + format: format.json(), + transports: [mockTransport], + }); + + logger.addRedactions(['hello']); + + logger.error('something went wrong', { + null: null, + nested: 'hello (world) from nested object', + nullProto: Object.create(null, { + foo: { value: 'hello foo', enumerable: true }, }), + }); + + expect(mockTransport.log).toHaveBeenCalledWith( + expect.objectContaining({ + [MESSAGE]: JSON.stringify({ + level: 'error', + message: 'something went wrong', + nested: '[REDACTED] (world) from nested object', + null: null, + nullProto: { + foo: '[REDACTED] foo', + }, + }), + }), + expect.any(Function), ); }); }); diff --git a/packages/backend-app-api/src/logging/WinstonLogger.ts b/packages/backend-app-api/src/logging/WinstonLogger.ts index 8d4b37bb8d..8ee86d247f 100644 --- a/packages/backend-app-api/src/logging/WinstonLogger.ts +++ b/packages/backend-app-api/src/logging/WinstonLogger.ts @@ -27,6 +27,7 @@ import { transports, transport as Transport, } from 'winston'; +import { MESSAGE } from 'triple-beam'; import { escapeRegExp } from '../lib/escapeRegExp'; /** @@ -61,8 +62,8 @@ export class WinstonLogger implements RootLoggerService { let logger = createLogger({ level: process.env.LOG_LEVEL || options.level || 'info', format: format.combine( - redacter.format, options.format ?? defaultFormatter, + redacter.format, ), transports: options.transports ?? new transports.Console(), }); @@ -85,20 +86,16 @@ export class WinstonLogger implements RootLoggerService { let redactionPattern: RegExp | undefined = undefined; - const replace = (obj: TransformableInfo) => { - for (const key in obj) { - if (obj.hasOwnProperty(key)) { - if (typeof obj[key] === 'object') { - obj[key] = replace(obj[key] as TransformableInfo); - } else if (typeof obj[key] === 'string') { - obj[key] = obj[key]?.replace(redactionPattern, '[REDACTED]'); - } - } - } - return obj; - }; return { - format: format(replace)(), + format: format((obj: TransformableInfo) => { + if (!redactionPattern || !obj) { + return obj; + } + + obj[MESSAGE] = obj[MESSAGE]?.replace?.(redactionPattern, '[REDACTED]'); + + return obj; + })(), add(newRedactions) { let added = 0; for (const redactionToTrim of newRedactions) { diff --git a/packages/backend-app-api/src/services/implementations/auth/DatabaseKeyStore.ts b/packages/backend-app-api/src/services/implementations/auth/DatabaseKeyStore.ts index 6a1536fd18..5bf9244707 100644 --- a/packages/backend-app-api/src/services/implementations/auth/DatabaseKeyStore.ts +++ b/packages/backend-app-api/src/services/implementations/auth/DatabaseKeyStore.ts @@ -14,11 +14,14 @@ * limitations under the License. */ -import { DatabaseService, LoggerService } from '@backstage/backend-plugin-api'; +import { + DatabaseService, + LoggerService, + resolvePackagePath, +} from '@backstage/backend-plugin-api'; import { DateTime } from 'luxon'; import { Knex } from 'knex'; import { JsonObject } from '@backstage/types'; -import { resolvePackagePath } from '@backstage/backend-common'; import { KeyStore } from './types'; const MIGRATIONS_TABLE = 'backstage_backend_public_keys__knex_migrations'; diff --git a/packages/backend-app-api/src/wiring/BackendInitializer.ts b/packages/backend-app-api/src/wiring/BackendInitializer.ts index fe949c2e33..1bf38a8c40 100644 --- a/packages/backend-app-api/src/wiring/BackendInitializer.ts +++ b/packages/backend-app-api/src/wiring/BackendInitializer.ts @@ -31,6 +31,7 @@ import { ForwardedError, ConflictError } from '@backstage/errors'; import { featureDiscoveryServiceRef } from '@backstage/backend-plugin-api/alpha'; import { DependencyGraph } from '../lib/DependencyGraph'; import { ServiceRegistry } from './ServiceRegistry'; +import { createInitializationLogger } from './createInitializationLogger'; export interface BackendRegisterInit { consumes: Set; @@ -226,6 +227,11 @@ export class BackendInitializer { const allPluginIds = [...pluginInits.keys()]; + const initLogger = createInitializationLogger( + allPluginIds, + await this.#serviceRegistry.get(coreServices.rootLogger, 'root'), + ); + // All plugins are initialized in parallel await Promise.all( allPluginIds.map(async pluginId => { @@ -289,6 +295,8 @@ export class BackendInitializer { }); } + initLogger.onPluginStarted(pluginId); + // Once the plugin and all modules have been initialized, we can signal that the plugin has stared up successfully const lifecycleService = await this.#getPluginLifecycleImpl(pluginId); await lifecycleService.startup(); @@ -299,6 +307,8 @@ export class BackendInitializer { const lifecycleService = await this.#getRootLifecycleImpl(); await lifecycleService.startup(); + initLogger.onAllStarted(); + // Once the backend is started, any uncaught errors or unhandled rejections are caught // and logged, in order to avoid crashing the entire backend on local failures. if (process.env.NODE_ENV !== 'test') { diff --git a/packages/backend-app-api/src/wiring/createInitializationLogger.ts b/packages/backend-app-api/src/wiring/createInitializationLogger.ts new file mode 100644 index 0000000000..566b5507ec --- /dev/null +++ b/packages/backend-app-api/src/wiring/createInitializationLogger.ts @@ -0,0 +1,79 @@ +/* + * Copyright 2024 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { RootLoggerService } from '@backstage/backend-plugin-api'; + +const LOGGER_INTERVAL_MAX = 60_000; + +function joinIds(ids: Iterable): string { + return [...ids].map(id => `'${id}'`).join(', '); +} + +export function createInitializationLogger( + pluginIds: string[], + rootLogger?: RootLoggerService, +): { + onPluginStarted(pluginId: string): void; + onAllStarted(): void; +} { + const logger = rootLogger?.child({ type: 'initialization' }); + const starting = new Set(pluginIds); + const started = new Set(); + + logger?.info(`Plugin initialization started: ${joinIds(pluginIds)}`); + + const getInitStatus = () => { + let status = ''; + if (started.size > 0) { + status = `, newly initialized: ${joinIds(started)}`; + started.clear(); + } + if (starting.size > 0) { + status += `, still initializing: ${joinIds(starting)}`; + } + return status; + }; + + // Periodically log the initialization status with a fibonacci backoff + let interval = 1000; + let prevInterval = 0; + let timeout: NodeJS.Timeout | undefined; + const onTimeout = () => { + logger?.info(`Plugin initialization in progress${getInitStatus()}`); + + const nextInterval = Math.min(interval + prevInterval, LOGGER_INTERVAL_MAX); + prevInterval = interval; + interval = nextInterval; + + timeout = setTimeout(onTimeout, nextInterval); + }; + timeout = setTimeout(onTimeout, interval); + + return { + onPluginStarted(pluginId: string) { + starting.delete(pluginId); + started.add(pluginId); + }, + onAllStarted() { + logger?.info(`Plugin initialization complete${getInitStatus()}`); + + if (timeout) { + clearTimeout(timeout); + timeout = undefined; + } + }, + }; +} diff --git a/packages/backend-common/CHANGELOG.md b/packages/backend-common/CHANGELOG.md index 3ab27aa3bf..70136051d0 100644 --- a/packages/backend-common/CHANGELOG.md +++ b/packages/backend-common/CHANGELOG.md @@ -1,5 +1,28 @@ # @backstage/backend-common +## 0.22.0 + +### Minor Changes + +- ed83f85: Internal refactor of the database code. + + **BREAKING**: The helper functions `createDatabaseClient` and `ensureDatabaseExists` have been removed from the public interface, since they have no usage within the repository and never were suitable for calling from the outside. Please consider using `coreServices.database` or `DatabaseManager` directly wherever possible instead. + +### Patch Changes + +- 2cc750d: Added `HarnessURLReader` with `readUrl` support. +- 57f692e: Preparing for a stable new backend system release, we are deprecating utilities in the `backend-common` that are not used by the core framework, such as the isomorphic `Git` class. As we will no longer support the isomorphic `Git` utility in the framework packages, we recommend plugins that start maintaining their own implementation of this class. +- 0ec0796: Plugins created through the `legacyPlugin` helper are now able to authenticate requests from plugins that are fully implemented using the new backend system. This fixes the `Key for the ES256 algorithm must be one of type KeyObject or CryptoKey. Received an instance of Uint8Array` error. +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- ccc8851: Added config prop `ensureSchemaExists` to support postgres instances where user can create schemas but not databases. +- f66bbb4: Only create a single actual connection to memcache/redis, even in cases where many `CacheService` instances are made +- ba0b8b4: Added option to `ServerTokenManager.fromConfig` that allows it to be instantiated in production without any configured keys. +- Updated dependencies + - @backstage/backend-app-api@0.7.3 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/integration@1.11.0 + ## 0.22.0-next.2 ### Patch Changes diff --git a/packages/backend-common/api-report-testUtils.md b/packages/backend-common/api-report-testUtils.md index 9dbdade10e..d53748234e 100644 --- a/packages/backend-common/api-report-testUtils.md +++ b/packages/backend-common/api-report-testUtils.md @@ -3,24 +3,19 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts -// @public -export function overridePackagePathResolution( - options: OverridePackagePathResolutionOptions, -): PackagePathResolutionOverride; +import { overridePackagePathResolution as overridePackagePathResolution_2 } from '@backstage/backend-plugin-api/testUtils'; +import { OverridePackagePathResolutionOptions as OverridePackagePathResolutionOptions_2 } from '@backstage/backend-plugin-api/testUtils'; +import { PackagePathResolutionOverride as PackagePathResolutionOverride_2 } from '@backstage/backend-plugin-api/testUtils'; -// @public (undocumented) -export interface OverridePackagePathResolutionOptions { - packageName: string; - path?: string; - paths?: { - [path in string]: string | (() => string); - }; -} +// @public @deprecated (undocumented) +export const overridePackagePathResolution: typeof overridePackagePathResolution_2; -// @public (undocumented) -export interface PackagePathResolutionOverride { - restore(): void; -} +// @public @deprecated (undocumented) +export type OverridePackagePathResolutionOptions = + OverridePackagePathResolutionOptions_2; + +// @public @deprecated (undocumented) +export type PackagePathResolutionOverride = PackagePathResolutionOverride_2; // (No @packageDocumentation comment for this package) ``` diff --git a/packages/backend-common/api-report.md b/packages/backend-common/api-report.md index cccf326b9f..42df32dc1d 100644 --- a/packages/backend-common/api-report.md +++ b/packages/backend-common/api-report.md @@ -34,7 +34,7 @@ import { HarnessIntegration } from '@backstage/integration'; import { HostDiscovery as HostDiscovery_2 } from '@backstage/backend-app-api'; import { HttpAuthService } from '@backstage/backend-plugin-api'; import { IdentityService } from '@backstage/backend-plugin-api'; -import { isChildPath } from '@backstage/cli-common'; +import { isChildPath as isChildPath_2 } from '@backstage/backend-plugin-api'; import { KubeConfig } from '@kubernetes/client-node'; import { LifecycleService } from '@backstage/backend-plugin-api'; import { LoadConfigOptionsRemote } from '@backstage/config-loader'; @@ -55,6 +55,8 @@ import { ReadTreeResponseFile } from '@backstage/backend-plugin-api'; import { ReadUrlOptions } from '@backstage/backend-plugin-api'; import { ReadUrlResponse } from '@backstage/backend-plugin-api'; import { RequestHandler } from 'express'; +import { resolvePackagePath as resolvePackagePath_2 } from '@backstage/backend-plugin-api'; +import { resolveSafeChildPath as resolveSafeChildPath_2 } from '@backstage/backend-plugin-api'; import { RootConfigService } from '@backstage/backend-plugin-api'; import { Router } from 'express'; import { SchedulerService } from '@backstage/backend-plugin-api'; @@ -71,7 +73,7 @@ import { V1PodTemplateSpec } from '@kubernetes/client-node'; import * as winston from 'winston'; import { Writable } from 'stream'; -// @public +// @public @deprecated export type AuthCallbackOptions = { onAuth: AuthCallback; logger?: LoggerService; @@ -370,7 +372,7 @@ export function getRootLogger(): winston.Logger; // @public export function getVoidLogger(): winston.Logger; -// @public +// @public @deprecated export class Git { // (undocumented) add(options: { dir: string; filepath: string }): Promise; @@ -533,7 +535,8 @@ export class HarnessUrlReader implements UrlReader { // @public export const HostDiscovery: typeof HostDiscovery_2; -export { isChildPath }; +// @public @deprecated (undocumented) +export const isChildPath: typeof isChildPath_2; // @public export function isDatabaseConflictError(e: unknown): boolean; @@ -738,11 +741,11 @@ export type RequestLoggingHandlerFactory = ( logger?: LoggerService, ) => RequestHandler; -// @public -export function resolvePackagePath(name: string, ...paths: string[]): string; +// @public @deprecated (undocumented) +export const resolvePackagePath: typeof resolvePackagePath_2; -// @public -export function resolveSafeChildPath(base: string, path: string): string; +// @public @deprecated (undocumented) +export const resolveSafeChildPath: typeof resolveSafeChildPath_2; // @public export type RunContainerOptions = { @@ -818,7 +821,7 @@ export function setRootLogger(newLogger: winston.Logger): void; // @public @deprecated export const SingleHostDiscovery: typeof HostDiscovery_2; -// @public +// @public @deprecated export type StaticAuthOptions = { username?: string; password?: string; diff --git a/packages/backend-common/package.json b/packages/backend-common/package.json index 52ae56cff4..8e0d388352 100644 --- a/packages/backend-common/package.json +++ b/packages/backend-common/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/backend-common", - "version": "0.22.0-next.2", + "version": "0.22.0", "description": "Common functionality library for Backstage backends", "backstage": { "role": "node-library" diff --git a/packages/backend-common/src/cache/CacheManager.integration.test.ts b/packages/backend-common/src/cache/CacheManager.integration.test.ts new file mode 100644 index 0000000000..7dc60a9051 --- /dev/null +++ b/packages/backend-common/src/cache/CacheManager.integration.test.ts @@ -0,0 +1,88 @@ +/* + * Copyright 2024 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { ConfigReader } from '@backstage/config'; +import { CacheManager } from './CacheManager'; +import KeyvRedis from '@keyv/redis'; + +// This test is in a separate file because the main test file uses other mocking +// that might interfere with this one. + +// Contrived code because it's hard to spy on a default export +jest.mock('@keyv/redis', () => { + const ActualKeyvRedis = jest.requireActual('@keyv/redis'); + return jest + .fn() + .mockImplementation((...args: any[]) => new ActualKeyvRedis(...args)); +}); + +describe('CacheManager integration', () => { + describe('redis', () => { + it('only creates one underlying connection', async () => { + const manager = CacheManager.fromConfig( + new ConfigReader({ + backend: { + cache: { + store: 'redis', + // no actual connection errors will be seen since we don't interact with it + connection: 'redis://localhost:6379', + }, + }, + }), + ); + + manager.forPlugin('p1').getClient(); + manager.forPlugin('p1').getClient({ defaultTtl: 200 }); + manager.forPlugin('p2').getClient(); + manager.forPlugin('p3').getClient({}); + + expect(KeyvRedis).toHaveBeenCalledTimes(1); + }); + + it('interacts correctly with redis', async () => { + // TODO(freben): This could be frameworkified as TestCaches just like + // TestDatabases, but that will have to come some other day + const connection = + process.env.BACKSTAGE_TEST_CACHE_REDIS_CONNECTION_STRING; + if (!connection) { + return; + } + + const manager = CacheManager.fromConfig( + new ConfigReader({ + backend: { + cache: { + store: 'redis', + connection, + }, + }, + }), + ); + + const plugin1 = manager.forPlugin('p1').getClient(); + const plugin2a = manager.forPlugin('p2').getClient(); + const plugin2b = manager.forPlugin('p2').getClient({ defaultTtl: 2000 }); + + await plugin1.set('a', 'plugin1'); + await plugin2a.set('a', 'plugin2a'); + await plugin2b.set('a', 'plugin2b'); + + await expect(plugin1.get('a')).resolves.toBe('plugin1'); + await expect(plugin2a.get('a')).resolves.toBe('plugin2b'); + await expect(plugin2b.get('a')).resolves.toBe('plugin2b'); + }); + }); +}); diff --git a/packages/backend-common/src/cache/CacheManager.ts b/packages/backend-common/src/cache/CacheManager.ts index c7298ab3e9..ec8a1d93f7 100644 --- a/packages/backend-common/src/cache/CacheManager.ts +++ b/packages/backend-common/src/cache/CacheManager.ts @@ -27,6 +27,8 @@ import { getRootLogger } from '../logging'; import { DefaultCacheClient } from './CacheClient'; import { CacheManagerOptions, PluginCacheManager } from './types'; +type StoreFactory = (pluginId: string, defaultTtl: number | undefined) => Keyv; + /** * Implements a Cache Manager which will automatically create new cache clients * for plugins when requested. All requested cache clients are created with the @@ -40,18 +42,11 @@ export class CacheManager { * that return Keyv instances appropriate to the store. */ private readonly storeFactories = { - redis: this.getRedisClient, - memcache: this.getMemcacheClient, - memory: this.getMemoryClient, + redis: this.createRedisStoreFactory(), + memcache: this.createMemcacheStoreFactory(), + memory: this.createMemoryStoreFactory(), }; - /** - * Shared memory store for the in-memory cache client. Sharing the same Map - * instance ensures get/set/delete operations hit the same store, regardless - * of where/when a client is instantiated. - */ - private readonly memoryStore = new Map(); - private readonly logger: LoggerService; private readonly store: keyof CacheManager['storeFactories']; private readonly connection: string; @@ -148,41 +143,46 @@ export class CacheManager { } private getClientWithTtl(pluginId: string, ttl: number | undefined): Keyv { - return this.storeFactories[this.store].call(this, pluginId, ttl); + return this.storeFactories[this.store](pluginId, ttl); } - private getRedisClient( - pluginId: string, - defaultTtl: number | undefined, - ): Keyv { - return new Keyv({ - namespace: pluginId, - ttl: defaultTtl, - store: new KeyvRedis(this.connection), - useRedisSets: this.useRedisSets, - }); + private createRedisStoreFactory(): StoreFactory { + let store: KeyvRedis | undefined; + return (pluginId, defaultTtl) => { + if (!store) { + store = new KeyvRedis(this.connection); + } + return new Keyv({ + namespace: pluginId, + ttl: defaultTtl, + store, + useRedisSets: this.useRedisSets, + }); + }; } - private getMemcacheClient( - pluginId: string, - defaultTtl: number | undefined, - ): Keyv { - return new Keyv({ - namespace: pluginId, - ttl: defaultTtl, - store: new KeyvMemcache(this.connection), - }); + private createMemcacheStoreFactory(): StoreFactory { + let store: KeyvMemcache | undefined; + return (pluginId, defaultTtl) => { + if (!store) { + store = new KeyvMemcache(this.connection); + } + return new Keyv({ + namespace: pluginId, + ttl: defaultTtl, + store, + }); + }; } - private getMemoryClient( - pluginId: string, - defaultTtl: number | undefined, - ): Keyv { - return new Keyv({ - namespace: pluginId, - ttl: defaultTtl, - store: this.memoryStore, - }); + private createMemoryStoreFactory(): StoreFactory { + const store = new Map(); + return (pluginId, defaultTtl) => + new Keyv({ + namespace: pluginId, + ttl: defaultTtl, + store, + }); } } diff --git a/packages/backend-common/src/database/connectors/mysql.ts b/packages/backend-common/src/database/connectors/mysql.ts index 1ad8b0b3be..2fb3545047 100644 --- a/packages/backend-common/src/database/connectors/mysql.ts +++ b/packages/backend-common/src/database/connectors/mysql.ts @@ -304,7 +304,7 @@ export class MysqlConnector implements Connector { const pluginDivisionMode = this.getPluginDivisionModeConfig(); if (pluginDivisionMode !== 'database') { throw new Error( - `The MySQL driver does not suppoert plugin division mode '${pluginDivisionMode}'`, + `The MySQL driver does not support plugin division mode '${pluginDivisionMode}'`, ); } diff --git a/packages/backend-common/src/deprecated/index.ts b/packages/backend-common/src/deprecated/index.ts new file mode 100644 index 0000000000..708e358bfc --- /dev/null +++ b/packages/backend-common/src/deprecated/index.ts @@ -0,0 +1,44 @@ +/* + * Copyright 2024 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +export * from './scm'; + +import { + resolvePackagePath as _resolvePackagePath, + resolveSafeChildPath as _resolveSafeChildPath, + isChildPath as _isChildPath, +} from '@backstage/backend-plugin-api'; + +/** + * @public + * @deprecated This type is deprecated and will be removed in a future release, see https://github.com/backstage/backstage/issues/24493. + * Please use the `resolvePackagePath` function from the `@backstage/backend-plugin-api` package instead. + */ +export const resolvePackagePath = _resolvePackagePath; + +/** + * @public + * @deprecated This type is deprecated and will be removed in a future release, see + * Please use the `resolveSafeChildPath` function from the `@backstage/backend-plugin-api` package instead. + */ +export const resolveSafeChildPath = _resolveSafeChildPath; + +/** + * @public + * @deprecated This type is deprecated and will be removed in a future release, see + * Please use the `isChildPath` function from the `@backstage/cli-common` package instead. + */ +export const isChildPath = _isChildPath; diff --git a/packages/backend-common/src/scm/git.test.ts b/packages/backend-common/src/deprecated/scm/git.test.ts similarity index 100% rename from packages/backend-common/src/scm/git.test.ts rename to packages/backend-common/src/deprecated/scm/git.test.ts diff --git a/packages/backend-common/src/deprecated/scm/git.ts b/packages/backend-common/src/deprecated/scm/git.ts new file mode 100644 index 0000000000..1a182e6f4d --- /dev/null +++ b/packages/backend-common/src/deprecated/scm/git.ts @@ -0,0 +1,357 @@ +/* + * Copyright 2020 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import git, { + ProgressCallback, + MergeResult, + ReadCommitResult, + AuthCallback, +} from 'isomorphic-git'; +import http from 'isomorphic-git/http/node'; +import fs from 'fs-extra'; +import { LoggerService } from '@backstage/backend-plugin-api'; + +function isAuthCallbackOptions( + options: StaticAuthOptions | AuthCallbackOptions, +): options is AuthCallbackOptions { + return 'onAuth' in options; +} + +/** + * Configure static credential for authentication + * @public + * @deprecated This type is deprecated and will be removed in a future release, see https://github.com/backstage/backstage/issues/24493. + */ +export type StaticAuthOptions = { + username?: string; + password?: string; + token?: string; + logger?: LoggerService; +}; + +/** + * Configure an authentication callback that can provide credentials on demand + * @public + * @deprecated This type is deprecated and will be removed in a future release, see https://github.com/backstage/backstage/issues/24493. + */ +export type AuthCallbackOptions = { + onAuth: AuthCallback; + logger?: LoggerService; +}; + +/* +provider username password +Azure 'notempty' token +Bitbucket Cloud 'x-token-auth' token +Bitbucket Server username password or token +GitHub 'x-access-token' token +GitLab 'oauth2' token + +From : https://isomorphic-git.org/docs/en/onAuth with fix for GitHub + +Or token provided as `token` for Bearer auth header +instead of Basic Auth (e.g., Bitbucket Server). +*/ + +/** + * A convenience wrapper around the `isomorphic-git` library. + * @public + * @deprecated This class is deprecated and will be removed in a future release, see https://github.com/backstage/backstage/issues/24493. + */ + +export class Git { + private readonly headers: { + [x: string]: string; + }; + + private constructor( + private readonly config: { + onAuth: AuthCallback; + token?: string; + logger?: LoggerService; + }, + ) { + this.onAuth = config.onAuth; + + this.headers = { + 'user-agent': 'git/@isomorphic-git', + ...(config.token ? { Authorization: `Bearer ${config.token}` } : {}), + }; + } + + async add(options: { dir: string; filepath: string }): Promise { + const { dir, filepath } = options; + this.config.logger?.info(`Adding file {dir=${dir},filepath=${filepath}}`); + + return git.add({ fs, dir, filepath }); + } + + async addRemote(options: { + dir: string; + remote: string; + url: string; + force?: boolean; + }): Promise { + const { dir, url, remote, force } = options; + this.config.logger?.info( + `Creating new remote {dir=${dir},remote=${remote},url=${url}}`, + ); + return git.addRemote({ fs, dir, remote, url, force }); + } + + async deleteRemote(options: { dir: string; remote: string }): Promise { + const { dir, remote } = options; + this.config.logger?.info(`Deleting remote {dir=${dir},remote=${remote}}`); + return git.deleteRemote({ fs, dir, remote }); + } + + async checkout(options: { dir: string; ref: string }): Promise { + const { dir, ref } = options; + this.config.logger?.info(`Checking out branch {dir=${dir},ref=${ref}}`); + + return git.checkout({ fs, dir, ref }); + } + + async branch(options: { dir: string; ref: string }): Promise { + const { dir, ref } = options; + this.config.logger?.info(`Creating branch {dir=${dir},ref=${ref}`); + + return git.branch({ fs, dir, ref }); + } + + async commit(options: { + dir: string; + message: string; + author: { name: string; email: string }; + committer: { name: string; email: string }; + }): Promise { + const { dir, message, author, committer } = options; + this.config.logger?.info( + `Committing file to repo {dir=${dir},message=${message}}`, + ); + return git.commit({ fs, dir, message, author, committer }); + } + + /** https://isomorphic-git.org/docs/en/clone */ + async clone(options: { + url: string; + dir: string; + ref?: string; + depth?: number; + noCheckout?: boolean; + }): Promise { + const { url, dir, ref, depth, noCheckout } = options; + this.config.logger?.info(`Cloning repo {dir=${dir},url=${url}}`); + + try { + return await git.clone({ + fs, + http, + url, + dir, + ref, + singleBranch: true, + depth: depth ?? 1, + noCheckout, + onProgress: this.onProgressHandler(), + headers: this.headers, + onAuth: this.onAuth, + }); + } catch (ex) { + this.config.logger?.error(`Failed to clone repo {dir=${dir},url=${url}}`); + if (ex.data) { + throw new Error(`${ex.message} {data=${JSON.stringify(ex.data)}}`); + } + throw ex; + } + } + + /** https://isomorphic-git.org/docs/en/currentBranch */ + async currentBranch(options: { + dir: string; + fullName?: boolean; + }): Promise { + const { dir, fullName = false } = options; + return git.currentBranch({ fs, dir, fullname: fullName }) as Promise< + string | undefined + >; + } + + /** https://isomorphic-git.org/docs/en/fetch */ + async fetch(options: { + dir: string; + remote?: string; + tags?: boolean; + }): Promise { + const { dir, remote = 'origin', tags = false } = options; + this.config.logger?.info( + `Fetching remote=${remote} for repository {dir=${dir}}`, + ); + + try { + await git.fetch({ + fs, + http, + dir, + remote, + tags, + onProgress: this.onProgressHandler(), + headers: this.headers, + onAuth: this.onAuth, + }); + } catch (ex) { + this.config.logger?.error( + `Failed to fetch repo {dir=${dir},remote=${remote}}`, + ); + if (ex.data) { + throw new Error(`${ex.message} {data=${JSON.stringify(ex.data)}}`); + } + throw ex; + } + } + + async init(options: { dir: string; defaultBranch?: string }): Promise { + const { dir, defaultBranch = 'master' } = options; + this.config.logger?.info(`Init git repository {dir=${dir}}`); + + return git.init({ + fs, + dir, + defaultBranch, + }); + } + + /** https://isomorphic-git.org/docs/en/merge */ + async merge(options: { + dir: string; + theirs: string; + ours?: string; + author: { name: string; email: string }; + committer: { name: string; email: string }; + }): Promise { + const { dir, theirs, ours, author, committer } = options; + this.config.logger?.info( + `Merging branch '${theirs}' into '${ours}' for repository {dir=${dir}}`, + ); + + // If ours is undefined, current branch is used. + return git.merge({ + fs, + dir, + ours, + theirs, + author, + committer, + }); + } + + async push(options: { + dir: string; + remote: string; + remoteRef?: string; + force?: boolean; + }) { + const { dir, remote, remoteRef, force } = options; + this.config.logger?.info( + `Pushing directory to remote {dir=${dir},remote=${remote}}`, + ); + try { + return await git.push({ + fs, + dir, + http, + onProgress: this.onProgressHandler(), + remoteRef, + force, + headers: this.headers, + remote, + onAuth: this.onAuth, + }); + } catch (ex) { + this.config.logger?.error( + `Failed to push to repo {dir=${dir}, remote=${remote}}`, + ); + if (ex.data) { + throw new Error(`${ex.message} {data=${JSON.stringify(ex.data)}}`); + } + throw ex; + } + } + + /** https://isomorphic-git.org/docs/en/readCommit */ + async readCommit(options: { + dir: string; + sha: string; + }): Promise { + const { dir, sha } = options; + return git.readCommit({ fs, dir, oid: sha }); + } + + /** https://isomorphic-git.org/docs/en/remove */ + async remove(options: { dir: string; filepath: string }): Promise { + const { dir, filepath } = options; + this.config.logger?.info( + `Removing file from git index {dir=${dir},filepath=${filepath}}`, + ); + return git.remove({ fs, dir, filepath }); + } + + /** https://isomorphic-git.org/docs/en/resolveRef */ + async resolveRef(options: { dir: string; ref: string }): Promise { + const { dir, ref } = options; + return git.resolveRef({ fs, dir, ref }); + } + + /** https://isomorphic-git.org/docs/en/log */ + async log(options: { + dir: string; + ref?: string; + }): Promise { + const { dir, ref } = options; + return git.log({ + fs, + dir, + ref: ref ?? 'HEAD', + }); + } + + private onAuth: AuthCallback; + + private onProgressHandler = (): ProgressCallback => { + let currentPhase = ''; + + return event => { + if (currentPhase !== event.phase) { + currentPhase = event.phase; + this.config.logger?.info(event.phase); + } + const total = event.total + ? `${Math.round((event.loaded / event.total) * 100)}%` + : event.loaded; + this.config.logger?.debug(`status={${event.phase},total={${total}}}`); + }; + }; + + static fromAuth = (options: StaticAuthOptions | AuthCallbackOptions) => { + if (isAuthCallbackOptions(options)) { + const { onAuth, logger } = options; + return new Git({ onAuth, logger }); + } + + const { username, password, token, logger } = options; + return new Git({ onAuth: () => ({ username, password }), token, logger }); + }; +} diff --git a/packages/backend-common/src/scm/index.ts b/packages/backend-common/src/deprecated/scm/index.ts similarity index 100% rename from packages/backend-common/src/scm/index.ts rename to packages/backend-common/src/deprecated/scm/index.ts diff --git a/packages/backend-common/src/index.ts b/packages/backend-common/src/index.ts index 4b1314b7d2..87bfa245f6 100644 --- a/packages/backend-common/src/index.ts +++ b/packages/backend-common/src/index.ts @@ -25,14 +25,13 @@ export type { LegacyCreateRouter } from './legacy'; export * from './auth'; export * from './cache'; export { loadBackendConfig } from './config'; +export * from './deprecated'; export * from './database'; export * from './discovery'; export * from './hot'; export * from './logging'; export * from './middleware'; -export * from './paths'; export * from './reading'; -export * from './scm'; export * from './service'; export * from './tokens'; export * from './util'; diff --git a/packages/backend-common/src/reading/FetchUrlReader.test.ts b/packages/backend-common/src/reading/FetchUrlReader.test.ts index 7b5e4ebc05..8a0b24002e 100644 --- a/packages/backend-common/src/reading/FetchUrlReader.test.ts +++ b/packages/backend-common/src/reading/FetchUrlReader.test.ts @@ -77,7 +77,7 @@ describe('FetchUrlReader', () => { worker.use( rest.get('https://backstage.io/error', (_req, res, ctx) => { - return res(ctx.status(500), ctx.body('An internal error occured')); + return res(ctx.status(500), ctx.body('An internal error occurred')); }), ); }); diff --git a/packages/backend-common/src/reading/GerritUrlReader.test.ts b/packages/backend-common/src/reading/GerritUrlReader.test.ts index 66943cac51..14f96b529a 100644 --- a/packages/backend-common/src/reading/GerritUrlReader.test.ts +++ b/packages/backend-common/src/reading/GerritUrlReader.test.ts @@ -47,7 +47,7 @@ const treeResponseFactory = DefaultReadTreeResponseFactory.create({ }); const cloneMock = jest.fn(() => Promise.resolve()); -jest.mock('../scm', () => ({ +jest.mock('./git', () => ({ Git: { fromAuth: () => ({ clone: cloneMock, diff --git a/packages/backend-common/src/reading/GerritUrlReader.ts b/packages/backend-common/src/reading/GerritUrlReader.ts index 76de711dec..52a541382b 100644 --- a/packages/backend-common/src/reading/GerritUrlReader.ts +++ b/packages/backend-common/src/reading/GerritUrlReader.ts @@ -14,7 +14,15 @@ * limitations under the License. */ -import { NotFoundError, NotModifiedError } from '@backstage/errors'; +import { Base64Decode } from 'base64-stream'; +import concatStream from 'concat-stream'; +import fs from 'fs-extra'; +import fetch, { Response } from 'node-fetch'; +import os from 'os'; +import { join as joinPath } from 'path'; +import { Readable, pipeline as pipelineCb } from 'stream'; +import tar from 'tar'; +import { promisify } from 'util'; import { GerritIntegration, ScmIntegrations, @@ -26,16 +34,7 @@ import { parseGerritGitilesUrl, parseGerritJsonResponse, } from '@backstage/integration'; -import { Base64Decode } from 'base64-stream'; -import concatStream from 'concat-stream'; -import fs from 'fs-extra'; -import fetch, { Response } from 'node-fetch'; -import os from 'os'; -import { join as joinPath } from 'path'; -import { Readable, pipeline as pipelineCb } from 'stream'; -import tar from 'tar'; -import { promisify } from 'util'; -import { Git } from '../scm'; +import { NotFoundError, NotModifiedError } from '@backstage/errors'; import { ReadTreeOptions, ReadTreeResponse, @@ -46,6 +45,7 @@ import { SearchResponse, UrlReader, } from './types'; +import { Git } from './git'; const pipeline = promisify(pipelineCb); diff --git a/packages/backend-common/src/reading/GiteaUrlReader.test.ts b/packages/backend-common/src/reading/GiteaUrlReader.test.ts index a941d2e5aa..f8658a2241 100644 --- a/packages/backend-common/src/reading/GiteaUrlReader.test.ts +++ b/packages/backend-common/src/reading/GiteaUrlReader.test.ts @@ -33,7 +33,7 @@ const treeResponseFactory = DefaultReadTreeResponseFactory.create({ config: new ConfigReader({}), }); -jest.mock('../scm', () => ({ +jest.mock('./git', () => ({ Git: { fromAuth: () => ({ clone: jest.fn(() => Promise.resolve({})), diff --git a/packages/backend-common/src/reading/HarnessUrlReader.test.ts b/packages/backend-common/src/reading/HarnessUrlReader.test.ts index bb09baa140..2741b75fd5 100644 --- a/packages/backend-common/src/reading/HarnessUrlReader.test.ts +++ b/packages/backend-common/src/reading/HarnessUrlReader.test.ts @@ -30,7 +30,7 @@ const treeResponseFactory = DefaultReadTreeResponseFactory.create({ config: new ConfigReader({}), }); -jest.mock('../scm', () => ({ +jest.mock('./git', () => ({ Git: { fromAuth: () => ({ clone: jest.fn(() => Promise.resolve({})), diff --git a/packages/backend-common/src/reading/git.ts b/packages/backend-common/src/reading/git.ts new file mode 100644 index 0000000000..119d4f64bd --- /dev/null +++ b/packages/backend-common/src/reading/git.ts @@ -0,0 +1,148 @@ +/* + * Copyright 2024 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import fs from 'fs-extra'; +import isomorphicGit, { ProgressCallback, AuthCallback } from 'isomorphic-git'; +import http from 'isomorphic-git/http/node'; +import { LoggerService } from '@backstage/backend-plugin-api'; + +/** + * Configure static credential for authentication + * + * @public + */ +export type StaticAuthOptions = { + username?: string; + password?: string; + token?: string; + logger?: LoggerService; +}; + +/** + * Configure an authentication callback that can provide credentials on demand + * + * @public + */ +export type AuthCallbackOptions = { + onAuth: AuthCallback; + logger?: LoggerService; +}; + +function isAuthCallbackOptions( + options: StaticAuthOptions | AuthCallbackOptions, +): options is AuthCallbackOptions { + return 'onAuth' in options; +} + +/* +provider username password +Azure 'notempty' token +Bitbucket Cloud 'x-token-auth' token +Bitbucket Server username password or token +GitHub 'x-access-token' token +GitLab 'oauth2' token + +From : https://isomorphic-git.org/docs/en/onAuth with fix for GitHub + +Or token provided as `token` for Bearer auth header +instead of Basic Auth (e.g., Bitbucket Server). +*/ +/** + * A convenience wrapper around the `isomorphic-git` library. + * + * @public + */ +export class Git { + private readonly headers: { + [x: string]: string; + }; + + private constructor( + private readonly config: { + onAuth: AuthCallback; + token?: string; + logger?: LoggerService; + }, + ) { + this.onAuth = config.onAuth; + + this.headers = { + 'user-agent': 'git/@isomorphic-git', + ...(config.token ? { Authorization: `Bearer ${config.token}` } : {}), + }; + } + + /** https://isomorphic-git.org/docs/en/clone */ + async clone(options: { + url: string; + dir: string; + ref?: string; + depth?: number; + noCheckout?: boolean; + }): Promise { + const { url, dir, ref, depth, noCheckout } = options; + this.config.logger?.info(`Cloning repo {dir=${dir},url=${url}}`); + + try { + return await isomorphicGit.clone({ + fs, + http, + url, + dir, + ref, + singleBranch: true, + depth: depth ?? 1, + noCheckout, + onProgress: this.onProgressHandler(), + headers: this.headers, + onAuth: this.onAuth, + }); + } catch (ex) { + this.config.logger?.error(`Failed to clone repo {dir=${dir},url=${url}}`); + if (ex.data) { + throw new Error(`${ex.message} {data=${JSON.stringify(ex.data)}}`); + } + throw ex; + } + } + + private onAuth: AuthCallback; + + private onProgressHandler = (): ProgressCallback => { + let currentPhase = ''; + + return event => { + if (currentPhase !== event.phase) { + currentPhase = event.phase; + this.config.logger?.info(event.phase); + } + const total = event.total + ? `${Math.round((event.loaded / event.total) * 100)}%` + : event.loaded; + this.config.logger?.debug(`status={${event.phase},total={${total}}}`); + }; + }; + + static fromAuth = (options: StaticAuthOptions | AuthCallbackOptions) => { + if (isAuthCallbackOptions(options)) { + const { onAuth, logger } = options; + return new Git({ onAuth, logger }); + } + + const { username, password, token, logger } = options; + return new Git({ onAuth: () => ({ username, password }), token, logger }); + }; +} diff --git a/packages/backend-common/src/reading/tree/ZipArchiveResponse.ts b/packages/backend-common/src/reading/tree/ZipArchiveResponse.ts index a191163517..412819c5b9 100644 --- a/packages/backend-common/src/reading/tree/ZipArchiveResponse.ts +++ b/packages/backend-common/src/reading/tree/ZipArchiveResponse.ts @@ -25,7 +25,7 @@ import { ReadTreeResponseFile, } from '../types'; import { streamToBuffer } from './util'; -import { resolveSafeChildPath } from '../../paths'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; /** * Wraps a zip archive stream into a tree response reader. diff --git a/packages/backend-common/src/testUtils.ts b/packages/backend-common/src/testUtils.ts index 9616ab1701..397d97f20e 100644 --- a/packages/backend-common/src/testUtils.ts +++ b/packages/backend-common/src/testUtils.ts @@ -1,5 +1,5 @@ /* - * Copyright 2023 The Backstage Authors + * Copyright 2024 The Backstage Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -14,66 +14,30 @@ * limitations under the License. */ -import { packagePathMocks } from './paths'; -import { posix as posixPath, resolve as resolvePath } from 'path'; - -/** @public */ -export interface PackagePathResolutionOverride { - /** Restores the normal behavior of resolvePackagePath */ - restore(): void; -} - -/** @public */ -export interface OverridePackagePathResolutionOptions { - /** The name of the package to mock the resolved path of */ - packageName: string; - - /** A replacement for the root package path */ - path?: string; - - /** - * Replacements for package sub-paths, each key must be an exact match of the posix-style path - * that is being resolved within the package. - * - * For example, code calling `resolvePackagePath('x', 'foo', 'bar')` would match only the following - * configuration: `overridePackagePathResolution({ packageName: 'x', paths: { 'foo/bar': baz } })` - */ - paths?: { [path in string]: string | (() => string) }; -} +import { + overridePackagePathResolution as _overridePackagePathResolution, + OverridePackagePathResolutionOptions as _OverridePackagePathResolutionOptions, + PackagePathResolutionOverride as _PackagePathResolutionOverride, +} from '@backstage/backend-plugin-api/testUtils'; /** - * This utility helps you override the paths returned by `resolvePackagePath` for a given package. - * * @public + * @deprecated This function is deprecated and will be removed in future release, see https://github.com/backstage/backstage/issues/24493. + * Please use the `overridePackagePathResolution` function from the `@backstage/backend-plugin-api/testUtils` package instead. */ -export function overridePackagePathResolution( - options: OverridePackagePathResolutionOptions, -): PackagePathResolutionOverride { - const name = options.packageName; +export const overridePackagePathResolution = _overridePackagePathResolution; - if (packagePathMocks.has(name)) { - throw new Error( - `Tried to override resolution for '${name}' more than once for package '${name}'`, - ); - } +/** + * @public + * @deprecated This type is deprecated and will be removed in a future release, see https://github.com/backstage/backstage/issues/24493. + * Please use the `OverridePackagePathResolutionOptions` type from the `@backstage/backend-plugin-api/testUtils` package instead. + */ +export type OverridePackagePathResolutionOptions = + _OverridePackagePathResolutionOptions; - packagePathMocks.set(name, paths => { - const joinedPath = posixPath.join(...paths); - const localResolver = options.paths?.[joinedPath]; - if (localResolver) { - return typeof localResolver === 'function' - ? localResolver() - : localResolver; - } - if (options.path) { - return resolvePath(options.path, ...paths); - } - return undefined; - }); - - return { - restore() { - packagePathMocks.delete(name); - }, - }; -} +/** + * @public + * @deprecated This type is deprecated and will be removed in a future release, see https://github.com/backstage/backstage/issues/24493. + * Please use the `PackagePathResolutionOverride` type from the `@backstage/backend-plugin-api/testUtils` package instead. + */ +export type PackagePathResolutionOverride = _PackagePathResolutionOverride; diff --git a/packages/backend-defaults/CHANGELOG.md b/packages/backend-defaults/CHANGELOG.md index 11a9e78a18..b43a592ba3 100644 --- a/packages/backend-defaults/CHANGELOG.md +++ b/packages/backend-defaults/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/backend-defaults +## 0.2.18 + +### Patch Changes + +- 7e5a50d: added `eventsServiceFactory` to `defaultServiceFactories` to resolve issue where different instances of the EventsServices could be used +- Updated dependencies + - @backstage/backend-app-api@0.7.3 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-events-node@0.3.4 + ## 0.2.18-next.2 ### Patch Changes diff --git a/packages/backend-defaults/package.json b/packages/backend-defaults/package.json index ec26ec6471..b5da7abbcf 100644 --- a/packages/backend-defaults/package.json +++ b/packages/backend-defaults/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-defaults", "description": "Backend defaults used by Backstage backend apps", - "version": "0.2.18-next.2", + "version": "0.2.18", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/backend-dynamic-feature-service/CHANGELOG.md b/packages/backend-dynamic-feature-service/CHANGELOG.md index a0f08195b1..ad620ee060 100644 --- a/packages/backend-dynamic-feature-service/CHANGELOG.md +++ b/packages/backend-dynamic-feature-service/CHANGELOG.md @@ -1,5 +1,26 @@ # @backstage/backend-dynamic-feature-service +## 0.2.10 + +### Patch Changes + +- b192752: Updated `README.md` to point to `packages/backend` instead of `packages/backend-next`. +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- b611fd0: Updates the `scanRoot` method in the `PluginScanner` class to specifically ignore the `lost+found` directory, which is a system-generated directory used for file recovery on Unix-like systems. Skipping this directory avoids unnecessary errors. +- Updated dependencies + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/backend-app-api@0.7.3 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-app-node@0.1.18 + - @backstage/plugin-events-backend@0.3.5 + - @backstage/plugin-permission-node@0.7.29 + ## 0.2.10-next.2 ### Patch Changes diff --git a/packages/backend-dynamic-feature-service/package.json b/packages/backend-dynamic-feature-service/package.json index 715ca5f44d..4c7a7bbaf5 100644 --- a/packages/backend-dynamic-feature-service/package.json +++ b/packages/backend-dynamic-feature-service/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-dynamic-feature-service", "description": "Backstage dynamic feature service", - "version": "0.2.10-next.2", + "version": "0.2.10", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/backend-dynamic-feature-service/src/manager/plugin-manager.test.ts b/packages/backend-dynamic-feature-service/src/manager/plugin-manager.test.ts index 487729687f..340991b11f 100644 --- a/packages/backend-dynamic-feature-service/src/manager/plugin-manager.test.ts +++ b/packages/backend-dynamic-feature-service/src/manager/plugin-manager.test.ts @@ -59,7 +59,7 @@ describe('backend-dynamic-feature-service', () => { name: string; packageManifest: ScannedPluginManifest; indexFile?: { - retativePath: string[]; + relativePath: string[]; content: string; }; expectedLogs?(location: URL): { @@ -83,7 +83,7 @@ describe('backend-dynamic-feature-service', () => { main: 'dist/index.cjs.js', }, indexFile: { - retativePath: ['dist', 'index.cjs.js'], + relativePath: ['dist', 'index.cjs.js'], content: 'exports.dynamicPluginInstaller={ kind: "new", install: () => [] }', }, @@ -127,7 +127,7 @@ describe('backend-dynamic-feature-service', () => { main: 'dist/index.cjs.js', }, indexFile: { - retativePath: ['dist', 'index.cjs.js'], + relativePath: ['dist', 'index.cjs.js'], content: `const alpha = { $$type: '@backstage/BackendFeature' }; exports["default"] = alpha;`, }, expectedLogs(location) { @@ -170,7 +170,7 @@ describe('backend-dynamic-feature-service', () => { main: 'dist/index.cjs.js', }, indexFile: { - retativePath: ['dist', 'index.cjs.js'], + relativePath: ['dist', 'index.cjs.js'], content: `const alpha = () => { return { $$type: '@backstage/BackendFeature' } }; alpha.$$type = '@backstage/BackendFeatureFactory'; exports["default"] = alpha;`, @@ -215,7 +215,7 @@ describe('backend-dynamic-feature-service', () => { main: 'dist/index.cjs.js', }, indexFile: { - retativePath: ['dist', 'index.cjs.js'], + relativePath: ['dist', 'index.cjs.js'], content: 'exports.dynamicPluginInstaller={ kind: "new", install: () => [] }', }, @@ -262,7 +262,7 @@ describe('backend-dynamic-feature-service', () => { return { errors: [ { - message: `an error occured while loading dynamic backend plugin 'backend-dynamic-plugin-test' from '${location}'`, + message: `an error occurred while loading dynamic backend plugin 'backend-dynamic-plugin-test' from '${location}'`, meta: { name: 'Error', message: expect.stringContaining( @@ -305,7 +305,7 @@ describe('backend-dynamic-feature-service', () => { main: 'dist/index.cjs.js', }, indexFile: { - retativePath: ['dist', 'index.cjs.js'], + relativePath: ['dist', 'index.cjs.js'], content: '', }, expectedLogs(location) { @@ -332,7 +332,7 @@ describe('backend-dynamic-feature-service', () => { main: 'dist/index.cjs.js', }, indexFile: { - retativePath: ['dist', 'index.cjs.js'], + relativePath: ['dist', 'index.cjs.js'], content: 'exports.dynamicPluginInstaller={ something: "else", unexpectedMethod() {} }', }, @@ -360,14 +360,14 @@ describe('backend-dynamic-feature-service', () => { main: 'dist/index.cjs.js', }, indexFile: { - retativePath: ['dist', 'index.cjs.js'], + relativePath: ['dist', 'index.cjs.js'], content: 'strange text with syntax error', }, expectedLogs(location) { return { errors: [ { - message: `an error occured while loading dynamic backend plugin 'backend-dynamic-plugin-test' from '${location}'`, + message: `an error occurred while loading dynamic backend plugin 'backend-dynamic-plugin-test' from '${location}'`, meta: { message: expect.stringContaining('Unexpected identifier'), name: 'SyntaxError', @@ -391,7 +391,7 @@ describe('backend-dynamic-feature-service', () => { main: 'dist/index.cjs.js', }, indexFile: { - retativePath: ['dist', 'index.cjs.js'], + relativePath: ['dist', 'index.cjs.js'], content: 'exports.dynamicPluginInstaller={ kind: "legacy", scaffolder: (env)=>[] }', }, @@ -458,7 +458,7 @@ describe('backend-dynamic-feature-service', () => { mockedFiles[ path.join( url.fileURLToPath(plugin.location), - ...tc.indexFile.retativePath, + ...tc.indexFile.relativePath, ) ] = tc.indexFile.content; } diff --git a/packages/backend-dynamic-feature-service/src/manager/plugin-manager.ts b/packages/backend-dynamic-feature-service/src/manager/plugin-manager.ts index edc3e20f72..95b0c6592c 100644 --- a/packages/backend-dynamic-feature-service/src/manager/plugin-manager.ts +++ b/packages/backend-dynamic-feature-service/src/manager/plugin-manager.ts @@ -188,7 +188,7 @@ export class DynamicPluginManager implements DynamicPluginProvider { }; } catch (error) { this.logger.error( - `an error occured while loading dynamic backend plugin '${plugin.manifest.name}' from '${plugin.location}'`, + `an error occurred while loading dynamic backend plugin '${plugin.manifest.name}' from '${plugin.location}'`, error, ); return undefined; diff --git a/packages/backend-dynamic-feature-service/src/schemas/appBackendModule.ts b/packages/backend-dynamic-feature-service/src/schemas/appBackendModule.ts index b44913edfd..6e54379e90 100644 --- a/packages/backend-dynamic-feature-service/src/schemas/appBackendModule.ts +++ b/packages/backend-dynamic-feature-service/src/schemas/appBackendModule.ts @@ -17,13 +17,13 @@ import { coreServices, createBackendModule, + resolvePackagePath, } from '@backstage/backend-plugin-api'; import { dynamicPluginsSchemasServiceRef } from './schemas'; import { configSchemaExtensionPoint, loadCompiledConfigSchema, } from '@backstage/plugin-app-node'; -import { resolvePackagePath } from '@backstage/backend-common'; /** @public */ export const dynamicPluginsFrontendSchemas = createBackendModule({ diff --git a/packages/backend-legacy/CHANGELOG.md b/packages/backend-legacy/CHANGELOG.md index c4a59512e5..9a5a720491 100644 --- a/packages/backend-legacy/CHANGELOG.md +++ b/packages/backend-legacy/CHANGELOG.md @@ -1,5 +1,45 @@ # example-backend-legacy +## 0.2.98 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-search-backend-module-elasticsearch@1.4.1 + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-scaffolder-backend@1.22.6 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/plugin-catalog-backend-module-unprocessed@0.4.5 + - @backstage/plugin-search-backend-module-catalog@0.1.24 + - @backstage/plugin-scaffolder-backend-module-gitlab@0.4.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-search-backend-module-pg@0.5.27 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-auth-backend@0.22.5 + - @backstage/plugin-app-backend@0.3.66 + - @backstage/plugin-devtools-backend@0.3.4 + - @backstage/plugin-signals-backend@0.1.4 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/plugin-search-backend@1.5.8 + - @backstage/plugin-techdocs-backend@1.10.5 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-search-backend-module-explore@0.1.24 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/integration@1.11.0 + - @backstage/plugin-search-backend-module-techdocs@0.1.23 + - example-app@0.2.97 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.16 + - @backstage/plugin-events-backend@0.3.5 + - @backstage/plugin-kubernetes-backend@0.17.1 + - @backstage/plugin-permission-backend@0.5.42 + - @backstage/plugin-permission-node@0.7.29 + - @backstage/plugin-proxy-backend@0.4.16 + - @backstage/plugin-scaffolder-backend-module-confluence-to-markdown@0.2.19 + - @backstage/plugin-scaffolder-backend-module-rails@0.4.35 + - @backstage/plugin-signals-node@0.1.4 + ## 0.2.98-next.2 ### Patch Changes diff --git a/packages/backend-legacy/package.json b/packages/backend-legacy/package.json index 799387f5d2..d5a3065df5 100644 --- a/packages/backend-legacy/package.json +++ b/packages/backend-legacy/package.json @@ -1,6 +1,6 @@ { "name": "example-backend-legacy", - "version": "0.2.98-next.2", + "version": "0.2.98", "backstage": { "role": "backend" }, diff --git a/packages/backend-openapi-utils/CHANGELOG.md b/packages/backend-openapi-utils/CHANGELOG.md index 3978b5dfd0..d3d8e4bdf8 100644 --- a/packages/backend-openapi-utils/CHANGELOG.md +++ b/packages/backend-openapi-utils/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/backend-openapi-utils +## 0.1.11 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + ## 0.1.11-next.1 ### Patch Changes diff --git a/packages/backend-openapi-utils/package.json b/packages/backend-openapi-utils/package.json index f77626001d..badda72b04 100644 --- a/packages/backend-openapi-utils/package.json +++ b/packages/backend-openapi-utils/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-openapi-utils", "description": "OpenAPI typescript support.", - "version": "0.1.11-next.1", + "version": "0.1.11", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/packages/backend-plugin-api/CHANGELOG.md b/packages/backend-plugin-api/CHANGELOG.md index e6a0d5c278..494634a9de 100644 --- a/packages/backend-plugin-api/CHANGELOG.md +++ b/packages/backend-plugin-api/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/backend-plugin-api +## 0.6.18 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 1fedf0c: Removed explicit `toString()` method from `ServiceRef` type. +- Updated dependencies + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-auth-node@0.4.13 + ## 0.6.18-next.1 ### Patch Changes diff --git a/packages/backend-plugin-api/api-report-testUtils.md b/packages/backend-plugin-api/api-report-testUtils.md new file mode 100644 index 0000000000..8c9bba8398 --- /dev/null +++ b/packages/backend-plugin-api/api-report-testUtils.md @@ -0,0 +1,26 @@ +## API Report File for "@backstage/backend-plugin-api" + +> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). + +```ts +// @public +export function overridePackagePathResolution( + options: OverridePackagePathResolutionOptions, +): PackagePathResolutionOverride; + +// @public (undocumented) +export interface OverridePackagePathResolutionOptions { + packageName: string; + path?: string; + paths?: { + [path in string]: string | (() => string); + }; +} + +// @public (undocumented) +export interface PackagePathResolutionOverride { + restore(): void; +} + +// (No @packageDocumentation comment for this package) +``` diff --git a/packages/backend-plugin-api/api-report.md b/packages/backend-plugin-api/api-report.md index b04c7bc20b..932ccc74ab 100644 --- a/packages/backend-plugin-api/api-report.md +++ b/packages/backend-plugin-api/api-report.md @@ -10,6 +10,7 @@ import { AuthorizePermissionResponse } from '@backstage/plugin-permission-common import { Config } from '@backstage/config'; import { Handler } from 'express'; import { IdentityApi } from '@backstage/plugin-auth-node'; +import { isChildPath } from '@backstage/cli-common'; import { JsonObject } from '@backstage/types'; import { JsonValue } from '@backstage/types'; import { Knex } from 'knex'; @@ -351,6 +352,8 @@ export interface HttpRouterServiceAuthPolicy { // @public (undocumented) export interface IdentityService extends IdentityApi {} +export { isChildPath }; + // @public (undocumented) export interface LifecycleService { addShutdownHook( @@ -496,6 +499,12 @@ export type ReadUrlResponse = { lastModifiedAt?: Date; }; +// @public +export function resolvePackagePath(name: string, ...paths: string[]): string; + +// @public +export function resolveSafeChildPath(base: string, path: string): string; + // @public (undocumented) export interface RootConfigService extends Config {} diff --git a/packages/backend-plugin-api/package.json b/packages/backend-plugin-api/package.json index fff99c0370..3199c97bda 100644 --- a/packages/backend-plugin-api/package.json +++ b/packages/backend-plugin-api/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/backend-plugin-api", - "version": "0.6.18-next.1", + "version": "0.6.18", "description": "Core API used by Backstage backend plugins", "backstage": { "role": "node-library" @@ -21,6 +21,7 @@ "exports": { ".": "./src/index.ts", "./alpha": "./src/alpha.ts", + "./testUtils": "./src/testUtils.ts", "./package.json": "./package.json" }, "main": "src/index.ts", @@ -30,6 +31,9 @@ "alpha": [ "src/alpha.ts" ], + "testUtils": [ + "src/testUtils.ts" + ], "package.json": [ "package.json" ] @@ -49,7 +53,9 @@ }, "dependencies": { "@backstage/backend-tasks": "workspace:^", + "@backstage/cli-common": "workspace:^", "@backstage/config": "workspace:^", + "@backstage/errors": "workspace:^", "@backstage/plugin-auth-node": "workspace:^", "@backstage/plugin-permission-common": "workspace:^", "@backstage/types": "workspace:^", @@ -58,6 +64,7 @@ "knex": "^3.0.0" }, "devDependencies": { + "@backstage/backend-test-utils": "workspace:^", "@backstage/cli": "workspace:^" } } diff --git a/packages/backend-plugin-api/src/index.ts b/packages/backend-plugin-api/src/index.ts index 8e0b23d20b..c2e2a13a89 100644 --- a/packages/backend-plugin-api/src/index.ts +++ b/packages/backend-plugin-api/src/index.ts @@ -22,4 +22,5 @@ export * from './services'; export type { BackendFeature } from './types'; +export * from './paths'; export * from './wiring'; diff --git a/packages/backend-common/src/paths.test.ts b/packages/backend-plugin-api/src/paths.test.ts similarity index 100% rename from packages/backend-common/src/paths.test.ts rename to packages/backend-plugin-api/src/paths.test.ts diff --git a/packages/backend-common/src/paths.ts b/packages/backend-plugin-api/src/paths.ts similarity index 100% rename from packages/backend-common/src/paths.ts rename to packages/backend-plugin-api/src/paths.ts diff --git a/packages/backend-plugin-api/src/testUtils.ts b/packages/backend-plugin-api/src/testUtils.ts new file mode 100644 index 0000000000..9616ab1701 --- /dev/null +++ b/packages/backend-plugin-api/src/testUtils.ts @@ -0,0 +1,79 @@ +/* + * Copyright 2023 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ + +import { packagePathMocks } from './paths'; +import { posix as posixPath, resolve as resolvePath } from 'path'; + +/** @public */ +export interface PackagePathResolutionOverride { + /** Restores the normal behavior of resolvePackagePath */ + restore(): void; +} + +/** @public */ +export interface OverridePackagePathResolutionOptions { + /** The name of the package to mock the resolved path of */ + packageName: string; + + /** A replacement for the root package path */ + path?: string; + + /** + * Replacements for package sub-paths, each key must be an exact match of the posix-style path + * that is being resolved within the package. + * + * For example, code calling `resolvePackagePath('x', 'foo', 'bar')` would match only the following + * configuration: `overridePackagePathResolution({ packageName: 'x', paths: { 'foo/bar': baz } })` + */ + paths?: { [path in string]: string | (() => string) }; +} + +/** + * This utility helps you override the paths returned by `resolvePackagePath` for a given package. + * + * @public + */ +export function overridePackagePathResolution( + options: OverridePackagePathResolutionOptions, +): PackagePathResolutionOverride { + const name = options.packageName; + + if (packagePathMocks.has(name)) { + throw new Error( + `Tried to override resolution for '${name}' more than once for package '${name}'`, + ); + } + + packagePathMocks.set(name, paths => { + const joinedPath = posixPath.join(...paths); + const localResolver = options.paths?.[joinedPath]; + if (localResolver) { + return typeof localResolver === 'function' + ? localResolver() + : localResolver; + } + if (options.path) { + return resolvePath(options.path, ...paths); + } + return undefined; + }); + + return { + restore() { + packagePathMocks.delete(name); + }, + }; +} diff --git a/packages/backend-tasks/CHANGELOG.md b/packages/backend-tasks/CHANGELOG.md index f90d8ff7ef..629f3e7853 100644 --- a/packages/backend-tasks/CHANGELOG.md +++ b/packages/backend-tasks/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/backend-tasks +## 0.5.23 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + ## 0.5.23-next.1 ### Patch Changes diff --git a/packages/backend-tasks/package.json b/packages/backend-tasks/package.json index a7f64b9db1..c0331c5e4c 100644 --- a/packages/backend-tasks/package.json +++ b/packages/backend-tasks/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-tasks", "description": "Common distributed task management library for Backstage backends", - "version": "0.5.23-next.1", + "version": "0.5.23", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/backend-tasks/src/database/migrateBackendTasks.ts b/packages/backend-tasks/src/database/migrateBackendTasks.ts index 9530668e3e..ae5048fbf7 100644 --- a/packages/backend-tasks/src/database/migrateBackendTasks.ts +++ b/packages/backend-tasks/src/database/migrateBackendTasks.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import { resolvePackagePath } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { Knex } from 'knex'; import { DB_MIGRATIONS_TABLE } from './tables'; diff --git a/packages/backend-test-utils/CHANGELOG.md b/packages/backend-test-utils/CHANGELOG.md index aafed2071e..d20d983fab 100644 --- a/packages/backend-test-utils/CHANGELOG.md +++ b/packages/backend-test-utils/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/backend-test-utils +## 0.3.8 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 7e5a50d: added `eventsServiceFactory` to `defaultServiceFactories` to resolve issue where different instances of the EventsServices could be used +- Updated dependencies + - @backstage/backend-app-api@0.7.3 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + ## 0.3.8-next.2 ### Patch Changes diff --git a/packages/backend-test-utils/package.json b/packages/backend-test-utils/package.json index f9d591e470..cb7711adfd 100644 --- a/packages/backend-test-utils/package.json +++ b/packages/backend-test-utils/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/backend-test-utils", - "version": "0.3.8-next.2", + "version": "0.3.8", "description": "Test helpers library for Backstage backends", "backstage": { "role": "node-library" diff --git a/packages/backend-test-utils/src/filesystem/MockDirectory.ts b/packages/backend-test-utils/src/filesystem/MockDirectory.ts index fff8a35a06..1c10c77fc6 100644 --- a/packages/backend-test-utils/src/filesystem/MockDirectory.ts +++ b/packages/backend-test-utils/src/filesystem/MockDirectory.ts @@ -15,7 +15,7 @@ */ import os from 'os'; -import { isChildPath } from '@backstage/backend-common'; +import { isChildPath } from '@backstage/backend-plugin-api'; import fs from 'fs-extra'; import textextensions from 'textextensions'; import { diff --git a/packages/backend/CHANGELOG.md b/packages/backend/CHANGELOG.md index 29e3aecc7c..a0e705f22f 100644 --- a/packages/backend/CHANGELOG.md +++ b/packages/backend/CHANGELOG.md @@ -1,5 +1,41 @@ # example-backend +## 0.0.26 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-backend@1.22.6 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/plugin-scaffolder-backend-module-github@0.2.8 + - @backstage/plugin-catalog-backend-module-unprocessed@0.4.5 + - @backstage/plugin-search-backend-module-catalog@0.1.24 + - @backstage/plugin-notifications-backend@0.2.1 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-auth-backend@0.22.5 + - @backstage/plugin-app-backend@0.3.66 + - @backstage/plugin-devtools-backend@0.3.4 + - @backstage/plugin-signals-backend@0.1.4 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/plugin-search-backend@1.5.8 + - @backstage/plugin-auth-backend-module-github-provider@0.1.15 + - @backstage/plugin-techdocs-backend@1.10.5 + - @backstage/plugin-catalog-backend-module-backstage-openapi@0.2.1 + - @backstage/plugin-auth-backend-module-guest-provider@0.1.4 + - @backstage/backend-defaults@0.2.18 + - @backstage/plugin-search-backend-module-explore@0.1.24 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-search-backend-module-techdocs@0.1.23 + - @backstage/plugin-catalog-backend-module-openapi@0.1.36 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.16 + - @backstage/plugin-kubernetes-backend@0.17.1 + - @backstage/plugin-permission-backend@0.5.42 + - @backstage/plugin-permission-backend-module-allow-all-policy@0.1.15 + - @backstage/plugin-permission-node@0.7.29 + - @backstage/plugin-proxy-backend@0.4.16 + ## 0.0.26-next.1 ### Patch Changes diff --git a/packages/backend/package.json b/packages/backend/package.json index 8d59d52ea8..a373a142a0 100644 --- a/packages/backend/package.json +++ b/packages/backend/package.json @@ -1,6 +1,6 @@ { "name": "example-backend", - "version": "0.0.26-next.1", + "version": "0.0.26", "main": "dist/index.cjs.js", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/packages/catalog-client/CHANGELOG.md b/packages/catalog-client/CHANGELOG.md index ef3ca6588e..da7b16dce1 100644 --- a/packages/catalog-client/CHANGELOG.md +++ b/packages/catalog-client/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/catalog-client +## 1.6.5 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + ## 1.6.5-next.0 ### Patch Changes diff --git a/packages/catalog-client/package.json b/packages/catalog-client/package.json index 39d8227fa5..c9e7f25723 100644 --- a/packages/catalog-client/package.json +++ b/packages/catalog-client/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/catalog-client", - "version": "1.6.5-next.0", + "version": "1.6.5", "description": "An isomorphic client for the catalog backend", "backstage": { "role": "common-library" diff --git a/packages/catalog-model/CHANGELOG.md b/packages/catalog-model/CHANGELOG.md index c04ac72136..f47465a03e 100644 --- a/packages/catalog-model/CHANGELOG.md +++ b/packages/catalog-model/CHANGELOG.md @@ -1,5 +1,11 @@ # @backstage/catalog-model +## 1.5.0 + +### Minor Changes + +- 79025f3: Introduce a domain attribute to the domain entity to allow a hierarchy of domains to exist. + ## 1.5.0-next.0 ### Minor Changes diff --git a/packages/catalog-model/package.json b/packages/catalog-model/package.json index 5622a20941..5a60531cb2 100644 --- a/packages/catalog-model/package.json +++ b/packages/catalog-model/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/catalog-model", - "version": "1.5.0-next.0", + "version": "1.5.0", "description": "Types and validators that help describe the model of a Backstage Catalog", "backstage": { "role": "common-library" diff --git a/packages/catalog-model/src/entity/policies/FieldFormatEntityPolicy.test.ts b/packages/catalog-model/src/entity/policies/FieldFormatEntityPolicy.test.ts index f32236e977..9fe041a839 100644 --- a/packages/catalog-model/src/entity/policies/FieldFormatEntityPolicy.test.ts +++ b/packages/catalog-model/src/entity/policies/FieldFormatEntityPolicy.test.ts @@ -65,11 +65,6 @@ describe('FieldFormatEntityPolicy', () => { await expect(policy.enforce(data)).rejects.toThrow(/kind/); }); - it('handles missing metadata gracefully', async () => { - delete data.medatata; - await expect(policy.enforce(data)).resolves.toBe(data); - }); - it('handles missing spec gracefully', async () => { delete data.spec; await expect(policy.enforce(data)).resolves.toBe(data); diff --git a/packages/cli-node/package.json b/packages/cli-node/package.json index 3bd9a98f60..a786d71949 100644 --- a/packages/cli-node/package.json +++ b/packages/cli-node/package.json @@ -35,7 +35,7 @@ "@backstage/errors": "workspace:^", "@backstage/types": "workspace:^", "@manypkg/get-packages": "^1.1.3", - "@yarnpkg/parsers": "^3.0.0-rc.4", + "@yarnpkg/parsers": "^3.0.0", "fs-extra": "^11.2.0", "semver": "^7.5.3", "zod": "^3.22.4" diff --git a/packages/cli/CHANGELOG.md b/packages/cli/CHANGELOG.md index 804966ba3b..7f59e4ef73 100644 --- a/packages/cli/CHANGELOG.md +++ b/packages/cli/CHANGELOG.md @@ -1,5 +1,23 @@ # @backstage/cli +## 0.26.5 + +### Patch Changes + +- b8f1fc2: The `build-workspace` command no longer manually runs `yarn postpack`, relying instead on the fact that running `yarn pack` will automatically invoke the `postpack` script. No action is necessary if you are running the latest version of yarn 1, 3, or 4. +- fcd3462: Both the target and types library have been bumped from ES2021 to ES2022 in `@backstage/cli/config/tsconfig.json`. +- 0cc5ed3: Add support for `versions:migrate` to do code changes. Can be skipped with `--no-code-changes` +- f97ad04: Add preserveModules to rollup, which allows better async loading and tree-shaking in webpack +- 2a6f10d: The `versions:bump` command will no longer exit with a non-zero status if the version bump fails due to forbidden duplicate package installations. It will now also provide more information about how to troubleshoot such an error. The set of forbidden duplicates has also been expanded to include all `@backstage/*-app-api` packages. +- c5d7b40: Allow passing a `--require` argument through to the Node process during `package start` +- cc3c518: Fixed an issue causing the `repo fix` command to set an incorrect `workspace` property using Windows +- 812dff0: Add previously-missing semicolon in file templated by `backstage-cli new --select plugin`. +- f185603: Fixed the dynamic import of vite. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/eslint-plugin@0.1.8 + - @backstage/integration@1.11.0 + ## 0.26.5-next.1 ### Patch Changes @@ -1628,9 +1646,7 @@ - 1fe6823bb5: Updated dependency `eslint-plugin-jest` to `^27.0.0`. Note that this major update to the Jest plugin contains some breaking changes. - This means that some of your tests may start seeing some new lint errors. [Read - about them - here](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md#2700-2022-08-28). + This means that some of your tests may start seeing some new lint errors. [Read about them here](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md#2700-2022-08-28). These are mostly possible to fix automatically. You can try to run `yarn backstage-cli repo lint --fix` in your repo root to have most or all of them corrected. @@ -1764,9 +1780,7 @@ - 1fe6823bb5: Updated dependency `eslint-plugin-jest` to `^27.0.0`. Note that this major update to the Jest plugin contains some breaking changes. - This means that some of your tests may start seeing some new lint errors. [Read - about them - here](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md#2700-2022-08-28). + This means that some of your tests may start seeing some new lint errors. [Read about them here](https://github.com/jest-community/eslint-plugin-jest/blob/main/CHANGELOG.md#2700-2022-08-28). These are mostly possible to fix automatically. You can try to run `yarn backstage-cli repo lint --fix` in your repo root to have most or all of them corrected. diff --git a/packages/cli/package.json b/packages/cli/package.json index d6fe116248..67492919d0 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/cli", - "version": "0.26.5-next.1", + "version": "0.26.5", "description": "CLI for developing Backstage plugins and apps", "backstage": { "role": "cli" @@ -79,7 +79,7 @@ "@typescript-eslint/eslint-plugin": "^6.12.0", "@typescript-eslint/parser": "^6.7.2", "@yarnpkg/lockfile": "^1.1.0", - "@yarnpkg/parsers": "^3.0.0-rc.4", + "@yarnpkg/parsers": "^3.0.0", "bfj": "^8.0.0", "buffer": "^6.0.3", "chalk": "^4.0.0", diff --git a/packages/cli/src/lib/builder/config.ts b/packages/cli/src/lib/builder/config.ts index 6fd92101f6..8beb2cbb1e 100644 --- a/packages/cli/src/lib/builder/config.ts +++ b/packages/cli/src/lib/builder/config.ts @@ -151,7 +151,7 @@ export async function makeRollupConfigs( template: svgrTemplate, }), esbuild({ - target: 'es2019', + target: 'ES2022', minify: options.minify, }), ], diff --git a/packages/cli/src/lib/bundler/server.ts b/packages/cli/src/lib/bundler/server.ts index 2b7311a34c..53f3b2c25a 100644 --- a/packages/cli/src/lib/bundler/server.ts +++ b/packages/cli/src/lib/bundler/server.ts @@ -165,7 +165,7 @@ DEPRECATION WARNING: React Router Beta is deprecated and support for it will be }); if (process.env.EXPERIMENTAL_VITE) { - const { default: vite } = await import('vite'); + const vite = await import('vite'); const { default: viteReact } = await import('@vitejs/plugin-react'); const { nodePolyfills: viteNodePolyfills } = await import( 'vite-plugin-node-polyfills' diff --git a/packages/cli/src/lib/versioning/Lockfile.ts b/packages/cli/src/lib/versioning/Lockfile.ts index 50d0a77cfd..6af115a4da 100644 --- a/packages/cli/src/lib/versioning/Lockfile.ts +++ b/packages/cli/src/lib/versioning/Lockfile.ts @@ -98,6 +98,24 @@ export class Lockfile { return Lockfile.parse(lockfileContents); } + static #getRangesFromDataKey(key: string): string[] { + const [, name, ranges] = key.match(ENTRY_PATTERN) ?? []; + if (!name) { + throw new Error(`Failed to parse yarn.lock entry '${key}'`); + } + + return ranges.split(/\s*,\s*/).map(rangePart => { + let range = rangePart; + if (range.startsWith(`${name}@`)) { + range = range.slice(`${name}@`.length); + } + if (range.startsWith('npm:')) { + range = range.slice('npm:'.length); + } + return range; + }); + } + static parse(content: string) { const legacy = LEGACY_REGEX.test(content); @@ -113,7 +131,7 @@ export class Lockfile { for (const [key, value] of Object.entries(data)) { if (SPECIAL_OBJECT_KEYS.includes(key)) continue; - const [, name, ranges] = ENTRY_PATTERN.exec(key) ?? []; + const [, name] = ENTRY_PATTERN.exec(key) ?? []; if (!name) { throw new Error(`Failed to parse yarn.lock entry '${key}'`); } @@ -123,13 +141,8 @@ export class Lockfile { queries = []; packages.set(name, queries); } - for (let range of ranges.split(/\s*,\s*/)) { - if (range.startsWith(`${name}@`)) { - range = range.slice(`${name}@`.length); - } - if (range.startsWith('npm:')) { - range = range.slice('npm:'.length); - } + const ranges = Lockfile.#getRangesFromDataKey(key); + for (const range of ranges) { queries.push({ range, version: value.version, dataKey: key }); } } @@ -276,9 +289,34 @@ export class Lockfile { } remove(name: string, range: string): boolean { - const query = `${name}@${range}`; + const simpleQuery = `${name}@${range}`; + const query = this.getEntryOf(name, range); + const existed = Boolean(this.data[query]); - delete this.data[query]; + + if (simpleQuery === query) { + // Single-versioned entry, just delete + delete this.data[query]; + } else { + // Remove this version from the entry key. This modifies the key, so the + // package queries' needs to be updated too. + const newRanges = Lockfile.#getRangesFromDataKey(query).filter( + q => q !== simpleQuery, + ); + const newQuery = newRanges.join(', '); + + // Replace the entry with a new one without this particular range + const entry = this.data[query]; + delete this.data[query]; + this.data[newQuery] = entry; + + // Fix all package queries pointing to the old query + this.packages.get(name)?.forEach(q => { + if (q.dataKey === query) { + q.dataKey = newQuery; + } + }); + } const newEntries = this.packages.get(name)?.filter(e => e.range !== range); if (newEntries) { @@ -288,19 +326,35 @@ export class Lockfile { return existed; } + getEntryOf(name: string, range: string) { + const query = this.packages.get(name)?.find(q => q.range === range); + if (!query) { + throw new Error(`No entry data for ${name}@${range}`); + } + + return query.dataKey; + } + /** Modifies the lockfile by bumping packages to the suggested versions */ replaceVersions(results: AnalyzeResultNewVersion[]) { + // When replacing versions, we might replace the same version multiple times, + // as a query may contain multiple versions. This keeps the original version, + // to ensure we don't make mistakes. + const oldVersions = Object.fromEntries( + Object.entries(this.data).map(([key, val]) => [key, val.version]), + ); + for (const { name, range, oldVersion, newVersion } of results) { - const query = `${name}@${range}`; + const query = this.getEntryOf(name, range); // Update the backing data const entryData = this.data[query]; if (!entryData) { throw new Error(`No entry data for ${query}`); } - if (entryData.version !== oldVersion) { + if (oldVersions[query] !== oldVersion) { throw new Error( - `Expected existing version data for ${query} to be ${oldVersion}, was ${entryData.version}`, + `Expected existing version data for ${query} to be ${oldVersion}, was ${oldVersions[query]}`, ); } diff --git a/packages/core-app-api/CHANGELOG.md b/packages/core-app-api/CHANGELOG.md index c13bf1613e..f171c222b7 100644 --- a/packages/core-app-api/CHANGELOG.md +++ b/packages/core-app-api/CHANGELOG.md @@ -1,5 +1,11 @@ # @backstage/core-app-api +## 1.12.5 + +### Patch Changes + +- 1bed9a3: The Backstage identity session expiration check will no longer fall back to using the provider expiration. This was introduced to smooth out the rollout of Backstage release 1.18, and is no longer needed. + ## 1.12.4 ### Patch Changes @@ -539,8 +545,7 @@ This change makes the dependence explicit, and removes the burden on OAuth2-based providers which require an ID token (e.g. this is done by various - default [auth - handlers](https://backstage.io/docs/auth/identity-resolver/#authhandler)) to add + default [auth handlers](https://backstage.io/docs/auth/identity-resolver/#authhandler)) to add `openid` to their default scopes. _That_ could carry another indirect benefit: by removing `openid` from the default scopes for a provider, grants for resource-specific access tokens can avoid requesting excess ID token-related @@ -568,8 +573,7 @@ This change makes the dependence explicit, and removes the burden on OAuth2-based providers which require an ID token (e.g. this is done by various - default [auth - handlers](https://backstage.io/docs/auth/identity-resolver/#authhandler)) to add + default [auth handlers](https://backstage.io/docs/auth/identity-resolver/#authhandler)) to add `openid` to their default scopes. _That_ could carry another indirect benefit: by removing `openid` from the default scopes for a provider, grants for resource-specific access tokens can avoid requesting excess ID token-related diff --git a/packages/core-app-api/package.json b/packages/core-app-api/package.json index b61a860298..0a74dac3f8 100644 --- a/packages/core-app-api/package.json +++ b/packages/core-app-api/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/core-app-api", "description": "Core app API used by Backstage apps", - "version": "1.12.4", + "version": "1.12.5", "publishConfig": { "access": "public" }, diff --git a/packages/core-app-api/src/apis/implementations/auth/oauth2/OAuth2.ts b/packages/core-app-api/src/apis/implementations/auth/oauth2/OAuth2.ts index 6be7cfc89d..dbad031652 100644 --- a/packages/core-app-api/src/apis/implementations/auth/oauth2/OAuth2.ts +++ b/packages/core-app-api/src/apis/implementations/auth/oauth2/OAuth2.ts @@ -116,16 +116,11 @@ export default class OAuth2 }, }; if (backstageIdentity) { - // TODO(Rugvip): This fallback can be removed a few releases after 1.18. It's there to avoid - // breaking deployments that update their frontend before updating their backend. - const expInSec = - backstageIdentity.expiresInSeconds ?? - res.providerInfo.expiresInSeconds; session.backstageIdentity = { token: backstageIdentity.token, identity: backstageIdentity.identity, - expiresAt: expInSec - ? new Date(Date.now() + expInSec * 1000) + expiresAt: backstageIdentity.expiresInSeconds + ? new Date(Date.now() + backstageIdentity.expiresInSeconds * 1000) : undefined, }; } diff --git a/packages/core-compat-api/CHANGELOG.md b/packages/core-compat-api/CHANGELOG.md index 3e3f824816..67084d7926 100644 --- a/packages/core-compat-api/CHANGELOG.md +++ b/packages/core-compat-api/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/core-compat-api +## 0.2.5 + +### Patch Changes + +- 5d99272: Update local development dependencies. +- Updated dependencies + - @backstage/frontend-plugin-api@0.6.5 + ## 0.2.5-next.1 ### Patch Changes diff --git a/packages/core-compat-api/package.json b/packages/core-compat-api/package.json index fbea128a68..9124060464 100644 --- a/packages/core-compat-api/package.json +++ b/packages/core-compat-api/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/core-compat-api", - "version": "0.2.5-next.1", + "version": "0.2.5", "backstage": { "role": "web-library" }, diff --git a/packages/core-components/CHANGELOG.md b/packages/core-components/CHANGELOG.md index dc31cb9f4d..4c2a973813 100644 --- a/packages/core-components/CHANGELOG.md +++ b/packages/core-components/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/core-components +## 0.14.7 + +### Patch Changes + +- e42779e: Properly log the `errorInfo` in `ErrorBoundary` +- 5223c4c: Fixed an internal circular import that broke Jest mocks. +- 71e4229: Added optional `initialShowDropDown` prop to `SidebarSubmenuItem` to internally manage the initial display state of the dropdown items. +- a2ee4df: Add `alignGauge` prop to the `GaugeCard`, and a small size version. When `alignGauge` is `'bottom'` the gauge will vertically align the gauge in the cards, even when the card titles span across multiple lines. + Add `alignContent` prop to the `InfoCard`, defaulting to `'normal'` with the option of `'bottom'` which vertically aligns the content to the bottom of the card. +- 5b7b49b: The `SignInPage` guest provider will now fall back to legacy guest auth if the backend request fails, allowing guest auth without a running backend. +- 359376a: Removing react-text-truncate with css styles. +- Updated dependencies + - @backstage/theme@0.5.4 + ## 0.14.7-next.2 ### Patch Changes diff --git a/packages/core-components/api-report.md b/packages/core-components/api-report.md index 09870afb9b..0f71bcb004 100644 --- a/packages/core-components/api-report.md +++ b/packages/core-components/api-report.md @@ -47,7 +47,6 @@ import { StyledComponentProps } from '@material-ui/core/styles/withStyles'; import { StyleRules } from '@material-ui/styles'; import { StyleRules as StyleRules_2 } from '@material-ui/core/styles/withStyles'; import { TabProps } from '@material-ui/core/Tab'; -import { TextTruncateProps } from 'react-text-truncate'; import { Theme } from '@material-ui/core/styles'; import { TooltipProps } from '@material-ui/core/Tooltip'; import { WithStyles } from '@material-ui/core/styles'; diff --git a/packages/core-components/package.json b/packages/core-components/package.json index 014059b89b..435a013062 100644 --- a/packages/core-components/package.json +++ b/packages/core-components/package.json @@ -1,31 +1,32 @@ { "name": "@backstage/core-components", "description": "Core components used by Backstage plugins and apps", - "version": "0.14.7-next.2", + "version": "0.14.7", "publishConfig": { "access": "public" }, "backstage": { "role": "web-library" }, + "keywords": [ + "backstage" + ], "homepage": "https://backstage.io", "repository": { "type": "git", "url": "https://github.com/backstage/backstage", "directory": "packages/core-components" }, - "keywords": [ - "backstage" - ], "license": "Apache-2.0", - "main": "src/index.ts", - "types": "src/index.ts", + "sideEffects": false, "exports": { ".": "./src/index.ts", "./alpha": "./src/alpha.ts", "./testUtils": "./src/testUtils.ts", "./package.json": "./package.json" }, + "main": "src/index.ts", + "types": "src/index.ts", "typesVersions": { "*": { "alpha": [ @@ -39,15 +40,18 @@ ] } }, - "sideEffects": false, + "files": [ + "dist", + "config.d.ts" + ], "scripts": { "build": "backstage-cli package build", + "clean": "backstage-cli package clean", "lint": "backstage-cli package lint", - "test": "backstage-cli package test", "prepack": "backstage-cli package prepack", "postpack": "backstage-cli package postpack", - "clean": "backstage-cli package clean", - "start": "backstage-cli package start" + "start": "backstage-cli package start", + "test": "backstage-cli package test" }, "dependencies": { "@backstage/config": "workspace:^", @@ -63,7 +67,6 @@ "@react-hookz/web": "^24.0.0", "@types/react": "^16.13.1 || ^17.0.0 || ^18.0.0", "@types/react-sparklines": "^1.7.0", - "@types/react-text-truncate": "^0.14.0", "ansi-regex": "^6.0.1", "classnames": "^2.2.6", "d3-selection": "^3.0.0", @@ -82,7 +85,6 @@ "react-markdown": "^8.0.0", "react-sparklines": "^1.7.0", "react-syntax-highlighter": "^15.4.5", - "react-text-truncate": "^0.19.0", "react-use": "^17.3.2", "react-virtualized-auto-sizer": "^1.0.11", "react-window": "^1.8.6", @@ -90,11 +92,6 @@ "zen-observable": "^0.10.0", "zod": "^3.22.4" }, - "peerDependencies": { - "react": "^16.13.1 || ^17.0.0 || ^18.0.0", - "react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0", - "react-router-dom": "6.0.0-beta.0 || ^6.3.0" - }, "devDependencies": { "@backstage/app-defaults": "workspace:^", "@backstage/cli": "workspace:^", @@ -120,9 +117,10 @@ "history": "^5.0.0", "msw": "^1.0.0" }, - "files": [ - "dist", - "config.d.ts" - ], + "peerDependencies": { + "react": "^16.13.1 || ^17.0.0 || ^18.0.0", + "react-dom": "^16.13.1 || ^17.0.0 || ^18.0.0", + "react-router-dom": "6.0.0-beta.0 || ^6.3.0" + }, "configSchema": "config.d.ts" } diff --git a/packages/core-components/src/components/OverflowTooltip/OverflowTooltip.tsx b/packages/core-components/src/components/OverflowTooltip/OverflowTooltip.tsx index da489725e4..4b5b0f4bde 100644 --- a/packages/core-components/src/components/OverflowTooltip/OverflowTooltip.tsx +++ b/packages/core-components/src/components/OverflowTooltip/OverflowTooltip.tsx @@ -16,15 +16,13 @@ import { makeStyles } from '@material-ui/core/styles'; import Tooltip, { TooltipProps } from '@material-ui/core/Tooltip'; -import React, { useState } from 'react'; -import TextTruncate, { TextTruncateProps } from 'react-text-truncate'; -import { useIsMounted } from '@react-hookz/web'; +import React from 'react'; +import Typography from '@material-ui/core/Typography'; type Props = { - text: TextTruncateProps['text']; - line?: TextTruncateProps['line']; - element?: TextTruncateProps['element']; + text?: string | undefined; title?: TooltipProps['title']; + line?: number | undefined; placement?: TooltipProps['placement']; }; @@ -35,33 +33,26 @@ const useStyles = makeStyles( container: { overflow: 'visible !important', }, + typo: { + overflow: 'hidden', + textOverflow: 'ellipsis', + display: '-webkit-box', + '-webkit-line-clamp': ({ line }: Props) => line || 1, + '-webkit-box-orient': 'vertical', + }, }, { name: 'BackstageOverflowTooltip' }, ); export function OverflowTooltip(props: Props) { - const [hover, setHover] = useState(false); - const isMounted = useIsMounted(); - const classes = useStyles(); - - const handleToggled = (truncated: boolean) => { - if (isMounted()) { - setHover(truncated); - } - }; + const classes = useStyles(props); return ( - + {props.text} ); } diff --git a/packages/core-components/src/layout/ErrorBoundary/ErrorBoundary.tsx b/packages/core-components/src/layout/ErrorBoundary/ErrorBoundary.tsx index 8f746882a1..b3a5d1db90 100644 --- a/packages/core-components/src/layout/ErrorBoundary/ErrorBoundary.tsx +++ b/packages/core-components/src/layout/ErrorBoundary/ErrorBoundary.tsx @@ -79,7 +79,7 @@ export const ErrorBoundary: ComponentClass< componentDidCatch(error: Error, errorInfo: ErrorInfo) { // eslint-disable-next-line no-console - console.error(`ErrorBoundary, error: ${error}, info: ${errorInfo}`); + console.error(`ErrorBoundary, error: ${error}`, { error, errorInfo }); this.setState({ error, errorInfo }); } diff --git a/packages/create-app/CHANGELOG.md b/packages/create-app/CHANGELOG.md index b301828207..be4c46ab03 100644 --- a/packages/create-app/CHANGELOG.md +++ b/packages/create-app/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/create-app +## 0.5.15 + +### Patch Changes + +- c066c88: Removed `packages/backend/src/types.ts` from the template as it is unused. It was mistakenly left in after moving the template to the new backend system. +- 5d99272: Update local development dependencies. +- 0478509: Bumped create-app version. +- d85dd88: Bumped create-app version. +- 8105aad: Removed the Tech Radar and GitHub Actions plugins from the template, which have been moved to the community plugins repository. + ## 0.5.15-next.2 ### Patch Changes @@ -1134,8 +1144,7 @@ Migrating to the stable version of `react-router` is optional for the time being. But if you want to do the same for your existing repository, please - follow [this - guide](https://backstage.io/docs/tutorials/react-router-stable-migration). + follow [this guide](https://backstage.io/docs/tutorials/react-router-stable-migration). - e05e0f021b: Update versions of packages used in the create-app template, to match those in the main repo - 01dff06be4: Leverage cache mounts in Dockerfile during `yarn install ...` and `apt-get ...` commands to speed up repeated builds. @@ -1182,8 +1191,7 @@ Migrating to the stable version of `react-router` is optional for the time being. But if you want to do the same for your existing repository, please - follow [this - guide](https://backstage.io/docs/tutorials/react-router-stable-migration). + follow [this guide](https://backstage.io/docs/tutorials/react-router-stable-migration). - e05e0f021b: Update versions of packages used in the create-app template, to match those in the main repo - 52f25858a8: Added `*.session.sql` Visual Studio Code database functionality files to `.gitignore` in the default template. This is optional but potentially helpful if your developers use Visual Studio Code; you can add a line with that exact value to your own root `.gitignore` if you want the same. @@ -3166,8 +3174,7 @@ The old `sqlite3` NPM library has been abandoned by its maintainers, which has led to unhandled security reports and other issues. Therefore, in the `knex` 1.x - release line they have instead switched over to the [`@vscode/sqlite3` - library](https://github.com/microsoft/vscode-node-sqlite3) by default, which is + release line they have instead switched over to the [`@vscode/sqlite3` library](https://github.com/microsoft/vscode-node-sqlite3) by default, which is actively maintained by Microsoft. This means that as you update to this version of Backstage, there are two @@ -3236,8 +3243,7 @@ The old `sqlite3` NPM library has been abandoned by its maintainers, which has led to unhandled security reports and other issues. Therefore, in the `knex` 1.x - release line they have instead switched over to the [`@vscode/sqlite3` - library](https://github.com/microsoft/vscode-node-sqlite3) by default, which is + release line they have instead switched over to the [`@vscode/sqlite3` library](https://github.com/microsoft/vscode-node-sqlite3) by default, which is actively maintained by Microsoft. This means that as you update to this version of Backstage, there are two diff --git a/packages/create-app/package.json b/packages/create-app/package.json index ec0e764fff..422442ed2b 100644 --- a/packages/create-app/package.json +++ b/packages/create-app/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/create-app", "description": "A CLI that helps you create your own Backstage app", - "version": "0.5.15-next.2", + "version": "0.5.15", "publishConfig": { "access": "public" }, diff --git a/packages/dev-utils/CHANGELOG.md b/packages/dev-utils/CHANGELOG.md index 673ee43d24..c8e32a39d0 100644 --- a/packages/dev-utils/CHANGELOG.md +++ b/packages/dev-utils/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/dev-utils +## 1.0.32 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/app-defaults@1.5.5 + - @backstage/integration-react@1.1.27 + ## 1.0.32-next.2 ### Patch Changes diff --git a/packages/dev-utils/package.json b/packages/dev-utils/package.json index f6308b6446..de5acd3249 100644 --- a/packages/dev-utils/package.json +++ b/packages/dev-utils/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/dev-utils", - "version": "1.0.32-next.2", + "version": "1.0.32", "description": "Utilities for developing Backstage plugins.", "backstage": { "role": "web-library" diff --git a/packages/e2e-test/CHANGELOG.md b/packages/e2e-test/CHANGELOG.md index 326002b350..7ff6862d2f 100644 --- a/packages/e2e-test/CHANGELOG.md +++ b/packages/e2e-test/CHANGELOG.md @@ -1,5 +1,12 @@ # e2e-test +## 0.2.16 + +### Patch Changes + +- Updated dependencies + - @backstage/create-app@0.5.15 + ## 0.2.16-next.1 ### Patch Changes diff --git a/packages/e2e-test/package.json b/packages/e2e-test/package.json index e4ddf47d73..a77bb8c8a1 100644 --- a/packages/e2e-test/package.json +++ b/packages/e2e-test/package.json @@ -1,7 +1,7 @@ { "name": "e2e-test", "description": "E2E test for verifying Backstage packages", - "version": "0.2.16-next.1", + "version": "0.2.16", "private": true, "backstage": { "role": "cli" diff --git a/packages/eslint-plugin/CHANGELOG.md b/packages/eslint-plugin/CHANGELOG.md index 60dde12184..63a7650400 100644 --- a/packages/eslint-plugin/CHANGELOG.md +++ b/packages/eslint-plugin/CHANGELOG.md @@ -1,5 +1,11 @@ # @backstage/eslint-plugin +## 0.1.8 + +### Patch Changes + +- 65ec043: add some `pickers` fixes + ## 0.1.7 ### Patch Changes diff --git a/packages/eslint-plugin/docs/rules/no-top-level-material-ui-4-imports.md b/packages/eslint-plugin/docs/rules/no-top-level-material-ui-4-imports.md index a105014abc..e2143354d2 100644 --- a/packages/eslint-plugin/docs/rules/no-top-level-material-ui-4-imports.md +++ b/packages/eslint-plugin/docs/rules/no-top-level-material-ui-4-imports.md @@ -41,3 +41,50 @@ import { import Typography from '@material-ui/core/Typography'; import Box from '@material-ui/core/Box'; ``` + +## --fix known issues + +This rule provides automatic fixes for the imports, but it has some known issues: + +### Non Props types import + +The fix will handle correctly 3 groups of imports: + +- Any import from related to styles (i.e `makeStyles`, `styled`, `WithStyles`) will be auto fixed to the `@material-ui/core/styles` import. +- Any import with `Props` suffix will be auto fixed to actual component for example `DialogProps` will be imported from `@material-ui/core/Dialog`. +- Any other import will be considered as a component import and will be auto fixed to the actual component import. + +This means that some types of imports without `Props` suffix will be wrongly auto fixed to the component import, for example this fix will be wrong: + +```diff +- import { Alert, Color } from '@material-ui/lab'; ++ import Alert from '@material-ui/lab/Alert'; ++ import Color from '@material-ui/lab/Color'; // this import is wrong +``` + +The correct import should look like this: + +```diff +- import { Alert, Color } from '@material-ui/lab'; ++ import Alert, {Color} from '@material-ui/lab/Alert'; +``` + +Because `Color` is a type coming from the Alert component. + +### No default export available + +Some components do not have a default export, for example `@material-ui/pickers/DateTimePicker` does not have a default export, so the fix will not work for these cases. + +The fix will be wrong for this import: + +```diff +- import { DateTimePicker } from '@material-ui/pickers'; ++ import DateTimePicker from '@material-ui/pickers/DateTimePicker'; // this default import does not exist +``` + +The correct import should look like this: + +```diff +- import { DateTimePicker } from '@material-ui/pickers'; ++ import { DateTimePicker } from '@material-ui/pickers/DateTimePicker'; // this is the correct import +``` diff --git a/packages/eslint-plugin/package.json b/packages/eslint-plugin/package.json index 395a3eea64..0d8db000e0 100644 --- a/packages/eslint-plugin/package.json +++ b/packages/eslint-plugin/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/eslint-plugin", - "version": "0.1.7", + "version": "0.1.8", "description": "Backstage ESLint plugin", "publishConfig": { "access": "public" diff --git a/packages/eslint-plugin/rules/no-top-level-material-ui-4-imports.js b/packages/eslint-plugin/rules/no-top-level-material-ui-4-imports.js index 77adcad215..78fd3d63e9 100644 --- a/packages/eslint-plugin/rules/no-top-level-material-ui-4-imports.js +++ b/packages/eslint-plugin/rules/no-top-level-material-ui-4-imports.js @@ -27,7 +27,23 @@ */ const KNOWN_STYLES = [ - // TODO: add exports from colorManipulator and transitions + // colorManipulator + 'hexToRgb', + 'rgbToHex', + 'hslToRgb', + 'decomposeColor', + 'recomposeColor', + 'getContrastRatio', + 'getLuminance', + 'emphasize', + 'fade', + 'alpha', + 'darken', + 'lighten', + // transitions + 'easing', + 'duration', + // styles 'createTheme', 'unstable_createMuiStrictModeTheme', 'createMuiTheme', @@ -139,7 +155,11 @@ module.exports = { const value = s.imported.name; const alias = s.local.name === value ? undefined : s.local.name; - const propsMatch = /^([A-Z]\w+)Props$/.exec(value); + const propsMatch = + /^([A-Z]\w+)Props$/.exec(value) ?? + (node.source.value === '@material-ui/pickers' + ? /^Keyboard([A-Z]\w+Picker)$/.exec(value) + : null); const emitProp = propsMatch !== null; const emitComponent = !emitProp; @@ -188,7 +208,7 @@ module.exports = { if (specifier.emitProp && !specifier.emitComponent) { const replacement = `import { ${getNamedImportValue( specifier, - )} } from '@material-ui/core/${specifier.componentValue}';`; + )} } from '${node.source.value}/${specifier.componentValue}';`; replacements.push(replacement); } @@ -197,9 +217,9 @@ module.exports = { replacements.push( `import ${ specifier.componentAlias ?? specifier.componentValue - }, { ${getNamedImportValue( - specifier, - )} } from '@material-ui/core/${specifier.componentValue}';`, + }, { ${getNamedImportValue(specifier)} } from '${ + node.source.value + }/${specifier.componentValue}';`, ); } } diff --git a/packages/eslint-plugin/src/no-top-level-material-ui-4-imports.test.ts b/packages/eslint-plugin/src/no-top-level-material-ui-4-imports.test.ts index 2d29c2f9e9..4b675bd038 100644 --- a/packages/eslint-plugin/src/no-top-level-material-ui-4-imports.test.ts +++ b/packages/eslint-plugin/src/no-top-level-material-ui-4-imports.test.ts @@ -93,6 +93,8 @@ import SvgIcon, { SvgIconProps } from '@material-ui/core/SvgIcon';`, ThemeProvider, WithStyles, Tooltip as MaterialTooltip, + alpha, + easing } from '@material-ui/core';`, errors: [{ messageId: 'topLevelImport' }], output: `import Box from '@material-ui/core/Box'; @@ -101,7 +103,7 @@ import DialogContent from '@material-ui/core/DialogContent'; import DialogTitle from '@material-ui/core/DialogTitle'; import Grid from '@material-ui/core/Grid'; import MaterialTooltip from '@material-ui/core/Tooltip'; -import { makeStyles, ThemeProvider, WithStyles } from '@material-ui/core/styles';`, +import { makeStyles, ThemeProvider, WithStyles, alpha, easing } from '@material-ui/core/styles';`, }, { code: `import { Box, Button, makeStyles } from '@material-ui/core';`, @@ -111,11 +113,11 @@ import Button from '@material-ui/core/Button'; import { makeStyles } from '@material-ui/core/styles';`, }, { - code: `import { Paper, Typography, styled, withStyles } from '@material-ui/core';`, + code: `import { Paper, Typography, styled, withStyles, alpha, duration} from '@material-ui/core';`, errors: [{ messageId: 'topLevelImport' }], output: `import Paper from '@material-ui/core/Paper'; import Typography from '@material-ui/core/Typography'; -import { styled, withStyles } from '@material-ui/core/styles';`, +import { styled, withStyles, alpha, duration } from '@material-ui/core/styles';`, }, { code: `import { styled } from '@material-ui/core';`, @@ -152,5 +154,17 @@ import { styled, withStyles } from '@material-ui/core/styles';`, errors: [{ messageId: 'topLevelImport' }], output: `import { styled as s } from '@material-ui/core/styles';`, }, + { + code: `import { TreeItem, TreeItemProps, TreeView, AlertProps } from '@material-ui/lab';`, + errors: [{ messageId: 'topLevelImport' }], + output: `import TreeItem, { TreeItemProps } from '@material-ui/lab/TreeItem'; +import TreeView from '@material-ui/lab/TreeView'; +import { AlertProps } from '@material-ui/lab/Alert';`, + }, + { + code: `import { KeyboardDatePicker } from '@material-ui/pickers';`, + errors: [{ messageId: 'topLevelImport' }], + output: `import { KeyboardDatePicker } from '@material-ui/pickers/DatePicker';`, + }, ], }); diff --git a/packages/frontend-app-api/CHANGELOG.md b/packages/frontend-app-api/CHANGELOG.md index c560948cc2..b9571091a8 100644 --- a/packages/frontend-app-api/CHANGELOG.md +++ b/packages/frontend-app-api/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/frontend-app-api +## 0.7.0 + +### Minor Changes + +- ddddecb: Extensions in app-config now always affect ordering. Previously, only when enabling disabled extensions did they rise to the top. + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/frontend-plugin-api@0.6.5 + ## 0.7.0-next.2 ### Minor Changes diff --git a/packages/frontend-app-api/package.json b/packages/frontend-app-api/package.json index 7602f688ef..2e350b5a98 100644 --- a/packages/frontend-app-api/package.json +++ b/packages/frontend-app-api/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/frontend-app-api", - "version": "0.7.0-next.2", + "version": "0.7.0", "backstage": { "role": "web-library" }, diff --git a/packages/frontend-plugin-api/CHANGELOG.md b/packages/frontend-plugin-api/CHANGELOG.md index 1c681fa6bc..f12de020f5 100644 --- a/packages/frontend-plugin-api/CHANGELOG.md +++ b/packages/frontend-plugin-api/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/frontend-plugin-api +## 0.6.5 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + ## 0.6.5-next.1 ### Patch Changes diff --git a/packages/frontend-plugin-api/package.json b/packages/frontend-plugin-api/package.json index 94906cfc67..2dedd6fc12 100644 --- a/packages/frontend-plugin-api/package.json +++ b/packages/frontend-plugin-api/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/frontend-plugin-api", - "version": "0.6.5-next.1", + "version": "0.6.5", "backstage": { "role": "web-library" }, diff --git a/packages/frontend-test-utils/CHANGELOG.md b/packages/frontend-test-utils/CHANGELOG.md index 0d41932eb0..b2abbd9c2d 100644 --- a/packages/frontend-test-utils/CHANGELOG.md +++ b/packages/frontend-test-utils/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/frontend-test-utils +## 0.1.7 + +### Patch Changes + +- Updated dependencies + - @backstage/frontend-app-api@0.7.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/test-utils@1.5.5 + ## 0.1.7-next.2 ### Patch Changes diff --git a/packages/frontend-test-utils/package.json b/packages/frontend-test-utils/package.json index 44eddc2ada..4845e7e9b1 100644 --- a/packages/frontend-test-utils/package.json +++ b/packages/frontend-test-utils/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/frontend-test-utils", - "version": "0.1.7-next.2", + "version": "0.1.7", "backstage": { "role": "web-library" }, diff --git a/packages/integration-react/CHANGELOG.md b/packages/integration-react/CHANGELOG.md index 33de746f92..f44e72919c 100644 --- a/packages/integration-react/CHANGELOG.md +++ b/packages/integration-react/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/integration-react +## 1.1.27 + +### Patch Changes + +- Updated dependencies + - @backstage/integration@1.11.0 + ## 1.1.27-next.0 ### Patch Changes diff --git a/packages/integration-react/package.json b/packages/integration-react/package.json index 5d87ccaa13..07effadbae 100644 --- a/packages/integration-react/package.json +++ b/packages/integration-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/integration-react", - "version": "1.1.27-next.0", + "version": "1.1.27", "description": "Frontend package for managing integrations towards external systems", "backstage": { "role": "web-library" diff --git a/packages/integration/CHANGELOG.md b/packages/integration/CHANGELOG.md index 0ed0080b10..0c00b80d58 100644 --- a/packages/integration/CHANGELOG.md +++ b/packages/integration/CHANGELOG.md @@ -1,5 +1,11 @@ # @backstage/integration +## 1.11.0 + +### Minor Changes + +- 2cc750d: Added `HarnessIntegration` via the `ScmIntegrations` interface. + ## 1.11.0-next.0 ### Minor Changes diff --git a/packages/integration/package.json b/packages/integration/package.json index ad41e216a7..da4b700fd6 100644 --- a/packages/integration/package.json +++ b/packages/integration/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/integration", - "version": "1.11.0-next.0", + "version": "1.11.0", "description": "Helpers for managing integrations towards external systems", "backstage": { "role": "common-library" diff --git a/packages/repo-tools/CHANGELOG.md b/packages/repo-tools/CHANGELOG.md index b3aefc9e67..251ddb28de 100644 --- a/packages/repo-tools/CHANGELOG.md +++ b/packages/repo-tools/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/repo-tools +## 0.9.0 + +### Minor Changes + +- 683870a: Adds 2 new commands `repo schema openapi diff` and `package schema openapi diff`. `repo schema openapi diff` is intended to power a new breaking changes check on pull requests and the package level command allows plugin developers to quickly see new API breaking changes. They're intended to be used in complement with the existing `repo schema openapi verify` command to validate your OpenAPI spec against a variety of things. + +### Patch Changes + +- 9ae9bb2: Update the paths logic in the api reports command to support complex subpaths +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + ## 0.9.0-next.2 ### Minor Changes diff --git a/packages/repo-tools/package.json b/packages/repo-tools/package.json index 14a2cbca1d..5c2e5e859c 100644 --- a/packages/repo-tools/package.json +++ b/packages/repo-tools/package.json @@ -1,38 +1,49 @@ { "name": "@backstage/repo-tools", "description": "CLI for Backstage repo tooling ", - "version": "0.9.0-next.2", + "version": "0.9.0", "publishConfig": { "access": "public" }, "backstage": { "role": "cli" }, + "keywords": [ + "backstage" + ], "homepage": "https://backstage.io", "repository": { "type": "git", "url": "https://github.com/backstage/backstage", "directory": "packages/repo-tools" }, - "keywords": [ - "backstage" - ], "license": "Apache-2.0", "main": "dist/index.cjs.js", - "scripts": { - "build": "backstage-cli package build", - "lint": "backstage-cli package lint", - "test": "backstage-cli package test", - "clean": "backstage-cli package clean", - "start": "nodemon --" - }, "bin": { "backstage-repo-tools": "bin/backstage-repo-tools" }, + "files": [ + "bin", + "dist/**/*.js", + "templates", + "openapitools.json" + ], + "scripts": { + "build": "backstage-cli package build", + "clean": "backstage-cli package clean", + "lint": "backstage-cli package lint", + "start": "nodemon --", + "test": "backstage-cli package test" + }, + "nodemonConfig": { + "exec": "bin/backstage-repo-tools", + "ext": "ts", + "watch": "./src" + }, "dependencies": { "@apidevtools/swagger-parser": "^10.1.0", "@apisyouwonthate/style-guide": "^1.4.0", - "@backstage/backend-common": "workspace:^", + "@backstage/backend-plugin-api": "workspace:^", "@backstage/catalog-model": "workspace:^", "@backstage/cli-common": "workspace:^", "@backstage/cli-node": "workspace:^", @@ -84,16 +95,5 @@ "prettier": { "optional": true } - }, - "files": [ - "bin", - "dist/**/*.js", - "templates", - "openapitools.json" - ], - "nodemonConfig": { - "watch": "./src", - "exec": "bin/backstage-repo-tools", - "ext": "ts" } } diff --git a/packages/repo-tools/src/commands/package/schema/openapi/generate/client.ts b/packages/repo-tools/src/commands/package/schema/openapi/generate/client.ts index 5dfed05f93..6963e02664 100644 --- a/packages/repo-tools/src/commands/package/schema/openapi/generate/client.ts +++ b/packages/repo-tools/src/commands/package/schema/openapi/generate/client.ts @@ -24,7 +24,7 @@ import { paths as cliPaths } from '../../../../../lib/paths'; import { mkdirpSync } from 'fs-extra'; import fs from 'fs-extra'; import { exec } from '../../../../../lib/exec'; -import { resolvePackagePath } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { getPathToCurrentOpenApiSpec } from '../../../../../lib/openapi/helpers'; async function generate(outputDirectory: string) { diff --git a/packages/techdocs-cli-embedded-app/CHANGELOG.md b/packages/techdocs-cli-embedded-app/CHANGELOG.md index cd27b1c1a7..0bb564782c 100644 --- a/packages/techdocs-cli-embedded-app/CHANGELOG.md +++ b/packages/techdocs-cli-embedded-app/CHANGELOG.md @@ -1,5 +1,22 @@ # techdocs-cli-embedded-app +## 0.2.96 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog@1.20.0 + - @backstage/cli@0.26.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-techdocs@1.10.5 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/app-defaults@1.5.5 + - @backstage/integration-react@1.1.27 + - @backstage/test-utils@1.5.5 + - @backstage/plugin-techdocs-react@1.2.4 + ## 0.2.96-next.2 ### Patch Changes diff --git a/packages/techdocs-cli-embedded-app/package.json b/packages/techdocs-cli-embedded-app/package.json index 687a469914..c6f776015c 100644 --- a/packages/techdocs-cli-embedded-app/package.json +++ b/packages/techdocs-cli-embedded-app/package.json @@ -1,6 +1,6 @@ { "name": "techdocs-cli-embedded-app", - "version": "0.2.96-next.2", + "version": "0.2.96", "private": true, "backstage": { "role": "frontend" diff --git a/packages/techdocs-cli/CHANGELOG.md b/packages/techdocs-cli/CHANGELOG.md index 3b2c544e7d..c1c15bb78c 100644 --- a/packages/techdocs-cli/CHANGELOG.md +++ b/packages/techdocs-cli/CHANGELOG.md @@ -1,5 +1,15 @@ # @techdocs/cli +## 1.8.11 + +### Patch Changes + +- 1a0e009: Fix cookie endpoint mock for `serve` +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-techdocs-node@1.12.4 + ## 1.8.11-next.1 ### Patch Changes diff --git a/packages/techdocs-cli/package.json b/packages/techdocs-cli/package.json index 13eed9d249..5af004aeb0 100644 --- a/packages/techdocs-cli/package.json +++ b/packages/techdocs-cli/package.json @@ -1,7 +1,7 @@ { "name": "@techdocs/cli", "description": "Utility CLI for managing TechDocs sites in Backstage.", - "version": "1.8.11-next.1", + "version": "1.8.11", "publishConfig": { "access": "public" }, diff --git a/packages/test-utils/CHANGELOG.md b/packages/test-utils/CHANGELOG.md index d28d0cac49..4c8e0c1173 100644 --- a/packages/test-utils/CHANGELOG.md +++ b/packages/test-utils/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/test-utils +## 1.5.5 + +### Patch Changes + +- Updated dependencies + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + ## 1.5.5-next.0 ### Patch Changes diff --git a/packages/test-utils/package.json b/packages/test-utils/package.json index 2e46e3a9b0..d48b652c43 100644 --- a/packages/test-utils/package.json +++ b/packages/test-utils/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/test-utils", - "version": "1.5.5-next.0", + "version": "1.5.5", "description": "Utilities to test Backstage plugins and apps.", "backstage": { "role": "web-library" diff --git a/packages/theme/CHANGELOG.md b/packages/theme/CHANGELOG.md index 20703a1d9d..397b6c80f5 100644 --- a/packages/theme/CHANGELOG.md +++ b/packages/theme/CHANGELOG.md @@ -1,5 +1,11 @@ # @backstage/theme +## 0.5.4 + +### Patch Changes + +- f1462df: Fixed bug where scrollbars don't pick up the theme when in dark mode + ## 0.5.4-next.0 ### Patch Changes diff --git a/packages/theme/package.json b/packages/theme/package.json index 07eefe756f..698d4f567c 100644 --- a/packages/theme/package.json +++ b/packages/theme/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/theme", - "version": "0.5.4-next.0", + "version": "0.5.4", "description": "material-ui theme for use with Backstage.", "backstage": { "role": "web-library" diff --git a/packages/theme/src/unified/UnifiedThemeProvider.test.tsx b/packages/theme/src/unified/UnifiedThemeProvider.test.tsx index da4af5abab..98fc73505d 100644 --- a/packages/theme/src/unified/UnifiedThemeProvider.test.tsx +++ b/packages/theme/src/unified/UnifiedThemeProvider.test.tsx @@ -22,7 +22,6 @@ import { useTheme as useV5Theme } from '@mui/material/styles'; import { makeStyles as makeV5Styles } from '@mui/styles'; import { render, screen } from '@testing-library/react'; import React from 'react'; -import './MuiClassNameSetup'; import { UnifiedThemeProvider } from './UnifiedThemeProvider'; import { themes } from './themes'; diff --git a/packages/theme/src/unified/UnifiedThemeProvider.tsx b/packages/theme/src/unified/UnifiedThemeProvider.tsx index 35abbe57d8..465a4dda24 100644 --- a/packages/theme/src/unified/UnifiedThemeProvider.tsx +++ b/packages/theme/src/unified/UnifiedThemeProvider.tsx @@ -15,7 +15,6 @@ */ import React, { ReactNode } from 'react'; -import './MuiClassNameSetup'; import { CssBaseline } from '@material-ui/core'; import { ThemeProvider, @@ -29,6 +28,7 @@ import { Theme as Mui5Theme, } from '@mui/material/styles'; import { UnifiedTheme } from './types'; +import { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/material/className'; /** * Props for {@link UnifiedThemeProvider}. @@ -41,10 +41,19 @@ export interface UnifiedThemeProviderProps { noCssBaseline?: boolean; } +/** + * This API is introduced in @mui/material (v5.0.5) as a replacement of deprecated createGenerateClassName & only affects v5 Material UI components from `@mui/*`. + * + * This call needs to be in the same module as the `UnifiedThemeProvider` to ensure that it doesn't get removed by tree shaking + */ +ClassNameGenerator.configure(componentName => { + return `v5-${componentName}`; +}); + // Background at https://mui.com/x/migration/migration-data-grid-v4/#using-mui-core-v4-with-v5 // Rather than disabling globals and custom seed, we instead only set a production prefix that -// won't collide with Material UI 5 styles. We've already got a separate class name generator for v5 set -// up in MuiClassNameSetup.ts, so only the production JSS needs deduplication. +// won't collide with Material UI 5 styles. We've already got the separate class name generator +// for v5 set up in just above, so only the production JSS needs deduplication. const generateV4ClassName = createGenerateClassName({ productionPrefix: 'jss4-', }); diff --git a/plugins/api-docs/CHANGELOG.md b/plugins/api-docs/CHANGELOG.md index 39613bd409..92eb1b44f1 100644 --- a/plugins/api-docs/CHANGELOG.md +++ b/plugins/api-docs/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-api-docs +## 0.11.5 + +### Patch Changes + +- 5d99272: Update local development dependencies. +- 725ff0b: Fix dark mode text color inside tables in `description:` from OpenAPI definitions +- Updated dependencies + - @backstage/plugin-catalog@1.20.0 + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.11.5-next.2 ### Patch Changes @@ -1349,8 +1364,7 @@ ### Patch Changes - 8f7b1835df: Updated dependency `msw` to `^0.41.0`. -- 811ff4bcf4: Updated `swagger-ui-react` to 4.11.1 in order to address a [XSS - vulnerability](https://github.com/advisories/GHSA-hqq7-2q2v-82xq) in `@braintree/sanitize-url` +- 811ff4bcf4: Updated `swagger-ui-react` to 4.11.1 in order to address a [XSS vulnerability](https://github.com/advisories/GHSA-hqq7-2q2v-82xq) in `@braintree/sanitize-url` - Updated dependencies - @backstage/plugin-catalog@1.3.0 - @backstage/plugin-catalog-react@1.1.1 diff --git a/plugins/api-docs/package.json b/plugins/api-docs/package.json index 4b8ff68d86..398407e33f 100644 --- a/plugins/api-docs/package.json +++ b/plugins/api-docs/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-api-docs", - "version": "0.11.5-next.2", + "version": "0.11.5", "description": "A Backstage plugin that helps represent API entities in the frontend", "backstage": { "role": "frontend-plugin" diff --git a/plugins/app-backend/CHANGELOG.md b/plugins/app-backend/CHANGELOG.md index 2b51f92102..c33d774b1a 100644 --- a/plugins/app-backend/CHANGELOG.md +++ b/plugins/app-backend/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-app-backend +## 0.3.66 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-app-node@0.1.18 + ## 0.3.66-next.1 ### Patch Changes diff --git a/plugins/app-backend/package.json b/plugins/app-backend/package.json index fc4a6a8ded..d0b07f4041 100644 --- a/plugins/app-backend/package.json +++ b/plugins/app-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-app-backend", "description": "A Backstage backend plugin that serves the Backstage frontend app", - "version": "0.3.66-next.1", + "version": "0.3.66", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/app-backend/src/lib/assets/StaticAssetsStore.ts b/plugins/app-backend/src/lib/assets/StaticAssetsStore.ts index 05d6424013..1179a11ef3 100644 --- a/plugins/app-backend/src/lib/assets/StaticAssetsStore.ts +++ b/plugins/app-backend/src/lib/assets/StaticAssetsStore.ts @@ -14,15 +14,15 @@ * limitations under the License. */ -import { - PluginDatabaseManager, - resolvePackagePath, -} from '@backstage/backend-common'; +import { PluginDatabaseManager } from '@backstage/backend-common'; import { Knex } from 'knex'; import { DateTime } from 'luxon'; import partition from 'lodash/partition'; import { StaticAsset, StaticAssetInput, StaticAssetProvider } from './types'; -import { LoggerService } from '@backstage/backend-plugin-api'; +import { + LoggerService, + resolvePackagePath, +} from '@backstage/backend-plugin-api'; const migrationsDir = resolvePackagePath( '@backstage/plugin-app-backend', diff --git a/plugins/app-backend/src/lib/assets/findStaticAssets.ts b/plugins/app-backend/src/lib/assets/findStaticAssets.ts index 7ecea7146e..c8731bfc93 100644 --- a/plugins/app-backend/src/lib/assets/findStaticAssets.ts +++ b/plugins/app-backend/src/lib/assets/findStaticAssets.ts @@ -17,7 +17,7 @@ import fs from 'fs-extra'; import globby from 'globby'; import { StaticAssetInput } from './types'; -import { resolveSafeChildPath } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; /** * Finds all static assets within a directory diff --git a/plugins/app-backend/src/service/__fixtures__/app-dir/dist/.config-schema.json b/plugins/app-backend/src/service/__fixtures__/app-dir/dist/.config-schema.json new file mode 100644 index 0000000000..3db59473d3 --- /dev/null +++ b/plugins/app-backend/src/service/__fixtures__/app-dir/dist/.config-schema.json @@ -0,0 +1,4 @@ +{ + "backstageConfigSchemaVersion": 1, + "schemas": [] +} diff --git a/plugins/app-backend/src/service/appPlugin.test.ts b/plugins/app-backend/src/service/appPlugin.test.ts index 647697c204..c239d476bd 100644 --- a/plugins/app-backend/src/service/appPlugin.test.ts +++ b/plugins/app-backend/src/service/appPlugin.test.ts @@ -22,7 +22,7 @@ import { } from '@backstage/backend-test-utils'; import { appPlugin } from './appPlugin'; import { createRootLogger } from '@backstage/backend-common'; -import { overridePackagePathResolution } from '@backstage/backend-common/testUtils'; +import { overridePackagePathResolution } from '@backstage/backend-plugin-api/testUtils'; const mockDir = createMockDirectory(); overridePackagePathResolution({ diff --git a/plugins/app-backend/src/service/router.test.ts b/plugins/app-backend/src/service/router.test.ts index 30fa5454c0..6fffdb149f 100644 --- a/plugins/app-backend/src/service/router.test.ts +++ b/plugins/app-backend/src/service/router.test.ts @@ -15,12 +15,13 @@ */ import { getVoidLogger } from '@backstage/backend-common'; -import { ConfigReader } from '@backstage/config'; +import { AppConfig, ConfigReader } from '@backstage/config'; import express from 'express'; import Router from 'express-promise-router'; import { resolve as resolvePath } from 'path'; import request from 'supertest'; import { createRouter } from './router'; +import { loadConfigSchema } from '@backstage/config-loader'; jest.mock('../lib/config', () => ({ injectConfig: jest.fn(), @@ -115,3 +116,75 @@ describe('createRouter with static fallback handler', () => { expect(response3.status).toBe(404); }); }); + +describe('createRouter config schema test', () => { + const libConfigs = require('../lib/config'); + const libConfigsActual = jest.requireActual('../lib/config'); + const readConfigsMock: jest.Mock = libConfigs.readConfigs; + + beforeEach(() => { + jest.resetAllMocks(); + readConfigsMock.mockImplementation(libConfigsActual.readConfigs); + }); + + it('uses an external schema', async () => { + await createRouter({ + logger: getVoidLogger(), + config: new ConfigReader({ + test: 'value', + }), + appPackageName: 'example-app', + schema: await loadConfigSchema({ + serialized: { + schemas: [ + { + value: { + type: 'object', + properties: { + test: { + visibility: 'frontend', + type: 'string', + }, + }, + }, + path: '/mock', + }, + ], + backstageConfigSchemaVersion: 1, + }, + }), + }); + + const results = readConfigsMock.mock.results; + expect(results.length).toBe(1); + + const mockedResult = results[0]; + expect(mockedResult.type).toBe('return'); + const result = await (mockedResult.value as Promise); + + expect(result.length).toBe(1); + expect(result[0].data).toStrictEqual({ + test: 'value', + }); + }); + + it('uses no external schema', async () => { + await createRouter({ + logger: getVoidLogger(), + config: new ConfigReader({ + test: 'value', + }), + appPackageName: 'example-app', + }); + + const results = readConfigsMock.mock.results; + expect(results.length).toBe(1); + + const mockedResult = results[0]; + expect(mockedResult.type).toBe('return'); + const result = await (mockedResult.value as Promise); + + expect(result.length).toBe(1); + expect(result[0].data).toStrictEqual({}); + }); +}); diff --git a/plugins/app-backend/src/service/router.ts b/plugins/app-backend/src/service/router.ts index af88f0d9da..8ec871df81 100644 --- a/plugins/app-backend/src/service/router.ts +++ b/plugins/app-backend/src/service/router.ts @@ -17,8 +17,8 @@ import { notFoundHandler, PluginDatabaseManager, - resolvePackagePath, } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { AppConfig, Config } from '@backstage/config'; import helmet from 'helmet'; import express from 'express'; @@ -113,6 +113,7 @@ export async function createRouter( staticFallbackHandler, auth, httpAuth, + schema, } = options; const disableConfigInjection = @@ -143,6 +144,7 @@ export async function createRouter( config, appDistDir, env: process.env, + schema, }); const assetStore = diff --git a/plugins/app-node/CHANGELOG.md b/plugins/app-node/CHANGELOG.md index dfc8e08cb9..75fc04fbdf 100644 --- a/plugins/app-node/CHANGELOG.md +++ b/plugins/app-node/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-app-node +## 0.1.18 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + ## 0.1.18-next.1 ### Patch Changes diff --git a/plugins/app-node/package.json b/plugins/app-node/package.json index a38ed25171..cbaca9f3d1 100644 --- a/plugins/app-node/package.json +++ b/plugins/app-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-app-node", "description": "Node.js library for the app plugin", - "version": "0.1.18-next.1", + "version": "0.1.18", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/app-visualizer/CHANGELOG.md b/plugins/app-visualizer/CHANGELOG.md index c3e117a8a0..bf39546c90 100644 --- a/plugins/app-visualizer/CHANGELOG.md +++ b/plugins/app-visualizer/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-app-visualizer +## 0.1.6 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/frontend-plugin-api@0.6.5 + ## 0.1.6-next.1 ### Patch Changes diff --git a/plugins/app-visualizer/package.json b/plugins/app-visualizer/package.json index 0b2370054c..a3e9d89e3b 100644 --- a/plugins/app-visualizer/package.json +++ b/plugins/app-visualizer/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-app-visualizer", - "version": "0.1.6-next.1", + "version": "0.1.6", "description": "Visualizes the Backstage app structure", "backstage": { "role": "frontend-plugin" diff --git a/plugins/auth-backend-module-atlassian-provider/CHANGELOG.md b/plugins/auth-backend-module-atlassian-provider/CHANGELOG.md index 915c9b0f19..f75da3056e 100644 --- a/plugins/auth-backend-module-atlassian-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-atlassian-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-atlassian-provider +## 0.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.10-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-atlassian-provider/package.json b/plugins/auth-backend-module-atlassian-provider/package.json index 0f0c3eeda9..0b0f949c44 100644 --- a/plugins/auth-backend-module-atlassian-provider/package.json +++ b/plugins/auth-backend-module-atlassian-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-atlassian-provider", "description": "The atlassian-provider backend module for the auth plugin.", - "version": "0.1.10-next.1", + "version": "0.1.10", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-aws-alb-provider/CHANGELOG.md b/plugins/auth-backend-module-aws-alb-provider/CHANGELOG.md index 784334ac96..f3c1594df9 100644 --- a/plugins/auth-backend-module-aws-alb-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-aws-alb-provider/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-auth-backend-module-aws-alb-provider +## 0.1.10 + +### Patch Changes + +- 4a0577e: fix: Move config declarations to appropriate auth backend modules +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-backend@0.22.5 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.10-next.2 ### Patch Changes diff --git a/plugins/auth-backend-module-aws-alb-provider/package.json b/plugins/auth-backend-module-aws-alb-provider/package.json index 86d4793d81..e699c13dfd 100644 --- a/plugins/auth-backend-module-aws-alb-provider/package.json +++ b/plugins/auth-backend-module-aws-alb-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-aws-alb-provider", "description": "The aws-alb provider module for the Backstage auth backend.", - "version": "0.1.10-next.2", + "version": "0.1.10", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-azure-easyauth-provider/CHANGELOG.md b/plugins/auth-backend-module-azure-easyauth-provider/CHANGELOG.md index 0ed21e2749..901f88b20a 100644 --- a/plugins/auth-backend-module-azure-easyauth-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-azure-easyauth-provider/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-auth-backend-module-azure-easyauth-provider +## 0.1.1 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.1-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-azure-easyauth-provider/package.json b/plugins/auth-backend-module-azure-easyauth-provider/package.json index e936f48f43..bec9f86224 100644 --- a/plugins/auth-backend-module-azure-easyauth-provider/package.json +++ b/plugins/auth-backend-module-azure-easyauth-provider/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-backend-module-azure-easyauth-provider", - "version": "0.1.1-next.1", + "version": "0.1.1", "description": "The azure-easyauth-provider backend module for the auth plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/auth-backend-module-bitbucket-provider/CHANGELOG.md b/plugins/auth-backend-module-bitbucket-provider/CHANGELOG.md index 4b414015cc..a3787cfdc0 100644 --- a/plugins/auth-backend-module-bitbucket-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-bitbucket-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-bitbucket-provider +## 0.1.1 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.1-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-bitbucket-provider/package.json b/plugins/auth-backend-module-bitbucket-provider/package.json index ba1184ab0f..3d16dc4bce 100644 --- a/plugins/auth-backend-module-bitbucket-provider/package.json +++ b/plugins/auth-backend-module-bitbucket-provider/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-backend-module-bitbucket-provider", - "version": "0.1.1-next.1", + "version": "0.1.1", "description": "The bitbucket-provider backend module for the auth plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/auth-backend-module-cloudflare-access-provider/CHANGELOG.md b/plugins/auth-backend-module-cloudflare-access-provider/CHANGELOG.md index 1aabb47fb9..d8e5dfe4d5 100644 --- a/plugins/auth-backend-module-cloudflare-access-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-cloudflare-access-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-cloudflare-access-provider +## 0.1.1 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.1-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-cloudflare-access-provider/package.json b/plugins/auth-backend-module-cloudflare-access-provider/package.json index 77f77052b5..7fe161480b 100644 --- a/plugins/auth-backend-module-cloudflare-access-provider/package.json +++ b/plugins/auth-backend-module-cloudflare-access-provider/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-backend-module-cloudflare-access-provider", - "version": "0.1.1-next.1", + "version": "0.1.1", "description": "The cloudflare-access-provider backend module for the auth plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/auth-backend-module-gcp-iap-provider/CHANGELOG.md b/plugins/auth-backend-module-gcp-iap-provider/CHANGELOG.md index 03576e316e..89f6dd9805 100644 --- a/plugins/auth-backend-module-gcp-iap-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-gcp-iap-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-gcp-iap-provider +## 0.2.13 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.2.13-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-gcp-iap-provider/package.json b/plugins/auth-backend-module-gcp-iap-provider/package.json index 1492ebaaf2..603fcc64c7 100644 --- a/plugins/auth-backend-module-gcp-iap-provider/package.json +++ b/plugins/auth-backend-module-gcp-iap-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-gcp-iap-provider", "description": "A GCP IAP auth provider module for the Backstage auth backend", - "version": "0.2.13-next.1", + "version": "0.2.13", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-github-provider/CHANGELOG.md b/plugins/auth-backend-module-github-provider/CHANGELOG.md index 32ea1205d9..a892924c64 100644 --- a/plugins/auth-backend-module-github-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-github-provider/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-auth-backend-module-github-provider +## 0.1.15 + +### Patch Changes + +- 4a0577e: fix: Move config declarations to appropriate auth backend modules +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.15-next.2 ### Patch Changes diff --git a/plugins/auth-backend-module-github-provider/package.json b/plugins/auth-backend-module-github-provider/package.json index 3f587ad033..2a45c2ed78 100644 --- a/plugins/auth-backend-module-github-provider/package.json +++ b/plugins/auth-backend-module-github-provider/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-backend-module-github-provider", - "version": "0.1.15-next.2", + "version": "0.1.15", "description": "The github-provider backend module for the auth plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/auth-backend-module-gitlab-provider/CHANGELOG.md b/plugins/auth-backend-module-gitlab-provider/CHANGELOG.md index 1f4f5ecbf9..201fa5901b 100644 --- a/plugins/auth-backend-module-gitlab-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-gitlab-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-gitlab-provider +## 0.1.15 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-gitlab-provider/package.json b/plugins/auth-backend-module-gitlab-provider/package.json index 5d8ee28020..146c26fffd 100644 --- a/plugins/auth-backend-module-gitlab-provider/package.json +++ b/plugins/auth-backend-module-gitlab-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-gitlab-provider", "description": "The gitlab-provider backend module for the auth plugin.", - "version": "0.1.15-next.1", + "version": "0.1.15", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-google-provider/CHANGELOG.md b/plugins/auth-backend-module-google-provider/CHANGELOG.md index 9e7e4043a3..46ea104253 100644 --- a/plugins/auth-backend-module-google-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-google-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-google-provider +## 0.1.15 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-google-provider/package.json b/plugins/auth-backend-module-google-provider/package.json index a9b529504d..35814282ec 100644 --- a/plugins/auth-backend-module-google-provider/package.json +++ b/plugins/auth-backend-module-google-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-google-provider", "description": "A Google auth provider module for the Backstage auth backend", - "version": "0.1.15-next.1", + "version": "0.1.15", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-guest-provider/CHANGELOG.md b/plugins/auth-backend-module-guest-provider/CHANGELOG.md index 56c4e179b8..91565c88fd 100644 --- a/plugins/auth-backend-module-guest-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-guest-provider/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-auth-backend-module-guest-provider +## 0.1.4 + +### Patch Changes + +- 07d8cca: Error if used outside of a development environment without explicit allowance +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.4-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-guest-provider/package.json b/plugins/auth-backend-module-guest-provider/package.json index 9676afb176..e27c19eb5d 100644 --- a/plugins/auth-backend-module-guest-provider/package.json +++ b/plugins/auth-backend-module-guest-provider/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-backend-module-guest-provider", - "version": "0.1.4-next.1", + "version": "0.1.4", "description": "The guest-provider backend module for the auth plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/auth-backend-module-microsoft-provider/CHANGELOG.md b/plugins/auth-backend-module-microsoft-provider/CHANGELOG.md index 14e4cef987..83c3bb229d 100644 --- a/plugins/auth-backend-module-microsoft-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-microsoft-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-microsoft-provider +## 0.1.13 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.13-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-microsoft-provider/package.json b/plugins/auth-backend-module-microsoft-provider/package.json index a8569903cc..9e2719acc3 100644 --- a/plugins/auth-backend-module-microsoft-provider/package.json +++ b/plugins/auth-backend-module-microsoft-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-microsoft-provider", "description": "The microsoft-provider backend module for the auth plugin.", - "version": "0.1.13-next.1", + "version": "0.1.13", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-oauth2-provider/CHANGELOG.md b/plugins/auth-backend-module-oauth2-provider/CHANGELOG.md index 747d8fa317..dbb970e028 100644 --- a/plugins/auth-backend-module-oauth2-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-oauth2-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-oauth2-provider +## 0.1.15 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-oauth2-provider/package.json b/plugins/auth-backend-module-oauth2-provider/package.json index 7cbc5929ae..6aecfd6c48 100644 --- a/plugins/auth-backend-module-oauth2-provider/package.json +++ b/plugins/auth-backend-module-oauth2-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-oauth2-provider", "description": "The oauth2-provider backend module for the auth plugin.", - "version": "0.1.15-next.1", + "version": "0.1.15", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-oauth2-proxy-provider/CHANGELOG.md b/plugins/auth-backend-module-oauth2-proxy-provider/CHANGELOG.md index acc41221f6..e5366af8b6 100644 --- a/plugins/auth-backend-module-oauth2-proxy-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-oauth2-proxy-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-oauth2-proxy-provider +## 0.1.11 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.11-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-oauth2-proxy-provider/package.json b/plugins/auth-backend-module-oauth2-proxy-provider/package.json index cbcef196a5..0f3063db34 100644 --- a/plugins/auth-backend-module-oauth2-proxy-provider/package.json +++ b/plugins/auth-backend-module-oauth2-proxy-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-oauth2-proxy-provider", "description": "The oauth2-proxy-provider backend module for the auth plugin.", - "version": "0.1.11-next.1", + "version": "0.1.11", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-oidc-provider/CHANGELOG.md b/plugins/auth-backend-module-oidc-provider/CHANGELOG.md index 6713b3c7b6..e8716f0ce1 100644 --- a/plugins/auth-backend-module-oidc-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-oidc-provider/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-auth-backend-module-oidc-provider +## 0.1.9 + +### Patch Changes + +- dd53bf3: Add nonce to authorize request to be added in ID token +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-backend@0.22.5 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.9-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-oidc-provider/package.json b/plugins/auth-backend-module-oidc-provider/package.json index c8894fc070..34bb282ba5 100644 --- a/plugins/auth-backend-module-oidc-provider/package.json +++ b/plugins/auth-backend-module-oidc-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-oidc-provider", "description": "The oidc-provider backend module for the auth plugin.", - "version": "0.1.9-next.1", + "version": "0.1.9", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-okta-provider/CHANGELOG.md b/plugins/auth-backend-module-okta-provider/CHANGELOG.md index 43e434a711..8378a83e7c 100644 --- a/plugins/auth-backend-module-okta-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-okta-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-okta-provider +## 0.0.11 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.0.11-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-okta-provider/package.json b/plugins/auth-backend-module-okta-provider/package.json index 3006544145..b8a679b0b0 100644 --- a/plugins/auth-backend-module-okta-provider/package.json +++ b/plugins/auth-backend-module-okta-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-okta-provider", "description": "The okta-provider backend module for the auth plugin.", - "version": "0.0.11-next.1", + "version": "0.0.11", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-pinniped-provider/CHANGELOG.md b/plugins/auth-backend-module-pinniped-provider/CHANGELOG.md index a115289d0b..e9631b54cc 100644 --- a/plugins/auth-backend-module-pinniped-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-pinniped-provider/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-backend-module-pinniped-provider +## 0.1.12 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.12-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-pinniped-provider/package.json b/plugins/auth-backend-module-pinniped-provider/package.json index 163c3f8e05..227055d366 100644 --- a/plugins/auth-backend-module-pinniped-provider/package.json +++ b/plugins/auth-backend-module-pinniped-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-pinniped-provider", "description": "The pinniped-provider backend module for the auth plugin.", - "version": "0.1.12-next.1", + "version": "0.1.12", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-vmware-cloud-provider/CHANGELOG.md b/plugins/auth-backend-module-vmware-cloud-provider/CHANGELOG.md index 9245b6ded5..97753a12d2 100644 --- a/plugins/auth-backend-module-vmware-cloud-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-vmware-cloud-provider/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-auth-backend-module-vmware-cloud-provider +## 0.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.10-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-vmware-cloud-provider/package.json b/plugins/auth-backend-module-vmware-cloud-provider/package.json index 6054f63ea1..64af928848 100644 --- a/plugins/auth-backend-module-vmware-cloud-provider/package.json +++ b/plugins/auth-backend-module-vmware-cloud-provider/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-backend-module-vmware-cloud-provider", - "version": "0.1.10-next.1", + "version": "0.1.10", "description": "The vmware-cloud-provider backend module for the auth plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/auth-backend/CHANGELOG.md b/plugins/auth-backend/CHANGELOG.md index 59a7aa4af0..2b161d638a 100644 --- a/plugins/auth-backend/CHANGELOG.md +++ b/plugins/auth-backend/CHANGELOG.md @@ -1,5 +1,34 @@ # @backstage/plugin-auth-backend +## 0.22.5 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 4a0577e: fix: Move config declarations to appropriate auth backend modules +- ea9262b: Allow overriding default ownership resolving with the new `AuthOwnershipResolutionExtensionPoint` +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-backend-module-aws-alb-provider@0.1.10 + - @backstage/plugin-auth-backend-module-github-provider@0.1.15 + - @backstage/plugin-auth-backend-module-oidc-provider@0.1.9 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-auth-backend-module-atlassian-provider@0.1.10 + - @backstage/plugin-auth-backend-module-azure-easyauth-provider@0.1.1 + - @backstage/plugin-auth-backend-module-bitbucket-provider@0.1.1 + - @backstage/plugin-auth-backend-module-cloudflare-access-provider@0.1.1 + - @backstage/plugin-auth-backend-module-gcp-iap-provider@0.2.13 + - @backstage/plugin-auth-backend-module-gitlab-provider@0.1.15 + - @backstage/plugin-auth-backend-module-google-provider@0.1.15 + - @backstage/plugin-auth-backend-module-microsoft-provider@0.1.13 + - @backstage/plugin-auth-backend-module-oauth2-provider@0.1.15 + - @backstage/plugin-auth-backend-module-oauth2-proxy-provider@0.1.11 + - @backstage/plugin-auth-backend-module-okta-provider@0.0.11 + ## 0.22.5-next.2 ### Patch Changes diff --git a/plugins/auth-backend/package.json b/plugins/auth-backend/package.json index 910c7d4180..0797145855 100644 --- a/plugins/auth-backend/package.json +++ b/plugins/auth-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-backend", - "version": "0.22.5-next.2", + "version": "0.22.5", "description": "A Backstage backend plugin that handles authentication", "backstage": { "role": "backend-plugin" diff --git a/plugins/auth-backend/src/database/AuthDatabase.ts b/plugins/auth-backend/src/database/AuthDatabase.ts index 97e4236754..ec4d2034e7 100644 --- a/plugins/auth-backend/src/database/AuthDatabase.ts +++ b/plugins/auth-backend/src/database/AuthDatabase.ts @@ -17,8 +17,8 @@ import { DatabaseManager, PluginDatabaseManager, - resolvePackagePath, } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { ConfigReader } from '@backstage/config'; import { Knex } from 'knex'; diff --git a/plugins/auth-node/CHANGELOG.md b/plugins/auth-node/CHANGELOG.md index af4318227d..ecfd0c78b6 100644 --- a/plugins/auth-node/CHANGELOG.md +++ b/plugins/auth-node/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-auth-node +## 0.4.13 + +### Patch Changes + +- ea9262b: Allow overriding default ownership resolving with the new `AuthOwnershipResolutionExtensionPoint` +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/catalog-client@1.6.5 + ## 0.4.13-next.1 ### Patch Changes diff --git a/plugins/auth-node/package.json b/plugins/auth-node/package.json index ba05caaad4..8b0e7f87c3 100644 --- a/plugins/auth-node/package.json +++ b/plugins/auth-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-node", - "version": "0.4.13-next.1", + "version": "0.4.13", "backstage": { "role": "node-library" }, diff --git a/plugins/auth-react/CHANGELOG.md b/plugins/auth-react/CHANGELOG.md index ebd567184f..46ddcc9a51 100644 --- a/plugins/auth-react/CHANGELOG.md +++ b/plugins/auth-react/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-auth-react +## 0.1.2 + +### Patch Changes + +- c297afd: When using `CookieAuthRefreshProvider` or `useCookieAuthRefresh`, a 404 response from the cookie endpoint will now be treated as if cookie auth is disabled and is not needed. +- Updated dependencies + - @backstage/core-components@0.14.7 + ## 0.1.2-next.1 ### Patch Changes diff --git a/plugins/auth-react/package.json b/plugins/auth-react/package.json index c223b4c40f..7b85295f48 100644 --- a/plugins/auth-react/package.json +++ b/plugins/auth-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-react", - "version": "0.1.2-next.1", + "version": "0.1.2", "description": "Web library for the auth plugin", "backstage": { "role": "web-library" diff --git a/plugins/bitbucket-cloud-common/CHANGELOG.md b/plugins/bitbucket-cloud-common/CHANGELOG.md index 1397e67af4..b20502394f 100644 --- a/plugins/bitbucket-cloud-common/CHANGELOG.md +++ b/plugins/bitbucket-cloud-common/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-bitbucket-cloud-common +## 0.2.19 + +### Patch Changes + +- d76cb29: Updated dependency `ts-morph` to `^22.0.0`. +- Updated dependencies + - @backstage/integration@1.11.0 + ## 0.2.19-next.0 ### Patch Changes diff --git a/plugins/bitbucket-cloud-common/package.json b/plugins/bitbucket-cloud-common/package.json index dba2dbc40f..a6d52a1850 100644 --- a/plugins/bitbucket-cloud-common/package.json +++ b/plugins/bitbucket-cloud-common/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-bitbucket-cloud-common", - "version": "0.2.19-next.0", + "version": "0.2.19", "description": "Common functionalities for bitbucket-cloud plugins", "backstage": { "role": "common-library" @@ -44,6 +44,6 @@ "@backstage/cli": "workspace:^", "@openapitools/openapi-generator-cli": "^2.4.26", "msw": "^1.0.0", - "ts-morph": "^21.0.0" + "ts-morph": "^22.0.0" } } diff --git a/plugins/catalog-backend-module-aws/CHANGELOG.md b/plugins/catalog-backend-module-aws/CHANGELOG.md index f0e0b8e6aa..cf7dc39048 100644 --- a/plugins/catalog-backend-module-aws/CHANGELOG.md +++ b/plugins/catalog-backend-module-aws/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-catalog-backend-module-aws +## 0.3.13 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/integration@1.11.0 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-kubernetes-common@0.7.6 + ## 0.3.13-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-aws/package.json b/plugins/catalog-backend-module-aws/package.json index d80383a18f..ba9a299fad 100644 --- a/plugins/catalog-backend-module-aws/package.json +++ b/plugins/catalog-backend-module-aws/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-aws", - "version": "0.3.13-next.2", + "version": "0.3.13", "description": "A Backstage catalog backend module that helps integrate towards AWS", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-azure/CHANGELOG.md b/plugins/catalog-backend-module-azure/CHANGELOG.md index 6d3af364bb..649c15872a 100644 --- a/plugins/catalog-backend-module-azure/CHANGELOG.md +++ b/plugins/catalog-backend-module-azure/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-catalog-backend-module-azure +## 0.1.38 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/integration@1.11.0 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.1.38-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-azure/package.json b/plugins/catalog-backend-module-azure/package.json index a0a7edb728..e5b47db18c 100644 --- a/plugins/catalog-backend-module-azure/package.json +++ b/plugins/catalog-backend-module-azure/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-azure", - "version": "0.1.38-next.2", + "version": "0.1.38", "description": "A Backstage catalog backend module that helps integrate towards Azure", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-backstage-openapi/CHANGELOG.md b/plugins/catalog-backend-module-backstage-openapi/CHANGELOG.md index fc48605090..2d63fdeadd 100644 --- a/plugins/catalog-backend-module-backstage-openapi/CHANGELOG.md +++ b/plugins/catalog-backend-module-backstage-openapi/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-catalog-backend-module-backstage-openapi +## 0.2.1 + +### Patch Changes + +- f3f0281: Fix incorrect dependency import. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/backend-openapi-utils@0.1.11 + ## 0.2.1-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-backstage-openapi/package.json b/plugins/catalog-backend-module-backstage-openapi/package.json index 408fdfcc4f..af9a299848 100644 --- a/plugins/catalog-backend-module-backstage-openapi/package.json +++ b/plugins/catalog-backend-module-backstage-openapi/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-backstage-openapi", - "version": "0.2.1-next.2", + "version": "0.2.1", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/catalog-backend-module-bitbucket-cloud/CHANGELOG.md b/plugins/catalog-backend-module-bitbucket-cloud/CHANGELOG.md index 8884d911d3..1fa58406c4 100644 --- a/plugins/catalog-backend-module-bitbucket-cloud/CHANGELOG.md +++ b/plugins/catalog-backend-module-bitbucket-cloud/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-catalog-backend-module-bitbucket-cloud +## 0.2.5 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-bitbucket-cloud-common@0.2.19 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.2.5-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-bitbucket-cloud/package.json b/plugins/catalog-backend-module-bitbucket-cloud/package.json index a6554c173a..b821a1e01d 100644 --- a/plugins/catalog-backend-module-bitbucket-cloud/package.json +++ b/plugins/catalog-backend-module-bitbucket-cloud/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-bitbucket-cloud", "description": "A Backstage catalog backend module that helps integrate towards Bitbucket Cloud", - "version": "0.2.5-next.2", + "version": "0.2.5", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-bitbucket-server/CHANGELOG.md b/plugins/catalog-backend-module-bitbucket-server/CHANGELOG.md index 424f143da1..ffb79454cf 100644 --- a/plugins/catalog-backend-module-bitbucket-server/CHANGELOG.md +++ b/plugins/catalog-backend-module-bitbucket-server/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-catalog-backend-module-bitbucket-server +## 0.1.32 + +### Patch Changes + +- 062ffb1: Allow skipping archived repositories (`skipArchivedRepos` flag) on Bitbucket. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/integration@1.11.0 + ## 0.1.32-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-bitbucket-server/package.json b/plugins/catalog-backend-module-bitbucket-server/package.json index e1b0e4c362..684b5fa95a 100644 --- a/plugins/catalog-backend-module-bitbucket-server/package.json +++ b/plugins/catalog-backend-module-bitbucket-server/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-bitbucket-server", - "version": "0.1.32-next.2", + "version": "0.1.32", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-gcp/CHANGELOG.md b/plugins/catalog-backend-module-gcp/CHANGELOG.md index 095366892f..008b18882b 100644 --- a/plugins/catalog-backend-module-gcp/CHANGELOG.md +++ b/plugins/catalog-backend-module-gcp/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-catalog-backend-module-gcp +## 0.1.19 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-kubernetes-common@0.7.6 + ## 0.1.19-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-gcp/package.json b/plugins/catalog-backend-module-gcp/package.json index 758a909b3c..f0f3b1722f 100644 --- a/plugins/catalog-backend-module-gcp/package.json +++ b/plugins/catalog-backend-module-gcp/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-gcp", - "version": "0.1.19-next.2", + "version": "0.1.19", "description": "A Backstage catalog backend module that helps integrate towards GCP", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-gerrit/CHANGELOG.md b/plugins/catalog-backend-module-gerrit/CHANGELOG.md index 3aaa06ae02..2b5f22e034 100644 --- a/plugins/catalog-backend-module-gerrit/CHANGELOG.md +++ b/plugins/catalog-backend-module-gerrit/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-catalog-backend-module-gerrit +## 0.1.35 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/integration@1.11.0 + ## 0.1.35-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-gerrit/package.json b/plugins/catalog-backend-module-gerrit/package.json index f58d6bb85f..1e9ff4284c 100644 --- a/plugins/catalog-backend-module-gerrit/package.json +++ b/plugins/catalog-backend-module-gerrit/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-gerrit", - "version": "0.1.35-next.2", + "version": "0.1.35", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/catalog-backend-module-github-org/CHANGELOG.md b/plugins/catalog-backend-module-github-org/CHANGELOG.md index 01a6fb3b7a..99f073203c 100644 --- a/plugins/catalog-backend-module-github-org/CHANGELOG.md +++ b/plugins/catalog-backend-module-github-org/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-catalog-backend-module-github-org +## 0.1.13 + +### Patch Changes + +- 5bdeaa7: Fixed an issue where the `catalog-backend-module-github-org` would not correctly create groups using `default` as namespace in case a single organization was configured. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-catalog-backend-module-github@0.6.1 + - @backstage/plugin-events-node@0.3.4 + ## 0.1.13-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-github-org/package.json b/plugins/catalog-backend-module-github-org/package.json index 4557cbedef..9f73d2a052 100644 --- a/plugins/catalog-backend-module-github-org/package.json +++ b/plugins/catalog-backend-module-github-org/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-github-org", - "version": "0.1.13-next.2", + "version": "0.1.13", "description": "The github-org backend module for the catalog plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-github-org/src/GithubOrgEntityCleanerProvider.ts b/plugins/catalog-backend-module-github-org/src/GithubOrgEntityCleanerProvider.ts new file mode 100644 index 0000000000..a00cd504d7 --- /dev/null +++ b/plugins/catalog-backend-module-github-org/src/GithubOrgEntityCleanerProvider.ts @@ -0,0 +1,42 @@ +/* + * Copyright 2024 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +import { LoggerService } from '@backstage/backend-plugin-api'; +import { + EntityProvider, + EntityProviderConnection, +} from '@backstage/plugin-catalog-node'; + +export class GithubOrgEntityCleanerProvider implements EntityProvider { + logger: LoggerService; + constructor(private readonly options: { id: string; logger: LoggerService }) { + this.logger = options.logger.child({ target: this.getProviderName() }); + } + + getProviderName() { + return `GithubOrgEntityProvider:${this.options.id}`; + } + async connect(connection: EntityProviderConnection) { + // Clean up any existing entities + connection + .applyMutation({ + type: 'full', + entities: [], + }) + .catch(error => { + this.logger.error('Failed to clean up entities', error); + }); + } +} diff --git a/plugins/catalog-backend-module-github-org/src/module.ts b/plugins/catalog-backend-module-github-org/src/module.ts index 0baa768644..31d4cef1c0 100644 --- a/plugins/catalog-backend-module-github-org/src/module.ts +++ b/plugins/catalog-backend-module-github-org/src/module.ts @@ -31,6 +31,7 @@ import { } from '@backstage/plugin-catalog-backend-module-github'; import { catalogProcessingExtensionPoint } from '@backstage/plugin-catalog-node/alpha'; import { eventsServiceRef } from '@backstage/plugin-events-node'; +import { GithubOrgEntityCleanerProvider } from './GithubOrgEntityCleanerProvider'; /** * Interface for {@link githubOrgEntityProviderTransformsExtensionPoint}. @@ -99,8 +100,14 @@ export const catalogModuleGithubOrgEntityProvider = createBackendModule({ logger: coreServices.logger, scheduler: coreServices.scheduler, }, + async init({ catalog, config, events, logger, scheduler }) { - for (const definition of readDefinitionsFromConfig(config)) { + const definitions = readDefinitionsFromConfig(config); + + for (const definition of definitions) { + catalog.addEntityProvider( + new GithubOrgEntityCleanerProvider({ id: definition.id, logger }), + ); catalog.addEntityProvider( GithubMultiOrgEntityProvider.fromConfig(config, { id: definition.id, @@ -113,6 +120,8 @@ export const catalogModuleGithubOrgEntityProvider = createBackendModule({ logger, userTransformer, teamTransformer, + alwaysUseDefaultNamespace: + definitions.length === 1 && definition.orgs?.length === 1, }), ); } diff --git a/plugins/catalog-backend-module-github/CHANGELOG.md b/plugins/catalog-backend-module-github/CHANGELOG.md index ad4281d185..09735e37ca 100644 --- a/plugins/catalog-backend-module-github/CHANGELOG.md +++ b/plugins/catalog-backend-module-github/CHANGELOG.md @@ -1,5 +1,28 @@ # @backstage/plugin-catalog-backend-module-github +## 0.6.1 + +### Patch Changes + +- 0b50143: GitHub push events now schedule a refresh on entities that have a `refresh_key` matching the `catalogPath` config itself. + This allows to support a `catalogPath` configuration that uses glob patterns. +- f2a2a83: Updated to use the new `catalogAnalysisExtensionPoint` API. +- 5bdeaa7: Added `alwaysUseDefaultNamespace` option to `GithubMultiOrgEntityProvider`. + + If set to true, the provider will use `default` as the namespace for all group entities. Groups with the same name across different orgs will be considered the same group. + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.6.1-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-github/api-report.md b/plugins/catalog-backend-module-github/api-report.md index b53d1b7b17..0b68170255 100644 --- a/plugins/catalog-backend-module-github/api-report.md +++ b/plugins/catalog-backend-module-github/api-report.md @@ -150,6 +150,7 @@ export class GithubMultiOrgEntityProvider implements EntityProvider { orgs?: string[]; userTransformer?: UserTransformer; teamTransformer?: TeamTransformer; + alwaysUseDefaultNamespace?: boolean; }); // (undocumented) connect(connection: EntityProviderConnection): Promise; @@ -165,6 +166,7 @@ export class GithubMultiOrgEntityProvider implements EntityProvider { // @public export interface GithubMultiOrgEntityProviderOptions { + alwaysUseDefaultNamespace?: boolean; events?: EventsService; githubCredentialsProvider?: GithubCredentialsProvider; githubUrl: string; diff --git a/plugins/catalog-backend-module-github/package.json b/plugins/catalog-backend-module-github/package.json index 05306549c3..d71303629a 100644 --- a/plugins/catalog-backend-module-github/package.json +++ b/plugins/catalog-backend-module-github/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-github", - "version": "0.6.1-next.2", + "version": "0.6.1", "description": "A Backstage catalog backend module that helps integrate towards GitHub", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-github/src/providers/GithubMultiOrgEntityProvider.test.ts b/plugins/catalog-backend-module-github/src/providers/GithubMultiOrgEntityProvider.test.ts index 0542e64d64..c89901fcb3 100644 --- a/plugins/catalog-backend-module-github/src/providers/GithubMultiOrgEntityProvider.test.ts +++ b/plugins/catalog-backend-module-github/src/providers/GithubMultiOrgEntityProvider.test.ts @@ -68,26 +68,24 @@ describe('GithubMultiOrgEntityProvider', () => { headers: { token: 'blah' }, type: 'app', }); - - const githubCredentialsProvider: GithubCredentialsProvider = { - getCredentials: mockGetCredentials, - }; - - entityProvider = new GithubMultiOrgEntityProvider({ - id: 'my-id', - gitHubConfig, - githubCredentialsProvider, - githubUrl: 'https://github.com', - logger, - orgs: ['orgA', 'orgB'], // only include for tests that require it - }); - - entityProvider.connect(entityProviderConnection); }); afterEach(() => jest.resetAllMocks()); it('should read specified orgs', async () => { + entityProvider = new GithubMultiOrgEntityProvider({ + id: 'my-id', + gitHubConfig, + githubCredentialsProvider: { + getCredentials: mockGetCredentials, + }, + githubUrl: 'https://github.com', + logger, + orgs: ['orgA', 'orgB'], + }); + + await entityProvider.connect(entityProviderConnection); + mockClient .mockResolvedValueOnce({ organization: { @@ -348,6 +346,19 @@ describe('GithubMultiOrgEntityProvider', () => { }); it('should read every accessible org', async () => { + entityProvider = new GithubMultiOrgEntityProvider({ + id: 'my-id', + gitHubConfig, + githubCredentialsProvider: { + getCredentials: mockGetCredentials, + }, + githubUrl: 'https://github.com', + logger, + orgs: ['orgA', 'orgB'], + }); + + await entityProvider.connect(entityProviderConnection); + getAllInstallationsMock.mockResolvedValue([ { target_type: 'Organization', @@ -636,7 +647,284 @@ describe('GithubMultiOrgEntityProvider', () => { }); }); + it('should use the default namespace if options.alwaysUseDefaultNamespace is provided', async () => { + mockClient + .mockResolvedValueOnce({ + organization: { + membersWithRole: { + pageInfo: { hasNextPage: false }, + nodes: [ + { + login: 'a', + name: 'b', + bio: 'c', + email: 'd', + avatarUrl: 'e', + }, + { + login: 'x', + name: 'y', + bio: 'z', + email: 'w', + avatarUrl: 'v', + }, + ], + }, + }, + }) + .mockResolvedValueOnce({ + organization: { + teams: { + pageInfo: { hasNextPage: false }, + nodes: [ + { + slug: 'team', + combinedSlug: 'orgC/team', + name: 'Team', + description: 'The one and only team', + avatarUrl: 'http://example.com/team.jpeg', + parentTeam: { + slug: 'parent', + combinedSlug: '', + members: { pageInfo: { hasNextPage: false }, nodes: [] }, + }, + members: { + pageInfo: { hasNextPage: false }, + nodes: [{ login: 'a' }, { login: 'x' }], + }, + }, + ], + }, + }, + }) + .mockResolvedValueOnce({ + organization: { + membersWithRole: { + pageInfo: { hasNextPage: false }, + nodes: [ + { + login: 'a', + name: 'b', + bio: 'c', + email: 'd', + avatarUrl: 'e', + }, + { + login: 'x', + name: 'y', + bio: 'z', + email: 'w', + avatarUrl: 'v', + }, + { + login: 'q', + name: 'r', + bio: 's', + email: 't', + avatarUrl: 'u', + }, + ], + }, + }, + }) + .mockResolvedValueOnce({ + organization: { + teams: { + pageInfo: { hasNextPage: false }, + nodes: [ + { + slug: 'team', + combinedSlug: 'orgD/team', + name: 'Team', + description: 'The one and only team', + avatarUrl: 'http://example.com/team.jpeg', + parentTeam: { + slug: 'parent', + combinedSlug: '', + members: { pageInfo: { hasNextPage: false }, nodes: [] }, + }, + members: { + pageInfo: { hasNextPage: false }, + nodes: [{ login: 'a' }, { login: 'q' }], + }, + }, + ], + }, + }, + }); + + (graphql.defaults as jest.Mock).mockReturnValue(mockClient); + + entityProvider = new GithubMultiOrgEntityProvider({ + id: 'my-id', + gitHubConfig, + githubCredentialsProvider: { + getCredentials: mockGetCredentials, + }, + githubUrl: 'https://github.com', + logger, + orgs: ['orgA', 'orgB'], + alwaysUseDefaultNamespace: true, + }); + + await entityProvider.connect(entityProviderConnection); + await entityProvider.read(); + + expect(entityProviderConnection.applyMutation).toHaveBeenCalledWith({ + entities: [ + { + entity: { + apiVersion: 'backstage.io/v1alpha1', + kind: 'User', + metadata: { + annotations: { + 'backstage.io/managed-by-location': + 'url:https://github.com/a', + 'backstage.io/managed-by-origin-location': + 'url:https://github.com/a', + 'github.com/user-login': 'a', + }, + description: 'c', + name: 'a', + }, + spec: { + memberOf: ['team'], + profile: { + displayName: 'b', + email: 'd', + picture: 'e', + }, + }, + }, + locationKey: 'github-multi-org-provider:my-id', + }, + { + entity: { + apiVersion: 'backstage.io/v1alpha1', + kind: 'User', + metadata: { + annotations: { + 'backstage.io/managed-by-location': + 'url:https://github.com/x', + 'backstage.io/managed-by-origin-location': + 'url:https://github.com/x', + 'github.com/user-login': 'x', + }, + description: 'z', + name: 'x', + }, + spec: { + memberOf: ['team'], + profile: { + displayName: 'y', + email: 'w', + picture: 'v', + }, + }, + }, + locationKey: 'github-multi-org-provider:my-id', + }, + { + entity: { + apiVersion: 'backstage.io/v1alpha1', + kind: 'User', + metadata: { + annotations: { + 'backstage.io/managed-by-location': + 'url:https://github.com/q', + 'backstage.io/managed-by-origin-location': + 'url:https://github.com/q', + 'github.com/user-login': 'q', + }, + description: 's', + name: 'q', + }, + spec: { + memberOf: ['team'], + profile: { + displayName: 'r', + email: 't', + picture: 'u', + }, + }, + }, + locationKey: 'github-multi-org-provider:my-id', + }, + { + entity: { + apiVersion: 'backstage.io/v1alpha1', + kind: 'Group', + metadata: { + annotations: { + 'backstage.io/managed-by-location': + 'url:https://github.com/orgs/orgC/teams/team', + 'backstage.io/managed-by-origin-location': + 'url:https://github.com/orgs/orgC/teams/team', + 'github.com/team-slug': 'orgC/team', + }, + name: 'team', + description: 'The one and only team', + }, + spec: { + children: [], + parent: 'parent', + profile: { + displayName: 'Team', + picture: 'http://example.com/team.jpeg', + }, + type: 'team', + members: ['default/a', 'default/x'], + }, + }, + locationKey: 'github-multi-org-provider:my-id', + }, + { + entity: { + apiVersion: 'backstage.io/v1alpha1', + kind: 'Group', + metadata: { + annotations: { + 'backstage.io/managed-by-location': + 'url:https://github.com/orgs/orgD/teams/team', + 'backstage.io/managed-by-origin-location': + 'url:https://github.com/orgs/orgD/teams/team', + 'github.com/team-slug': 'orgD/team', + }, + name: 'team', + description: 'The one and only team', + }, + spec: { + children: [], + parent: 'parent', + profile: { + displayName: 'Team', + picture: 'http://example.com/team.jpeg', + }, + type: 'team', + members: ['default/a', 'default/q'], + }, + }, + locationKey: 'github-multi-org-provider:my-id', + }, + ], + type: 'full', + }); + }); + it('should not call applyMutation if an error is thrown', async () => { + entityProvider = new GithubMultiOrgEntityProvider({ + id: 'my-id', + gitHubConfig, + githubCredentialsProvider: { + getCredentials: mockGetCredentials, + }, + githubUrl: 'https://github.com', + logger, + orgs: ['orgA', 'orgB'], + }); + + await entityProvider.connect(entityProviderConnection); + mockClient.mockImplementationOnce(() => { throw new Error('Network Error'); }); diff --git a/plugins/catalog-backend-module-github/src/providers/GithubMultiOrgEntityProvider.ts b/plugins/catalog-backend-module-github/src/providers/GithubMultiOrgEntityProvider.ts index f07d033ecd..756b9902c6 100644 --- a/plugins/catalog-backend-module-github/src/providers/GithubMultiOrgEntityProvider.ts +++ b/plugins/catalog-backend-module-github/src/providers/GithubMultiOrgEntityProvider.ts @@ -143,6 +143,15 @@ export interface GithubMultiOrgEntityProviderOptions { */ githubCredentialsProvider?: GithubCredentialsProvider; + /** + * Use the default namespace for groups. By default, groups will be namespaced according to their GitHub org. + * + * @remarks + * + * If set to true, groups with the same name across different orgs will be considered the same group. + */ + alwaysUseDefaultNamespace?: boolean; + /** * Optionally include a user transformer for transforming from GitHub users to User Entities */ @@ -198,6 +207,7 @@ export class GithubMultiOrgEntityProvider implements EntityProvider { userTransformer: options.userTransformer, teamTransformer: options.teamTransformer, events: options.events, + alwaysUseDefaultNamespace: options.alwaysUseDefaultNamespace, }); provider.schedule(options.schedule); @@ -216,6 +226,7 @@ export class GithubMultiOrgEntityProvider implements EntityProvider { orgs?: string[]; userTransformer?: UserTransformer; teamTransformer?: TeamTransformer; + alwaysUseDefaultNamespace?: boolean; }, ) {} @@ -846,7 +857,10 @@ export class GithubMultiOrgEntityProvider implements EntityProvider { const result = await defaultOrganizationTeamTransformer(team, ctx); if (result && result.spec) { - result.metadata.namespace = ctx.org.toLocaleLowerCase('en-US'); + if (!this.options.alwaysUseDefaultNamespace) { + result.metadata.namespace = ctx.org.toLocaleLowerCase('en-US'); + } + // Group `spec.members` inherits the namespace of it's group so need to explicitly specify refs here result.spec.members = team.members.map( user => `${DEFAULT_NAMESPACE}/${user.login}`, diff --git a/plugins/catalog-backend-module-gitlab-org/CHANGELOG.md b/plugins/catalog-backend-module-gitlab-org/CHANGELOG.md index 4926c5efc4..793b10fd8b 100644 --- a/plugins/catalog-backend-module-gitlab-org/CHANGELOG.md +++ b/plugins/catalog-backend-module-gitlab-org/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-catalog-backend-module-gitlab-org +## 0.0.1 + +### Patch Changes + +- a70377d: Added a new `catalog-backend-module-gitlab-org` module which adds the `GitlabOrgDiscoveryEntityProvider` to the catalog's providers using the new backend system. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-catalog-backend-module-gitlab@0.3.15 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + ## 0.0.1-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-gitlab-org/package.json b/plugins/catalog-backend-module-gitlab-org/package.json index e0eb268ba6..d0069fc968 100644 --- a/plugins/catalog-backend-module-gitlab-org/package.json +++ b/plugins/catalog-backend-module-gitlab-org/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-gitlab-org", - "version": "0.0.1-next.2", + "version": "0.0.1", "description": "The gitlab-org backend module for the catalog plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-gitlab/CHANGELOG.md b/plugins/catalog-backend-module-gitlab/CHANGELOG.md index 661d422547..ee1ceb70b7 100644 --- a/plugins/catalog-backend-module-gitlab/CHANGELOG.md +++ b/plugins/catalog-backend-module-gitlab/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-catalog-backend-module-gitlab +## 0.3.16 + +### Patch Changes + +- a70377d: Added events support for `GitlabDiscoveryEntityProvider` and `GitlabOrgDiscoveryEntityProvider`. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + - @backstage/integration@1.11.0 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.3.15-next.4 ### Patch Changes diff --git a/plugins/catalog-backend-module-gitlab/package.json b/plugins/catalog-backend-module-gitlab/package.json index c485326f3e..109dee369e 100644 --- a/plugins/catalog-backend-module-gitlab/package.json +++ b/plugins/catalog-backend-module-gitlab/package.json @@ -1,8 +1,53 @@ { + "name": "@backstage/plugin-catalog-backend-module-gitlab", + "version": "0.3.16", + "description": "A Backstage catalog backend module that helps integrate towards GitLab", "backstage": { "role": "backend-plugin-module" }, - "configSchema": "config.d.ts", + "publishConfig": { + "access": "public" + }, + "keywords": [ + "backstage" + ], + "homepage": "https://backstage.io", + "repository": { + "type": "git", + "url": "https://github.com/backstage/backstage", + "directory": "plugins/catalog-backend-module-gitlab" + }, + "license": "Apache-2.0", + "exports": { + ".": "./src/index.ts", + "./alpha": "./src/alpha.ts", + "./package.json": "./package.json" + }, + "main": "src/index.ts", + "types": "src/index.ts", + "typesVersions": { + "*": { + "alpha": [ + "src/alpha.ts" + ], + "package.json": [ + "package.json" + ] + } + }, + "files": [ + "config.d.ts", + "dist" + ], + "scripts": { + "build": "backstage-cli package build", + "clean": "backstage-cli package clean", + "lint": "backstage-cli package lint", + "prepack": "backstage-cli package prepack", + "postpack": "backstage-cli package postpack", + "start": "backstage-cli package start", + "test": "backstage-cli package test" + }, "dependencies": { "@backstage/backend-common": "workspace:^", "@backstage/backend-plugin-api": "workspace:^", @@ -18,7 +63,6 @@ "node-fetch": "^2.6.7", "uuid": "^9.0.0" }, - "description": "A Backstage catalog backend module that helps integrate towards GitLab", "devDependencies": { "@backstage/backend-test-utils": "workspace:^", "@backstage/cli": "workspace:^", @@ -28,49 +72,5 @@ "luxon": "^3.0.0", "msw": "^1.0.0" }, - "exports": { - ".": "./src/index.ts", - "./alpha": "./src/alpha.ts", - "./package.json": "./package.json" - }, - "files": [ - "config.d.ts", - "dist" - ], - "homepage": "https://backstage.io", - "keywords": [ - "backstage" - ], - "license": "Apache-2.0", - "main": "src/index.ts", - "name": "@backstage/plugin-catalog-backend-module-gitlab", - "publishConfig": { - "access": "public" - }, - "repository": { - "directory": "plugins/catalog-backend-module-gitlab", - "type": "git", - "url": "https://github.com/backstage/backstage" - }, - "scripts": { - "build": "backstage-cli package build", - "clean": "backstage-cli package clean", - "lint": "backstage-cli package lint", - "postpack": "backstage-cli package postpack", - "prepack": "backstage-cli package prepack", - "start": "backstage-cli package start", - "test": "backstage-cli package test" - }, - "types": "src/index.ts", - "typesVersions": { - "*": { - "alpha": [ - "src/alpha.ts" - ], - "package.json": [ - "package.json" - ] - } - }, - "version": "0.3.15-next.4" + "configSchema": "config.d.ts" } diff --git a/plugins/catalog-backend-module-incremental-ingestion/CHANGELOG.md b/plugins/catalog-backend-module-incremental-ingestion/CHANGELOG.md index 961ebe081c..b20c236f55 100644 --- a/plugins/catalog-backend-module-incremental-ingestion/CHANGELOG.md +++ b/plugins/catalog-backend-module-incremental-ingestion/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-catalog-backend-module-incremental-ingestion +## 0.4.23 + +### Patch Changes + +- 8c1ab9e: Fix plugin/incremental-ingestion 'Maximum call stack size exceeded' error when ingest large entities. +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + ## 0.4.23-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-incremental-ingestion/package.json b/plugins/catalog-backend-module-incremental-ingestion/package.json index 0a4f73c5d4..8f6016a228 100644 --- a/plugins/catalog-backend-module-incremental-ingestion/package.json +++ b/plugins/catalog-backend-module-incremental-ingestion/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-incremental-ingestion", - "version": "0.4.23-next.2", + "version": "0.4.23", "description": "An entity provider for streaming large asset sources into the catalog", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-incremental-ingestion/src/database/migrations.ts b/plugins/catalog-backend-module-incremental-ingestion/src/database/migrations.ts index 940a82107b..08c581e77a 100644 --- a/plugins/catalog-backend-module-incremental-ingestion/src/database/migrations.ts +++ b/plugins/catalog-backend-module-incremental-ingestion/src/database/migrations.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import { resolvePackagePath } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { Knex } from 'knex'; import { DB_MIGRATIONS_TABLE } from './tables'; diff --git a/plugins/catalog-backend-module-ldap/CHANGELOG.md b/plugins/catalog-backend-module-ldap/CHANGELOG.md index 22da3d6099..917f895046 100644 --- a/plugins/catalog-backend-module-ldap/CHANGELOG.md +++ b/plugins/catalog-backend-module-ldap/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-catalog-backend-module-ldap +## 0.5.34 + +### Patch Changes + +- 7699967: Remove dependency to Winston Logger and use Backstage LoggerService instead +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.5.34-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-ldap/api-report.md b/plugins/catalog-backend-module-ldap/api-report.md index 277a48af8d..76276c8fad 100644 --- a/plugins/catalog-backend-module-ldap/api-report.md +++ b/plugins/catalog-backend-module-ldap/api-report.md @@ -12,7 +12,7 @@ import { EntityProviderConnection } from '@backstage/plugin-catalog-node'; import { GroupEntity } from '@backstage/catalog-model'; import { JsonValue } from '@backstage/types'; import { LocationSpec } from '@backstage/plugin-catalog-common'; -import { Logger } from 'winston'; +import { LoggerService } from '@backstage/backend-plugin-api'; import { SearchEntry } from 'ldapjs'; import { SearchOptions } from 'ldapjs'; import { TaskRunner } from '@backstage/backend-tasks'; @@ -76,10 +76,10 @@ export const LDAP_UUID_ANNOTATION = 'backstage.io/ldap-uuid'; // @public export class LdapClient { - constructor(client: Client, logger: Logger); + constructor(client: Client, logger: LoggerService); // (undocumented) static create( - logger: Logger, + logger: LoggerService, target: string, bind?: BindConfig, tls?: TLSConfig, @@ -99,7 +99,7 @@ export class LdapOrgEntityProvider implements EntityProvider { constructor(options: { id: string; provider: LdapProviderConfig; - logger: Logger; + logger: LoggerService; userTransformer?: UserTransformer; groupTransformer?: GroupTransformer; }); @@ -112,14 +112,14 @@ export class LdapOrgEntityProvider implements EntityProvider { ): LdapOrgEntityProvider; // (undocumented) getProviderName(): string; - read(options?: { logger?: Logger }): Promise; + read(options?: { logger?: LoggerService }): Promise; } // @public export interface LdapOrgEntityProviderOptions { groupTransformer?: GroupTransformer; id: string; - logger: Logger; + logger: LoggerService; schedule: 'manual' | TaskRunner; target: string; userTransformer?: UserTransformer; @@ -129,7 +129,7 @@ export interface LdapOrgEntityProviderOptions { export class LdapOrgReaderProcessor implements CatalogProcessor { constructor(options: { providers: LdapProviderConfig[]; - logger: Logger; + logger: LoggerService; groupTransformer?: GroupTransformer; userTransformer?: UserTransformer; }); @@ -137,7 +137,7 @@ export class LdapOrgReaderProcessor implements CatalogProcessor { static fromConfig( configRoot: Config, options: { - logger: Logger; + logger: LoggerService; groupTransformer?: GroupTransformer; userTransformer?: UserTransformer; }, @@ -187,7 +187,7 @@ export function readLdapOrg( options: { groupTransformer?: GroupTransformer; userTransformer?: UserTransformer; - logger: Logger; + logger: LoggerService; }, ): Promise<{ users: UserEntity[]; diff --git a/plugins/catalog-backend-module-ldap/package.json b/plugins/catalog-backend-module-ldap/package.json index e50d629e0e..2b447ea7ec 100644 --- a/plugins/catalog-backend-module-ldap/package.json +++ b/plugins/catalog-backend-module-ldap/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-ldap", - "version": "0.5.34-next.2", + "version": "0.5.34", "description": "A Backstage catalog backend module that helps integrate towards LDAP", "backstage": { "role": "backend-plugin-module" @@ -36,6 +36,7 @@ "test": "backstage-cli package test" }, "dependencies": { + "@backstage/backend-plugin-api": "workspace:^", "@backstage/backend-tasks": "workspace:^", "@backstage/catalog-model": "workspace:^", "@backstage/config": "workspace:^", @@ -46,8 +47,7 @@ "@types/ldapjs": "^2.2.5", "ldapjs": "^2.3.3", "lodash": "^4.17.21", - "uuid": "^9.0.0", - "winston": "^3.2.1" + "uuid": "^9.0.0" }, "devDependencies": { "@backstage/cli": "workspace:^", diff --git a/plugins/catalog-backend-module-ldap/src/ldap/client.ts b/plugins/catalog-backend-module-ldap/src/ldap/client.ts index 75e54013b3..48a3eedfb8 100644 --- a/plugins/catalog-backend-module-ldap/src/ldap/client.ts +++ b/plugins/catalog-backend-module-ldap/src/ldap/client.ts @@ -19,7 +19,6 @@ import { readFile } from 'fs/promises'; import ldap, { Client, SearchEntry, SearchOptions } from 'ldapjs'; import { cloneDeep } from 'lodash'; import tlsLib from 'tls'; -import { Logger } from 'winston'; import { BindConfig, TLSConfig } from './config'; import { createOptions, errorString } from './util'; import { @@ -29,6 +28,7 @@ import { FreeIpaVendor, LdapVendor, } from './vendors'; +import { LoggerService } from '@backstage/backend-plugin-api'; /** * Basic wrapper for the `ldapjs` library. @@ -41,7 +41,7 @@ export class LdapClient { private vendor: Promise | undefined; static async create( - logger: Logger, + logger: LoggerService, target: string, bind?: BindConfig, tls?: TLSConfig, @@ -89,7 +89,7 @@ export class LdapClient { constructor( private readonly client: Client, - private readonly logger: Logger, + private readonly logger: LoggerService, ) {} /** diff --git a/plugins/catalog-backend-module-ldap/src/ldap/read.ts b/plugins/catalog-backend-module-ldap/src/ldap/read.ts index 590d27ba8b..50036b94b0 100644 --- a/plugins/catalog-backend-module-ldap/src/ldap/read.ts +++ b/plugins/catalog-backend-module-ldap/src/ldap/read.ts @@ -31,9 +31,9 @@ import { LDAP_UUID_ANNOTATION, } from './constants'; import { LdapVendor } from './vendors'; -import { Logger } from 'winston'; import { GroupTransformer, UserTransformer } from './types'; import { mapStringAttr } from './util'; +import { LoggerService } from '@backstage/backend-plugin-api'; /** * The default implementation of the transformation from an LDAP entry to a @@ -269,7 +269,7 @@ export async function readLdapOrg( options: { groupTransformer?: GroupTransformer; userTransformer?: UserTransformer; - logger: Logger; + logger: LoggerService; }, ): Promise<{ users: UserEntity[]; diff --git a/plugins/catalog-backend-module-ldap/src/processors/LdapOrgEntityProvider.ts b/plugins/catalog-backend-module-ldap/src/processors/LdapOrgEntityProvider.ts index d4f19d0522..97ea4a53b0 100644 --- a/plugins/catalog-backend-module-ldap/src/processors/LdapOrgEntityProvider.ts +++ b/plugins/catalog-backend-module-ldap/src/processors/LdapOrgEntityProvider.ts @@ -27,7 +27,6 @@ import { } from '@backstage/plugin-catalog-node'; import { merge } from 'lodash'; import * as uuid from 'uuid'; -import { Logger } from 'winston'; import { GroupTransformer, LdapClient, @@ -37,6 +36,7 @@ import { readLdapOrg, UserTransformer, } from '../ldap'; +import { LoggerService } from '@backstage/backend-plugin-api'; /** * Options for {@link LdapOrgEntityProvider}. @@ -64,7 +64,7 @@ export interface LdapOrgEntityProviderOptions { /** * The logger to use. */ - logger: Logger; + logger: LoggerService; /** * The refresh schedule to use. @@ -143,7 +143,7 @@ export class LdapOrgEntityProvider implements EntityProvider { private options: { id: string; provider: LdapProviderConfig; - logger: Logger; + logger: LoggerService; userTransformer?: UserTransformer; groupTransformer?: GroupTransformer; }, @@ -164,7 +164,7 @@ export class LdapOrgEntityProvider implements EntityProvider { * Runs one single complete ingestion. This is only necessary if you use * manual scheduling. */ - async read(options?: { logger?: Logger }) { + async read(options?: { logger?: LoggerService }) { if (!this.connection) { throw new Error('Not initialized'); } @@ -237,7 +237,7 @@ export class LdapOrgEntityProvider implements EntityProvider { } // Helps wrap the timing and logging behaviors -function trackProgress(logger: Logger) { +function trackProgress(logger: LoggerService) { let timestamp = Date.now(); let summary: string; diff --git a/plugins/catalog-backend-module-ldap/src/processors/LdapOrgReaderProcessor.ts b/plugins/catalog-backend-module-ldap/src/processors/LdapOrgReaderProcessor.ts index 00578ac3a4..c920968fc1 100644 --- a/plugins/catalog-backend-module-ldap/src/processors/LdapOrgReaderProcessor.ts +++ b/plugins/catalog-backend-module-ldap/src/processors/LdapOrgReaderProcessor.ts @@ -15,7 +15,6 @@ */ import { Config } from '@backstage/config'; -import { Logger } from 'winston'; import { GroupTransformer, LdapClient, @@ -30,6 +29,7 @@ import { processingResult, } from '@backstage/plugin-catalog-node'; import { LocationSpec } from '@backstage/plugin-catalog-common'; +import { LoggerService } from '@backstage/backend-plugin-api'; /** * Extracts teams and users out of an LDAP server. @@ -38,14 +38,14 @@ import { LocationSpec } from '@backstage/plugin-catalog-common'; */ export class LdapOrgReaderProcessor implements CatalogProcessor { private readonly providers: LdapProviderConfig[]; - private readonly logger: Logger; + private readonly logger: LoggerService; private readonly groupTransformer?: GroupTransformer; private readonly userTransformer?: UserTransformer; static fromConfig( configRoot: Config, options: { - logger: Logger; + logger: LoggerService; groupTransformer?: GroupTransformer; userTransformer?: UserTransformer; }, @@ -62,7 +62,7 @@ export class LdapOrgReaderProcessor implements CatalogProcessor { constructor(options: { providers: LdapProviderConfig[]; - logger: Logger; + logger: LoggerService; groupTransformer?: GroupTransformer; userTransformer?: UserTransformer; }) { diff --git a/plugins/catalog-backend-module-msgraph/CHANGELOG.md b/plugins/catalog-backend-module-msgraph/CHANGELOG.md index 4d6a4bc350..526a8609ac 100644 --- a/plugins/catalog-backend-module-msgraph/CHANGELOG.md +++ b/plugins/catalog-backend-module-msgraph/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-catalog-backend-module-msgraph +## 0.5.26 + +### Patch Changes + +- 49eab29: Fixed disabling of user photo fetching. Previously, the config value wasn't propagated properly, so user photos was still being fetched despite disabled by config. +- 6e370e6: Handle fetching huge amounts of users from Azure without crashing +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.5.26-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-msgraph/package.json b/plugins/catalog-backend-module-msgraph/package.json index ddc3ca4af3..b12afe2f01 100644 --- a/plugins/catalog-backend-module-msgraph/package.json +++ b/plugins/catalog-backend-module-msgraph/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-msgraph", - "version": "0.5.26-next.2", + "version": "0.5.26", "description": "A Backstage catalog backend module that helps integrate towards Microsoft Graph", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-openapi/CHANGELOG.md b/plugins/catalog-backend-module-openapi/CHANGELOG.md index 2b1e0650a8..a0f8b3945d 100644 --- a/plugins/catalog-backend-module-openapi/CHANGELOG.md +++ b/plugins/catalog-backend-module-openapi/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-catalog-backend-module-openapi +## 0.1.36 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-catalog-backend@1.22.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/integration@1.11.0 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.1.36-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-openapi/package.json b/plugins/catalog-backend-module-openapi/package.json index 2eb832684d..40975fc254 100644 --- a/plugins/catalog-backend-module-openapi/package.json +++ b/plugins/catalog-backend-module-openapi/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-openapi", - "version": "0.1.36-next.2", + "version": "0.1.36", "description": "A Backstage catalog backend module that helps with OpenAPI specifications", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-puppetdb/CHANGELOG.md b/plugins/catalog-backend-module-puppetdb/CHANGELOG.md index 84d705b8be..e49b8fdfa2 100644 --- a/plugins/catalog-backend-module-puppetdb/CHANGELOG.md +++ b/plugins/catalog-backend-module-puppetdb/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-catalog-backend-module-puppetdb +## 0.1.24 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + ## 0.1.24-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-puppetdb/package.json b/plugins/catalog-backend-module-puppetdb/package.json index 6d3a71092e..d12990b54d 100644 --- a/plugins/catalog-backend-module-puppetdb/package.json +++ b/plugins/catalog-backend-module-puppetdb/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-puppetdb", - "version": "0.1.24-next.2", + "version": "0.1.24", "description": "A Backstage catalog backend module that helps integrate towards PuppetDB", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-scaffolder-entity-model/CHANGELOG.md b/plugins/catalog-backend-module-scaffolder-entity-model/CHANGELOG.md index b51aacb4f1..e2a2e7f299 100644 --- a/plugins/catalog-backend-module-scaffolder-entity-model/CHANGELOG.md +++ b/plugins/catalog-backend-module-scaffolder-entity-model/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-catalog-backend-module-scaffolder-entity-model +## 0.1.16 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.1.16-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-scaffolder-entity-model/package.json b/plugins/catalog-backend-module-scaffolder-entity-model/package.json index 2bf29a3bb3..5f7a22b8dc 100644 --- a/plugins/catalog-backend-module-scaffolder-entity-model/package.json +++ b/plugins/catalog-backend-module-scaffolder-entity-model/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-scaffolder-entity-model", - "version": "0.1.16-next.2", + "version": "0.1.16", "description": "Adds support for the scaffolder specific entity model (e.g. the Template kind) to the catalog backend plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend-module-unprocessed/CHANGELOG.md b/plugins/catalog-backend-module-unprocessed/CHANGELOG.md index 1a2e2a2785..16b105df8d 100644 --- a/plugins/catalog-backend-module-unprocessed/CHANGELOG.md +++ b/plugins/catalog-backend-module-unprocessed/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-catalog-backend-module-unprocessed +## 0.4.5 + +### Patch Changes + +- b192752: Updated `README.md` to point to `packages/backend` instead of `packages/backend-next`. +- 6f5a3a3: Correctly convert owner to string in case owner has not been provided +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.4.5-next.2 ### Patch Changes diff --git a/plugins/catalog-backend-module-unprocessed/package.json b/plugins/catalog-backend-module-unprocessed/package.json index ba13df5a2a..c1df39fc6c 100644 --- a/plugins/catalog-backend-module-unprocessed/package.json +++ b/plugins/catalog-backend-module-unprocessed/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend-module-unprocessed", - "version": "0.4.5-next.2", + "version": "0.4.5", "description": "Backstage Catalog module to view unprocessed entities", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/catalog-backend/CHANGELOG.md b/plugins/catalog-backend/CHANGELOG.md index 4d8e2f1cd0..3934bb495f 100644 --- a/plugins/catalog-backend/CHANGELOG.md +++ b/plugins/catalog-backend/CHANGELOG.md @@ -1,5 +1,33 @@ # @backstage/plugin-catalog-backend +## 1.22.0 + +### Minor Changes + +- f2a2a83: Deprecated the `LocationAnalyzer` type, which has been moved to `@backstage/plugin-catalog-node`. +- f2a2a83: The `/alpha` plugin export has had its implementation of the `catalogAnalysisExtensionPoint` updated to reflect the new API. +- 8d14475: Emit well known relationships for the Domain entity kind. + +### Patch Changes + +- 131e5cb: Fix broken links in README. +- c6cb568: Add lifecycle monitoring for the catalog processing +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 8479a0b: Fixed bug in stitching queue gauge that included entities that are scheduled in the future. +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-search-backend-module-catalog@0.1.24 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + - @backstage/integration@1.11.0 + - @backstage/backend-openapi-utils@0.1.11 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-permission-node@0.7.29 + ## 1.22.0-next.2 ### Minor Changes @@ -3574,8 +3602,7 @@ `packages/backend/src/plugins/catalog.ts` creates the catalog builder using `CatalogBuilder.create`. If you instead call `new CatalogBuilder`, you are on the old implementation and will experience breakage if you upgrade to this - version. If you are still on the old version, see [the relevant change log - entry](https://github.com/backstage/backstage/blob/master/plugins/catalog-backend/CHANGELOG.md#patch-changes-27) + version. If you are still on the old version, see [the relevant change log entry](https://github.com/backstage/backstage/blob/master/plugins/catalog-backend/CHANGELOG.md#patch-changes-27) for migration instructions. The minimal `packages/backend/src/plugins/catalog.ts` file is now: @@ -3668,8 +3695,7 @@ `packages/backend/src/plugins/catalog.ts` creates the catalog builder using `CatalogBuilder.create`. If you instead call `new CatalogBuilder`, you are on the old implementation and will experience breakage if you upgrade to this - version. If you are still on the old version, see [the relevant change log - entry](https://github.com/backstage/backstage/blob/master/plugins/catalog-backend/CHANGELOG.md#patch-changes-27) + version. If you are still on the old version, see [the relevant change log entry](https://github.com/backstage/backstage/blob/master/plugins/catalog-backend/CHANGELOG.md#patch-changes-27) for migration instructions. The minimal `packages/backend/src/plugins/catalog.ts` file is now: diff --git a/plugins/catalog-backend/README.md b/plugins/catalog-backend/README.md index 7f886de155..b0bd0328ab 100644 --- a/plugins/catalog-backend/README.md +++ b/plugins/catalog-backend/README.md @@ -1,9 +1,7 @@ # Catalog Backend -This is the backend for the default Backstage [software -catalog](http://backstage.io/docs/features/software-catalog/). -This provides an API for consumers such as the frontend [catalog -plugin](https://github.com/backstage/backstage/tree/master/plugins/catalog). +This is the backend for the default Backstage [software catalog](http://backstage.io/docs/features/software-catalog/). +This provides an API for consumers such as the frontend [catalog plugin](https://github.com/backstage/backstage/tree/master/plugins/catalog). It comes with a builtin database-backed implementation of the catalog that can store and serve your catalog for you. @@ -30,12 +28,19 @@ restoring the plugin, if you previously removed it. yarn --cwd packages/backend add @backstage/plugin-catalog-backend ``` -### Adding the plugin to your `packages/backend` +Then add the plugin to your backend, typically in `packages/backend/src/index.ts`: -You'll need to add the plugin to the router in your `backend` package. You can -do this by creating a file called `packages/backend/src/plugins/catalog.ts` with -contents matching [catalog.ts in the create-app -template](https://github.com/backstage/backstage/blob/master/packages/create-app/templates/default-app/packages/backend/src/plugins/catalog.ts). +```ts +const backend = createBackend(); +// ... +backend.add(import('@backstage/plugin-catalog-backend/alpha')); +``` + +#### Old backend system + +In the old backend system there's a bit more wiring required. You'll need to +create a file called `packages/backend/src/plugins/catalog.ts` with contents +matching [catalog.ts in the create-app template](https://github.com/backstage/backstage/blob/ad9314d3a7e0405719ba93badf96e97adde8ef83/packages/create-app/templates/default-app/packages/backend/src/plugins/catalog.ts). With the `catalog.ts` router setup in place, add the router to `packages/backend/src/index.ts`: @@ -60,10 +65,8 @@ async function main() { ### Adding catalog entities At this point the `catalog-backend` is installed in your backend package, but -you will not have any catalog entities loaded. See [Catalog -Configuration](https://backstage.io/docs/features/software-catalog/configuration) -for how to add locations, or copy the catalog locations from the [create-app -template](https://github.com/backstage/backstage/blob/master/packages/create-app/templates/default-app/app-config.yaml.hbs) +you will not have any catalog entities loaded. See [Catalog Configuration](https://backstage.io/docs/features/software-catalog/configuration) +for how to add locations, or copy the catalog locations from the [create-app template](https://github.com/backstage/backstage/blob/master/packages/create-app/templates/default-app/app-config.yaml.hbs) to get up and running quickly. ## Development diff --git a/plugins/catalog-backend/package.json b/plugins/catalog-backend/package.json index f57efe5ae6..44f35dccf2 100644 --- a/plugins/catalog-backend/package.json +++ b/plugins/catalog-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-backend", - "version": "1.22.0-next.2", + "version": "1.22.0", "description": "The Backstage backend plugin that provides the Backstage catalog", "backstage": { "role": "backend-plugin" diff --git a/plugins/catalog-backend/src/database/migrations.ts b/plugins/catalog-backend/src/database/migrations.ts index ed3a7751b5..5139c74930 100644 --- a/plugins/catalog-backend/src/database/migrations.ts +++ b/plugins/catalog-backend/src/database/migrations.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import { resolvePackagePath } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { Knex } from 'knex'; export async function applyDatabaseMigrations(knex: Knex): Promise { diff --git a/plugins/catalog-common/CHANGELOG.md b/plugins/catalog-common/CHANGELOG.md index f070ca11e2..a6dc3f06d6 100644 --- a/plugins/catalog-common/CHANGELOG.md +++ b/plugins/catalog-common/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-catalog-common +## 1.0.23 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + ## 1.0.23-next.0 ### Patch Changes diff --git a/plugins/catalog-common/package.json b/plugins/catalog-common/package.json index 59d0019512..936fc3c935 100644 --- a/plugins/catalog-common/package.json +++ b/plugins/catalog-common/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-common", - "version": "1.0.23-next.0", + "version": "1.0.23", "description": "Common functionalities for the catalog plugin", "backstage": { "role": "common-library" diff --git a/plugins/catalog-graph/CHANGELOG.md b/plugins/catalog-graph/CHANGELOG.md index 372a94a19c..9d5a638ad7 100644 --- a/plugins/catalog-graph/CHANGELOG.md +++ b/plugins/catalog-graph/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-catalog-graph +## 0.4.5 + +### Patch Changes + +- 39564b3: Allow multiple edges with different type (e.g. `ownedBy` and `applicationOwnerBy`) to have the same source and target node. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + ## 0.4.5-next.2 ### Patch Changes diff --git a/plugins/catalog-graph/package.json b/plugins/catalog-graph/package.json index ac9039a441..4d2ac4b393 100644 --- a/plugins/catalog-graph/package.json +++ b/plugins/catalog-graph/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-graph", - "version": "0.4.5-next.2", + "version": "0.4.5", "backstage": { "role": "frontend-plugin" }, diff --git a/plugins/catalog-graph/src/components/EntityRelationsGraph/DefaultRenderLabel.tsx b/plugins/catalog-graph/src/components/EntityRelationsGraph/DefaultRenderLabel.tsx index cde4808f6e..ae01a113dd 100644 --- a/plugins/catalog-graph/src/components/EntityRelationsGraph/DefaultRenderLabel.tsx +++ b/plugins/catalog-graph/src/components/EntityRelationsGraph/DefaultRenderLabel.tsx @@ -38,7 +38,7 @@ export function DefaultRenderLabel({ return ( {relations.map((r, i) => ( - 0 && classes.secondary)}> + {i > 0 && / } {r} diff --git a/plugins/catalog-graph/src/components/EntityRelationsGraph/useEntityRelationNodesAndEdges.test.ts b/plugins/catalog-graph/src/components/EntityRelationsGraph/useEntityRelationNodesAndEdges.test.ts index 8c7b59b9c4..0a5e43bf37 100644 --- a/plugins/catalog-graph/src/components/EntityRelationsGraph/useEntityRelationNodesAndEdges.test.ts +++ b/plugins/catalog-graph/src/components/EntityRelationsGraph/useEntityRelationNodesAndEdges.test.ts @@ -371,12 +371,6 @@ describe('useEntityRelationNodesAndEdges', () => { relations: [RELATION_HAS_PART, RELATION_PART_OF], to: 'b:d/c1', }, - { - from: 'b:d/c', - label: 'visible', - relations: [RELATION_HAS_PART, RELATION_PART_OF], - to: 'b:d/c1', - }, { from: 'b:d/c1', label: 'visible', @@ -389,24 +383,6 @@ describe('useEntityRelationNodesAndEdges', () => { relations: [RELATION_HAS_PART, RELATION_PART_OF], to: 'b:d/c2', }, - { - from: 'b:d/c1', - label: 'visible', - relations: [RELATION_HAS_PART, RELATION_PART_OF], - to: 'b:d/c2', - }, - { - from: 'b:d/c', - label: 'visible', - relations: [RELATION_OWNER_OF, RELATION_OWNED_BY], - to: 'k:d/a1', - }, - { - from: 'b:d/c1', - label: 'visible', - relations: [RELATION_OWNER_OF, RELATION_OWNED_BY], - to: 'k:d/a1', - }, ]); }); diff --git a/plugins/catalog-graph/src/components/EntityRelationsGraph/useEntityRelationNodesAndEdges.ts b/plugins/catalog-graph/src/components/EntityRelationsGraph/useEntityRelationNodesAndEdges.ts index d2a5138ccb..74aff1b3d0 100644 --- a/plugins/catalog-graph/src/components/EntityRelationsGraph/useEntityRelationNodesAndEdges.ts +++ b/plugins/catalog-graph/src/components/EntityRelationsGraph/useEntityRelationNodesAndEdges.ts @@ -146,11 +146,60 @@ export function useEntityRelationNodesAndEdges({ nodeQueue.push(rel.targetRef); visitedNodes.add(rel.targetRef); } + + // if unidirectional add missing relations as entities are only visited once + if (unidirectional) { + const findIndex = edges.findIndex( + edge => + entityRef === edge.from && + rel.targetRef === edge.to && + !edge.relations.includes(rel.type), + ); + if (findIndex >= 0) { + if (mergeRelations) { + const pair = relationPairs.find( + ([l, r]) => l === rel.type || r === rel.type, + ) ?? [rel.type]; + edges[findIndex].relations = [ + ...edges[findIndex].relations, + ...pair, + ]; + } else { + edges[findIndex].relations = [ + ...edges[findIndex].relations, + rel.type, + ]; + } + } + } }); } } - setNodesAndEdges({ nodes, edges }); + // Reduce edges as the dependency graph anyway ignores duplicated edges regarding from / to + // Additionally, this will improve rendering speed for the dependency graph + const finalEdges = edges.reduce((previousEdges, currentEdge) => { + const indexFound = previousEdges.findIndex( + previousEdge => + previousEdge.from === currentEdge.from && + previousEdge.to === currentEdge.to, + ); + if (indexFound >= 0) { + previousEdges[indexFound] = { + ...previousEdges[indexFound], + relations: Array.from( + new Set([ + ...previousEdges[indexFound].relations, + ...currentEdge.relations, + ]), + ), + }; + return previousEdges; + } + return [...previousEdges, currentEdge]; + }, [] as EntityEdge[]); + + setNodesAndEdges({ nodes, edges: finalEdges }); }, 100, [ diff --git a/plugins/catalog-import/CHANGELOG.md b/plugins/catalog-import/CHANGELOG.md index f201bf7552..8bc9f0914e 100644 --- a/plugins/catalog-import/CHANGELOG.md +++ b/plugins/catalog-import/CHANGELOG.md @@ -1,5 +1,24 @@ # @backstage/plugin-catalog-import +## 0.11.0 + +### Minor Changes + +- e1174b0: `EntityListComponent` uses `entityPresentationApi` instead of `humanizeEntityRef` to display Entity + +### Patch Changes + +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.10.11-next.2 ### Patch Changes diff --git a/plugins/catalog-import/package.json b/plugins/catalog-import/package.json index d5f70964a1..822ed6f395 100644 --- a/plugins/catalog-import/package.json +++ b/plugins/catalog-import/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-import", - "version": "0.10.11-next.2", + "version": "0.11.0", "description": "A Backstage plugin the helps you import entities into your catalog", "backstage": { "role": "frontend-plugin" @@ -78,6 +78,7 @@ "@backstage/cli": "workspace:^", "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", + "@backstage/plugin-catalog": "workspace:^", "@backstage/test-utils": "workspace:^", "@testing-library/dom": "^10.0.0", "@testing-library/jest-dom": "^6.0.0", diff --git a/plugins/catalog-import/src/components/EntityListComponent/EntityListComponent.tsx b/plugins/catalog-import/src/components/EntityListComponent/EntityListComponent.tsx index ef57fad204..80a2d90fcc 100644 --- a/plugins/catalog-import/src/components/EntityListComponent/EntityListComponent.tsx +++ b/plugins/catalog-import/src/components/EntityListComponent/EntityListComponent.tsx @@ -14,11 +14,16 @@ * limitations under the License. */ -import { Entity, CompoundEntityRef } from '@backstage/catalog-model'; -import { useApp } from '@backstage/core-plugin-api'; import { + Entity, + CompoundEntityRef, + stringifyEntityRef, +} from '@backstage/catalog-model'; +import { useApi } from '@backstage/core-plugin-api'; +import { + EntityDisplayName, EntityRefLink, - humanizeEntityRef, + entityPresentationApiRef, } from '@backstage/plugin-catalog-react'; import Collapse from '@material-ui/core/Collapse'; import IconButton from '@material-ui/core/IconButton'; @@ -38,12 +43,6 @@ const useStyles = makeStyles(theme => ({ }, })); -function sortEntities(entities: Array) { - return entities.sort((a, b) => - humanizeEntityRef(a).localeCompare(humanizeEntityRef(b)), - ); -} - /** * Props for {@link EntityListComponent}. * @@ -76,9 +75,8 @@ export const EntityListComponent = (props: EntityListComponentProps) => { withLinks = false, } = props; - const app = useApp(); const classes = useStyles(); - + const entityPresentationApi = useApi(entityPresentationApiRef); const [expandedUrls, setExpandedUrls] = useState([]); const handleClick = (url: string) => { @@ -87,6 +85,17 @@ export const EntityListComponent = (props: EntityListComponentProps) => { ); }; + function sortEntities(entities: Array) { + return entities.sort((a, b) => + entityPresentationApi + .forEntity(stringifyEntityRef(a)) + .snapshot.entityRef.localeCompare( + entityPresentationApi.forEntity(stringifyEntityRef(b)).snapshot + .entityRef, + ), + ); + } + return ( {firstListItem} @@ -124,12 +133,9 @@ export const EntityListComponent = (props: EntityListComponentProps) => { > {sortEntities(r.entities).map(entity => { - const Icon = app.getSystemIcon( - `kind:${entity.kind.toLocaleLowerCase('en-US')}`, - ); return ( { } : {})} > - {Icon && } - + } + /> ); })} diff --git a/plugins/catalog-import/src/components/StepPrepareSelectLocations/StepPrepareSelectLocations.test.tsx b/plugins/catalog-import/src/components/StepPrepareSelectLocations/StepPrepareSelectLocations.test.tsx index b5efd3fbbf..e5a4174859 100644 --- a/plugins/catalog-import/src/components/StepPrepareSelectLocations/StepPrepareSelectLocations.test.tsx +++ b/plugins/catalog-import/src/components/StepPrepareSelectLocations/StepPrepareSelectLocations.test.tsx @@ -14,14 +14,22 @@ * limitations under the License. */ -import { renderInTestApp } from '@backstage/test-utils'; +import { TestApiProvider, renderInTestApp } from '@backstage/test-utils'; import { act, screen } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import React from 'react'; import { AnalyzeResult } from '../../api'; import { StepPrepareSelectLocations } from './StepPrepareSelectLocations'; +import { + CatalogApi, + catalogApiRef, + entityPresentationApiRef, +} from '@backstage/plugin-catalog-react'; +import { DefaultEntityPresentationApi } from '@backstage/plugin-catalog'; +import { Entity } from '@backstage/catalog-model'; describe('', () => { + let entities: Entity[]; const analyzeResult = { type: 'locations', locations: [ @@ -53,17 +61,43 @@ describe('', () => { ], } as Extract; + const catalogApi: jest.Mocked = { + getLocationById: jest.fn(), + getEntityByName: jest.fn(), + getEntities: jest.fn(async () => ({ items: entities })), + addLocation: jest.fn(), + getLocationByRef: jest.fn(), + removeEntityByUid: jest.fn(), + } as any; + let Wrapper: React.ComponentType>; + beforeEach(() => { jest.resetAllMocks(); + catalogApi.getEntities.mockResolvedValue({ items: entities }); + Wrapper = ({ children }: { children?: React.ReactNode }) => ( + + {children} + + ); }); it('renders display locations to be added', async () => { await renderInTestApp( - undefined} - onGoBack={() => undefined} - />, + + undefined} + onGoBack={() => undefined} + /> + , ); expect(screen.getByText('url-1')).toBeInTheDocument(); @@ -96,11 +130,13 @@ describe('', () => { } as Extract; await renderInTestApp( - undefined} - onGoBack={() => undefined} - />, + + undefined} + onGoBack={() => undefined} + /> + , ); expect(screen.getByText(/my-target/)).toBeInTheDocument(); @@ -112,11 +148,13 @@ describe('', () => { it('should select and deselect all', async () => { await renderInTestApp( - undefined} - onGoBack={() => undefined} - />, + + undefined} + onGoBack={() => undefined} + /> + , ); const checkboxes = screen.getAllByRole('checkbox'); @@ -144,15 +182,17 @@ describe('', () => { it('should preselect prepared locations', async () => { await renderInTestApp( - undefined} - onGoBack={() => undefined} - />, + + undefined} + onGoBack={() => undefined} + /> + , ); const checkboxes = screen.getAllByRole('checkbox'); @@ -164,11 +204,13 @@ describe('', () => { it('should select items', async () => { await renderInTestApp( - undefined} - onGoBack={() => undefined} - />, + + undefined} + onGoBack={() => undefined} + /> + , ); const checkboxes = screen.getAllByRole('checkbox'); @@ -193,11 +235,13 @@ describe('', () => { const onGoBack = jest.fn(); await renderInTestApp( - undefined} - onGoBack={onGoBack} - />, + + undefined} + onGoBack={onGoBack} + /> + , ); await act(async () => { @@ -211,11 +255,13 @@ describe('', () => { const onPrepare = jest.fn(); await renderInTestApp( - undefined} - />, + + undefined} + /> + , ); const checkboxes = screen.getAllByRole('checkbox'); diff --git a/plugins/catalog-node/CHANGELOG.md b/plugins/catalog-node/CHANGELOG.md index 949a44b384..8948ad6f98 100644 --- a/plugins/catalog-node/CHANGELOG.md +++ b/plugins/catalog-node/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-catalog-node +## 1.12.0 + +### Minor Changes + +- f2a2a83: Added `LocationAnalyzer` type, moved from `@backstage/plugin-catalog-backend`. +- f2a2a83: Breaking change to `/alpha` API where the `catalogAnalysisExtensionPoint` has been reworked. The `addLocationAnalyzer` method has been renamed to `addScmLocationAnalyzer`, and a new `setLocationAnalyzer` method has been added which allows the full `LocationAnalyzer` implementation to be overridden. + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-permission-node@0.7.29 + ## 1.12.0-next.2 ### Minor Changes diff --git a/plugins/catalog-node/package.json b/plugins/catalog-node/package.json index 010389079d..da6a67f163 100644 --- a/plugins/catalog-node/package.json +++ b/plugins/catalog-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-node", - "version": "1.12.0-next.2", + "version": "1.12.0", "description": "The plugin-catalog-node module for @backstage/plugin-catalog-backend", "backstage": { "role": "node-library" diff --git a/plugins/catalog-react/CHANGELOG.md b/plugins/catalog-react/CHANGELOG.md index fe64a6101d..ab6f2290ba 100644 --- a/plugins/catalog-react/CHANGELOG.md +++ b/plugins/catalog-react/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-catalog-react +## 1.12.0 + +### Minor Changes + +- 8834daf: Updated the presentation API to return a promise, in addition to the snapshot and observable that were there before. This makes it much easier to consume the API in a non-React context. + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + ## 1.12.0-next.2 ### Minor Changes @@ -2945,8 +2961,7 @@ `CatalogPage` component in your `App.tsx` routing allows you to adjust the layout, header, and which filters are available. - See the documentation added on [Catalog - Customization](https://backstage.io/docs/features/software-catalog/catalog-customization) + See the documentation added on [Catalog Customization](https://backstage.io/docs/features/software-catalog/catalog-customization) for instructions. ### Patch Changes diff --git a/plugins/catalog-react/package.json b/plugins/catalog-react/package.json index 85b7ba95be..6f0094f0c7 100644 --- a/plugins/catalog-react/package.json +++ b/plugins/catalog-react/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-react", "description": "A frontend library that helps other Backstage plugins interact with the catalog", - "version": "1.12.0-next.2", + "version": "1.12.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-react/src/components/EntityTable/presets.test.tsx b/plugins/catalog-react/src/components/EntityTable/presets.test.tsx index 82075df5e9..afe4336300 100644 --- a/plugins/catalog-react/src/components/EntityTable/presets.test.tsx +++ b/plugins/catalog-react/src/components/EntityTable/presets.test.tsx @@ -72,7 +72,7 @@ describe('systemEntityColumns', () => { expect(screen.getByText('my-namespace/my-system')).toBeInTheDocument(); expect(screen.getByText('my-namespace/my-domain')).toBeInTheDocument(); expect(screen.getByText('test')).toBeInTheDocument(); - expect(screen.getByText(/Some/)).toBeInTheDocument(); + expect(screen.queryAllByText(/Some/)).not.toHaveLength(0); }); }); }); @@ -126,7 +126,7 @@ describe('componentEntityColumns', () => { expect(screen.getByText('test')).toBeInTheDocument(); expect(screen.getByText('production')).toBeInTheDocument(); expect(screen.getByText('service')).toBeInTheDocument(); - expect(screen.getByText(/Some/)).toBeInTheDocument(); + expect(screen.queryAllByText(/Some/)).not.toHaveLength(0); }); }); }); diff --git a/plugins/catalog-unprocessed-entities/CHANGELOG.md b/plugins/catalog-unprocessed-entities/CHANGELOG.md index 06d4344889..989a852b55 100644 --- a/plugins/catalog-unprocessed-entities/CHANGELOG.md +++ b/plugins/catalog-unprocessed-entities/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-catalog-unprocessed-entities +## 0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + ## 0.2.4-next.1 ### Patch Changes diff --git a/plugins/catalog-unprocessed-entities/package.json b/plugins/catalog-unprocessed-entities/package.json index eb35eae31e..059dc8802b 100644 --- a/plugins/catalog-unprocessed-entities/package.json +++ b/plugins/catalog-unprocessed-entities/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-unprocessed-entities", - "version": "0.2.4-next.1", + "version": "0.2.4", "backstage": { "role": "frontend-plugin" }, diff --git a/plugins/catalog/CHANGELOG.md b/plugins/catalog/CHANGELOG.md index d20331bbfe..b2d036e914 100644 --- a/plugins/catalog/CHANGELOG.md +++ b/plugins/catalog/CHANGELOG.md @@ -1,5 +1,28 @@ # @backstage/plugin-catalog +## 1.20.0 + +### Minor Changes + +- 8834daf: Updated the presentation API to return a promise, in addition to the snapshot and observable that were there before. This makes it much easier to consume the API in a non-React context. + +### Patch Changes + +- 131e5cb: Fix broken links in README. +- 5d99272: Update local development dependencies. +- 4118530: Avoiding pre-loading display total count undefined for table counts +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + - @backstage/plugin-search-react@1.7.11 + ## 1.20.0-next.2 ### Minor Changes @@ -3361,8 +3384,7 @@ `CatalogPage` component in your `App.tsx` routing allows you to adjust the layout, header, and which filters are available. - See the documentation added on [Catalog - Customization](https://backstage.io/docs/features/software-catalog/catalog-customization) + See the documentation added on [Catalog Customization](https://backstage.io/docs/features/software-catalog/catalog-customization) for instructions. ### Patch Changes diff --git a/plugins/catalog/README.md b/plugins/catalog/README.md index 1ce7b2bf69..9375c14a4a 100644 --- a/plugins/catalog/README.md +++ b/plugins/catalog/README.md @@ -1,7 +1,6 @@ # Backstage Catalog Frontend -This is the React frontend for the default Backstage [software -catalog](http://backstage.io/docs/features/software-catalog/). +This is the React frontend for the default Backstage [software catalog](http://backstage.io/docs/features/software-catalog/). This package supplies interfaces related to listing catalog entities or showing more information about them on entity pages. diff --git a/plugins/catalog/package.json b/plugins/catalog/package.json index b7178c912e..cfff1f3ef1 100644 --- a/plugins/catalog/package.json +++ b/plugins/catalog/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog", - "version": "1.20.0-next.2", + "version": "1.20.0", "description": "The Backstage plugin for browsing the Backstage catalog", "backstage": { "role": "frontend-plugin" diff --git a/plugins/config-schema/CHANGELOG.md b/plugins/config-schema/CHANGELOG.md index 792691f33d..4d6609477c 100644 --- a/plugins/config-schema/CHANGELOG.md +++ b/plugins/config-schema/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-config-schema +## 0.1.55 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + ## 0.1.55-next.1 ### Patch Changes diff --git a/plugins/config-schema/package.json b/plugins/config-schema/package.json index 19f2401602..bbf1e786a1 100644 --- a/plugins/config-schema/package.json +++ b/plugins/config-schema/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-config-schema", - "version": "0.1.55-next.1", + "version": "0.1.55", "description": "A Backstage plugin that lets you browse the configuration schema of your app", "backstage": { "role": "frontend-plugin" diff --git a/plugins/devtools-backend/CHANGELOG.md b/plugins/devtools-backend/CHANGELOG.md index 38e0da331f..902a43c880 100644 --- a/plugins/devtools-backend/CHANGELOG.md +++ b/plugins/devtools-backend/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-devtools-backend +## 0.3.4 + +### Patch Changes + +- 036feca: Added discovery property to the readme documentation to ensure that it will build when setting it up as new to a Backstage instance +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-permission-node@0.7.29 + ## 0.3.4-next.2 ### Patch Changes diff --git a/plugins/devtools-backend/package.json b/plugins/devtools-backend/package.json index fd2c8eac4a..11441eb302 100644 --- a/plugins/devtools-backend/package.json +++ b/plugins/devtools-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-devtools-backend", - "version": "0.3.4-next.2", + "version": "0.3.4", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -41,7 +41,7 @@ "@manypkg/get-packages": "^1.1.3", "@types/express": "*", "@yarnpkg/lockfile": "^1.1.0", - "@yarnpkg/parsers": "^3.0.0-rc.4", + "@yarnpkg/parsers": "^3.0.0", "express": "^4.18.1", "express-promise-router": "^4.1.0", "fs-extra": "^11.0.0", diff --git a/plugins/devtools/CHANGELOG.md b/plugins/devtools/CHANGELOG.md index b618417ce0..ee7fd659bb 100644 --- a/plugins/devtools/CHANGELOG.md +++ b/plugins/devtools/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-devtools +## 0.1.14 + +### Patch Changes + +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/frontend-plugin-api@0.6.5 + ## 0.1.14-next.1 ### Patch Changes diff --git a/plugins/devtools/package.json b/plugins/devtools/package.json index 64b3626546..c711d941c6 100644 --- a/plugins/devtools/package.json +++ b/plugins/devtools/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-devtools", - "version": "0.1.14-next.1", + "version": "0.1.14", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-backend-module-aws-sqs/CHANGELOG.md b/plugins/events-backend-module-aws-sqs/CHANGELOG.md index 498f89b6fa..1398d95e4a 100644 --- a/plugins/events-backend-module-aws-sqs/CHANGELOG.md +++ b/plugins/events-backend-module-aws-sqs/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-events-backend-module-aws-sqs +## 0.3.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-events-node@0.3.4 + ## 0.3.4-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-aws-sqs/package.json b/plugins/events-backend-module-aws-sqs/package.json index ab33e2c451..0e889a2f8e 100644 --- a/plugins/events-backend-module-aws-sqs/package.json +++ b/plugins/events-backend-module-aws-sqs/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend-module-aws-sqs", - "version": "0.3.4-next.1", + "version": "0.3.4", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/events-backend-module-azure/CHANGELOG.md b/plugins/events-backend-module-azure/CHANGELOG.md index 1fbb360beb..d9c8e91140 100644 --- a/plugins/events-backend-module-azure/CHANGELOG.md +++ b/plugins/events-backend-module-azure/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-events-backend-module-azure +## 0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + ## 0.2.4-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-azure/package.json b/plugins/events-backend-module-azure/package.json index f7ade8b3a2..9264fe2374 100644 --- a/plugins/events-backend-module-azure/package.json +++ b/plugins/events-backend-module-azure/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend-module-azure", - "version": "0.2.4-next.1", + "version": "0.2.4", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/events-backend-module-bitbucket-cloud/CHANGELOG.md b/plugins/events-backend-module-bitbucket-cloud/CHANGELOG.md index b649c38b5b..b2734012c0 100644 --- a/plugins/events-backend-module-bitbucket-cloud/CHANGELOG.md +++ b/plugins/events-backend-module-bitbucket-cloud/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-events-backend-module-bitbucket-cloud +## 0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + ## 0.2.4-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-bitbucket-cloud/package.json b/plugins/events-backend-module-bitbucket-cloud/package.json index baed6171fd..5dc4d0147a 100644 --- a/plugins/events-backend-module-bitbucket-cloud/package.json +++ b/plugins/events-backend-module-bitbucket-cloud/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend-module-bitbucket-cloud", - "version": "0.2.4-next.1", + "version": "0.2.4", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/events-backend-module-gerrit/CHANGELOG.md b/plugins/events-backend-module-gerrit/CHANGELOG.md index 57c6390296..5a1134e692 100644 --- a/plugins/events-backend-module-gerrit/CHANGELOG.md +++ b/plugins/events-backend-module-gerrit/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-events-backend-module-gerrit +## 0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + ## 0.2.4-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-gerrit/package.json b/plugins/events-backend-module-gerrit/package.json index b3f8161604..61d0fafd53 100644 --- a/plugins/events-backend-module-gerrit/package.json +++ b/plugins/events-backend-module-gerrit/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend-module-gerrit", - "version": "0.2.4-next.1", + "version": "0.2.4", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/events-backend-module-github/CHANGELOG.md b/plugins/events-backend-module-github/CHANGELOG.md index ae5ee59263..88b0b1634d 100644 --- a/plugins/events-backend-module-github/CHANGELOG.md +++ b/plugins/events-backend-module-github/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-events-backend-module-github +## 0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + ## 0.2.4-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-github/package.json b/plugins/events-backend-module-github/package.json index 9fb876f714..d234a7e01b 100644 --- a/plugins/events-backend-module-github/package.json +++ b/plugins/events-backend-module-github/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend-module-github", - "version": "0.2.4-next.1", + "version": "0.2.4", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/events-backend-module-gitlab/CHANGELOG.md b/plugins/events-backend-module-gitlab/CHANGELOG.md index 73c4c7e281..b6bb80f18f 100644 --- a/plugins/events-backend-module-gitlab/CHANGELOG.md +++ b/plugins/events-backend-module-gitlab/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-events-backend-module-gitlab +## 0.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + ## 0.2.4-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-gitlab/package.json b/plugins/events-backend-module-gitlab/package.json index e10b26736f..f793455a5d 100644 --- a/plugins/events-backend-module-gitlab/package.json +++ b/plugins/events-backend-module-gitlab/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend-module-gitlab", - "version": "0.2.4-next.1", + "version": "0.2.4", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/events-backend-test-utils/CHANGELOG.md b/plugins/events-backend-test-utils/CHANGELOG.md index f5ba8b9609..eeb52a1d29 100644 --- a/plugins/events-backend-test-utils/CHANGELOG.md +++ b/plugins/events-backend-test-utils/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-events-backend-test-utils +## 0.1.28 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-events-node@0.3.4 + ## 0.1.28-next.1 ### Patch Changes diff --git a/plugins/events-backend-test-utils/package.json b/plugins/events-backend-test-utils/package.json index f766130efc..b96b7afe7f 100644 --- a/plugins/events-backend-test-utils/package.json +++ b/plugins/events-backend-test-utils/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend-test-utils", - "version": "0.1.28-next.1", + "version": "0.1.28", "description": "The plugin-events-backend-test-utils for @backstage/plugin-events-node", "backstage": { "role": "node-library" diff --git a/plugins/events-backend/CHANGELOG.md b/plugins/events-backend/CHANGELOG.md index 1bb33b6db1..0862263896 100644 --- a/plugins/events-backend/CHANGELOG.md +++ b/plugins/events-backend/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-events-backend +## 0.3.5 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + ## 0.3.5-next.1 ### Patch Changes diff --git a/plugins/events-backend/package.json b/plugins/events-backend/package.json index dc36a33d07..1cd3f909cc 100644 --- a/plugins/events-backend/package.json +++ b/plugins/events-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend", - "version": "0.3.5-next.1", + "version": "0.3.5", "backstage": { "role": "backend-plugin" }, diff --git a/plugins/events-node/CHANGELOG.md b/plugins/events-node/CHANGELOG.md index 7238c9ed49..5b907547d8 100644 --- a/plugins/events-node/CHANGELOG.md +++ b/plugins/events-node/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-events-node +## 0.3.4 + +### Patch Changes + +- 7e5a50d: added `eventsServiceFactory` to `defaultServiceFactories` to resolve issue where different instances of the EventsServices could be used +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + ## 0.3.4-next.2 ### Patch Changes diff --git a/plugins/events-node/package.json b/plugins/events-node/package.json index 9500fdc0ad..c082da2eab 100644 --- a/plugins/events-node/package.json +++ b/plugins/events-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-node", - "version": "0.3.4-next.2", + "version": "0.3.4", "description": "The plugin-events-node module for @backstage/plugin-events-backend", "backstage": { "role": "node-library" diff --git a/plugins/example-todo-list-backend/CHANGELOG.md b/plugins/example-todo-list-backend/CHANGELOG.md index 2d6dee39e2..d152236a11 100644 --- a/plugins/example-todo-list-backend/CHANGELOG.md +++ b/plugins/example-todo-list-backend/CHANGELOG.md @@ -1,5 +1,14 @@ # @internal/plugin-todo-list-backend +## 1.0.27 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 1.0.27-next.1 ### Patch Changes diff --git a/plugins/example-todo-list-backend/package.json b/plugins/example-todo-list-backend/package.json index cd45af6d37..15a9d16ee9 100644 --- a/plugins/example-todo-list-backend/package.json +++ b/plugins/example-todo-list-backend/package.json @@ -1,6 +1,6 @@ { "name": "@internal/plugin-todo-list-backend", - "version": "1.0.27-next.1", + "version": "1.0.27", "backstage": { "role": "backend-plugin" }, diff --git a/plugins/example-todo-list/CHANGELOG.md b/plugins/example-todo-list/CHANGELOG.md index 0962426ac3..a86ffe7c60 100644 --- a/plugins/example-todo-list/CHANGELOG.md +++ b/plugins/example-todo-list/CHANGELOG.md @@ -1,5 +1,12 @@ # @internal/plugin-todo-list +## 1.0.27 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + ## 1.0.27-next.1 ### Patch Changes diff --git a/plugins/example-todo-list/package.json b/plugins/example-todo-list/package.json index 849b96433a..4bd01f6e32 100644 --- a/plugins/example-todo-list/package.json +++ b/plugins/example-todo-list/package.json @@ -1,6 +1,6 @@ { "name": "@internal/plugin-todo-list", - "version": "1.0.27-next.1", + "version": "1.0.27", "backstage": { "role": "frontend-plugin" }, diff --git a/plugins/home-react/CHANGELOG.md b/plugins/home-react/CHANGELOG.md index b1f8f6793e..6013cad734 100644 --- a/plugins/home-react/CHANGELOG.md +++ b/plugins/home-react/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-home-react +## 0.1.13 + +### Patch Changes + +- 0040ec2: Updated dependency `@rjsf/utils` to `5.18.2`. + Updated dependency `@rjsf/core` to `5.18.2`. + Updated dependency `@rjsf/material-ui` to `5.18.2`. + Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. +- Updated dependencies + - @backstage/core-components@0.14.7 + ## 0.1.13-next.1 ### Patch Changes diff --git a/plugins/home-react/package.json b/plugins/home-react/package.json index bb04ce8211..3853ef0f85 100644 --- a/plugins/home-react/package.json +++ b/plugins/home-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-home-react", - "version": "0.1.13-next.1", + "version": "0.1.13", "description": "A Backstage plugin that contains react components helps you build a home page", "backstage": { "role": "web-library" diff --git a/plugins/home/CHANGELOG.md b/plugins/home/CHANGELOG.md index 6fb3fbaec9..9543096cd0 100644 --- a/plugins/home/CHANGELOG.md +++ b/plugins/home/CHANGELOG.md @@ -1,5 +1,25 @@ # @backstage/plugin-home +## 0.7.4 + +### Patch Changes + +- 2196d3e: Use relative time when displaying visits from the same day +- 0040ec2: Updated dependency `@rjsf/utils` to `5.18.2`. + Updated dependency `@rjsf/core` to `5.18.2`. + Updated dependency `@rjsf/material-ui` to `5.18.2`. + Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/plugin-home-react@0.1.13 + - @backstage/core-app-api@1.12.5 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + ## 0.7.4-next.2 ### Patch Changes diff --git a/plugins/home/package.json b/plugins/home/package.json index 63f01e84c4..79003a2ad7 100644 --- a/plugins/home/package.json +++ b/plugins/home/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-home", - "version": "0.7.4-next.2", + "version": "0.7.4", "description": "A Backstage plugin that helps you build a home page", "backstage": { "role": "frontend-plugin" diff --git a/plugins/kubernetes-backend/CHANGELOG.md b/plugins/kubernetes-backend/CHANGELOG.md index 48e205f868..bc447b62e0 100644 --- a/plugins/kubernetes-backend/CHANGELOG.md +++ b/plugins/kubernetes-backend/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-kubernetes-backend +## 0.17.1 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-kubernetes-common@0.7.6 + - @backstage/plugin-kubernetes-node@0.1.12 + - @backstage/plugin-permission-node@0.7.29 + ## 0.17.1-next.2 ### Patch Changes diff --git a/plugins/kubernetes-backend/package.json b/plugins/kubernetes-backend/package.json index 24a52bc8a8..7589a453a7 100644 --- a/plugins/kubernetes-backend/package.json +++ b/plugins/kubernetes-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-kubernetes-backend", "description": "A Backstage backend plugin that integrates towards Kubernetes", - "version": "0.17.1-next.2", + "version": "0.17.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/kubernetes-cluster/CHANGELOG.md b/plugins/kubernetes-cluster/CHANGELOG.md index 09adcabc63..aad774818d 100644 --- a/plugins/kubernetes-cluster/CHANGELOG.md +++ b/plugins/kubernetes-cluster/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-kubernetes-cluster +## 0.0.11 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/plugin-kubernetes-react@0.3.5 + - @backstage/plugin-kubernetes-common@0.7.6 + ## 0.0.11-next.2 ### Patch Changes diff --git a/plugins/kubernetes-cluster/package.json b/plugins/kubernetes-cluster/package.json index 409c385263..db9d08b5d7 100644 --- a/plugins/kubernetes-cluster/package.json +++ b/plugins/kubernetes-cluster/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-kubernetes-cluster", - "version": "0.0.11-next.2", + "version": "0.0.11", "description": "A Backstage plugin that shows details of Kubernetes clusters", "backstage": { "role": "frontend-plugin" diff --git a/plugins/kubernetes-common/CHANGELOG.md b/plugins/kubernetes-common/CHANGELOG.md index 55f3485ff4..778364af1b 100644 --- a/plugins/kubernetes-common/CHANGELOG.md +++ b/plugins/kubernetes-common/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-kubernetes-common +## 0.7.6 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + ## 0.7.6-next.0 ### Patch Changes diff --git a/plugins/kubernetes-common/package.json b/plugins/kubernetes-common/package.json index 77201e4fbf..f3bba8b855 100644 --- a/plugins/kubernetes-common/package.json +++ b/plugins/kubernetes-common/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-kubernetes-common", - "version": "0.7.6-next.0", + "version": "0.7.6", "description": "Common functionalities for kubernetes, to be shared between kubernetes and kubernetes-backend plugin", "backstage": { "role": "common-library" diff --git a/plugins/kubernetes-node/CHANGELOG.md b/plugins/kubernetes-node/CHANGELOG.md index 89c7a58526..730d43b95c 100644 --- a/plugins/kubernetes-node/CHANGELOG.md +++ b/plugins/kubernetes-node/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-kubernetes-node +## 0.1.12 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-kubernetes-common@0.7.6 + ## 0.1.12-next.1 ### Patch Changes diff --git a/plugins/kubernetes-node/package.json b/plugins/kubernetes-node/package.json index 79e304671a..dbe0a35d44 100644 --- a/plugins/kubernetes-node/package.json +++ b/plugins/kubernetes-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-kubernetes-node", - "version": "0.1.12-next.1", + "version": "0.1.12", "description": "Node.js library for the kubernetes plugin", "backstage": { "role": "node-library" diff --git a/plugins/kubernetes-react/CHANGELOG.md b/plugins/kubernetes-react/CHANGELOG.md index e05d103ad6..76abb6a50a 100644 --- a/plugins/kubernetes-react/CHANGELOG.md +++ b/plugins/kubernetes-react/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-kubernetes-react +## 0.3.5 + +### Patch Changes + +- 3102a99: add the namespace label to CronJobDrawer & IngressDrawer. +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-kubernetes-common@0.7.6 + ## 0.3.5-next.1 ### Patch Changes diff --git a/plugins/kubernetes-react/package.json b/plugins/kubernetes-react/package.json index 7ff42ab26c..0991845ebd 100644 --- a/plugins/kubernetes-react/package.json +++ b/plugins/kubernetes-react/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-kubernetes-react", "description": "Web library for the kubernetes-react plugin", - "version": "0.3.5-next.1", + "version": "0.3.5", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/kubernetes/CHANGELOG.md b/plugins/kubernetes/CHANGELOG.md index 87b1132710..abd18e5e21 100644 --- a/plugins/kubernetes/CHANGELOG.md +++ b/plugins/kubernetes/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-kubernetes +## 0.11.10 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/plugin-kubernetes-react@0.3.5 + - @backstage/plugin-kubernetes-common@0.7.6 + ## 0.11.10-next.2 ### Patch Changes diff --git a/plugins/kubernetes/package.json b/plugins/kubernetes/package.json index bfb8ed1e2c..fd02de4137 100644 --- a/plugins/kubernetes/package.json +++ b/plugins/kubernetes/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-kubernetes", "description": "A Backstage plugin that integrates towards Kubernetes", - "version": "0.11.10-next.2", + "version": "0.11.10", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/notifications-backend-module-email/CHANGELOG.md b/plugins/notifications-backend-module-email/CHANGELOG.md index 1c6e150a29..41bb1d2d9e 100644 --- a/plugins/notifications-backend-module-email/CHANGELOG.md +++ b/plugins/notifications-backend-module-email/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-notifications-backend-module-email +## 0.0.1 + +### Patch Changes + +- d541ff6: Fixed email processor `esm` issue and config reading +- e538b10: Support relative links in notifications sent via email +- dbf2696: Allow sending notifications by email with the new notifications module +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-notifications-node@0.1.4 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/catalog-client@1.6.5 + ## 0.0.1-next.1 ### Patch Changes diff --git a/plugins/notifications-backend-module-email/package.json b/plugins/notifications-backend-module-email/package.json index 1884dc6352..892c8c9156 100644 --- a/plugins/notifications-backend-module-email/package.json +++ b/plugins/notifications-backend-module-email/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-notifications-backend-module-email", - "version": "0.0.1-next.1", + "version": "0.0.1", "description": "The email backend module for the notifications plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/notifications-backend/CHANGELOG.md b/plugins/notifications-backend/CHANGELOG.md index 5d6792659d..26762f5b2a 100644 --- a/plugins/notifications-backend/CHANGELOG.md +++ b/plugins/notifications-backend/CHANGELOG.md @@ -1,5 +1,24 @@ # @backstage/plugin-notifications-backend +## 0.2.1 + +### Patch Changes + +- d541ff6: Fixed email processor `esm` issue and config reading +- 295c05d: Support for filtering entities from notification recipients after resolving them from the recipients +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- cba628a: Add possibility to generate random notifications on the fly in local development +- ee09dfc: Updated documentation for sending messages by external services. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/plugin-notifications-node@0.1.4 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-signals-node@0.1.4 + ## 0.2.1-next.2 ### Patch Changes diff --git a/plugins/notifications-backend/package.json b/plugins/notifications-backend/package.json index 3aada48a9c..6e6c0e04cb 100644 --- a/plugins/notifications-backend/package.json +++ b/plugins/notifications-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-notifications-backend", - "version": "0.2.1-next.2", + "version": "0.2.1", "backstage": { "role": "backend-plugin" }, diff --git a/plugins/notifications-backend/src/database/DatabaseNotificationsStore.ts b/plugins/notifications-backend/src/database/DatabaseNotificationsStore.ts index ae548a9892..f4bd25d1ba 100644 --- a/plugins/notifications-backend/src/database/DatabaseNotificationsStore.ts +++ b/plugins/notifications-backend/src/database/DatabaseNotificationsStore.ts @@ -13,10 +13,8 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -import { - PluginDatabaseManager, - resolvePackagePath, -} from '@backstage/backend-common'; +import { PluginDatabaseManager } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { NotificationGetOptions, NotificationModifyOptions, diff --git a/plugins/notifications-node/CHANGELOG.md b/plugins/notifications-node/CHANGELOG.md index 2b6321a3f8..86813090da 100644 --- a/plugins/notifications-node/CHANGELOG.md +++ b/plugins/notifications-node/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-notifications-node +## 0.1.4 + +### Patch Changes + +- 295c05d: Support for filtering entities from notification recipients after resolving them from the recipients +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-signals-node@0.1.4 + ## 0.1.4-next.1 ### Patch Changes diff --git a/plugins/notifications-node/package.json b/plugins/notifications-node/package.json index 1abfcc07ba..9f764c732b 100644 --- a/plugins/notifications-node/package.json +++ b/plugins/notifications-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-notifications-node", - "version": "0.1.4-next.1", + "version": "0.1.4", "description": "Node.js library for the notifications plugin", "backstage": { "role": "node-library" diff --git a/plugins/notifications/CHANGELOG.md b/plugins/notifications/CHANGELOG.md index 13cff2c7f7..278ac77062 100644 --- a/plugins/notifications/CHANGELOG.md +++ b/plugins/notifications/CHANGELOG.md @@ -1,5 +1,24 @@ # @backstage/plugin-notifications +## 0.2.1 + +### Patch Changes + +- e6bf85f: Allow overriding `NotificationsPage` page properties +- f730c0b: The user can newly mark all unread messages as read at one click. +- bfcb2f1: Allow showing notifications as snackbars in the UI +- e49a810: Show all notifications by default to match the sidebar item status +- 42eaf63: Increase default and allow modifying notification snackbar auto hide duration +- a42a19b: Empty descriptions are not rendered to improve the look&feel. +- 1bc3b86: Fix to show web notifications even when browser is on foreground. Fix duplicate notifications with multiple tabs. +- f793112: Allow defining `className` and additional properties for `NotificationsSideBarItem` +- e1c7d6e: Fix infinite loop in the notification title counter +- fcda449: The rendered size of a notification is limited for very long descriptions. +- f6633ca: Add option to set the notification as read automatically when the notification link is opened +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + ## 0.2.1-next.2 ### Patch Changes diff --git a/plugins/notifications/package.json b/plugins/notifications/package.json index 09127ecf04..8307103942 100644 --- a/plugins/notifications/package.json +++ b/plugins/notifications/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-notifications", - "version": "0.2.1-next.2", + "version": "0.2.1", "backstage": { "role": "frontend-plugin" }, diff --git a/plugins/notifications/src/components/NotificationsPage/NotificationsPage.tsx b/plugins/notifications/src/components/NotificationsPage/NotificationsPage.tsx index d1dde185f2..ef1fda0407 100644 --- a/plugins/notifications/src/components/NotificationsPage/NotificationsPage.tsx +++ b/plugins/notifications/src/components/NotificationsPage/NotificationsPage.tsx @@ -71,7 +71,7 @@ export const NotificationsPage = (props?: NotificationsPageProps) => { const [pageNumber, setPageNumber] = React.useState(0); const [pageSize, setPageSize] = React.useState(5); const [containsText, setContainsText] = React.useState(); - const [createdAfter, setCreatedAfter] = React.useState('lastWeek'); + const [createdAfter, setCreatedAfter] = React.useState('all'); const [sorting, setSorting] = React.useState( SortByOptions.newest.sortBy, ); diff --git a/plugins/notifications/src/components/NotificationsTable/NotificationsTable.tsx b/plugins/notifications/src/components/NotificationsTable/NotificationsTable.tsx index db2b351432..72a27975f6 100644 --- a/plugins/notifications/src/components/NotificationsTable/NotificationsTable.tsx +++ b/plugins/notifications/src/components/NotificationsTable/NotificationsTable.tsx @@ -43,7 +43,7 @@ const ThrottleDelayMs = 1000; const useStyles = makeStyles({ description: { maxHeight: '5rem', - overflow: 'scroll', + overflow: 'auto', }, severityItem: { alignContent: 'center', diff --git a/plugins/org-react/CHANGELOG.md b/plugins/org-react/CHANGELOG.md index 8767b0e303..853a4e76e3 100644 --- a/plugins/org-react/CHANGELOG.md +++ b/plugins/org-react/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-org-react +## 0.1.24 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/catalog-client@1.6.5 + ## 0.1.24-next.2 ### Patch Changes diff --git a/plugins/org-react/package.json b/plugins/org-react/package.json index 53f8f83fe2..dd9bc64f5a 100644 --- a/plugins/org-react/package.json +++ b/plugins/org-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-org-react", - "version": "0.1.24-next.2", + "version": "0.1.24", "backstage": { "role": "web-library" }, diff --git a/plugins/org/CHANGELOG.md b/plugins/org/CHANGELOG.md index a18e9a4e61..885f03cb3d 100644 --- a/plugins/org/CHANGELOG.md +++ b/plugins/org/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-org +## 0.6.25 + +### Patch Changes + +- 99e6105: Fix ownership card sometimes locking up for complex org structures +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.6.25-next.2 ### Patch Changes diff --git a/plugins/org/package.json b/plugins/org/package.json index 719eef72ce..5c9580ee0b 100644 --- a/plugins/org/package.json +++ b/plugins/org/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-org", - "version": "0.6.25-next.2", + "version": "0.6.25", "description": "A Backstage plugin that helps you create entity pages for your organization", "backstage": { "role": "frontend-plugin" diff --git a/plugins/org/src/components/Cards/Group/MembersList/MembersListCard.test.tsx b/plugins/org/src/components/Cards/Group/MembersList/MembersListCard.test.tsx index 06ec3b0ebd..793ffe274b 100644 --- a/plugins/org/src/components/Cards/Group/MembersList/MembersListCard.test.tsx +++ b/plugins/org/src/components/Cards/Group/MembersList/MembersListCard.test.tsx @@ -36,19 +36,6 @@ import { screen } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import { Observable } from '@backstage/types'; -// Mock needed because jsdom doesn't correctly implement box-sizing -// https://github.com/ShinyChang/React-Text-Truncate/issues/70 -// https://stackoverflow.com/questions/71916701/how-to-mock-a-react-function-component-that-takes-a-ref-prop -jest.mock('react-text-truncate', () => { - const { forwardRef } = jest.requireActual('react'); - return { - __esModule: true, - default: forwardRef((props: any, ref: any) => ( -
{props.text}
- )), - }; -}); - const mockedStarredEntitiesApi: Partial = { starredEntitie$: () => { return { diff --git a/plugins/org/src/components/Cards/OwnershipCard/OwnershipCard.test.tsx b/plugins/org/src/components/Cards/OwnershipCard/OwnershipCard.test.tsx index 72a912e16e..f2b949f768 100644 --- a/plugins/org/src/components/Cards/OwnershipCard/OwnershipCard.test.tsx +++ b/plugins/org/src/components/Cards/OwnershipCard/OwnershipCard.test.tsx @@ -120,19 +120,6 @@ const getEntitiesMock = ( } as GetEntitiesResponse); }; -// Mock needed because jsdom doesn't correctly implement box-sizing -// https://github.com/ShinyChang/React-Text-Truncate/issues/70 -// https://stackoverflow.com/questions/71916701/how-to-mock-a-react-function-component-that-takes-a-ref-prop -jest.mock('react-text-truncate', () => { - const { forwardRef } = jest.requireActual('react'); - return { - __esModule: true, - default: forwardRef((props: any, ref: any) => ( -
{props.text}
- )), - }; -}); - describe('OwnershipCard', () => { const groupEntity: GroupEntity = { apiVersion: 'backstage.io/v1alpha1', diff --git a/plugins/permission-backend-module-policy-allow-all/CHANGELOG.md b/plugins/permission-backend-module-policy-allow-all/CHANGELOG.md index 90874346ad..d2ae73f5f4 100644 --- a/plugins/permission-backend-module-policy-allow-all/CHANGELOG.md +++ b/plugins/permission-backend-module-policy-allow-all/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-permission-backend-module-allow-all-policy +## 0.1.15 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-permission-node@0.7.29 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/permission-backend-module-policy-allow-all/package.json b/plugins/permission-backend-module-policy-allow-all/package.json index ef5dfade7f..6e08904940 100644 --- a/plugins/permission-backend-module-policy-allow-all/package.json +++ b/plugins/permission-backend-module-policy-allow-all/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-permission-backend-module-allow-all-policy", - "version": "0.1.15-next.1", + "version": "0.1.15", "description": "Allow all policy backend module for the permission plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/permission-backend/CHANGELOG.md b/plugins/permission-backend/CHANGELOG.md index cc5b497a2c..6548fdfac1 100644 --- a/plugins/permission-backend/CHANGELOG.md +++ b/plugins/permission-backend/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-permission-backend +## 0.5.42 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-permission-node@0.7.29 + ## 0.5.42-next.1 ### Patch Changes diff --git a/plugins/permission-backend/package.json b/plugins/permission-backend/package.json index 3671e2b5a4..e039cd1898 100644 --- a/plugins/permission-backend/package.json +++ b/plugins/permission-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-permission-backend", - "version": "0.5.42-next.1", + "version": "0.5.42", "backstage": { "role": "backend-plugin" }, diff --git a/plugins/permission-node/CHANGELOG.md b/plugins/permission-node/CHANGELOG.md index fd84633615..8b145de147 100644 --- a/plugins/permission-node/CHANGELOG.md +++ b/plugins/permission-node/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-permission-node +## 0.7.29 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.7.29-next.1 ### Patch Changes diff --git a/plugins/permission-node/package.json b/plugins/permission-node/package.json index c510014089..bf6afc9e34 100644 --- a/plugins/permission-node/package.json +++ b/plugins/permission-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-permission-node", "description": "Common permission and authorization utilities for backend plugins", - "version": "0.7.29-next.1", + "version": "0.7.29", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/proxy-backend/CHANGELOG.md b/plugins/proxy-backend/CHANGELOG.md index b133154c85..80e2f2e241 100644 --- a/plugins/proxy-backend/CHANGELOG.md +++ b/plugins/proxy-backend/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-proxy-backend +## 0.4.16 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + ## 0.4.16-next.1 ### Patch Changes diff --git a/plugins/proxy-backend/package.json b/plugins/proxy-backend/package.json index 9430f7120d..0614956a18 100644 --- a/plugins/proxy-backend/package.json +++ b/plugins/proxy-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-proxy-backend", - "version": "0.4.16-next.1", + "version": "0.4.16", "description": "A Backstage backend plugin that helps you set up proxy endpoints in the backend", "backstage": { "role": "backend-plugin" diff --git a/plugins/scaffolder-backend-module-azure/CHANGELOG.md b/plugins/scaffolder-backend-module-azure/CHANGELOG.md index cdbe8cd77e..c2418d6309 100644 --- a/plugins/scaffolder-backend-module-azure/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-azure/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-scaffolder-backend-module-azure +## 0.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.1.10-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-azure/package.json b/plugins/scaffolder-backend-module-azure/package.json index d9d648ec6d..bc6b4a45d0 100644 --- a/plugins/scaffolder-backend-module-azure/package.json +++ b/plugins/scaffolder-backend-module-azure/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-azure", - "version": "0.1.10-next.2", + "version": "0.1.10", "description": "The azure module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-bitbucket-cloud/CHANGELOG.md b/plugins/scaffolder-backend-module-bitbucket-cloud/CHANGELOG.md index 93fc9f821f..9a1340c1ad 100644 --- a/plugins/scaffolder-backend-module-bitbucket-cloud/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-bitbucket-cloud/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-scaffolder-backend-module-bitbucket-cloud +## 0.1.8 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.1.8-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-bitbucket-cloud/package.json b/plugins/scaffolder-backend-module-bitbucket-cloud/package.json index d58a871f99..abde43fb2f 100644 --- a/plugins/scaffolder-backend-module-bitbucket-cloud/package.json +++ b/plugins/scaffolder-backend-module-bitbucket-cloud/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-bitbucket-cloud", - "version": "0.1.8-next.2", + "version": "0.1.8", "description": "The Bitbucket Cloud module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-bitbucket-server/CHANGELOG.md b/plugins/scaffolder-backend-module-bitbucket-server/CHANGELOG.md index 9b083cfaf4..fc245e48ba 100644 --- a/plugins/scaffolder-backend-module-bitbucket-server/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-bitbucket-server/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-scaffolder-backend-module-bitbucket-server +## 0.1.8 + +### Patch Changes + +- 24dd655: Add examples for `publish:bitbucketServer:pull-request` scaffolder action & improve related tests +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.1.8-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-bitbucket-server/package.json b/plugins/scaffolder-backend-module-bitbucket-server/package.json index b75099e81d..2a9fcc3f9d 100644 --- a/plugins/scaffolder-backend-module-bitbucket-server/package.json +++ b/plugins/scaffolder-backend-module-bitbucket-server/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-bitbucket-server", - "version": "0.1.8-next.2", + "version": "0.1.8", "description": "The Bitbucket Server module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-bitbucket/CHANGELOG.md b/plugins/scaffolder-backend-module-bitbucket/CHANGELOG.md index 5067f00aa8..97a57ff28f 100644 --- a/plugins/scaffolder-backend-module-bitbucket/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-bitbucket/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-scaffolder-backend-module-bitbucket +## 0.2.8 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/plugin-scaffolder-backend-module-bitbucket-server@0.1.8 + - @backstage/integration@1.11.0 + - @backstage/plugin-scaffolder-backend-module-bitbucket-cloud@0.1.8 + ## 0.2.8-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-bitbucket/package.json b/plugins/scaffolder-backend-module-bitbucket/package.json index ce82b551b4..355ca41844 100644 --- a/plugins/scaffolder-backend-module-bitbucket/package.json +++ b/plugins/scaffolder-backend-module-bitbucket/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-bitbucket", - "version": "0.2.8-next.2", + "version": "0.2.8", "description": "The bitbucket module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-confluence-to-markdown/CHANGELOG.md b/plugins/scaffolder-backend-module-confluence-to-markdown/CHANGELOG.md index 23a7973822..77152b9659 100644 --- a/plugins/scaffolder-backend-module-confluence-to-markdown/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-confluence-to-markdown/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-scaffolder-backend-module-confluence-to-markdown +## 0.2.19 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.2.19-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-confluence-to-markdown/package.json b/plugins/scaffolder-backend-module-confluence-to-markdown/package.json index f33e71b536..7cca3be249 100644 --- a/plugins/scaffolder-backend-module-confluence-to-markdown/package.json +++ b/plugins/scaffolder-backend-module-confluence-to-markdown/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-confluence-to-markdown", - "version": "0.2.19-next.2", + "version": "0.2.19", "description": "The confluence-to-markdown module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-cookiecutter/CHANGELOG.md b/plugins/scaffolder-backend-module-cookiecutter/CHANGELOG.md index 7220f00aa1..a6c6b24a07 100644 --- a/plugins/scaffolder-backend-module-cookiecutter/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-cookiecutter/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-scaffolder-backend-module-cookiecutter +## 0.2.42 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.2.42-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-cookiecutter/package.json b/plugins/scaffolder-backend-module-cookiecutter/package.json index 78b9a2a8ce..b0f137ffab 100644 --- a/plugins/scaffolder-backend-module-cookiecutter/package.json +++ b/plugins/scaffolder-backend-module-cookiecutter/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-cookiecutter", - "version": "0.2.42-next.2", + "version": "0.2.42", "description": "A module for the scaffolder backend that lets you template projects using cookiecutter", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-cookiecutter/src/actions/fetch/cookiecutter.ts b/plugins/scaffolder-backend-module-cookiecutter/src/actions/fetch/cookiecutter.ts index 1a49ab0855..d170acb5d0 100644 --- a/plugins/scaffolder-backend-module-cookiecutter/src/actions/fetch/cookiecutter.ts +++ b/plugins/scaffolder-backend-module-cookiecutter/src/actions/fetch/cookiecutter.ts @@ -14,11 +14,8 @@ * limitations under the License. */ -import { - ContainerRunner, - UrlReader, - resolveSafeChildPath, -} from '@backstage/backend-common'; +import { ContainerRunner, UrlReader } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { JsonObject, JsonValue } from '@backstage/types'; import { InputError } from '@backstage/errors'; import { ScmIntegrations } from '@backstage/integration'; diff --git a/plugins/scaffolder-backend-module-gerrit/CHANGELOG.md b/plugins/scaffolder-backend-module-gerrit/CHANGELOG.md index fd11a0f755..3daf8fc28a 100644 --- a/plugins/scaffolder-backend-module-gerrit/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-gerrit/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-scaffolder-backend-module-gerrit +## 0.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.1.10-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-gerrit/package.json b/plugins/scaffolder-backend-module-gerrit/package.json index 7215239608..1d9e003cfd 100644 --- a/plugins/scaffolder-backend-module-gerrit/package.json +++ b/plugins/scaffolder-backend-module-gerrit/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-gerrit", - "version": "0.1.10-next.2", + "version": "0.1.10", "description": "The gerrit module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-gitea/CHANGELOG.md b/plugins/scaffolder-backend-module-gitea/CHANGELOG.md index c88d71f652..6ec5592bc5 100644 --- a/plugins/scaffolder-backend-module-gitea/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-gitea/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-scaffolder-backend-module-gitea +## 0.1.8 + +### Patch Changes + +- 554af73: Allow defining `repoVisibility` field for the action `publish:gitea` +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.1.8-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-gitea/package.json b/plugins/scaffolder-backend-module-gitea/package.json index c49954b6b9..1d8ad190bc 100644 --- a/plugins/scaffolder-backend-module-gitea/package.json +++ b/plugins/scaffolder-backend-module-gitea/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-gitea", - "version": "0.1.8-next.2", + "version": "0.1.8", "description": "The gitea module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-github/CHANGELOG.md b/plugins/scaffolder-backend-module-github/CHANGELOG.md index 39454530eb..40c8349399 100644 --- a/plugins/scaffolder-backend-module-github/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-github/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-scaffolder-backend-module-github +## 0.2.8 + +### Patch Changes + +- 5d99272: Update local development dependencies. +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- 52ab241: Adding support to change the default commit author for `publish:github:pull-request` +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.2.8-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-github/api-report.md b/plugins/scaffolder-backend-module-github/api-report.md index 0284c362eb..b1a1c80af5 100644 --- a/plugins/scaffolder-backend-module-github/api-report.md +++ b/plugins/scaffolder-backend-module-github/api-report.md @@ -128,6 +128,7 @@ export interface CreateGithubPullRequestActionOptions { } | null>; } >; + config?: Config; githubCredentialsProvider?: GithubCredentialsProvider; integrations: ScmIntegrationRegistry; } @@ -389,6 +390,8 @@ export const createPublishGithubPullRequestAction: ( commitMessage?: string | undefined; update?: boolean | undefined; forceFork?: boolean | undefined; + gitAuthorName?: string | undefined; + gitAuthorEmail?: string | undefined; }, JsonObject >; diff --git a/plugins/scaffolder-backend-module-github/package.json b/plugins/scaffolder-backend-module-github/package.json index a593541e08..56dbd291a3 100644 --- a/plugins/scaffolder-backend-module-github/package.json +++ b/plugins/scaffolder-backend-module-github/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-github", - "version": "0.2.8-next.2", + "version": "0.2.8", "description": "The github module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.examples.test.ts b/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.examples.test.ts index dd07c88a70..26469dfcb4 100644 --- a/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.examples.test.ts +++ b/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.examples.test.ts @@ -103,6 +103,7 @@ describe('publish:github:pull-request examples', () => { integrations, githubCredentialsProvider, clientFactory, + config, }); }); @@ -484,6 +485,138 @@ describe('publish:github:pull-request examples', () => { expect(mockContext.output).toHaveBeenCalledWith('pullRequestNumber', 123); }); + it('Create a pull request with a git author name and email', async () => { + const input = yaml.parse(examples[9].example).steps[0].input; + + await action.handler({ + ...mockContext, + workspacePath, + input, + }); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'owner', + repo: 'repo', + title: 'Create my new app', + body: 'This PR is really good', + head: 'new-app', + draft: undefined, + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'foo@bar.example', + name: 'Foo Bar', + }, + }, + ], + }); + + expect(fakeClient.rest.pulls.requestReviewers).not.toHaveBeenCalled(); + expect(mockContext.output).toHaveBeenCalledTimes(3); + expect(mockContext.output).toHaveBeenCalledWith('targetBranchName', 'main'); + expect(mockContext.output).toHaveBeenCalledWith( + 'remoteUrl', + 'https://github.com/myorg/myrepo/pull/123', + ); + expect(mockContext.output).toHaveBeenCalledWith('pullRequestNumber', 123); + }); + + it('Create a pull request with a git author name', async () => { + const input = yaml.parse(examples[10].example).steps[0].input; + + await action.handler({ + ...mockContext, + workspacePath, + input, + }); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'owner', + repo: 'repo', + title: 'Create my new app', + body: 'This PR is really good', + head: 'new-app', + draft: undefined, + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'scaffolder@backstage.io', + name: 'Foo Bar', + }, + }, + ], + }); + + expect(fakeClient.rest.pulls.requestReviewers).not.toHaveBeenCalled(); + expect(mockContext.output).toHaveBeenCalledTimes(3); + expect(mockContext.output).toHaveBeenCalledWith('targetBranchName', 'main'); + expect(mockContext.output).toHaveBeenCalledWith( + 'remoteUrl', + 'https://github.com/myorg/myrepo/pull/123', + ); + expect(mockContext.output).toHaveBeenCalledWith('pullRequestNumber', 123); + }); + + it('Create a pull request with a git author email', async () => { + const input = yaml.parse(examples[11].example).steps[0].input; + + await action.handler({ + ...mockContext, + workspacePath, + input, + }); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'owner', + repo: 'repo', + title: 'Create my new app', + body: 'This PR is really good', + head: 'new-app', + draft: undefined, + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'foo@bar.example', + name: 'Scaffolder', + }, + }, + ], + }); + + expect(fakeClient.rest.pulls.requestReviewers).not.toHaveBeenCalled(); + expect(mockContext.output).toHaveBeenCalledTimes(3); + expect(mockContext.output).toHaveBeenCalledWith('targetBranchName', 'main'); + expect(mockContext.output).toHaveBeenCalledWith( + 'remoteUrl', + 'https://github.com/myorg/myrepo/pull/123', + ); + expect(mockContext.output).toHaveBeenCalledWith('pullRequestNumber', 123); + }); + it('Create a pull request with all parameters', async () => { mockDir.setContent({ [workspacePath]: { @@ -491,7 +624,7 @@ describe('publish:github:pull-request examples', () => { irrelevant: { 'bar.txt': 'Nothing to see here' }, }, }); - const input = yaml.parse(examples[9].example).steps[0].input; + const input = yaml.parse(examples[12].example).steps[0].input; await action.handler({ ...mockContext, @@ -517,6 +650,10 @@ describe('publish:github:pull-request examples', () => { mode: '100644', }, }, + author: { + email: 'foo@bar.example', + name: 'Foo Bar', + }, }, ], }); diff --git a/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.examples.ts b/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.examples.ts index d6138b262b..b6d31e732b 100644 --- a/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.examples.ts +++ b/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.examples.ts @@ -178,6 +178,65 @@ export const examples: TemplateExample[] = [ ], }), }, + { + description: 'Create a pull request with a git author name and email', + example: yaml.stringify({ + steps: [ + { + action: 'publish:github:pull-request', + name: 'Create a pull reuqest', + input: { + repoUrl: 'github.com?repo=repo&owner=owner', + branchName: 'new-app', + title: 'Create my new app', + description: 'This PR is really good', + gitAuthorName: 'Foo Bar', + gitAuthorEmail: 'foo@bar.example', + }, + }, + ], + }), + }, + { + description: 'Create a pull request with a git author name', + example: yaml.stringify({ + steps: [ + { + action: 'publish:github:pull-request', + name: 'Create a pull reuqest', + input: { + repoUrl: 'github.com?repo=repo&owner=owner', + branchName: 'new-app', + title: 'Create my new app', + description: 'This PR is really good', + // gitAuthorEmail will be 'scaffolder@backstage.io' + // once one author attribute has been set we need to set both + gitAuthorName: 'Foo Bar', + }, + }, + ], + }), + }, + { + description: 'Create a pull request with a git author email', + example: yaml.stringify({ + steps: [ + { + action: 'publish:github:pull-request', + name: 'Create a pull reuqest', + input: { + repoUrl: 'github.com?repo=repo&owner=owner', + branchName: 'new-app', + title: 'Create my new app', + description: 'This PR is really good', + // gitAuthorName will be 'Scaffolder' + // once one author attribute has been set we need to set both + gitAuthorEmail: 'foo@bar.example', + }, + }, + ], + }), + }, { description: 'Create a pull request with all parameters', example: yaml.stringify({ @@ -198,6 +257,8 @@ export const examples: TemplateExample[] = [ reviewers: ['foobar'], teamReviewers: ['team-foo'], commitMessage: 'Commit for foo changes', + gitAuthorName: 'Foo Bar', + gitAuthorEmail: 'foo@bar.example', }, }, ], diff --git a/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.test.ts b/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.test.ts index c9d1498187..20508494b8 100644 --- a/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.test.ts +++ b/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.test.ts @@ -15,7 +15,7 @@ */ import { createRootLogger } from '@backstage/backend-common'; -import { ConfigReader } from '@backstage/config'; +import { Config, ConfigReader } from '@backstage/config'; import { GithubCredentialsProvider, ScmIntegrations, @@ -46,6 +46,8 @@ describe('createPublishGithubPullRequestAction', () => { pulls: { requestReviewers: jest.Mock }; }; }; + let config: Config; + let integrations: ScmIntegrations; const mockDir = createMockDirectory(); const workspacePath = mockDir.resolve('workspace'); @@ -53,7 +55,8 @@ describe('createPublishGithubPullRequestAction', () => { beforeEach(() => { mockDir.clear(); - const integrations = ScmIntegrations.fromConfig(new ConfigReader({})); + config = new ConfigReader({}); + integrations = ScmIntegrations.fromConfig(config); fakeClient = { createPullRequest: jest.fn(async (_: any) => { return { @@ -84,6 +87,7 @@ describe('createPublishGithubPullRequestAction', () => { integrations, githubCredentialsProvider, clientFactory, + config, }); }); @@ -663,4 +667,352 @@ describe('createPublishGithubPullRequestAction', () => { }); }); }); + + describe('with author name and email', () => { + let input: GithubPullRequestActionInput; + let ctx: ActionContext; + + beforeEach(() => { + input = { + repoUrl: 'github.com?owner=myorg&repo=myrepo', + title: 'Create my new app', + branchName: 'new-app', + description: 'This PR is really good', + gitAuthorEmail: 'foo@bar.example', + gitAuthorName: 'Foo Bar', + }; + + mockDir.setContent({ + [workspacePath]: { 'file.txt': 'Hello there!' }, + }); + + ctx = createMockActionContext({ input, workspacePath }); + }); + + it('creates a pull request', async () => { + await instance.handler(ctx); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'myorg', + repo: 'myrepo', + title: 'Create my new app', + head: 'new-app', + body: 'This PR is really good', + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'foo@bar.example', + name: 'Foo Bar', + }, + }, + ], + }); + }); + }); + + describe('with author name', () => { + let input: GithubPullRequestActionInput; + let ctx: ActionContext; + + beforeEach(() => { + input = { + repoUrl: 'github.com?owner=myorg&repo=myrepo', + title: 'Create my new app', + branchName: 'new-app', + description: 'This PR is really good', + gitAuthorName: 'Foo Bar', + }; + + mockDir.setContent({ + [workspacePath]: { 'file.txt': 'Hello there!' }, + }); + + ctx = createMockActionContext({ input, workspacePath }); + }); + + it('creates a pull request', async () => { + await instance.handler(ctx); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'myorg', + repo: 'myrepo', + title: 'Create my new app', + head: 'new-app', + body: 'This PR is really good', + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'scaffolder@backstage.io', + name: 'Foo Bar', + }, + }, + ], + }); + }); + }); + + describe('with author email', () => { + let input: GithubPullRequestActionInput; + let ctx: ActionContext; + + beforeEach(() => { + input = { + repoUrl: 'github.com?owner=myorg&repo=myrepo', + title: 'Create my new app', + branchName: 'new-app', + description: 'This PR is really good', + gitAuthorEmail: 'foo@bar.example', + }; + + mockDir.setContent({ + [workspacePath]: { 'file.txt': 'Hello there!' }, + }); + + ctx = createMockActionContext({ input, workspacePath }); + }); + + it('creates a pull request', async () => { + await instance.handler(ctx); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'myorg', + repo: 'myrepo', + title: 'Create my new app', + head: 'new-app', + body: 'This PR is really good', + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'foo@bar.example', + name: 'Scaffolder', + }, + }, + ], + }); + }); + }); + + describe('with author from config file', () => { + let input: GithubPullRequestActionInput; + let ctx: ActionContext; + + beforeEach(() => { + input = { + repoUrl: 'github.com?owner=myorg&repo=myrepo', + title: 'Create my new app', + branchName: 'new-app', + description: 'This PR is really good', + }; + + mockDir.setContent({ + [workspacePath]: { 'file.txt': 'Hello there!' }, + }); + + ctx = createMockActionContext({ input, workspacePath }); + }); + + it('creates a pull request with default config attributes', async () => { + config = new ConfigReader({ + scaffolder: { + defaultAuthor: { + name: 'Config', + email: 'config@file.example', + }, + }, + }); + + const clientFactory = jest.fn(async () => fakeClient as any); + const githubCredentialsProvider: GithubCredentialsProvider = { + getCredentials: jest.fn(), + }; + + const instanceWithConfig = createPublishGithubPullRequestAction({ + integrations, + githubCredentialsProvider, + clientFactory, + config, + }); + + await instanceWithConfig.handler(ctx); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'myorg', + repo: 'myrepo', + title: 'Create my new app', + head: 'new-app', + body: 'This PR is really good', + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'config@file.example', + name: 'Config', + }, + }, + ], + }); + }); + }); + + describe('with author attributes and config file', () => { + let input: GithubPullRequestActionInput; + let ctx: ActionContext; + + beforeEach(() => { + input = { + repoUrl: 'github.com?owner=myorg&repo=myrepo', + title: 'Create my new app', + branchName: 'new-app', + description: 'This PR is really good', + gitAuthorEmail: 'foo@bar.example', + gitAuthorName: 'Foo Bar', + }; + + mockDir.setContent({ + [workspacePath]: { 'file.txt': 'Hello there!' }, + }); + + ctx = createMockActionContext({ input, workspacePath }); + }); + + it('creates a pull request with using author name and email from input', async () => { + config = new ConfigReader({ + scaffolder: { + defaultAuthor: { + name: 'Config', + email: 'config@file.example', + }, + }, + }); + + const clientFactory = jest.fn(async () => fakeClient as any); + const githubCredentialsProvider: GithubCredentialsProvider = { + getCredentials: jest.fn(), + }; + + const instanceWithConfig = createPublishGithubPullRequestAction({ + integrations, + githubCredentialsProvider, + clientFactory, + config, + }); + + await instanceWithConfig.handler(ctx); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'myorg', + repo: 'myrepo', + title: 'Create my new app', + head: 'new-app', + body: 'This PR is really good', + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'foo@bar.example', + name: 'Foo Bar', + }, + }, + ], + }); + }); + }); + + describe('with author fallback and no config', () => { + let input: GithubPullRequestActionInput; + let ctx: ActionContext; + + beforeEach(() => { + input = { + repoUrl: 'github.com?owner=myorg&repo=myrepo', + title: 'Create my new app', + branchName: 'new-app', + description: 'This PR is really good', + gitAuthorName: 'Foo Bar', + }; + + mockDir.setContent({ + [workspacePath]: { 'file.txt': 'Hello there!' }, + }); + + ctx = createMockActionContext({ input, workspacePath }); + }); + + it('creates a pull request with using author name and email fallback when have no config', async () => { + const clientFactory = jest.fn(async () => fakeClient as any); + const githubCredentialsProvider: GithubCredentialsProvider = { + getCredentials: jest.fn(), + }; + + const instanceWithConfig = createPublishGithubPullRequestAction({ + integrations, + githubCredentialsProvider, + clientFactory, + }); + + await instanceWithConfig.handler(ctx); + + expect(fakeClient.createPullRequest).toHaveBeenCalledWith({ + owner: 'myorg', + repo: 'myrepo', + title: 'Create my new app', + head: 'new-app', + body: 'This PR is really good', + changes: [ + { + commit: 'Create my new app', + files: { + 'file.txt': { + content: Buffer.from('Hello there!').toString('base64'), + encoding: 'base64', + mode: '100644', + }, + }, + author: { + email: 'scaffolder@backstage.io', + name: 'Foo Bar', + }, + }, + ], + }); + }); + }); }); diff --git a/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.ts b/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.ts index b4aa03b602..5efcc6e0bb 100644 --- a/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.ts +++ b/plugins/scaffolder-backend-module-github/src/actions/githubPullRequest.ts @@ -27,11 +27,14 @@ import { } from '@backstage/plugin-scaffolder-node'; import { Octokit } from 'octokit'; import { CustomErrorBase, InputError } from '@backstage/errors'; -import { resolveSafeChildPath } from '@backstage/backend-common'; import { createPullRequest } from 'octokit-plugin-create-pull-request'; import { getOctokitOptions } from './helpers'; import { examples } from './githubPullRequest.examples'; -import { LoggerService } from '@backstage/backend-plugin-api'; +import { + LoggerService, + resolveSafeChildPath, +} from '@backstage/backend-plugin-api'; +import { Config } from '@backstage/config'; export type Encoding = 'utf-8' | 'base64'; @@ -100,6 +103,10 @@ export interface CreateGithubPullRequestActionOptions { } | null>; } >; + /** + * An instance of {@link @backstage/config#Config} that will be used in the action. + */ + config?: Config; } type GithubPullRequest = { @@ -119,6 +126,7 @@ export const createPublishGithubPullRequestAction = ( integrations, githubCredentialsProvider, clientFactory = defaultClientFactory, + config, } = options; return createTemplateAction<{ @@ -136,6 +144,8 @@ export const createPublishGithubPullRequestAction = ( commitMessage?: string; update?: boolean; forceFork?: boolean; + gitAuthorName?: string; + gitAuthorEmail?: string; }>({ id: 'publish:github:pull-request', examples, @@ -223,6 +233,18 @@ export const createPublishGithubPullRequestAction = ( title: 'Force Fork', description: 'Create pull request from a fork', }, + gitAuthorName: { + type: 'string', + title: 'Default Author Name', + description: + "Sets the default author name for the commit. The default value is the authenticated user or 'Scaffolder'", + }, + gitAuthorEmail: { + type: 'string', + title: 'Default Author Email', + description: + "Sets the default author email for the commit. The default value is the authenticated user or 'scaffolder@backstage.io'", + }, }, }, output: { @@ -262,6 +284,8 @@ export const createPublishGithubPullRequestAction = ( commitMessage, update, forceFork, + gitAuthorEmail, + gitAuthorName, } = ctx.input; const { owner, repo, host } = parseRepoUrl(repoUrl, integrations); @@ -327,7 +351,10 @@ export const createPublishGithubPullRequestAction = ( changes: [ { files, - commit: commitMessage ?? title, + commit: + commitMessage ?? + config?.getOptionalString('scaffolder.defaultCommitMessage') ?? + title, }, ], body: description, @@ -336,6 +363,36 @@ export const createPublishGithubPullRequestAction = ( update, forceFork, }; + + const gitAuthorInfo = { + name: + gitAuthorName ?? + config?.getOptionalString('scaffolder.defaultAuthor.name'), + email: + gitAuthorEmail ?? + config?.getOptionalString('scaffolder.defaultAuthor.email'), + }; + + if (gitAuthorInfo.name || gitAuthorInfo.email) { + if (Array.isArray(createOptions.changes)) { + createOptions.changes = createOptions.changes.map(change => ({ + ...change, + author: { + name: gitAuthorInfo.name || 'Scaffolder', + email: gitAuthorInfo.email || 'scaffolder@backstage.io', + }, + })); + } else { + createOptions.changes = { + ...createOptions.changes, + author: { + name: gitAuthorInfo.name || 'Scaffolder', + email: gitAuthorInfo.email || 'scaffolder@backstage.io', + }, + }; + } + } + if (targetBranchName) { createOptions.base = targetBranchName; } diff --git a/plugins/scaffolder-backend-module-github/src/module.ts b/plugins/scaffolder-backend-module-github/src/module.ts index 79c954a6dd..1817a68bfb 100644 --- a/plugins/scaffolder-backend-module-github/src/module.ts +++ b/plugins/scaffolder-backend-module-github/src/module.ts @@ -89,6 +89,7 @@ export const githubModule = createBackendModule({ createPublishGithubPullRequestAction({ integrations, githubCredentialsProvider, + config, }), ); }, diff --git a/plugins/scaffolder-backend-module-gitlab/CHANGELOG.md b/plugins/scaffolder-backend-module-gitlab/CHANGELOG.md index 18efb70009..829e2122f3 100644 --- a/plugins/scaffolder-backend-module-gitlab/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-gitlab/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-scaffolder-backend-module-gitlab +## 0.4.0 + +### Minor Changes + +- 18f736f: Add examples for `gitlab:projectVariable:create` scaffolder action & improve related tests + +### Patch Changes + +- 8fa8a00: Add merge method and squash option for project creation +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- ffc73ec: Add examples for `gitlab:repo:push` scaffolder action & improve related tests +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.4.0-next.2 ### Minor Changes diff --git a/plugins/scaffolder-backend-module-gitlab/package.json b/plugins/scaffolder-backend-module-gitlab/package.json index d03fb65c1b..383ef0e79d 100644 --- a/plugins/scaffolder-backend-module-gitlab/package.json +++ b/plugins/scaffolder-backend-module-gitlab/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-gitlab", - "version": "0.4.0-next.2", + "version": "0.4.0", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/scaffolder-backend-module-gitlab/src/actions/gitlabMergeRequest.ts b/plugins/scaffolder-backend-module-gitlab/src/actions/gitlabMergeRequest.ts index c9b8ce68a9..a549585426 100644 --- a/plugins/scaffolder-backend-module-gitlab/src/actions/gitlabMergeRequest.ts +++ b/plugins/scaffolder-backend-module-gitlab/src/actions/gitlabMergeRequest.ts @@ -23,7 +23,7 @@ import { Types } from '@gitbeaker/core'; import path from 'path'; import { ScmIntegrationRegistry } from '@backstage/integration'; import { InputError } from '@backstage/errors'; -import { resolveSafeChildPath } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { createGitlabApi } from './helpers'; import { examples } from './gitlabMergeRequest.examples'; diff --git a/plugins/scaffolder-backend-module-gitlab/src/actions/gitlabRepoPush.ts b/plugins/scaffolder-backend-module-gitlab/src/actions/gitlabRepoPush.ts index aae3b05c49..c926fe2971 100644 --- a/plugins/scaffolder-backend-module-gitlab/src/actions/gitlabRepoPush.ts +++ b/plugins/scaffolder-backend-module-gitlab/src/actions/gitlabRepoPush.ts @@ -23,7 +23,7 @@ import { Types } from '@gitbeaker/core'; import path from 'path'; import { ScmIntegrationRegistry } from '@backstage/integration'; import { InputError } from '@backstage/errors'; -import { resolveSafeChildPath } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { createGitlabApi } from './helpers'; import { examples } from './gitlabRepoPush.examples'; diff --git a/plugins/scaffolder-backend-module-notifications/CHANGELOG.md b/plugins/scaffolder-backend-module-notifications/CHANGELOG.md index 9a1c1b8891..d5d3902191 100644 --- a/plugins/scaffolder-backend-module-notifications/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-notifications/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-scaffolder-backend-module-notifications +## 0.0.1 + +### Patch Changes + +- 503d769: Add a new scaffolder action to allow sending notifications from templates +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/plugin-notifications-node@0.1.4 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + ## 0.0.1-next.0 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-notifications/package.json b/plugins/scaffolder-backend-module-notifications/package.json index 7cb996f72b..07cb5e9bb1 100644 --- a/plugins/scaffolder-backend-module-notifications/package.json +++ b/plugins/scaffolder-backend-module-notifications/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-notifications", - "version": "0.0.1-next.0", + "version": "0.0.1", "description": "The notifications backend module for the scaffolder plugin.", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-rails/CHANGELOG.md b/plugins/scaffolder-backend-module-rails/CHANGELOG.md index f721032c0a..64c1c79d7c 100644 --- a/plugins/scaffolder-backend-module-rails/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-rails/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-scaffolder-backend-module-rails +## 0.4.35 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/integration@1.11.0 + ## 0.4.35-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-rails/package.json b/plugins/scaffolder-backend-module-rails/package.json index f8e1289359..0d822764dd 100644 --- a/plugins/scaffolder-backend-module-rails/package.json +++ b/plugins/scaffolder-backend-module-rails/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-rails", - "version": "0.4.35-next.2", + "version": "0.4.35", "description": "A module for the scaffolder backend that lets you template projects using Rails", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/scaffolder-backend-module-sentry/CHANGELOG.md b/plugins/scaffolder-backend-module-sentry/CHANGELOG.md index d3685153d5..fa5b12ae0e 100644 --- a/plugins/scaffolder-backend-module-sentry/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-sentry/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-scaffolder-backend-module-sentry +## 0.1.26 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + ## 0.1.26-next.1 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-sentry/package.json b/plugins/scaffolder-backend-module-sentry/package.json index bd7555a8c2..1f2e48ad59 100644 --- a/plugins/scaffolder-backend-module-sentry/package.json +++ b/plugins/scaffolder-backend-module-sentry/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-sentry", - "version": "0.1.26-next.1", + "version": "0.1.26", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/scaffolder-backend-module-yeoman/CHANGELOG.md b/plugins/scaffolder-backend-module-yeoman/CHANGELOG.md index 96b7222d0f..cb1a73f9f7 100644 --- a/plugins/scaffolder-backend-module-yeoman/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-yeoman/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-scaffolder-backend-module-yeoman +## 0.3.1 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/plugin-scaffolder-node-test-utils@0.1.4 + ## 0.3.1-next.1 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-yeoman/package.json b/plugins/scaffolder-backend-module-yeoman/package.json index c0f0c85f72..9a2fb1fdb1 100644 --- a/plugins/scaffolder-backend-module-yeoman/package.json +++ b/plugins/scaffolder-backend-module-yeoman/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend-module-yeoman", - "version": "0.3.1-next.1", + "version": "0.3.1", "backstage": { "role": "backend-plugin-module" }, diff --git a/plugins/scaffolder-backend/CHANGELOG.md b/plugins/scaffolder-backend/CHANGELOG.md index 265517070d..05be28c1ae 100644 --- a/plugins/scaffolder-backend/CHANGELOG.md +++ b/plugins/scaffolder-backend/CHANGELOG.md @@ -1,5 +1,36 @@ # @backstage/plugin-scaffolder-backend +## 1.22.6 + +### Patch Changes + +- 131e5cb: Fix broken links in README. +- 025641b: Fix issue with the log format not being respected when logging from actions +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- e4b50ab: Scaffolder workspace serialization +- 025641b: Redact `meta` fields too with the logger +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/plugin-scaffolder-backend-module-github@0.2.8 + - @backstage/plugin-scaffolder-backend-module-gitea@0.1.8 + - @backstage/plugin-scaffolder-backend-module-gitlab@0.4.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-scaffolder-node@0.4.4 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-scaffolder-backend-module-bitbucket-server@0.1.8 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.16 + - @backstage/plugin-permission-node@0.7.29 + - @backstage/plugin-scaffolder-backend-module-azure@0.1.10 + - @backstage/plugin-scaffolder-backend-module-bitbucket@0.2.8 + - @backstage/plugin-scaffolder-backend-module-bitbucket-cloud@0.1.8 + - @backstage/plugin-scaffolder-backend-module-gerrit@0.1.10 + ## 1.22.6-next.2 ### Patch Changes diff --git a/plugins/scaffolder-backend/README.md b/plugins/scaffolder-backend/README.md index 0aa57fd90c..d760b0fc2d 100644 --- a/plugins/scaffolder-backend/README.md +++ b/plugins/scaffolder-backend/README.md @@ -1,9 +1,7 @@ # Scaffolder Backend -This is the backend for the default Backstage [software -templates](https://backstage.io/docs/features/software-templates/). -This provides the API for the frontend [scaffolder -plugin](https://github.com/backstage/backstage/tree/master/plugins/scaffolder), +This is the backend for the default Backstage [software templates](https://backstage.io/docs/features/software-templates/). +This provides the API for the frontend [scaffolder plugin](https://github.com/backstage/backstage/tree/master/plugins/scaffolder), as well as the built-in template actions, tasks and stages. ## Installation @@ -24,12 +22,19 @@ restoring the plugin, if you previously removed it. yarn --cwd packages/backend add @backstage/plugin-scaffolder-backend ``` -### Adding the plugin to your `packages/backend` +Then add the plugin to your backend, typically in `packages/backend/src/index.ts`: -You'll need to add the plugin to the router in your `backend` package. You can -do this by creating a file called `packages/backend/src/plugins/scaffolder.ts` -with contents matching [scaffolder.ts in the create-app -template](https://github.com/backstage/backstage/blob/master/packages/create-app/templates/default-app/packages/backend/src/plugins/scaffolder.ts). +```ts +const backend = createBackend(); +// ... +backend.add(import('@backstage/plugin-scaffolder-backend/alpha')); +``` + +#### Old backend system + +In the old backend system there's a bit more wiring required. You'll need to +create a file called `packages/backend/src/plugins/scaffolder.ts` +with contents matching [scaffolder.ts in the create-app template](https://github.com/backstage/backstage/blob/ad9314d3a7e0405719ba93badf96e97adde8ef83/packages/create-app/templates/default-app/packages/backend/src/plugins/scaffolder.ts). With the `scaffolder.ts` router setup in place, add the router to `packages/backend/src/index.ts`: @@ -54,10 +59,7 @@ async function main() { ### Adding templates At this point the scaffolder backend is installed in your backend package, but -you will not have any templates available to use. These need to be [added to the -software -catalog](https://backstage.io/docs/features/software-templates/adding-templates). +you will not have any templates available to use. These need to be [added to the software catalog](https://backstage.io/docs/features/software-templates/adding-templates). To get up and running and try out some templates quickly, you can or copy the -catalog locations from the [create-app -template](https://github.com/backstage/backstage/blob/master/packages/create-app/templates/default-app/app-config.yaml.hbs). +catalog locations from the [create-app template](https://github.com/backstage/backstage/blob/master/packages/create-app/templates/default-app/app-config.yaml.hbs). diff --git a/plugins/scaffolder-backend/api-report.md b/plugins/scaffolder-backend/api-report.md index 895b55f6e1..c141733ec4 100644 --- a/plugins/scaffolder-backend/api-report.md +++ b/plugins/scaffolder-backend/api-report.md @@ -287,6 +287,8 @@ export const createPublishGithubPullRequestAction: ( commitMessage?: string | undefined; update?: boolean | undefined; forceFork?: boolean | undefined; + gitAuthorName?: string | undefined; + gitAuthorEmail?: string | undefined; }, JsonObject >; diff --git a/plugins/scaffolder-backend/package.json b/plugins/scaffolder-backend/package.json index cf3d3d1ca0..f748ccb92d 100644 --- a/plugins/scaffolder-backend/package.json +++ b/plugins/scaffolder-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-backend", - "version": "1.22.6-next.2", + "version": "1.22.6", "description": "The Backstage backend plugin that helps you create new things", "backstage": { "role": "backend-plugin" @@ -95,6 +95,7 @@ "p-queue": "^6.6.2", "prom-client": "^15.0.0", "tar": "^6.1.12", + "triple-beam": "^1.4.1", "uuid": "^9.0.0", "winston": "^3.2.1", "winston-transport": "^4.7.0", diff --git a/plugins/scaffolder-backend/src/lib/templating/SecureTemplater.ts b/plugins/scaffolder-backend/src/lib/templating/SecureTemplater.ts index 14a58e4975..6860902c78 100644 --- a/plugins/scaffolder-backend/src/lib/templating/SecureTemplater.ts +++ b/plugins/scaffolder-backend/src/lib/templating/SecureTemplater.ts @@ -15,7 +15,7 @@ */ import { Isolate } from 'isolated-vm'; -import { resolvePackagePath } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { TemplateFilter as _TemplateFilter, TemplateGlobal as _TemplateGlobal, diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/catalog/write.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/catalog/write.ts index 27c39dd098..9feaa14c07 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/catalog/write.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/catalog/write.ts @@ -17,7 +17,7 @@ import fs from 'fs-extra'; import { createTemplateAction } from '@backstage/plugin-scaffolder-node'; import * as yaml from 'yaml'; -import { resolveSafeChildPath } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { z } from 'zod'; import { examples } from './write.examples'; diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/createBuiltinActions.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/createBuiltinActions.ts index a017c2e224..673776bec9 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/createBuiltinActions.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/createBuiltinActions.ts @@ -178,6 +178,7 @@ export const createBuiltinActions = ( createPublishGithubPullRequestAction({ integrations, githubCredentialsProvider, + config, }), createPublishGitlabAction({ integrations, diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/plain.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/plain.ts index 8bca630af9..c6beaa2d67 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/plain.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/plain.ts @@ -14,7 +14,8 @@ * limitations under the License. */ -import { UrlReader, resolveSafeChildPath } from '@backstage/backend-common'; +import { UrlReader } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { ScmIntegrations } from '@backstage/integration'; import { examples } from './plain.examples'; diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/plainFile.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/plainFile.ts index da0255ff5a..92db7aa3ed 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/plainFile.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/plainFile.ts @@ -14,7 +14,8 @@ * limitations under the License. */ -import { UrlReader, resolveSafeChildPath } from '@backstage/backend-common'; +import { UrlReader } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { ScmIntegrations } from '@backstage/integration'; import { examples } from './plainFile.examples'; import { diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.examples.test.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.examples.test.ts index 36f1f00b50..02fe0c30a4 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.examples.test.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.examples.test.ts @@ -16,7 +16,8 @@ import { join as joinPath, sep as pathSep } from 'path'; import fs from 'fs-extra'; -import { resolvePackagePath, UrlReader } from '@backstage/backend-common'; +import { UrlReader } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { ScmIntegrations } from '@backstage/integration'; import { createMockActionContext } from '@backstage/plugin-scaffolder-node-test-utils'; import { createFetchTemplateAction } from './template'; diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.test.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.test.ts index fd0ef7d757..0542b6a50d 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.test.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.test.ts @@ -21,7 +21,8 @@ jest.mock('@backstage/plugin-scaffolder-node', () => { import { join as joinPath, sep as pathSep } from 'path'; import fs from 'fs-extra'; -import { resolvePackagePath, UrlReader } from '@backstage/backend-common'; +import { UrlReader } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { ScmIntegrations } from '@backstage/integration'; import { createFetchTemplateAction } from './template'; import { diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.ts index b39582e18b..0983199339 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/fetch/template.ts @@ -15,7 +15,8 @@ */ import { extname } from 'path'; -import { resolveSafeChildPath, UrlReader } from '@backstage/backend-common'; +import { UrlReader } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { InputError } from '@backstage/errors'; import { ScmIntegrations } from '@backstage/integration'; import { diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/filesystem/delete.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/filesystem/delete.ts index 5787d245ab..13dfc69525 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/filesystem/delete.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/filesystem/delete.ts @@ -16,7 +16,7 @@ import { createTemplateAction } from '@backstage/plugin-scaffolder-node'; import { InputError } from '@backstage/errors'; -import { resolveSafeChildPath } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import fs from 'fs-extra'; import { examples } from './delete.examples'; diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/filesystem/rename.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/filesystem/rename.ts index 5d9d666d15..238fc9e8c0 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/filesystem/rename.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/filesystem/rename.ts @@ -15,7 +15,7 @@ */ import { createTemplateAction } from '@backstage/plugin-scaffolder-node'; -import { resolveSafeChildPath } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { InputError } from '@backstage/errors'; import fs from 'fs-extra'; import { examples } from './rename.examples'; diff --git a/plugins/scaffolder-backend/src/scaffolder/dryrun/createDryRunner.ts b/plugins/scaffolder-backend/src/scaffolder/dryrun/createDryRunner.ts index 2eaa505c8c..6b8caf5a3d 100644 --- a/plugins/scaffolder-backend/src/scaffolder/dryrun/createDryRunner.ts +++ b/plugins/scaffolder-backend/src/scaffolder/dryrun/createDryRunner.ts @@ -33,9 +33,11 @@ import { TemplateActionRegistry } from '../actions'; import { NunjucksWorkflowRunner } from '../tasks/NunjucksWorkflowRunner'; import { DecoratedActionsRegistry } from './DecoratedActionsRegistry'; import fs from 'fs-extra'; -import { resolveSafeChildPath } from '@backstage/backend-common'; import { PermissionEvaluator } from '@backstage/plugin-permission-common'; -import { BackstageCredentials } from '@backstage/backend-plugin-api'; +import { + BackstageCredentials, + resolveSafeChildPath, +} from '@backstage/backend-plugin-api'; interface DryRunInput { spec: TaskSpec; diff --git a/plugins/scaffolder-backend/src/scaffolder/tasks/DatabaseTaskStore.ts b/plugins/scaffolder-backend/src/scaffolder/tasks/DatabaseTaskStore.ts index f6f00b0441..9c95c11017 100644 --- a/plugins/scaffolder-backend/src/scaffolder/tasks/DatabaseTaskStore.ts +++ b/plugins/scaffolder-backend/src/scaffolder/tasks/DatabaseTaskStore.ts @@ -15,10 +15,8 @@ */ import { JsonObject } from '@backstage/types'; -import { - PluginDatabaseManager, - resolvePackagePath, -} from '@backstage/backend-common'; +import { PluginDatabaseManager } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { ConflictError, NotFoundError } from '@backstage/errors'; import { Knex } from 'knex'; import { v4 as uuid } from 'uuid'; diff --git a/plugins/scaffolder-backend/src/scaffolder/tasks/logger.ts b/plugins/scaffolder-backend/src/scaffolder/tasks/logger.ts index 064eb69349..3824a32a6f 100644 --- a/plugins/scaffolder-backend/src/scaffolder/tasks/logger.ts +++ b/plugins/scaffolder-backend/src/scaffolder/tasks/logger.ts @@ -21,6 +21,7 @@ import { JsonObject } from '@backstage/types'; import { Format, TransformableInfo } from 'logform'; import Transport, { TransportStreamOptions } from 'winston-transport'; import { Logger, format, createLogger, transports } from 'winston'; +import { MESSAGE } from 'triple-beam'; /** * Escapes a given string to be used inside a RegExp. @@ -107,20 +108,16 @@ export class WinstonLogger implements RootLoggerService { let redactionPattern: RegExp | undefined = undefined; - const replace = (obj: TransformableInfo) => { - for (const key in obj) { - if (obj.hasOwnProperty(key)) { - if (typeof obj[key] === 'object') { - obj[key] = replace(obj[key] as TransformableInfo); - } else if (typeof obj[key] === 'string') { - obj[key] = obj[key]?.replace(redactionPattern, '[REDACTED]'); - } - } - } - return obj; - }; return { - format: format(replace)(), + format: format((obj: TransformableInfo) => { + if (!redactionPattern || !obj) { + return obj; + } + + obj[MESSAGE] = obj[MESSAGE]?.replace?.(redactionPattern, '[REDACTED]'); + + return obj; + })(), add(newRedactions) { let added = 0; for (const redactionToTrim of newRedactions) { diff --git a/plugins/scaffolder-common/CHANGELOG.md b/plugins/scaffolder-common/CHANGELOG.md index 4a9e1b870b..8b5c2d7c99 100644 --- a/plugins/scaffolder-common/CHANGELOG.md +++ b/plugins/scaffolder-common/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-scaffolder-common +## 1.5.2 + +### Patch Changes + +- 9156654: Capturing more event clicks for scaffolder +- Updated dependencies + - @backstage/catalog-model@1.5.0 + ## 1.5.2-next.1 ### Patch Changes @@ -641,8 +649,7 @@ - e72d371296: Added `TemplateEntityV1beta2` which was moved here from `@backstage/plugin-scaffolder-common`. It has also been marked as deprecated in - the process - please consider [migrating to `v1beta3` - templates](https://backstage.io/docs/features/software-templates/migrating-from-v1beta2-to-v1beta3). + the process - please consider [migrating to `v1beta3` templates](https://backstage.io/docs/features/software-templates/migrating-from-v1beta2-to-v1beta3). - c77c5c7eb6: Added `backstage.role` to `package.json` - Updated dependencies - @backstage/catalog-model@0.10.0 diff --git a/plugins/scaffolder-common/package.json b/plugins/scaffolder-common/package.json index 614bd16a25..a0060b1427 100644 --- a/plugins/scaffolder-common/package.json +++ b/plugins/scaffolder-common/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-common", - "version": "1.5.2-next.1", + "version": "1.5.2", "description": "Common functionalities for the scaffolder, to be shared between scaffolder and scaffolder-backend plugin", "backstage": { "role": "common-library" diff --git a/plugins/scaffolder-node-test-utils/CHANGELOG.md b/plugins/scaffolder-node-test-utils/CHANGELOG.md index 5914c8fdee..72804941e4 100644 --- a/plugins/scaffolder-node-test-utils/CHANGELOG.md +++ b/plugins/scaffolder-node-test-utils/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-scaffolder-node-test-utils +## 0.1.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-test-utils@0.3.8 + - @backstage/plugin-scaffolder-node@0.4.4 + ## 0.1.4-next.1 ### Patch Changes diff --git a/plugins/scaffolder-node-test-utils/package.json b/plugins/scaffolder-node-test-utils/package.json index 99adae5ab7..8686592f7a 100644 --- a/plugins/scaffolder-node-test-utils/package.json +++ b/plugins/scaffolder-node-test-utils/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-node-test-utils", - "version": "0.1.4-next.1", + "version": "0.1.4", "backstage": { "role": "node-library" }, diff --git a/plugins/scaffolder-node/CHANGELOG.md b/plugins/scaffolder-node/CHANGELOG.md index d9e2804297..5c6fe0f6cc 100644 --- a/plugins/scaffolder-node/CHANGELOG.md +++ b/plugins/scaffolder-node/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-scaffolder-node +## 0.4.4 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- e4b50ab: Scaffolder workspace serialization +- f633efa: To remove the dependency on the soon-to-be-deprecated `backend-common` package, this package now maintains its own isomorphic Git class implementation. +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/integration@1.11.0 + ## 0.4.4-next.2 ### Patch Changes diff --git a/plugins/scaffolder-node/package.json b/plugins/scaffolder-node/package.json index 11d3da67bc..af26f204dd 100644 --- a/plugins/scaffolder-node/package.json +++ b/plugins/scaffolder-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-node", - "version": "0.4.4-next.2", + "version": "0.4.4", "description": "The plugin-scaffolder-node module for @backstage/plugin-scaffolder-backend", "backstage": { "role": "node-library" @@ -54,6 +54,7 @@ "@backstage/types": "workspace:^", "fs-extra": "^11.2.0", "globby": "^11.0.0", + "isomorphic-git": "^1.23.0", "jsonschema": "^1.2.6", "p-limit": "^3.1.0", "winston": "^3.2.1", diff --git a/plugins/scaffolder-node/src/actions/fetch.ts b/plugins/scaffolder-node/src/actions/fetch.ts index 6b3e08bc7e..63bc4b1352 100644 --- a/plugins/scaffolder-node/src/actions/fetch.ts +++ b/plugins/scaffolder-node/src/actions/fetch.ts @@ -14,7 +14,8 @@ * limitations under the License. */ -import { resolveSafeChildPath, UrlReader } from '@backstage/backend-common'; +import { UrlReader } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { InputError } from '@backstage/errors'; import { ScmIntegrations } from '@backstage/integration'; import fs from 'fs-extra'; diff --git a/plugins/scaffolder-node/src/actions/gitHelpers.test.ts b/plugins/scaffolder-node/src/actions/gitHelpers.test.ts index b230b2cd06..64281d660f 100644 --- a/plugins/scaffolder-node/src/actions/gitHelpers.test.ts +++ b/plugins/scaffolder-node/src/actions/gitHelpers.test.ts @@ -14,7 +14,8 @@ * limitations under the License. */ -import { Git, getVoidLogger } from '@backstage/backend-common'; +import { getVoidLogger } from '@backstage/backend-common'; +import { Git } from '../scm'; import { commitAndPushRepo, initRepoAndPush, @@ -24,7 +25,7 @@ import { cloneRepo, } from './gitHelpers'; -jest.mock('@backstage/backend-common', () => ({ +jest.mock('../scm', () => ({ Git: { fromAuth: jest.fn().mockReturnValue({ init: jest.fn(), diff --git a/plugins/scaffolder-node/src/actions/gitHelpers.ts b/plugins/scaffolder-node/src/actions/gitHelpers.ts index 2026e75247..04f47d1648 100644 --- a/plugins/scaffolder-node/src/actions/gitHelpers.ts +++ b/plugins/scaffolder-node/src/actions/gitHelpers.ts @@ -14,8 +14,8 @@ * limitations under the License. */ -import { Git } from '@backstage/backend-common'; import { Logger } from 'winston'; +import { Git } from '../scm'; /** * @public diff --git a/plugins/scaffolder-node/src/actions/util.ts b/plugins/scaffolder-node/src/actions/util.ts index 7f7121ef16..2b3a1296bf 100644 --- a/plugins/scaffolder-node/src/actions/util.ts +++ b/plugins/scaffolder-node/src/actions/util.ts @@ -15,7 +15,7 @@ */ import { InputError } from '@backstage/errors'; -import { isChildPath } from '@backstage/backend-common'; +import { isChildPath } from '@backstage/backend-plugin-api'; import { join as joinPath, normalize as normalizePath } from 'path'; import { ScmIntegrationRegistry } from '@backstage/integration'; diff --git a/plugins/scaffolder-node/src/files/deserializeDirectoryContents.ts b/plugins/scaffolder-node/src/files/deserializeDirectoryContents.ts index bdcecd99f1..4c6ae251ee 100644 --- a/plugins/scaffolder-node/src/files/deserializeDirectoryContents.ts +++ b/plugins/scaffolder-node/src/files/deserializeDirectoryContents.ts @@ -16,7 +16,7 @@ import fs from 'fs-extra'; import { dirname } from 'path'; -import { resolveSafeChildPath } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { SerializedFile } from './types'; /** diff --git a/plugins/scaffolder-node/src/files/serializeDirectoryContents.ts b/plugins/scaffolder-node/src/files/serializeDirectoryContents.ts index 7e52f6323b..1b83a8cf32 100644 --- a/plugins/scaffolder-node/src/files/serializeDirectoryContents.ts +++ b/plugins/scaffolder-node/src/files/serializeDirectoryContents.ts @@ -17,7 +17,7 @@ import { promises as fs } from 'fs'; import globby from 'globby'; import limiterFactory from 'p-limit'; -import { resolveSafeChildPath } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { SerializedFile } from './types'; import { isError } from '@backstage/errors'; diff --git a/plugins/scaffolder-node/src/scm/git.test.ts b/plugins/scaffolder-node/src/scm/git.test.ts new file mode 100644 index 0000000000..1c07dfb917 --- /dev/null +++ b/plugins/scaffolder-node/src/scm/git.test.ts @@ -0,0 +1,606 @@ +/* + * Copyright 2020 The Backstage Authors + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +jest.mock('isomorphic-git'); +jest.mock('isomorphic-git/http/node'); +jest.mock('fs-extra'); + +import * as isomorphic from 'isomorphic-git'; +import { Git } from './git'; +import http from 'isomorphic-git/http/node'; +import fs from 'fs-extra'; + +describe('Git', () => { + beforeEach(() => { + jest.resetAllMocks(); + }); + + describe('add', () => { + it('should call isomorphic-git add with the correct arguments', async () => { + const git = Git.fromAuth({}); + const dir = 'mockdirectory'; + const filepath = 'mockfile/path'; + + await git.add({ dir, filepath }); + + expect(isomorphic.add).toHaveBeenCalledWith({ + fs, + dir, + filepath, + }); + }); + }); + + describe('addRemote', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const git = Git.fromAuth({}); + const dir = 'mockdirectory'; + const remote = 'origin'; + const url = 'git@github.com/something/sads'; + const force = true; + + await git.addRemote({ dir, remote, url, force }); + + expect(isomorphic.addRemote).toHaveBeenCalledWith({ + fs, + dir, + remote, + url, + force, + }); + }); + }); + + describe('remove', () => { + it('should call isomorphic-git remove with the correct arguments', async () => { + const git = Git.fromAuth({}); + const dir = 'mockdirectory'; + const filepath = 'mockfile/path'; + + await git.remove({ dir, filepath }); + + expect(isomorphic.remove).toHaveBeenCalledWith({ + fs, + dir, + filepath, + }); + }); + }); + + describe('deleteRemote', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const git = Git.fromAuth({}); + const dir = 'mockdirectory'; + const remote = 'origin'; + + await git.deleteRemote({ dir, remote }); + + expect(isomorphic.deleteRemote).toHaveBeenCalledWith({ + fs, + dir, + remote, + }); + }); + }); + + describe('checkout', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const git = Git.fromAuth({}); + const dir = 'mockdirectory'; + const ref = 'master'; + + await git.checkout({ dir, ref }); + + expect(isomorphic.checkout).toHaveBeenCalledWith({ + fs, + dir, + ref, + }); + }); + }); + + describe('branch', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const git = Git.fromAuth({}); + const dir = 'mockdirectory'; + const ref = 'master'; + + await git.branch({ dir, ref }); + + expect(isomorphic.branch).toHaveBeenCalledWith({ + fs, + dir, + ref, + }); + }); + }); + + describe('commit', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const git = Git.fromAuth({}); + const dir = 'mockdirectory'; + const message = 'Inital Commit'; + const author = { + name: 'author', + email: 'test@backstage.io', + }; + const committer = { + name: 'comitter', + email: 'test@backstage.io', + }; + + await git.commit({ dir, message, author, committer }); + + expect(isomorphic.commit).toHaveBeenCalledWith({ + fs, + dir, + message, + author, + committer, + }); + }); + }); + + describe('clone', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const url = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + + await git.clone({ url, dir }); + + expect(isomorphic.clone).toHaveBeenCalledWith({ + fs, + http, + url, + dir, + singleBranch: true, + depth: 1, + onProgress: expect.any(Function), + headers: { + 'user-agent': 'git/@isomorphic-git', + }, + onAuth: expect.any(Function), + }); + }); + + it('should call isomorphic-git with the correct arguments (Bearer)', async () => { + const url = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + token: 'test', + }; + const git = Git.fromAuth(auth); + + await git.clone({ url, dir }); + + expect(isomorphic.clone).toHaveBeenCalledWith({ + fs, + http, + url, + dir, + singleBranch: true, + depth: 1, + onProgress: expect.any(Function), + headers: { + Authorization: 'Bearer test', + 'user-agent': 'git/@isomorphic-git', + }, + onAuth: expect.any(Function), + }); + }); + + it('should pass a function that returns the authorization as the onAuth handler when username and password are specified', async () => { + const url = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + + await git.clone({ url, dir }); + + const { onAuth } = ( + isomorphic.clone as unknown as jest.Mock<(typeof isomorphic)['clone']> + ).mock.calls[0][0]!; + + expect(onAuth()).toEqual(auth); + }); + + it('should pass the provided callback as the onAuth handler when on auth is specified', async () => { + const url = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + username: 'from', + password: 'callback', + }; + + const git = Git.fromAuth({ onAuth: () => auth }); + + await git.clone({ url, dir }); + + const { onAuth } = ( + isomorphic.clone as unknown as jest.Mock<(typeof isomorphic)['clone']> + ).mock.calls[0][0]!; + + expect(onAuth()).toEqual(auth); + }); + + it('should propagate the data from the error handler', async () => { + const url = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + + (isomorphic.clone as jest.Mock).mockImplementation(() => { + const error: Error & { data?: unknown } = new Error('mock error'); + error.data = { some: 'more information here' }; + + throw error; + }); + + await expect(git.clone({ url, dir })).rejects.toThrow( + 'more information here', + ); + }); + }); + + describe('currentBranch', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const dir = '/some/mock/dir'; + const fullName = true; + const git = Git.fromAuth({}); + + await git.currentBranch({ dir, fullName }); + + expect(isomorphic.currentBranch).toHaveBeenCalledWith({ + fs, + dir, + fullname: true, + }); + + await git.currentBranch({ dir }); + + expect(isomorphic.currentBranch).toHaveBeenCalledWith({ + fs, + dir, + fullname: false, + }); + }); + }); + + describe('fetch', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const remote = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + + await git.fetch({ remote, dir, tags: true }); + + expect(isomorphic.fetch).toHaveBeenCalledWith({ + fs, + http, + remote, + dir, + tags: true, + onProgress: expect.any(Function), + headers: { + 'user-agent': 'git/@isomorphic-git', + }, + onAuth: expect.any(Function), + }); + }); + + it('should call isomorphic-git with the correct arguments (Bearer)', async () => { + const remote = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + token: 'test', + }; + const git = Git.fromAuth(auth); + + await git.fetch({ remote, dir }); + + expect(isomorphic.fetch).toHaveBeenCalledWith({ + fs, + http, + remote, + dir, + tags: false, + onProgress: expect.any(Function), + headers: { + Authorization: 'Bearer test', + 'user-agent': 'git/@isomorphic-git', + }, + onAuth: expect.any(Function), + }); + }); + + it('should pass a function that returns the authorization as the onAuth handler', async () => { + const remote = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + + await git.fetch({ remote, dir }); + + const { onAuth } = ( + isomorphic.fetch as unknown as jest.Mock<(typeof isomorphic)['fetch']> + ).mock.calls[0][0]!; + + expect(onAuth()).toEqual(auth); + }); + + it('should propagate the data from the error handler', async () => { + const remote = 'http://github.com/some/repo'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + + (isomorphic.fetch as jest.Mock).mockImplementation(() => { + const error: Error & { data?: unknown } = new Error('mock error'); + error.data = { some: 'more information here' }; + + throw error; + }); + + await expect(git.fetch({ remote, dir })).rejects.toThrow( + 'more information here', + ); + }); + }); + + describe('init', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const dir = '/some/mock/dir'; + const defaultBranch = 'master'; + + const git = Git.fromAuth({}); + + await git.init({ dir, defaultBranch }); + + expect(isomorphic.init).toHaveBeenCalledWith({ + fs, + dir, + defaultBranch, + }); + }); + }); + + describe('merge', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const dir = '/some/mock/dir'; + const author = { + name: 'author', + email: 'test@backstage.io', + }; + const committer = { + name: 'comitter', + email: 'test@backstage.io', + }; + const theirs = 'master'; + const ours = 'production'; + + const git = Git.fromAuth({}); + + await git.merge({ dir, theirs, ours, author, committer }); + + expect(isomorphic.merge).toHaveBeenCalledWith({ + fs, + dir, + ours, + theirs, + author, + committer, + }); + }); + }); + + describe('push', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const remote = 'origin'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + const remoteRef = 'master'; + const force = true; + + await git.push({ dir, remote, remoteRef, force }); + + expect(isomorphic.push).toHaveBeenCalledWith({ + fs, + http, + remote, + dir, + remoteRef, + force, + onProgress: expect.any(Function), + headers: { + 'user-agent': 'git/@isomorphic-git', + }, + onAuth: expect.any(Function), + }); + }); + + it('should call isomorphic-git with the correct arguments (Bearer)', async () => { + const remote = 'origin'; + const dir = '/some/mock/dir'; + const auth = { + token: 'test', + }; + const git = Git.fromAuth(auth); + const remoteRef = 'master'; + const force = true; + + await git.push({ dir, remote, remoteRef, force }); + + expect(isomorphic.push).toHaveBeenCalledWith({ + fs, + http, + remote, + dir, + remoteRef, + force, + onProgress: expect.any(Function), + headers: { + Authorization: 'Bearer test', + 'user-agent': 'git/@isomorphic-git', + }, + onAuth: expect.any(Function), + }); + }); + + it('should call isomorphic-git with remoteRef parameter', async () => { + const remote = 'origin'; + const remoteRef = 'refs/for/master'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + + await git.push({ dir, remote, remoteRef }); + + expect(isomorphic.push).toHaveBeenCalledWith({ + fs, + http, + remote, + remoteRef, + dir, + onProgress: expect.any(Function), + headers: { + 'user-agent': 'git/@isomorphic-git', + }, + onAuth: expect.any(Function), + }); + }); + + it('should pass a function that returns the authorization as the onAuth handler', async () => { + const remote = 'origin'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + const remoteRef = 'master'; + const force = true; + + await git.push({ remote, dir, remoteRef, force }); + + const { onAuth } = ( + isomorphic.push as unknown as jest.Mock<(typeof isomorphic)['push']> + ).mock.calls[0][0]!; + + expect(onAuth()).toEqual(auth); + }); + + it('should propagate the data from the error handler', async () => { + const remote = 'origin'; + const dir = '/some/mock/dir'; + const auth = { + username: 'blob', + password: 'hunter2', + }; + const git = Git.fromAuth(auth); + const remoteRef = 'master'; + const force = true; + + (isomorphic.push as jest.Mock).mockImplementation(() => { + const error: Error & { data?: unknown } = new Error('mock error'); + error.data = { some: 'more information here' }; + + throw error; + }); + + await expect(git.push({ remote, dir, remoteRef, force })).rejects.toThrow( + 'more information here', + ); + }); + }); + + describe('readCommit', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const dir = '/some/mock/dir'; + const sha = 'as43bd7'; + + const git = Git.fromAuth({}); + + await git.readCommit({ dir, sha }); + + expect(isomorphic.readCommit).toHaveBeenCalledWith({ + fs, + dir, + oid: sha, + }); + }); + }); + + describe('resolveRef', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const dir = '/some/mock/dir'; + const ref = 'as43bd7'; + + const git = Git.fromAuth({}); + + await git.resolveRef({ dir, ref }); + + expect(isomorphic.resolveRef).toHaveBeenCalledWith({ + fs, + dir, + ref, + }); + }); + }); + + describe('log', () => { + it('should call isomorphic-git with the correct arguments', async () => { + const dir = '/some/mock/dir'; + const ref = 'as43bd7'; + + const git = Git.fromAuth({}); + + await git.log({ dir, ref }); + + expect(isomorphic.log).toHaveBeenCalledWith({ + fs, + dir, + ref, + }); + }); + }); +}); diff --git a/packages/backend-common/src/scm/git.ts b/plugins/scaffolder-node/src/scm/git.ts similarity index 100% rename from packages/backend-common/src/scm/git.ts rename to plugins/scaffolder-node/src/scm/git.ts diff --git a/packages/theme/src/unified/MuiClassNameSetup.ts b/plugins/scaffolder-node/src/scm/index.ts similarity index 59% rename from packages/theme/src/unified/MuiClassNameSetup.ts rename to plugins/scaffolder-node/src/scm/index.ts index 5d7e0b26fe..f9c59e99eb 100644 --- a/packages/theme/src/unified/MuiClassNameSetup.ts +++ b/plugins/scaffolder-node/src/scm/index.ts @@ -1,5 +1,5 @@ /* - * Copyright 2022 The Backstage Authors + * Copyright 2020 The Backstage Authors * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -14,11 +14,5 @@ * limitations under the License. */ -import { unstable_ClassNameGenerator as ClassNameGenerator } from '@mui/material/className'; - -/** - * This API is introduced in @mui/material (v5.0.5) as a replacement of deprecated createGenerateClassName & only affects v5 Material UI components from `@mui/*` - */ -ClassNameGenerator.configure(componentName => { - return `v5-${componentName}`; -}); +export { Git } from './git'; +export type { StaticAuthOptions, AuthCallbackOptions } from './git'; diff --git a/plugins/scaffolder-react/CHANGELOG.md b/plugins/scaffolder-react/CHANGELOG.md index ca23ab25be..c445b76d06 100644 --- a/plugins/scaffolder-react/CHANGELOG.md +++ b/plugins/scaffolder-react/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-scaffolder-react +## 1.8.5 + +### Patch Changes + +- 9156654: Capturing more event clicks for scaffolder +- 0040ec2: Updated dependency `@rjsf/utils` to `5.18.2`. + Updated dependency `@rjsf/core` to `5.18.2`. + Updated dependency `@rjsf/material-ui` to `5.18.2`. + Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/catalog-client@1.6.5 + ## 1.8.5-next.2 ### Patch Changes diff --git a/plugins/scaffolder-react/package.json b/plugins/scaffolder-react/package.json index d98fcffbb2..85a835fd69 100644 --- a/plugins/scaffolder-react/package.json +++ b/plugins/scaffolder-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder-react", - "version": "1.8.5-next.2", + "version": "1.8.5", "description": "A frontend library that helps other Backstage plugins interact with the Scaffolder", "backstage": { "role": "web-library" diff --git a/plugins/scaffolder-react/src/next/components/ScaffolderField/ScaffolderField.tsx b/plugins/scaffolder-react/src/next/components/ScaffolderField/ScaffolderField.tsx index 1bb1656fd0..60c3907ddb 100644 --- a/plugins/scaffolder-react/src/next/components/ScaffolderField/ScaffolderField.tsx +++ b/plugins/scaffolder-react/src/next/components/ScaffolderField/ScaffolderField.tsx @@ -76,6 +76,7 @@ export const ScaffolderField = ( {displayLabel && rawDescription ? ( ) : null} diff --git a/plugins/scaffolder/CHANGELOG.md b/plugins/scaffolder/CHANGELOG.md index 6edfc1484d..c4949715d7 100644 --- a/plugins/scaffolder/CHANGELOG.md +++ b/plugins/scaffolder/CHANGELOG.md @@ -1,5 +1,33 @@ # @backstage/plugin-scaffolder +## 1.20.0 + +### Minor Changes + +- 4268696: `MultiEntityPicker` uses `EntityDisplayName` instead of `humanizeEntityRef` to display entity. + +### Patch Changes + +- 9156654: Capturing more event clicks for scaffolder +- 131e5cb: Fix broken links in README. +- 0040ec2: Updated dependency `@rjsf/utils` to `5.18.2`. + Updated dependency `@rjsf/core` to `5.18.2`. + Updated dependency `@rjsf/material-ui` to `5.18.2`. + Updated dependency `@rjsf/validator-ajv8` to `5.18.2`. +- 762141c: Fixed a bug where the `MultiEntityPicker` was not able to be set as required +- Updated dependencies + - @backstage/plugin-scaffolder-common@1.5.2 + - @backstage/plugin-scaffolder-react@1.8.5 + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/integration@1.11.0 + - @backstage/catalog-client@1.6.5 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-catalog-common@1.0.23 + ## 1.19.4-next.2 ### Patch Changes diff --git a/plugins/scaffolder/README.md b/plugins/scaffolder/README.md index a6af441d62..8acf456b08 100644 --- a/plugins/scaffolder/README.md +++ b/plugins/scaffolder/README.md @@ -1,7 +1,6 @@ # Scaffolder Frontend -This is the React frontend for the default Backstage [software -templates](https://backstage.io/docs/features/software-templates/). +This is the React frontend for the default Backstage [software templates](https://backstage.io/docs/features/software-templates/). This package supplies interfaces related to showing available templates in the Backstage catalog and the workflow to create software using those templates. diff --git a/plugins/scaffolder/package.json b/plugins/scaffolder/package.json index 1c8ec4ca6f..363e0724dd 100644 --- a/plugins/scaffolder/package.json +++ b/plugins/scaffolder/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-scaffolder", - "version": "1.19.4-next.2", + "version": "1.20.0", "description": "The Backstage plugin that helps you create new things", "backstage": { "role": "frontend-plugin" diff --git a/plugins/scaffolder/src/components/fields/MultiEntityPicker/MultiEntityPicker.test.tsx b/plugins/scaffolder/src/components/fields/MultiEntityPicker/MultiEntityPicker.test.tsx index bc0a5ed32d..4be07b139d 100644 --- a/plugins/scaffolder/src/components/fields/MultiEntityPicker/MultiEntityPicker.test.tsx +++ b/plugins/scaffolder/src/components/fields/MultiEntityPicker/MultiEntityPicker.test.tsx @@ -16,7 +16,11 @@ import { CATALOG_FILTER_EXISTS } from '@backstage/catalog-client'; import { Entity } from '@backstage/catalog-model'; -import { CatalogApi, catalogApiRef } from '@backstage/plugin-catalog-react'; +import { + CatalogApi, + catalogApiRef, + entityPresentationApiRef, +} from '@backstage/plugin-catalog-react'; import { renderInTestApp, TestApiProvider } from '@backstage/test-utils'; import { fireEvent, screen } from '@testing-library/react'; @@ -24,6 +28,7 @@ import React from 'react'; import { MultiEntityPicker } from './MultiEntityPicker'; import { MultiEntityPickerProps } from './schema'; import { ScaffolderRJSFFieldProps as FieldProps } from '@backstage/plugin-scaffolder-react'; +import { DefaultEntityPresentationApi } from '@backstage/plugin-catalog'; const makeEntity = (kind: string, namespace: string, name: string): Entity => ({ apiVersion: 'scaffolder.backstage.io/v1beta3', @@ -59,7 +64,15 @@ describe('', () => { ]; Wrapper = ({ children }: { children?: React.ReactNode }) => ( - + {children} ); diff --git a/plugins/scaffolder/src/components/fields/MultiEntityPicker/MultiEntityPicker.tsx b/plugins/scaffolder/src/components/fields/MultiEntityPicker/MultiEntityPicker.tsx index 8f17bf1ea6..f8fc831976 100644 --- a/plugins/scaffolder/src/components/fields/MultiEntityPicker/MultiEntityPicker.tsx +++ b/plugins/scaffolder/src/components/fields/MultiEntityPicker/MultiEntityPicker.tsx @@ -25,7 +25,9 @@ import { import { useApi } from '@backstage/core-plugin-api'; import { catalogApiRef, - humanizeEntityRef, + entityPresentationApiRef, + EntityDisplayName, + EntityRefPresentationSnapshot, } from '@backstage/plugin-catalog-react'; import TextField from '@material-ui/core/TextField'; import FormControl from '@material-ui/core/FormControl'; @@ -64,33 +66,31 @@ export const MultiEntityPicker = (props: MultiEntityPickerProps) => { uiSchema['ui:options']?.defaultNamespace || undefined; const catalogApi = useApi(catalogApiRef); - + const entityPresentationApi = useApi(entityPresentationApiRef); const { value: entities, loading } = useAsync(async () => { const { items } = await catalogApi.getEntities( catalogFilter ? { filter: catalogFilter } : undefined, ); - return items; + const entityRefToPresentation = new Map< + string, + EntityRefPresentationSnapshot + >( + await Promise.all( + items.map(async item => { + const presentation = await entityPresentationApi.forEntity(item) + .promise; + return [stringifyEntityRef(item), presentation] as [ + string, + EntityRefPresentationSnapshot, + ]; + }), + ), + ); + return { entities: items, entityRefToPresentation }; }); const allowArbitraryValues = uiSchema['ui:options']?.allowArbitraryValues ?? true; - const getLabel = useCallback( - (ref: string) => { - try { - return humanizeEntityRef( - parseEntityRef(ref, { defaultKind, defaultNamespace }), - { - defaultKind, - defaultNamespace, - }, - ); - } catch (err) { - return ref; - } - }, - [defaultKind, defaultNamespace], - ); - const onSelect = useCallback( (_: any, refs: (string | Entity)[], reason: AutocompleteChangeReason) => { const values = refs @@ -130,8 +130,8 @@ export const MultiEntityPicker = (props: MultiEntityPickerProps) => { ); useEffect(() => { - if (entities?.length === 1) { - onChange([stringifyEntityRef(entities[0])]); + if (entities?.entities?.length === 1) { + onChange([stringifyEntityRef(entities?.entities[0])]); } }, [entities, onChange]); @@ -144,23 +144,18 @@ export const MultiEntityPicker = (props: MultiEntityPickerProps) => { formData && formData.includes(stringifyEntityRef(e)), - ) ?? (allowArbitraryValues && formData ? formData.map(getLabel) : []) - } loading={loading} onChange={onSelect} - options={entities || []} + options={entities?.entities || []} + renderOption={option => } getOptionLabel={option => // option can be a string due to freeSolo. typeof option === 'string' ? option - : humanizeEntityRef(option, { defaultKind, defaultNamespace })! + : entities?.entityRefToPresentation.get(stringifyEntityRef(option)) + ?.entityRef! } autoSelect freeSolo={allowArbitraryValues} @@ -170,7 +165,10 @@ export const MultiEntityPicker = (props: MultiEntityPickerProps) => { label={title} margin="dense" helperText={description} - FormHelperTextProps={{ margin: 'dense', style: { marginLeft: 0 } }} + FormHelperTextProps={{ + margin: 'dense', + style: { marginLeft: 0 }, + }} variant="outlined" required={required} InputProps={{ diff --git a/plugins/search-backend-module-catalog/CHANGELOG.md b/plugins/search-backend-module-catalog/CHANGELOG.md index 6ed9030a22..d0c84a7617 100644 --- a/plugins/search-backend-module-catalog/CHANGELOG.md +++ b/plugins/search-backend-module-catalog/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-search-backend-module-catalog +## 0.1.24 + +### Patch Changes + +- b192752: Updated `README.md` to point to `packages/backend` instead of `packages/backend-next`. +- d5fff66: Fix wiring of the module exported at the `/alpha` path, which was causing authentication failures. +- 5dc5f4f: Allow the `tokenManager` parameter to be optional when instantiating collator +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.1.24-next.2 ### Patch Changes diff --git a/plugins/search-backend-module-catalog/package.json b/plugins/search-backend-module-catalog/package.json index aef1a1028d..f7eca60fbd 100644 --- a/plugins/search-backend-module-catalog/package.json +++ b/plugins/search-backend-module-catalog/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-backend-module-catalog", - "version": "0.1.24-next.2", + "version": "0.1.24", "description": "A module for the search backend that exports catalog modules", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/search-backend-module-elasticsearch/CHANGELOG.md b/plugins/search-backend-module-elasticsearch/CHANGELOG.md index 1af0204403..5bf9aa19ea 100644 --- a/plugins/search-backend-module-elasticsearch/CHANGELOG.md +++ b/plugins/search-backend-module-elasticsearch/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-search-backend-module-elasticsearch +## 1.4.1 + +### Patch Changes + +- 5252ee1: Fix never resolved indexer promise. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-search-backend-node@1.2.22 + ## 1.4.1-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-elasticsearch/package.json b/plugins/search-backend-module-elasticsearch/package.json index 85489b4043..128bc0e28c 100644 --- a/plugins/search-backend-module-elasticsearch/package.json +++ b/plugins/search-backend-module-elasticsearch/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-backend-module-elasticsearch", - "version": "1.4.1-next.1", + "version": "1.4.1", "description": "A module for the search backend that implements search using ElasticSearch", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/search-backend-module-explore/CHANGELOG.md b/plugins/search-backend-module-explore/CHANGELOG.md index ce6499ab4e..fc8ff4b307 100644 --- a/plugins/search-backend-module-explore/CHANGELOG.md +++ b/plugins/search-backend-module-explore/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-search-backend-module-explore +## 0.1.24 + +### Patch Changes + +- ca6e2e0: Migrate search collator to use the new auth services. +- 5d99272: Update README.md to point to explore plugin in community-plugins repository. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-search-backend-node@1.2.22 + ## 0.1.24-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-explore/package.json b/plugins/search-backend-module-explore/package.json index d181d70cbf..28ba6945c3 100644 --- a/plugins/search-backend-module-explore/package.json +++ b/plugins/search-backend-module-explore/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-backend-module-explore", - "version": "0.1.24-next.1", + "version": "0.1.24", "description": "A module for the search backend that exports explore modules", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/search-backend-module-pg/CHANGELOG.md b/plugins/search-backend-module-pg/CHANGELOG.md index 37386a7fd1..ba6674606d 100644 --- a/plugins/search-backend-module-pg/CHANGELOG.md +++ b/plugins/search-backend-module-pg/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-search-backend-module-pg +## 0.5.27 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-search-backend-node@1.2.22 + ## 0.5.27-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-pg/package.json b/plugins/search-backend-module-pg/package.json index 3aec50e503..6645e2642f 100644 --- a/plugins/search-backend-module-pg/package.json +++ b/plugins/search-backend-module-pg/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-backend-module-pg", - "version": "0.5.27-next.1", + "version": "0.5.27", "description": "A module for the search backend that implements search using PostgreSQL", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/search-backend-module-pg/src/database/DatabaseDocumentStore.ts b/plugins/search-backend-module-pg/src/database/DatabaseDocumentStore.ts index 3019c63a64..88ba7072dd 100644 --- a/plugins/search-backend-module-pg/src/database/DatabaseDocumentStore.ts +++ b/plugins/search-backend-module-pg/src/database/DatabaseDocumentStore.ts @@ -13,10 +13,8 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -import { - PluginDatabaseManager, - resolvePackagePath, -} from '@backstage/backend-common'; +import { PluginDatabaseManager } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { IndexableDocument } from '@backstage/plugin-search-common'; import { Knex } from 'knex'; import { diff --git a/plugins/search-backend-module-stack-overflow-collator/CHANGELOG.md b/plugins/search-backend-module-stack-overflow-collator/CHANGELOG.md index c8faaf7609..c56c40ebe4 100644 --- a/plugins/search-backend-module-stack-overflow-collator/CHANGELOG.md +++ b/plugins/search-backend-module-stack-overflow-collator/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-search-backend-module-stack-overflow-collator +## 0.1.11 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-search-backend-node@1.2.22 + ## 0.1.11-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-stack-overflow-collator/package.json b/plugins/search-backend-module-stack-overflow-collator/package.json index 3c76ed164b..5ae74d37bc 100644 --- a/plugins/search-backend-module-stack-overflow-collator/package.json +++ b/plugins/search-backend-module-stack-overflow-collator/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-backend-module-stack-overflow-collator", - "version": "0.1.11-next.1", + "version": "0.1.11", "description": "A module for the search backend that exports stack overflow modules", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/search-backend-module-techdocs/CHANGELOG.md b/plugins/search-backend-module-techdocs/CHANGELOG.md index 850db158c8..569a73c232 100644 --- a/plugins/search-backend-module-techdocs/CHANGELOG.md +++ b/plugins/search-backend-module-techdocs/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-search-backend-module-techdocs +## 0.1.23 + +### Patch Changes + +- 5dc5f4f: Allow the `tokenManager` parameter to be optional when instantiating collator +- Updated dependencies + - @backstage/plugin-catalog-node@1.12.0 + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + - @backstage/plugin-techdocs-node@1.12.4 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + ## 0.1.23-next.2 ### Patch Changes diff --git a/plugins/search-backend-module-techdocs/package.json b/plugins/search-backend-module-techdocs/package.json index 5cf53c40be..c27fe52d93 100644 --- a/plugins/search-backend-module-techdocs/package.json +++ b/plugins/search-backend-module-techdocs/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-backend-module-techdocs", - "version": "0.1.23-next.2", + "version": "0.1.23", "description": "A module for the search backend that exports techdocs modules", "backstage": { "role": "backend-plugin-module" diff --git a/plugins/search-backend-node/CHANGELOG.md b/plugins/search-backend-node/CHANGELOG.md index 854996ba53..74ba4c86c1 100644 --- a/plugins/search-backend-node/CHANGELOG.md +++ b/plugins/search-backend-node/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-search-backend-node +## 1.2.22 + +### Patch Changes + +- c6cb568: Add lifecycle monitoring for the search index registry +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/backend-tasks@0.5.23 + ## 1.2.22-next.1 ### Patch Changes diff --git a/plugins/search-backend-node/api-report-alpha.md b/plugins/search-backend-node/api-report-alpha.md index 8e35e70f65..4f3015a0e4 100644 --- a/plugins/search-backend-node/api-report-alpha.md +++ b/plugins/search-backend-node/api-report-alpha.md @@ -33,19 +33,20 @@ export const searchIndexRegistryExtensionPoint: ExtensionPoint; - start(options: SearchIndexServiceStartOptions): Promise; + init(options: SearchIndexServiceInitOptions): void; + start(): Promise; stop(): Promise; } // @alpha -export const searchIndexServiceRef: ServiceRef; - -// @alpha -export type SearchIndexServiceStartOptions = { +export type SearchIndexServiceInitOptions = { searchEngine: SearchEngine; collators: RegisterCollatorParameters[]; decorators: RegisterDecoratorParameters[]; }; +// @alpha +export const searchIndexServiceRef: ServiceRef; + // (No @packageDocumentation comment for this package) ``` diff --git a/plugins/search-backend-node/package.json b/plugins/search-backend-node/package.json index c734681980..a3c9e16f95 100644 --- a/plugins/search-backend-node/package.json +++ b/plugins/search-backend-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-backend-node", - "version": "1.2.22-next.1", + "version": "1.2.22", "description": "A library for Backstage backend plugins that want to interact with the search backend plugin", "backstage": { "role": "node-library" diff --git a/plugins/search-backend-node/src/alpha.ts b/plugins/search-backend-node/src/alpha.ts index 331f0ae304..6fb0c609e5 100644 --- a/plugins/search-backend-node/src/alpha.ts +++ b/plugins/search-backend-node/src/alpha.ts @@ -32,9 +32,9 @@ import { /** * @alpha - * Options for build method on {@link SearchIndexService}. + * Options for the init method on {@link SearchIndexService}. */ -export type SearchIndexServiceStartOptions = { +export type SearchIndexServiceInitOptions = { searchEngine: SearchEngine; collators: RegisterCollatorParameters[]; decorators: RegisterDecoratorParameters[]; @@ -45,15 +45,21 @@ export type SearchIndexServiceStartOptions = { * Interface for implementation of index service. */ export interface SearchIndexService { + /** + * Initializes state in preparation for starting the search index service + */ + init(options: SearchIndexServiceInitOptions): void; + /** * Starts indexing process */ - start(options: SearchIndexServiceStartOptions): Promise; + start(): Promise; /** * Stops indexing process */ stop(): Promise; + /** * Returns an index types list. */ @@ -83,7 +89,7 @@ type DefaultSearchIndexServiceOptions = { /** * @alpha - * Reponsible for register the indexing task and start the schedule. + * Responsible for register the indexing task and start the schedule. */ class DefaultSearchIndexService implements SearchIndexService { private readonly logger: LoggerService; @@ -98,7 +104,7 @@ class DefaultSearchIndexService implements SearchIndexService { return new DefaultSearchIndexService(options); } - async start(options: SearchIndexServiceStartOptions): Promise { + init(options: SearchIndexServiceInitOptions): void { this.indexBuilder = new IndexBuilder({ logger: this.logger, searchEngine: options.searchEngine, @@ -111,8 +117,13 @@ class DefaultSearchIndexService implements SearchIndexService { options.decorators.forEach(decorator => this.indexBuilder?.addDecorator(decorator), ); + } - const { scheduler } = await this.indexBuilder?.build(); + async start(): Promise { + if (!this.indexBuilder) { + throw new Error('IndexBuilder is not initialized, call init first'); + } + const { scheduler } = await this.indexBuilder.build(); this.scheduler = scheduler; this.scheduler!.start(); } diff --git a/plugins/search-backend/CHANGELOG.md b/plugins/search-backend/CHANGELOG.md index c4bc71318c..0a80301ede 100644 --- a/plugins/search-backend/CHANGELOG.md +++ b/plugins/search-backend/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-search-backend +## 1.5.8 + +### Patch Changes + +- c6cb568: Add lifecycle monitoring for the search index registry +- Updated dependencies + - @backstage/repo-tools@0.9.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-search-backend-node@1.2.22 + - @backstage/backend-openapi-utils@0.1.11 + - @backstage/plugin-permission-node@0.7.29 + ## 1.5.8-next.2 ### Patch Changes diff --git a/plugins/search-backend/package.json b/plugins/search-backend/package.json index dde1dc9de9..146e50d177 100644 --- a/plugins/search-backend/package.json +++ b/plugins/search-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-backend", - "version": "1.5.8-next.2", + "version": "1.5.8", "description": "The Backstage backend plugin that provides your backstage app with search", "backstage": { "role": "backend-plugin" diff --git a/plugins/search-backend/src/alpha.ts b/plugins/search-backend/src/alpha.ts index a17b542903..3a3ba82c3e 100644 --- a/plugins/search-backend/src/alpha.ts +++ b/plugins/search-backend/src/alpha.ts @@ -121,13 +121,14 @@ export default createBackendPlugin({ const collators = searchIndexRegistry.getCollators(); const decorators = searchIndexRegistry.getDecorators(); + searchIndexService.init({ + searchEngine: searchEngine!, + collators, + decorators, + }); lifecycle.addStartupHook(async () => { - await searchIndexService.start({ - searchEngine: searchEngine!, - collators, - decorators, - }); + await searchIndexService.start(); }); lifecycle.addShutdownHook(async () => { diff --git a/plugins/search-react/CHANGELOG.md b/plugins/search-react/CHANGELOG.md index c4e75fa41a..046532facf 100644 --- a/plugins/search-react/CHANGELOG.md +++ b/plugins/search-react/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-search-react +## 1.7.11 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + - @backstage/frontend-plugin-api@0.6.5 + ## 1.7.11-next.1 ### Patch Changes diff --git a/plugins/search-react/package.json b/plugins/search-react/package.json index 274deae1d7..1e6b2b0e8e 100644 --- a/plugins/search-react/package.json +++ b/plugins/search-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search-react", - "version": "1.7.11-next.1", + "version": "1.7.11", "backstage": { "role": "web-library" }, diff --git a/plugins/search/CHANGELOG.md b/plugins/search/CHANGELOG.md index 2b221c75e9..b738d853f8 100644 --- a/plugins/search/CHANGELOG.md +++ b/plugins/search/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-search +## 1.4.11 + +### Patch Changes + +- 0501243: Added `aria-label` attribute to DialogTitle element and set `aria-modal` attribute to `true` for improved accessibility in the search modal. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/plugin-search-react@1.7.11 + ## 1.4.11-next.2 ### Patch Changes diff --git a/plugins/search/package.json b/plugins/search/package.json index f064be1433..1a9a09a5fe 100644 --- a/plugins/search/package.json +++ b/plugins/search/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-search", - "version": "1.4.11-next.2", + "version": "1.4.11", "description": "The Backstage plugin that provides your backstage app with search", "backstage": { "role": "frontend-plugin" diff --git a/plugins/signals-backend/CHANGELOG.md b/plugins/signals-backend/CHANGELOG.md index 5287438fb6..f6eeac9bf4 100644 --- a/plugins/signals-backend/CHANGELOG.md +++ b/plugins/signals-backend/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-signals-backend +## 0.1.4 + +### Patch Changes + +- 845d56a: Improved signal lifecycle management and added server side pinging of connections +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + - @backstage/plugin-signals-node@0.1.4 + ## 0.1.4-next.2 ### Patch Changes diff --git a/plugins/signals-backend/package.json b/plugins/signals-backend/package.json index b6f16c272a..b148d4d5e5 100644 --- a/plugins/signals-backend/package.json +++ b/plugins/signals-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-signals-backend", - "version": "0.1.4-next.2", + "version": "0.1.4", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/signals-node/CHANGELOG.md b/plugins/signals-node/CHANGELOG.md index ea703d4291..e26991c787 100644 --- a/plugins/signals-node/CHANGELOG.md +++ b/plugins/signals-node/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-signals-node +## 0.1.4 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-events-node@0.3.4 + - @backstage/plugin-auth-node@0.4.13 + ## 0.1.4-next.1 ### Patch Changes diff --git a/plugins/signals-node/package.json b/plugins/signals-node/package.json index 970b89aca2..4d1ad9e1ef 100644 --- a/plugins/signals-node/package.json +++ b/plugins/signals-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-signals-node", "description": "Node.js library for the signals plugin", - "version": "0.1.4-next.1", + "version": "0.1.4", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/signals/CHANGELOG.md b/plugins/signals/CHANGELOG.md index fdfddfdf2a..971a849a03 100644 --- a/plugins/signals/CHANGELOG.md +++ b/plugins/signals/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-signals +## 0.0.6 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/theme@0.5.4 + ## 0.0.6-next.1 ### Patch Changes diff --git a/plugins/signals/package.json b/plugins/signals/package.json index 7d5fb3bcf9..ec618415a8 100644 --- a/plugins/signals/package.json +++ b/plugins/signals/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-signals", - "version": "0.0.6-next.1", + "version": "0.0.6", "backstage": { "role": "frontend-plugin" }, diff --git a/plugins/techdocs-addons-test-utils/CHANGELOG.md b/plugins/techdocs-addons-test-utils/CHANGELOG.md index 00c7297773..8a4b3d1eb8 100644 --- a/plugins/techdocs-addons-test-utils/CHANGELOG.md +++ b/plugins/techdocs-addons-test-utils/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-techdocs-addons-test-utils +## 1.0.32 + +### Patch Changes + +- 2f13862: Fix bug in TechDocsAddonTester when jest.resetAllMocks is called between tests +- Updated dependencies + - @backstage/plugin-catalog@1.20.0 + - @backstage/plugin-techdocs@1.10.5 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/core-app-api@1.12.5 + - @backstage/integration-react@1.1.27 + - @backstage/test-utils@1.5.5 + - @backstage/plugin-search-react@1.7.11 + - @backstage/plugin-techdocs-react@1.2.4 + ## 1.0.32-next.2 ### Patch Changes diff --git a/plugins/techdocs-addons-test-utils/package.json b/plugins/techdocs-addons-test-utils/package.json index e1ee4400bb..02161159e9 100644 --- a/plugins/techdocs-addons-test-utils/package.json +++ b/plugins/techdocs-addons-test-utils/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-techdocs-addons-test-utils", - "version": "1.0.32-next.2", + "version": "1.0.32", "backstage": { "role": "web-library" }, diff --git a/plugins/techdocs-backend/CHANGELOG.md b/plugins/techdocs-backend/CHANGELOG.md index d6847da1ae..d4d18976b0 100644 --- a/plugins/techdocs-backend/CHANGELOG.md +++ b/plugins/techdocs-backend/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-techdocs-backend +## 1.10.5 + +### Patch Changes + +- 5863cf7: The `techdocs.builder` config is now optional and it will default to `local`. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-techdocs-node@1.12.4 + - @backstage/integration@1.11.0 + - @backstage/plugin-search-backend-module-techdocs@0.1.23 + - @backstage/catalog-client@1.6.5 + - @backstage/plugin-catalog-common@1.0.23 + ## 1.10.5-next.2 ### Patch Changes diff --git a/plugins/techdocs-backend/package.json b/plugins/techdocs-backend/package.json index 79a701413a..a5a8e0ba76 100644 --- a/plugins/techdocs-backend/package.json +++ b/plugins/techdocs-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-techdocs-backend", - "version": "1.10.5-next.2", + "version": "1.10.5", "description": "The Backstage backend plugin that renders technical documentation for your components", "backstage": { "role": "backend-plugin" diff --git a/plugins/techdocs-module-addons-contrib/CHANGELOG.md b/plugins/techdocs-module-addons-contrib/CHANGELOG.md index 77e83144d5..2ab0cef022 100644 --- a/plugins/techdocs-module-addons-contrib/CHANGELOG.md +++ b/plugins/techdocs-module-addons-contrib/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-techdocs-module-addons-contrib +## 1.1.10 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/integration@1.11.0 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-techdocs-react@1.2.4 + ## 1.1.10-next.2 ### Patch Changes diff --git a/plugins/techdocs-module-addons-contrib/package.json b/plugins/techdocs-module-addons-contrib/package.json index 8c89c9bf37..2aaca2c4e0 100644 --- a/plugins/techdocs-module-addons-contrib/package.json +++ b/plugins/techdocs-module-addons-contrib/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-techdocs-module-addons-contrib", - "version": "1.1.10-next.2", + "version": "1.1.10", "description": "Plugin module for contributed TechDocs Addons", "backstage": { "role": "frontend-plugin-module" diff --git a/plugins/techdocs-node/CHANGELOG.md b/plugins/techdocs-node/CHANGELOG.md index aea92cb71c..59a0cc2055 100644 --- a/plugins/techdocs-node/CHANGELOG.md +++ b/plugins/techdocs-node/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-techdocs-node +## 1.12.4 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/catalog-model@1.5.0 + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/integration@1.11.0 + ## 1.12.4-next.2 ### Patch Changes diff --git a/plugins/techdocs-node/package.json b/plugins/techdocs-node/package.json index 0eda77c887..7d4c83545d 100644 --- a/plugins/techdocs-node/package.json +++ b/plugins/techdocs-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-techdocs-node", - "version": "1.12.4-next.2", + "version": "1.12.4", "description": "Common node.js functionalities for TechDocs, to be shared between techdocs-backend plugin and techdocs-cli", "backstage": { "role": "node-library" diff --git a/plugins/techdocs-node/src/helpers.ts b/plugins/techdocs-node/src/helpers.ts index 39a1f4c666..c293d16896 100644 --- a/plugins/techdocs-node/src/helpers.ts +++ b/plugins/techdocs-node/src/helpers.ts @@ -14,7 +14,8 @@ * limitations under the License. */ -import { resolveSafeChildPath, UrlReader } from '@backstage/backend-common'; +import { UrlReader } from '@backstage/backend-common'; +import { resolveSafeChildPath } from '@backstage/backend-plugin-api'; import { Entity, getEntitySourceLocation, diff --git a/plugins/techdocs-node/src/stages/generate/helpers.ts b/plugins/techdocs-node/src/stages/generate/helpers.ts index 1450a4afba..df1a31470d 100644 --- a/plugins/techdocs-node/src/stages/generate/helpers.ts +++ b/plugins/techdocs-node/src/stages/generate/helpers.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import { isChildPath } from '@backstage/backend-common'; +import { isChildPath } from '@backstage/backend-plugin-api'; import { Entity } from '@backstage/catalog-model'; import { assertError, ForwardedError } from '@backstage/errors'; import { ScmIntegrationRegistry } from '@backstage/integration'; diff --git a/plugins/techdocs-node/src/stages/publish/local.test.ts b/plugins/techdocs-node/src/stages/publish/local.test.ts index 4019f80d11..89a38c7ed2 100644 --- a/plugins/techdocs-node/src/stages/publish/local.test.ts +++ b/plugins/techdocs-node/src/stages/publish/local.test.ts @@ -17,7 +17,7 @@ import { getVoidLogger, PluginEndpointDiscovery, } from '@backstage/backend-common'; -import { overridePackagePathResolution } from '@backstage/backend-common/testUtils'; +import { overridePackagePathResolution } from '@backstage/backend-plugin-api/testUtils'; import { ConfigReader } from '@backstage/config'; import express from 'express'; import request from 'supertest'; diff --git a/plugins/techdocs-node/src/stages/publish/local.ts b/plugins/techdocs-node/src/stages/publish/local.ts index 1a02cb7eee..37f41080b4 100644 --- a/plugins/techdocs-node/src/stages/publish/local.ts +++ b/plugins/techdocs-node/src/stages/publish/local.ts @@ -13,11 +13,11 @@ * See the License for the specific language governing permissions and * limitations under the License. */ +import { PluginEndpointDiscovery } from '@backstage/backend-common'; import { - PluginEndpointDiscovery, resolvePackagePath, resolveSafeChildPath, -} from '@backstage/backend-common'; +} from '@backstage/backend-plugin-api'; import { Entity, CompoundEntityRef, diff --git a/plugins/techdocs-react/CHANGELOG.md b/plugins/techdocs-react/CHANGELOG.md index 9a13bd2149..4b76fe42e4 100644 --- a/plugins/techdocs-react/CHANGELOG.md +++ b/plugins/techdocs-react/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-techdocs-react +## 1.2.4 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + ## 1.2.4-next.1 ### Patch Changes diff --git a/plugins/techdocs-react/package.json b/plugins/techdocs-react/package.json index ebba33cdca..283e3afcff 100644 --- a/plugins/techdocs-react/package.json +++ b/plugins/techdocs-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-techdocs-react", - "version": "1.2.4-next.1", + "version": "1.2.4", "description": "Shared frontend utilities for TechDocs and Addons", "backstage": { "role": "web-library" diff --git a/plugins/techdocs/CHANGELOG.md b/plugins/techdocs/CHANGELOG.md index 5011b3471c..7e8f3056e5 100644 --- a/plugins/techdocs/CHANGELOG.md +++ b/plugins/techdocs/CHANGELOG.md @@ -1,5 +1,24 @@ # @backstage/plugin-techdocs +## 1.10.5 + +### Patch Changes + +- d2cc139: Update path in Readme for Plugin Techdocs to show the correct setup information. +- 5863cf7: The `techdocs.builder` config is now optional and it will default to `local`. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/catalog-model@1.5.0 + - @backstage/plugin-auth-react@0.1.2 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/integration@1.11.0 + - @backstage/frontend-plugin-api@0.6.5 + - @backstage/integration-react@1.1.27 + - @backstage/plugin-search-react@1.7.11 + - @backstage/plugin-techdocs-react@1.2.4 + ## 1.10.5-next.2 ### Patch Changes diff --git a/plugins/techdocs/package.json b/plugins/techdocs/package.json index d75774cb10..bc9c4c8022 100644 --- a/plugins/techdocs/package.json +++ b/plugins/techdocs/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-techdocs", - "version": "1.10.5-next.2", + "version": "1.10.5", "description": "The Backstage plugin that renders technical documentation for your components", "backstage": { "role": "frontend-plugin" diff --git a/plugins/techdocs/src/reader/transformers/copyToClipboard.tsx b/plugins/techdocs/src/reader/transformers/copyToClipboard.tsx index 70868baa21..53f407586a 100644 --- a/plugins/techdocs/src/reader/transformers/copyToClipboard.tsx +++ b/plugins/techdocs/src/reader/transformers/copyToClipboard.tsx @@ -67,7 +67,7 @@ const CopyToClipboardButton = ({ text }: CopyToClipboardButtonProps) => { leaveDelay={1000} > diff --git a/plugins/techdocs/src/reader/transformers/styles/rules/variables.ts b/plugins/techdocs/src/reader/transformers/styles/rules/variables.ts index a858d17354..3999430efb 100644 --- a/plugins/techdocs/src/reader/transformers/styles/rules/variables.ts +++ b/plugins/techdocs/src/reader/transformers/styles/rules/variables.ts @@ -58,6 +58,9 @@ export default ({ theme }: RuleOptions) => ` /* ACCENT */ --md-accent-fg-color: var(--md-primary-fg-color); + --md-accent-fg-color--transparent: ${alpha(theme.palette.primary.main, 0.1)}; + --md-accent-bg-color: var(--md-primary-bg-color); + --md-accent-bg-color--light: var(--md-primary-bg-color--light); /* SHADOW */ --md-shadow-z1: ${theme.shadows[1]}; @@ -101,6 +104,7 @@ export default ({ theme }: RuleOptions) => ` --md-code-fg-color: ${theme.palette.text.primary}; --md-code-bg-color: ${theme.palette.background.paper}; --md-code-hl-color: ${alpha(theme.palette.warning.main, 0.5)}; + --md-code-hl-color--light: var(--md-code-hl-color); --md-code-hl-keyword-color: ${ theme.palette.type === 'dark' ? theme.palette.primary.light @@ -135,6 +139,7 @@ export default ({ theme }: RuleOptions) => ` --md-typeset-color: var(--md-default-fg-color); --md-typeset-a-color: ${theme.palette.link}; --md-typeset-table-color: ${theme.palette.text.primary}; + --md-typeset-table-color--light: ${alpha(theme.palette.text.primary, 0.5)}; --md-typeset-del-color: ${ theme.palette.type === 'dark' ? alpha(theme.palette.error.dark, 0.5) @@ -150,6 +155,9 @@ export default ({ theme }: RuleOptions) => ` ? alpha(theme.palette.warning.dark, 0.5) : alpha(theme.palette.warning.light, 0.5) }; + --md-typeset-kbd-color: var(--md-code-bg-color); + --md-typeset-kbd-accent-color var(--md-code-bg-color); + --md-typeset-kbd-border-color: var(--md-default-fg-color--light); } @media screen and (max-width: 76.1875em) { @@ -165,4 +173,7 @@ export default ({ theme }: RuleOptions) => ` --md-typeset-font-size: .7rem; } } + + --md-footer-bg-color: var(--md-default-bg-color); + --md-footer-bg-color--dark: var(--md-default-bg-color); `; diff --git a/plugins/techdocs/src/search/components/TechDocsSearch.tsx b/plugins/techdocs/src/search/components/TechDocsSearch.tsx index 665f99c1bb..ce77d547db 100644 --- a/plugins/techdocs/src/search/components/TechDocsSearch.tsx +++ b/plugins/techdocs/src/search/components/TechDocsSearch.tsx @@ -63,6 +63,7 @@ const TechDocsSearchBar = (props: TechDocsSearchProps) => { const navigate = useNavigate(); const { setFilters, + term, result: { loading, value: searchVal }, } = useSearch(); const [options, setOptions] = useState([]); @@ -109,7 +110,7 @@ const TechDocsSearchBar = (props: TechDocsSearchProps) => { ''} filterOptions={x => { return x; // This is needed to get renderOption to be called after options change. Bug in material-ui? @@ -117,7 +118,7 @@ const TechDocsSearchBar = (props: TechDocsSearchProps) => { onClose={() => { setOpen(false); }} - onFocus={() => { + onOpen={() => { setOpen(true); }} onChange={handleSelection} diff --git a/plugins/techdocs/src/search/components/TechDocsSearchResultListItem.test.tsx b/plugins/techdocs/src/search/components/TechDocsSearchResultListItem.test.tsx index 15444fca9e..9ba88a78ff 100644 --- a/plugins/techdocs/src/search/components/TechDocsSearchResultListItem.test.tsx +++ b/plugins/techdocs/src/search/components/TechDocsSearchResultListItem.test.tsx @@ -18,11 +18,6 @@ import React from 'react'; import { TechDocsSearchResultListItem } from './TechDocsSearchResultListItem'; import { renderInTestApp } from '@backstage/test-utils'; -// Using canvas to render text.. -jest.mock('react-text-truncate', () => { - return ({ text }: { text: string }) => {text}; -}); - const validResult = { location: 'https://backstage.io/docs', title: 'Documentation', diff --git a/plugins/user-settings-backend/CHANGELOG.md b/plugins/user-settings-backend/CHANGELOG.md index 57e3663d5f..f689d8090f 100644 --- a/plugins/user-settings-backend/CHANGELOG.md +++ b/plugins/user-settings-backend/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-user-settings-backend +## 0.2.17 + +### Patch Changes + +- d229dc4: Move path utilities from `backend-common` to the `backend-plugin-api` package. +- Updated dependencies + - @backstage/backend-common@0.22.0 + - @backstage/backend-plugin-api@0.6.18 + - @backstage/plugin-auth-node@0.4.13 + ## 0.2.17-next.1 ### Patch Changes diff --git a/plugins/user-settings-backend/package.json b/plugins/user-settings-backend/package.json index f8b46d8d3f..ac5e5d9af2 100644 --- a/plugins/user-settings-backend/package.json +++ b/plugins/user-settings-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-user-settings-backend", - "version": "0.2.17-next.1", + "version": "0.2.17", "description": "The Backstage backend plugin to manage user settings", "backstage": { "role": "backend-plugin" diff --git a/plugins/user-settings-backend/src/database/DatabaseUserSettingsStore.ts b/plugins/user-settings-backend/src/database/DatabaseUserSettingsStore.ts index b0fe8fdecc..99c4b2cff4 100644 --- a/plugins/user-settings-backend/src/database/DatabaseUserSettingsStore.ts +++ b/plugins/user-settings-backend/src/database/DatabaseUserSettingsStore.ts @@ -14,10 +14,8 @@ * limitations under the License. */ -import { - PluginDatabaseManager, - resolvePackagePath, -} from '@backstage/backend-common'; +import { PluginDatabaseManager } from '@backstage/backend-common'; +import { resolvePackagePath } from '@backstage/backend-plugin-api'; import { NotFoundError } from '@backstage/errors'; import { JsonValue } from '@backstage/types'; import { Knex } from 'knex'; diff --git a/plugins/user-settings/CHANGELOG.md b/plugins/user-settings/CHANGELOG.md index 01d7c1214c..85930ec041 100644 --- a/plugins/user-settings/CHANGELOG.md +++ b/plugins/user-settings/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-user-settings +## 0.8.6 + +### Patch Changes + +- 131e5cb: Fix broken links in README. +- Updated dependencies + - @backstage/core-compat-api@0.2.5 + - @backstage/core-components@0.14.7 + - @backstage/plugin-catalog-react@1.12.0 + - @backstage/theme@0.5.4 + - @backstage/core-app-api@1.12.5 + - @backstage/frontend-plugin-api@0.6.5 + ## 0.8.6-next.2 ### Patch Changes diff --git a/plugins/user-settings/README.md b/plugins/user-settings/README.md index 1ecaaeb536..41a6930ae3 100644 --- a/plugins/user-settings/README.md +++ b/plugins/user-settings/README.md @@ -8,8 +8,7 @@ This plugin provides two components, `` is intended to be used w It also provides a `UserSettingsStorage` implementation of the `StorageApi`, to be used in the frontend as a persistent alternative to the builtin `WebStorage`. -Please see [the backend -README](https://github.com/backstage/backstage/tree/master/plugins/user-settings-backend) +Please see [the backend README](https://github.com/backstage/backstage/tree/master/plugins/user-settings-backend) for installation instructions. ## Components Usage diff --git a/plugins/user-settings/package.json b/plugins/user-settings/package.json index 1af0b2fb41..b3f0f244c8 100644 --- a/plugins/user-settings/package.json +++ b/plugins/user-settings/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-user-settings", - "version": "0.8.6-next.2", + "version": "0.8.6", "description": "A Backstage plugin that provides a settings page", "backstage": { "role": "frontend-plugin" diff --git a/scripts/verify-links.js b/scripts/verify-links.js index 94ffc497cd..cb7385d972 100755 --- a/scripts/verify-links.js +++ b/scripts/verify-links.js @@ -137,6 +137,16 @@ async function verifyFile(filePath, docPages) { } } + const multiLineLinks = + content.match(/\[[^\]\n]+?\n[^\]\n]*?(?:\n[^\]\n]*?)?\]\(/g) || []; + badUrls.push( + ...multiLineLinks.map(url => ({ + url, + basePath: filePath, + problem: 'multi-line', + })), + ); + return badUrls; } @@ -226,7 +236,7 @@ async function main() { console.error(` From: ${basePath}`); console.error(` To: ${url}`); if (suggestion) { - console.error(` Replace With: ${suggestion}`); + console.error(` Replace with: ${suggestion}`); } } else if (problem === 'not-relative') { console.error('Links within /docs/ must be relative'); @@ -238,6 +248,10 @@ async function main() { ); console.error(` From: ${basePath}`); console.error(` To: ${url}`); + } else if (problem === 'multi-line') { + console.error(`Links are not allowed to span multiple lines:`); + console.error(` From: ${basePath}`); + console.error(` To: ${url.replace(/\n/g, '\n ')}`); } } process.exit(1); diff --git a/yarn.lock b/yarn.lock index 210a9996e0..a4cdabf15d 100644 --- a/yarn.lock +++ b/yarn.lock @@ -3330,6 +3330,7 @@ __metadata: selfsigned: ^2.0.0 stoppable: ^1.1.0 supertest: ^6.1.3 + triple-beam: ^1.4.1 uuid: ^9.0.0 winston: ^3.2.1 winston-transport: ^4.5.0 @@ -3506,8 +3507,11 @@ __metadata: resolution: "@backstage/backend-plugin-api@workspace:packages/backend-plugin-api" dependencies: "@backstage/backend-tasks": "workspace:^" + "@backstage/backend-test-utils": "workspace:^" "@backstage/cli": "workspace:^" + "@backstage/cli-common": "workspace:^" "@backstage/config": "workspace:^" + "@backstage/errors": "workspace:^" "@backstage/plugin-auth-node": "workspace:^" "@backstage/plugin-permission-common": "workspace:^" "@backstage/types": "workspace:^" @@ -3571,18 +3575,6 @@ __metadata: languageName: unknown linkType: soft -"@backstage/catalog-client@npm:^1.6.4": - version: 1.6.4 - resolution: "@backstage/catalog-client@npm:1.6.4" - dependencies: - "@backstage/catalog-model": ^1.4.5 - "@backstage/errors": ^1.2.4 - cross-fetch: ^4.0.0 - uri-template: ^2.0.0 - checksum: af3537d04f0abd6e6f3e49c7623994cc83db6efb2776fff5d59faee26c598840486e42a99c2bbb4a1b6ff97ad97ac857e913830cad62cda7cd71eef74cf2e179 - languageName: node - linkType: hard - "@backstage/catalog-client@workspace:^, @backstage/catalog-client@workspace:packages/catalog-client": version: 0.0.0-use.local resolution: "@backstage/catalog-client@workspace:packages/catalog-client" @@ -3596,19 +3588,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/catalog-model@npm:^1.4.3, @backstage/catalog-model@npm:^1.4.5": - version: 1.4.5 - resolution: "@backstage/catalog-model@npm:1.4.5" - dependencies: - "@backstage/errors": ^1.2.4 - "@backstage/types": ^1.1.1 - ajv: ^8.10.0 - lodash: ^4.17.21 - checksum: 34aaa4b82d29bf3b0a4b52552f8eb8189041df826f87a7bbdef5107a1efb8ce1f7eb1c1a343868718ca2af9be76d9f5184f6a92076d893d3a3951d16881647b7 - languageName: node - linkType: hard - -"@backstage/catalog-model@workspace:^, @backstage/catalog-model@workspace:packages/catalog-model": +"@backstage/catalog-model@^1.4.3, @backstage/catalog-model@^1.4.5, @backstage/catalog-model@workspace:^, @backstage/catalog-model@workspace:packages/catalog-model": version: 0.0.0-use.local resolution: "@backstage/catalog-model@workspace:packages/catalog-model" dependencies: @@ -3642,7 +3622,7 @@ __metadata: "@backstage/errors": "workspace:^" "@backstage/types": "workspace:^" "@manypkg/get-packages": ^1.1.3 - "@yarnpkg/parsers": ^3.0.0-rc.4 + "@yarnpkg/parsers": ^3.0.0 fs-extra: ^11.2.0 semver: ^7.5.3 zod: ^3.22.4 @@ -3716,7 +3696,7 @@ __metadata: "@typescript-eslint/parser": ^6.7.2 "@vitejs/plugin-react": ^4.0.4 "@yarnpkg/lockfile": ^1.1.0 - "@yarnpkg/parsers": ^3.0.0-rc.4 + "@yarnpkg/parsers": ^3.0.0 bfj: ^8.0.0 buffer: ^6.0.3 chalk: ^4.0.0 @@ -3860,7 +3840,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/config@^1.1.1, @backstage/config@^1.2.0, @backstage/config@workspace:^, @backstage/config@workspace:packages/config": +"@backstage/config@^1.1.1, @backstage/config@workspace:^, @backstage/config@workspace:packages/config": version: 0.0.0-use.local resolution: "@backstage/config@workspace:packages/config" dependencies: @@ -3932,6 +3912,77 @@ __metadata: languageName: unknown linkType: soft +"@backstage/core-components@^0.14.4, @backstage/core-components@workspace:^, @backstage/core-components@workspace:packages/core-components": + version: 0.0.0-use.local + resolution: "@backstage/core-components@workspace:packages/core-components" + dependencies: + "@backstage/app-defaults": "workspace:^" + "@backstage/cli": "workspace:^" + "@backstage/config": "workspace:^" + "@backstage/core-app-api": "workspace:^" + "@backstage/core-plugin-api": "workspace:^" + "@backstage/errors": "workspace:^" + "@backstage/test-utils": "workspace:^" + "@backstage/theme": "workspace:^" + "@backstage/version-bridge": "workspace:^" + "@date-io/core": ^1.3.13 + "@material-table/core": ^3.1.0 + "@material-ui/core": ^4.12.2 + "@material-ui/icons": ^4.9.1 + "@material-ui/lab": 4.0.0-alpha.61 + "@react-hookz/web": ^24.0.0 + "@testing-library/dom": ^10.0.0 + "@testing-library/jest-dom": ^6.0.0 + "@testing-library/react": ^15.0.0 + "@testing-library/user-event": ^14.0.0 + "@types/ansi-regex": ^5.0.0 + "@types/classnames": ^2.2.9 + "@types/d3-selection": ^3.0.1 + "@types/d3-shape": ^3.0.1 + "@types/d3-zoom": ^3.0.1 + "@types/dagre": ^0.7.44 + "@types/google-protobuf": ^3.7.2 + "@types/react": ^16.13.1 || ^17.0.0 || ^18.0.0 + "@types/react-helmet": ^6.1.0 + "@types/react-sparklines": ^1.7.0 + "@types/react-syntax-highlighter": ^15.0.0 + "@types/react-virtualized-auto-sizer": ^1.0.1 + "@types/react-window": ^1.8.5 + "@types/zen-observable": ^0.8.0 + ansi-regex: ^6.0.1 + classnames: ^2.2.6 + cross-fetch: ^4.0.0 + d3-selection: ^3.0.0 + d3-shape: ^3.0.0 + d3-zoom: ^3.0.0 + dagre: ^0.8.5 + history: ^5.0.0 + linkify-react: 4.1.3 + linkifyjs: 4.1.3 + lodash: ^4.17.21 + msw: ^1.0.0 + pluralize: ^8.0.0 + qs: ^6.9.4 + rc-progress: 3.5.1 + react-helmet: 6.1.0 + react-hook-form: ^7.12.2 + react-idle-timer: 5.7.2 + react-markdown: ^8.0.0 + react-sparklines: ^1.7.0 + react-syntax-highlighter: ^15.4.5 + react-use: ^17.3.2 + react-virtualized-auto-sizer: ^1.0.11 + react-window: ^1.8.6 + remark-gfm: ^3.0.1 + zen-observable: ^0.10.0 + zod: ^3.22.4 + peerDependencies: + react: ^16.13.1 || ^17.0.0 || ^18.0.0 + react-dom: ^16.13.1 || ^17.0.0 || ^18.0.0 + react-router-dom: 6.0.0-beta.0 || ^6.3.0 + languageName: unknown + linkType: soft + "@backstage/core-components@npm:^0.13.10": version: 0.13.10 resolution: "@backstage/core-components@npm:0.13.10" @@ -3983,130 +4034,6 @@ __metadata: languageName: node linkType: hard -"@backstage/core-components@npm:^0.14.4": - version: 0.14.4 - resolution: "@backstage/core-components@npm:0.14.4" - dependencies: - "@backstage/config": ^1.2.0 - "@backstage/core-plugin-api": ^1.9.2 - "@backstage/errors": ^1.2.4 - "@backstage/theme": ^0.5.3 - "@backstage/version-bridge": ^1.0.8 - "@date-io/core": ^1.3.13 - "@material-table/core": ^3.1.0 - "@material-ui/core": ^4.12.2 - "@material-ui/icons": ^4.9.1 - "@material-ui/lab": 4.0.0-alpha.61 - "@react-hookz/web": ^24.0.0 - "@types/react": ^16.13.1 || ^17.0.0 || ^18.0.0 - "@types/react-sparklines": ^1.7.0 - "@types/react-text-truncate": ^0.14.0 - ansi-regex: ^6.0.1 - classnames: ^2.2.6 - d3-selection: ^3.0.0 - d3-shape: ^3.0.0 - d3-zoom: ^3.0.0 - dagre: ^0.8.5 - linkify-react: 4.1.3 - linkifyjs: 4.1.3 - lodash: ^4.17.21 - pluralize: ^8.0.0 - qs: ^6.9.4 - rc-progress: 3.5.1 - react-helmet: 6.1.0 - react-hook-form: ^7.12.2 - react-idle-timer: 5.7.2 - react-markdown: ^8.0.0 - react-sparklines: ^1.7.0 - react-syntax-highlighter: ^15.4.5 - react-text-truncate: ^0.19.0 - react-use: ^17.3.2 - react-virtualized-auto-sizer: ^1.0.11 - react-window: ^1.8.6 - remark-gfm: ^3.0.1 - zen-observable: ^0.10.0 - zod: ^3.22.4 - peerDependencies: - react: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-dom: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - checksum: b96721b267daeec5a73a8b487f96ab5b5b3a85b8b113b2e45c5b733f3201af0d5cda3d7a325f5f68a4057ccbe78beac9f239b51ceb3099d3b0001709ec16928b - languageName: node - linkType: hard - -"@backstage/core-components@workspace:^, @backstage/core-components@workspace:packages/core-components": - version: 0.0.0-use.local - resolution: "@backstage/core-components@workspace:packages/core-components" - dependencies: - "@backstage/app-defaults": "workspace:^" - "@backstage/cli": "workspace:^" - "@backstage/config": "workspace:^" - "@backstage/core-app-api": "workspace:^" - "@backstage/core-plugin-api": "workspace:^" - "@backstage/errors": "workspace:^" - "@backstage/test-utils": "workspace:^" - "@backstage/theme": "workspace:^" - "@backstage/version-bridge": "workspace:^" - "@date-io/core": ^1.3.13 - "@material-table/core": ^3.1.0 - "@material-ui/core": ^4.12.2 - "@material-ui/icons": ^4.9.1 - "@material-ui/lab": 4.0.0-alpha.61 - "@react-hookz/web": ^24.0.0 - "@testing-library/dom": ^10.0.0 - "@testing-library/jest-dom": ^6.0.0 - "@testing-library/react": ^15.0.0 - "@testing-library/user-event": ^14.0.0 - "@types/ansi-regex": ^5.0.0 - "@types/classnames": ^2.2.9 - "@types/d3-selection": ^3.0.1 - "@types/d3-shape": ^3.0.1 - "@types/d3-zoom": ^3.0.1 - "@types/dagre": ^0.7.44 - "@types/google-protobuf": ^3.7.2 - "@types/react": ^16.13.1 || ^17.0.0 || ^18.0.0 - "@types/react-helmet": ^6.1.0 - "@types/react-sparklines": ^1.7.0 - "@types/react-syntax-highlighter": ^15.0.0 - "@types/react-text-truncate": ^0.14.0 - "@types/react-virtualized-auto-sizer": ^1.0.1 - "@types/react-window": ^1.8.5 - "@types/zen-observable": ^0.8.0 - ansi-regex: ^6.0.1 - classnames: ^2.2.6 - cross-fetch: ^4.0.0 - d3-selection: ^3.0.0 - d3-shape: ^3.0.0 - d3-zoom: ^3.0.0 - dagre: ^0.8.5 - history: ^5.0.0 - linkify-react: 4.1.3 - linkifyjs: 4.1.3 - lodash: ^4.17.21 - msw: ^1.0.0 - pluralize: ^8.0.0 - qs: ^6.9.4 - rc-progress: 3.5.1 - react-helmet: 6.1.0 - react-hook-form: ^7.12.2 - react-idle-timer: 5.7.2 - react-markdown: ^8.0.0 - react-sparklines: ^1.7.0 - react-syntax-highlighter: ^15.4.5 - react-text-truncate: ^0.19.0 - react-use: ^17.3.2 - react-virtualized-auto-sizer: ^1.0.11 - react-window: ^1.8.6 - remark-gfm: ^3.0.1 - zen-observable: ^0.10.0 - zod: ^3.22.4 - peerDependencies: - react: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-dom: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - languageName: unknown - linkType: soft - "@backstage/core-plugin-api@^1.8.2, @backstage/core-plugin-api@^1.9.2, @backstage/core-plugin-api@workspace:^, @backstage/core-plugin-api@workspace:packages/core-plugin-api": version: 0.0.0-use.local resolution: "@backstage/core-plugin-api@workspace:packages/core-plugin-api" @@ -4254,26 +4181,6 @@ __metadata: languageName: unknown linkType: soft -"@backstage/frontend-plugin-api@npm:^0.6.4": - version: 0.6.4 - resolution: "@backstage/frontend-plugin-api@npm:0.6.4" - dependencies: - "@backstage/core-components": ^0.14.4 - "@backstage/core-plugin-api": ^1.9.2 - "@backstage/types": ^1.1.1 - "@backstage/version-bridge": ^1.0.8 - "@material-ui/core": ^4.12.4 - "@types/react": ^16.13.1 || ^17.0.0 || ^18.0.0 - lodash: ^4.17.21 - zod: ^3.22.4 - zod-to-json-schema: ^3.21.4 - peerDependencies: - react: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - checksum: 2ae2919147dcfd8a5b4379059ecb76461a27f38159c398915384db7a7396bc65451cf696d955e4ba23eb6dfb549395624d09412d0c9c776072d3f003e5f1cba8 - languageName: node - linkType: hard - "@backstage/frontend-plugin-api@workspace:^, @backstage/frontend-plugin-api@workspace:packages/frontend-plugin-api": version: 0.0.0-use.local resolution: "@backstage/frontend-plugin-api@workspace:packages/frontend-plugin-api" @@ -4337,24 +4244,6 @@ __metadata: languageName: unknown linkType: soft -"@backstage/integration-react@npm:^1.1.26": - version: 1.1.26 - resolution: "@backstage/integration-react@npm:1.1.26" - dependencies: - "@backstage/config": ^1.2.0 - "@backstage/core-plugin-api": ^1.9.2 - "@backstage/integration": ^1.10.0 - "@material-ui/core": ^4.12.2 - "@material-ui/icons": ^4.9.1 - "@types/react": ^16.13.1 || ^17.0.0 - peerDependencies: - react: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-dom: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - checksum: 590e8293a0e21a034126c1a00c1c69c66bba81dcbf39675336c092b250ee139effe874e443a99521751b3c1aa9b103603bc8a3177a9f115ff0f1a0249ac5eed6 - languageName: node - linkType: hard - "@backstage/integration-react@workspace:^, @backstage/integration-react@workspace:packages/integration-react": version: 0.0.0-use.local resolution: "@backstage/integration-react@workspace:packages/integration-react" @@ -4379,23 +4268,6 @@ __metadata: languageName: unknown linkType: soft -"@backstage/integration@npm:^1.10.0": - version: 1.10.0 - resolution: "@backstage/integration@npm:1.10.0" - dependencies: - "@azure/identity": ^4.0.0 - "@backstage/config": ^1.2.0 - "@backstage/errors": ^1.2.4 - "@octokit/auth-app": ^4.0.0 - "@octokit/rest": ^19.0.3 - cross-fetch: ^4.0.0 - git-url-parse: ^14.0.0 - lodash: ^4.17.21 - luxon: ^3.0.0 - checksum: 86324df95b30ff6ae92fcc605bd21d0f12cdc0553d555ebe8977a1be6554819ad8723eabcd99d1574c7c244b4822a6628d01273557040c89360394ba3198f6b9 - languageName: node - linkType: hard - "@backstage/integration@workspace:^, @backstage/integration@workspace:packages/integration": version: 0.0.0-use.local resolution: "@backstage/integration@workspace:packages/integration" @@ -4984,7 +4856,7 @@ __metadata: "@openapitools/openapi-generator-cli": ^2.4.26 cross-fetch: ^4.0.0 msw: ^1.0.0 - ts-morph: ^21.0.0 + ts-morph: ^22.0.0 languageName: unknown linkType: soft @@ -5269,6 +5141,7 @@ __metadata: version: 0.0.0-use.local resolution: "@backstage/plugin-catalog-backend-module-ldap@workspace:plugins/catalog-backend-module-ldap" dependencies: + "@backstage/backend-plugin-api": "workspace:^" "@backstage/backend-tasks": "workspace:^" "@backstage/catalog-model": "workspace:^" "@backstage/cli": "workspace:^" @@ -5282,7 +5155,6 @@ __metadata: ldapjs: ^2.3.3 lodash: ^4.17.21 uuid: ^9.0.0 - winston: ^3.2.1 languageName: unknown linkType: soft @@ -5448,18 +5320,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/plugin-catalog-common@npm:^1.0.20, @backstage/plugin-catalog-common@npm:^1.0.22": - version: 1.0.22 - resolution: "@backstage/plugin-catalog-common@npm:1.0.22" - dependencies: - "@backstage/catalog-model": ^1.4.5 - "@backstage/plugin-permission-common": ^0.7.13 - "@backstage/plugin-search-common": ^1.2.11 - checksum: f468ade184d5e535cc27cbb27a9dbd6cd21c1601b5a84167d2ea1004f471180ef8bf148df5561b5557c332bdc01480d020e93f62915f029cc728802cebf8e255 - languageName: node - linkType: hard - -"@backstage/plugin-catalog-common@workspace:^, @backstage/plugin-catalog-common@workspace:plugins/catalog-common": +"@backstage/plugin-catalog-common@^1.0.20, @backstage/plugin-catalog-common@workspace:^, @backstage/plugin-catalog-common@workspace:plugins/catalog-common": version: 0.0.0-use.local resolution: "@backstage/plugin-catalog-common@workspace:plugins/catalog-common" dependencies: @@ -5524,6 +5385,7 @@ __metadata: "@backstage/frontend-plugin-api": "workspace:^" "@backstage/integration": "workspace:^" "@backstage/integration-react": "workspace:^" + "@backstage/plugin-catalog": "workspace:^" "@backstage/plugin-catalog-common": "workspace:^" "@backstage/plugin-catalog-react": "workspace:^" "@backstage/test-utils": "workspace:^" @@ -5567,43 +5429,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/plugin-catalog-react@npm:^1.11.3, @backstage/plugin-catalog-react@npm:^1.9.3": - version: 1.11.3 - resolution: "@backstage/plugin-catalog-react@npm:1.11.3" - dependencies: - "@backstage/catalog-client": ^1.6.4 - "@backstage/catalog-model": ^1.4.5 - "@backstage/core-components": ^0.14.4 - "@backstage/core-plugin-api": ^1.9.2 - "@backstage/errors": ^1.2.4 - "@backstage/frontend-plugin-api": ^0.6.4 - "@backstage/integration-react": ^1.1.26 - "@backstage/plugin-catalog-common": ^1.0.22 - "@backstage/plugin-permission-common": ^0.7.13 - "@backstage/plugin-permission-react": ^0.4.22 - "@backstage/types": ^1.1.1 - "@backstage/version-bridge": ^1.0.8 - "@material-ui/core": ^4.12.2 - "@material-ui/icons": ^4.9.1 - "@material-ui/lab": 4.0.0-alpha.61 - "@react-hookz/web": ^24.0.0 - "@types/react": ^16.13.1 || ^17.0.0 || ^18.0.0 - classnames: ^2.2.6 - lodash: ^4.17.21 - material-ui-popup-state: ^1.9.3 - qs: ^6.9.4 - react-use: ^17.2.4 - yaml: ^2.0.0 - zen-observable: ^0.10.0 - peerDependencies: - react: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-dom: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-router-dom: 6.0.0-beta.0 || ^6.3.0 - checksum: d04919bff692094bb145d8479aae47368911f3adc92644b4742e5db1296af9a2673cf4341995b9c65e660cd608d3b59a136b9c164ab2df51bdc3ccbaf5af71fd - languageName: node - linkType: hard - -"@backstage/plugin-catalog-react@workspace:^, @backstage/plugin-catalog-react@workspace:plugins/catalog-react": +"@backstage/plugin-catalog-react@^1.11.3, @backstage/plugin-catalog-react@^1.9.3, @backstage/plugin-catalog-react@workspace:^, @backstage/plugin-catalog-react@workspace:plugins/catalog-react": version: 0.0.0-use.local resolution: "@backstage/plugin-catalog-react@workspace:plugins/catalog-react" dependencies: @@ -5779,7 +5605,7 @@ __metadata: "@types/supertest": ^2.0.8 "@types/yarnpkg__lockfile": ^1.1.4 "@yarnpkg/lockfile": ^1.1.0 - "@yarnpkg/parsers": ^3.0.0-rc.4 + "@yarnpkg/parsers": ^3.0.0 express: ^4.18.1 express-promise-router: ^4.1.0 fs-extra: ^11.0.0 @@ -6443,7 +6269,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/plugin-permission-common@^0.7.13, @backstage/plugin-permission-common@workspace:^, @backstage/plugin-permission-common@workspace:plugins/permission-common": +"@backstage/plugin-permission-common@workspace:^, @backstage/plugin-permission-common@workspace:plugins/permission-common": version: 0.0.0-use.local resolution: "@backstage/plugin-permission-common@workspace:plugins/permission-common" dependencies: @@ -6481,7 +6307,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/plugin-permission-react@^0.4.22, @backstage/plugin-permission-react@workspace:^, @backstage/plugin-permission-react@workspace:plugins/permission-react": +"@backstage/plugin-permission-react@workspace:^, @backstage/plugin-permission-react@workspace:plugins/permission-react": version: 0.0.0-use.local resolution: "@backstage/plugin-permission-react@workspace:plugins/permission-react" dependencies: @@ -6861,6 +6687,7 @@ __metadata: strip-ansi: ^7.1.0 supertest: ^6.1.3 tar: ^6.1.12 + triple-beam: ^1.4.1 uuid: ^9.0.0 wait-for-expect: ^3.0.2 winston: ^3.2.1 @@ -6911,6 +6738,7 @@ __metadata: "@backstage/types": "workspace:^" fs-extra: ^11.2.0 globby: ^11.0.0 + isomorphic-git: ^1.23.0 jsonschema: ^1.2.6 p-limit: ^3.1.0 winston: ^3.2.1 @@ -7219,7 +7047,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/plugin-search-common@^1.2.11, @backstage/plugin-search-common@workspace:^, @backstage/plugin-search-common@workspace:plugins/search-common": +"@backstage/plugin-search-common@workspace:^, @backstage/plugin-search-common@workspace:plugins/search-common": version: 0.0.0-use.local resolution: "@backstage/plugin-search-common@workspace:plugins/search-common" dependencies: @@ -7676,7 +7504,7 @@ __metadata: dependencies: "@apidevtools/swagger-parser": ^10.1.0 "@apisyouwonthate/style-guide": ^1.4.0 - "@backstage/backend-common": "workspace:^" + "@backstage/backend-plugin-api": "workspace:^" "@backstage/backend-test-utils": "workspace:^" "@backstage/catalog-model": "workspace:^" "@backstage/cli": "workspace:^" @@ -7756,23 +7584,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/theme@npm:^0.5.0, @backstage/theme@npm:^0.5.3": - version: 0.5.3 - resolution: "@backstage/theme@npm:0.5.3" - dependencies: - "@emotion/react": ^11.10.5 - "@emotion/styled": ^11.10.5 - "@mui/material": ^5.12.2 - peerDependencies: - "@material-ui/core": ^4.12.2 - "@types/react": ^16.13.1 || ^17.0.0 || ^18.0.0 - react: ^16.13.1 || ^17.0.0 || ^18.0.0 - react-dom: ^16.13.1 || ^17.0.0 || ^18.0.0 - checksum: ac6c3bbd73294385f73aa91e04f8bf3a1bb78cadc0e43034760ebf19e86814ed2d679f2641bb086aa9e305a24d923d8c3480b2de3bff55189c19bc5dfdce1814 - languageName: node - linkType: hard - -"@backstage/theme@workspace:^, @backstage/theme@workspace:packages/theme": +"@backstage/theme@^0.5.0, @backstage/theme@workspace:^, @backstage/theme@workspace:packages/theme": version: 0.0.0-use.local resolution: "@backstage/theme@workspace:packages/theme" dependencies: @@ -7803,7 +7615,7 @@ __metadata: languageName: unknown linkType: soft -"@backstage/version-bridge@^1.0.7, @backstage/version-bridge@^1.0.8, @backstage/version-bridge@workspace:^, @backstage/version-bridge@workspace:packages/version-bridge": +"@backstage/version-bridge@^1.0.7, @backstage/version-bridge@workspace:^, @backstage/version-bridge@workspace:packages/version-bridge": version: 0.0.0-use.local resolution: "@backstage/version-bridge@workspace:packages/version-bridge" dependencies: @@ -13344,14 +13156,12 @@ __metadata: linkType: hard "@pmmmwh/react-refresh-webpack-plugin@npm:^0.5.7": - version: 0.5.11 - resolution: "@pmmmwh/react-refresh-webpack-plugin@npm:0.5.11" + version: 0.5.13 + resolution: "@pmmmwh/react-refresh-webpack-plugin@npm:0.5.13" dependencies: ansi-html-community: ^0.0.8 - common-path-prefix: ^3.0.0 core-js-pure: ^3.23.3 error-stack-parser: ^2.0.6 - find-up: ^5.0.0 html-entities: ^2.1.0 loader-utils: ^2.0.4 schema-utils: ^3.0.0 @@ -13362,7 +13172,7 @@ __metadata: sockjs-client: ^1.4.0 type-fest: ">=0.17.0 <5.0.0" webpack: ">=4.43.0 <6.0.0" - webpack-dev-server: 3.x || 4.x + webpack-dev-server: 3.x || 4.x || 5.x webpack-hot-middleware: 2.x webpack-plugin-serve: 0.x || 1.x peerDependenciesMeta: @@ -13378,7 +13188,7 @@ __metadata: optional: true webpack-plugin-serve: optional: true - checksum: a82eced9519f4dcac424acae719f819ab4150bfcf2874ac7daaf25a4f1c409e3d8b9d693fea0c686c24d520a5473756df32da90d8b89739670f8f8084c600bb4 + checksum: 9f931cf79945f58ee31569b83f4b294ae0849ea8232b6c79e690b46a3d7f2b981aa72718a4bd7517ab82657dddfed2a691c9d9e37295a87dfd0b18b2693d4aa6 languageName: node linkType: hard @@ -16654,15 +16464,15 @@ __metadata: languageName: node linkType: hard -"@ts-morph/common@npm:~0.22.0": - version: 0.22.0 - resolution: "@ts-morph/common@npm:0.22.0" +"@ts-morph/common@npm:~0.23.0": + version: 0.23.0 + resolution: "@ts-morph/common@npm:0.23.0" dependencies: fast-glob: ^3.3.2 minimatch: ^9.0.3 mkdirp: ^3.0.1 path-browserify: ^1.0.1 - checksum: e549facfff2a68eeef4e3e2c4183e7216a02b57e62cdfe60ca15d5fdee24770bd3b5b6d1a0388cfce7b4dfaeb0ebe31ffa40585e36b9fb7948aea8081fa73769 + checksum: 96463742ec1114900901ded8aecc2c9664b20119454a56c896042e6a5e5b153af1d986467362d737ed0130506aeac9655731922dc8c4e851a16f9c1a8a8099b4 languageName: node linkType: hard @@ -17925,13 +17735,13 @@ __metadata: linkType: hard "@types/passport-oauth2@npm:*, @types/passport-oauth2@npm:^1.4.11, @types/passport-oauth2@npm:^1.4.15": - version: 1.4.15 - resolution: "@types/passport-oauth2@npm:1.4.15" + version: 1.4.16 + resolution: "@types/passport-oauth2@npm:1.4.16" dependencies: "@types/express": "*" "@types/oauth": "*" "@types/passport": "*" - checksum: 352c4e2d09a86f8fc0dcf2c917c221f302a35a14e7467e2fa3a1653c0a9a1f842c910a4e52f799856536522e6359c20d1afc319579d9edf4b2ac7ea11b183b52 + checksum: a590d3fcdf93dbe4498c636de139dc22a723bbf12a7f248f432085a47ec1b76b2e1201336ee26cd65c400d7ce6fb30ae0b151f40067267942c8a5b3c708cc23d languageName: node linkType: hard @@ -18905,13 +18715,13 @@ __metadata: languageName: node linkType: hard -"@useoptic/json-pointer-helpers@npm:0.54.8": - version: 0.54.8 - resolution: "@useoptic/json-pointer-helpers@npm:0.54.8" +"@useoptic/json-pointer-helpers@npm:0.54.13": + version: 0.54.13 + resolution: "@useoptic/json-pointer-helpers@npm:0.54.13" dependencies: jsonpointer: ^5.0.1 minimatch: 9.0.3 - checksum: 4eddabb6dce3ca8160dcd4904299b6964945c3fe47d39bfeca6c68b9a50b058b901a6fb10ab168295475d651df3349149faa5f27f77293e15b6eee8d4417432e + checksum: ad987e9bbec82606bd5995f4ffea7eb708549573e8a94a201ed266e4efc854423804671c3772be714457c417641da69d6689a1e61164bd0cfb8f83a1561facdb languageName: node linkType: hard @@ -18970,10 +18780,10 @@ __metadata: linkType: hard "@useoptic/openapi-utilities@npm:^0.54.8": - version: 0.54.8 - resolution: "@useoptic/openapi-utilities@npm:0.54.8" + version: 0.54.13 + resolution: "@useoptic/openapi-utilities@npm:0.54.13" dependencies: - "@useoptic/json-pointer-helpers": 0.54.8 + "@useoptic/json-pointer-helpers": 0.54.13 ajv: ^8.6.0 ajv-errors: ~3.0.0 ajv-formats: ~2.1.0 @@ -18990,7 +18800,7 @@ __metadata: ts-invariant: ^0.9.3 url-join: ^4.0.1 yaml-ast-parser: ^0.0.43 - checksum: fa9e9f430c77687591aaf8b43b7b31a7c2f80fe9c140aaa978f1948f84d3e974181c91c3d8ec3e06efca9735c7826290baf4be72063bf733887aa632b40c3c4a + checksum: d02eabba96af29632557cdb5532edcc4a629860471fe6cd02990c54ad8014c980d07e3dde8d04ed644a0bd3c2218a93fc50fe9904ee317ef6189b2db41bc7505 languageName: node linkType: hard @@ -19332,13 +19142,13 @@ __metadata: languageName: node linkType: hard -"@yarnpkg/parsers@npm:^3.0.0-rc.4": - version: 3.0.0-rc.21 - resolution: "@yarnpkg/parsers@npm:3.0.0-rc.21" +"@yarnpkg/parsers@npm:^3.0.0": + version: 3.0.0 + resolution: "@yarnpkg/parsers@npm:3.0.0" dependencies: js-yaml: ^3.10.0 tslib: ^2.4.0 - checksum: c0741ef01089a7d452dfb75b8c24a82ddcc3e218dac22b794a06f2e50c7070378c460f63f63fb7ed0f62f634114e448e3d85a75ccd4db84e1526242ae9b4a7d5 + checksum: fefe5ecafb5bfa2b678ac9ba9259810fdda40142afd9d0b7e0e5cc1cce1fd824dffc52217c5e429807481d8fd18ead074bd317e64fd626335d3c9f1a320bade2 languageName: node linkType: hard @@ -21992,10 +21802,10 @@ __metadata: languageName: node linkType: hard -"code-block-writer@npm:^12.0.0": - version: 12.0.0 - resolution: "code-block-writer@npm:12.0.0" - checksum: 9f6505a4d668c9131c6f3f686359079439e66d5f50c236614d52fcfa53aeb0bc615b2c6c64ef05b5511e3b0433ccfd9f7756ad40eb3b9298af6a7d791ab1981d +"code-block-writer@npm:^13.0.1": + version: 13.0.1 + resolution: "code-block-writer@npm:13.0.1" + checksum: 678b740d1723c7cc3c5addcbc1a91d9a7a3f033510eb8e0639154fcaae456c80630dbd40d16aefdffaf3edb5ffb352d7d46f195f69c8be692c4d7debb1dc7933 languageName: node linkType: hard @@ -22260,13 +22070,6 @@ __metadata: languageName: node linkType: hard -"common-path-prefix@npm:^3.0.0": - version: 3.0.0 - resolution: "common-path-prefix@npm:3.0.0" - checksum: fdb3c4f54e51e70d417ccd950c07f757582de800c0678ca388aedefefc84982039f346f9fd9a1252d08d2da9e9ef4019f580a1d1d3a10da031e4bb3c924c5818 - languageName: node - linkType: hard - "common-tags@npm:^1.8.0": version: 1.8.2 resolution: "common-tags@npm:1.8.2" @@ -41685,10 +41488,10 @@ __metadata: languageName: node linkType: hard -"triple-beam@npm:^1.3.0": - version: 1.3.0 - resolution: "triple-beam@npm:1.3.0" - checksum: 7d7b77d8625fb252c126c24984a68de462b538a8fcd1de2abd0a26421629cf3527d48e23b3c2264f08f4a6c3bc40a478a722176f4d7b6a1acc154cb70c359f2b +"triple-beam@npm:^1.3.0, triple-beam@npm:^1.4.1": + version: 1.4.1 + resolution: "triple-beam@npm:1.4.1" + checksum: 2e881a3e8e076b6f2b85b9ec9dd4a900d3f5016e6d21183ed98e78f9abcc0149e7d54d79a3f432b23afde46b0885bdcdcbff789f39bc75de796316961ec07f61 languageName: node linkType: hard @@ -41759,13 +41562,13 @@ __metadata: languageName: node linkType: hard -"ts-morph@npm:^21.0.0": - version: 21.0.1 - resolution: "ts-morph@npm:21.0.1" +"ts-morph@npm:^22.0.0": + version: 22.0.0 + resolution: "ts-morph@npm:22.0.0" dependencies: - "@ts-morph/common": ~0.22.0 - code-block-writer: ^12.0.0 - checksum: f8e6acd4cdb2842af47ccf4e8900dc3f230f20c3b0d28e1e8b58c395b0a16d7b3e03ef56f29da3fdb861c50e22eb52524e0fc4bfca0fde8448f81b8f4f6aa157 + "@ts-morph/common": ~0.23.0 + code-block-writer: ^13.0.1 + checksum: 7bf0ec8cc9ab2a4ce528ec249634db315caa01b5783259484fd91ac0dae2f05b94d9c53ba236939fad2b8ab882e7fce1c82a689ab7c9a4a9dcec5c1160d77264 languageName: node linkType: hard