diff --git a/.changeset/create-app-1696937840.md b/.changeset/create-app-1696937840.md new file mode 100644 index 0000000000..b50d431d4b --- /dev/null +++ b/.changeset/create-app-1696937840.md @@ -0,0 +1,5 @@ +--- +'@backstage/create-app': patch +--- + +Bumped create-app version. diff --git a/.changeset/dirty-doors-wave.md b/.changeset/dirty-doors-wave.md new file mode 100644 index 0000000000..aad6e8f414 --- /dev/null +++ b/.changeset/dirty-doors-wave.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-scaffolder-backend': patch +--- + +Add examples for `github:issues:label` scaffolder action & improve related tests diff --git a/.changeset/eleven-hounds-invent.md b/.changeset/eleven-hounds-invent.md new file mode 100644 index 0000000000..ba863ebc28 --- /dev/null +++ b/.changeset/eleven-hounds-invent.md @@ -0,0 +1,5 @@ +--- +'@backstage/cli': patch +--- + +In frontend builds and tests `process.env.HAS_REACT_DOM_CLIENT` will now be defined if `react-dom/client` is present, i.e. if using React 18. This allows for conditional imports of `react-dom/client`. diff --git a/.changeset/empty-clocks-argue.md b/.changeset/empty-clocks-argue.md new file mode 100644 index 0000000000..e3c5985f8a --- /dev/null +++ b/.changeset/empty-clocks-argue.md @@ -0,0 +1,5 @@ +--- +'@backstage/core-app-api': patch +--- + +Fixed bug in `AppRouter` to determine the correct `signOutTargetUrl` if `app.baseUrl` contains a `basePath` diff --git a/.changeset/five-hornets-provide.md b/.changeset/five-hornets-provide.md new file mode 100644 index 0000000000..a422c5fbc8 --- /dev/null +++ b/.changeset/five-hornets-provide.md @@ -0,0 +1,5 @@ +--- +'@backstage/frontend-app-api': patch +--- + +The app will now reject any extensions that attach to nonexistent inputs. diff --git a/.changeset/healthy-shirts-fold.md b/.changeset/healthy-shirts-fold.md new file mode 100644 index 0000000000..f2ac0a9e83 --- /dev/null +++ b/.changeset/healthy-shirts-fold.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-catalog': patch +'@backstage/plugin-techdocs': patch +--- + +The `spec.lifecycle' field in entities will now always be rendered as a string. diff --git a/.changeset/heavy-plants-doubt.md b/.changeset/heavy-plants-doubt.md new file mode 100644 index 0000000000..3988a16752 --- /dev/null +++ b/.changeset/heavy-plants-doubt.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-user-settings': patch +--- + +Added experimental support for declarative integration via the `/alpha` subpath. diff --git a/.changeset/hungry-coats-judge.md b/.changeset/hungry-coats-judge.md new file mode 100644 index 0000000000..7e5b634237 --- /dev/null +++ b/.changeset/hungry-coats-judge.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-scaffolder': patch +--- + +Preserve time execution for a non-running task diff --git a/.changeset/itchy-rabbits-exist.md b/.changeset/itchy-rabbits-exist.md index acac771a97..6a16ac5648 100644 --- a/.changeset/itchy-rabbits-exist.md +++ b/.changeset/itchy-rabbits-exist.md @@ -2,6 +2,6 @@ '@backstage/cli': minor --- -The new backend start command that used to be enabled by setting `EXPERIMENTAL_BACKEND_START` is now the default. To revert to the old behavior, set `LEGACY_BACKEND_START` instead. +**BREAKING** The new backend start command that used to be enabled by setting `EXPERIMENTAL_BACKEND_START` is now the default. To revert to the old behavior set `LEGACY_BACKEND_START`, which is recommended if you haven't migrated to the new backend system. This new command is no longer based on Webpack, but instead uses Node.js loaders to transpile on the fly. Rather than hot reloading modules the entire backend is now restarted on change, but the SQLite database state is still maintained across restarts via a parent process. diff --git a/.changeset/khaki-tools-tease.md b/.changeset/khaki-tools-tease.md new file mode 100644 index 0000000000..e4383c9e33 --- /dev/null +++ b/.changeset/khaki-tools-tease.md @@ -0,0 +1,11 @@ +--- +'@backstage/plugin-scaffolder-backend': minor +--- + +Updated `publish:gitlab` action properties to support additional Gitlab project settings: + +- general project settings provided by gitlab project create API (new `settings` property) +- branch level settings to create additional branches and make them protected (new `branches` property) +- project level environment variables settings (new `projectVariables` property) + +Marked existed properties `repoVisibility` and `topics` as deprecated, as they are covered by `settings` property. diff --git a/.changeset/large-balloons-brush.md b/.changeset/large-balloons-brush.md new file mode 100644 index 0000000000..0dcada12bf --- /dev/null +++ b/.changeset/large-balloons-brush.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-auth-node': minor +--- + +**BREAKING**: The recently introduced `ProxyAuthenticator.initialize()` method is no longer `async` to match the way the OAuth equivalent is implemented. diff --git a/.changeset/light-squids-deny.md b/.changeset/light-squids-deny.md new file mode 100644 index 0000000000..07a124bed3 --- /dev/null +++ b/.changeset/light-squids-deny.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-catalog-graphql': minor +'@backstage/plugin-graphql-backend': minor +--- + +This package has been deprecated, consider using [@frontside/backstage-plugin-graphql-backend](https://www.npmjs.com/package/@frontside/backstage-plugin-graphql-backend) instead. diff --git a/.changeset/little-ligers-cheat.md b/.changeset/little-ligers-cheat.md new file mode 100644 index 0000000000..30b4238c59 --- /dev/null +++ b/.changeset/little-ligers-cheat.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-scaffolder': patch +--- + +Make entity picker more reliable with only one available entity diff --git a/.changeset/long-owls-complain.md b/.changeset/long-owls-complain.md new file mode 100644 index 0000000000..f96b0f0987 --- /dev/null +++ b/.changeset/long-owls-complain.md @@ -0,0 +1,5 @@ +--- +'@backstage/frontend-app-api': patch +--- + +Fixed an issue preventing the routing system to match subroutes diff --git a/.changeset/many-impalas-wait.md b/.changeset/many-impalas-wait.md new file mode 100644 index 0000000000..843adf66a1 --- /dev/null +++ b/.changeset/many-impalas-wait.md @@ -0,0 +1,5 @@ +--- +'@backstage/frontend-plugin-api': patch +--- + +Plugins can now be assigned `routes` and `externalRoutes` when created. diff --git a/.changeset/modern-owls-mate.md b/.changeset/modern-owls-mate.md new file mode 100644 index 0000000000..bed33c6bbc --- /dev/null +++ b/.changeset/modern-owls-mate.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-techdocs': minor +--- + +Added experimental support for declarative integration via the `/alpha` subpath. diff --git a/.changeset/nice-ghosts-build.md b/.changeset/nice-ghosts-build.md new file mode 100644 index 0000000000..abdad08c3b --- /dev/null +++ b/.changeset/nice-ghosts-build.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-kubernetes-node': minor +'@backstage/plugin-kubernetes-backend': patch +--- + +A new plugin has been introduced to house the extension points for Kubernetes backend plugin; at the moment only the `KubernetesObjectsProviderExtensionPoint` is present. The `kubernetes-backend` plugin was modified to use this new extension point. diff --git a/.changeset/olive-geese-rest.md b/.changeset/olive-geese-rest.md new file mode 100644 index 0000000000..547fb828d8 --- /dev/null +++ b/.changeset/olive-geese-rest.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-jenkins-backend': patch +--- + +Added support for the [new backend system](https://backstage.io/docs/backend-system/) diff --git a/.changeset/olive-islands-sneeze.md b/.changeset/olive-islands-sneeze.md new file mode 100644 index 0000000000..b44f071acc --- /dev/null +++ b/.changeset/olive-islands-sneeze.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-catalog-backend-module-github': patch +'@backstage/cli': patch +--- + +Request slightly smaller pages of data from GitHub diff --git a/.changeset/orange-cycles-wait.md b/.changeset/orange-cycles-wait.md new file mode 100644 index 0000000000..5e71b69e80 --- /dev/null +++ b/.changeset/orange-cycles-wait.md @@ -0,0 +1,5 @@ +--- +'@backstage/frontend-app-api': patch +--- + +Added the `bindRoutes` option to `createApp`. diff --git a/.changeset/perfect-cobras-bake.md b/.changeset/perfect-cobras-bake.md new file mode 100644 index 0000000000..bf66c12e83 --- /dev/null +++ b/.changeset/perfect-cobras-bake.md @@ -0,0 +1,9 @@ +--- +'@backstage/plugin-jenkins-backend': minor +'@backstage/plugin-jenkins': minor +--- + +Added JobRunTable Component. +Added new Route and extended Api to get buildJobs. +Actions column has a new icon button, clicking on which takes us to page where we +can see all the job runs. diff --git a/.changeset/perfect-shrimps-attend.md b/.changeset/perfect-shrimps-attend.md new file mode 100644 index 0000000000..b530d0e2a2 --- /dev/null +++ b/.changeset/perfect-shrimps-attend.md @@ -0,0 +1,5 @@ +--- +'@backstage/core-components': patch +--- + +Fixed overflowing messages in `WarningPanel`. diff --git a/.changeset/popular-bikes-do.md b/.changeset/popular-bikes-do.md new file mode 100644 index 0000000000..b1cc5c2cdd --- /dev/null +++ b/.changeset/popular-bikes-do.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-code-coverage': patch +--- + +The warning for missing code coverage will now render the entity as a reference. diff --git a/.changeset/pre.json b/.changeset/pre.json index d767fe77f0..d6534f2b5a 100644 --- a/.changeset/pre.json +++ b/.changeset/pre.json @@ -246,52 +246,84 @@ "@backstage/plugin-vault-backend": "0.3.8", "@backstage/plugin-xcmetrics": "0.2.43", "@backstage/e2e-test-utils": "0.0.0", - "@backstage/plugin-kubernetes-react": "0.0.0" + "@backstage/plugin-kubernetes-react": "0.0.0", + "@backstage/plugin-auth-backend-module-microsoft-provider": "0.0.0", + "@backstage/plugin-catalog-backend-module-github-org": "0.0.0", + "@backstage/plugin-kubernetes-cluster": "0.0.0", + "@backstage/plugin-kubernetes-node": "0.0.0" }, "changesets": [ "angry-badgers-beg", + "angry-clocks-exercise", "big-spies-beam", "breezy-dryers-thank", + "calm-carpets-kiss", "calm-scissors-rescue", "chatty-papayas-care", "clean-forks-love", "cold-bees-jam", "cold-seas-repeat", + "create-app-1696937840", + "dirty-doors-wave", "dull-bugs-build", "dull-dolls-explode", "dull-experts-kiss", "dull-laws-camp", + "early-toes-develop", "eight-melons-cough", + "eight-spiders-fold", + "eight-suns-tan", "eighty-actors-type", + "empty-schools-check", "fair-frogs-enjoy", + "flat-pandas-tan", + "flat-rules-rush", "four-jars-protect", "four-onions-clap", "four-pans-sin", + "fresh-badgers-study", "fresh-kangaroos-tap", + "fuzzy-pillows-remain", "gentle-elephants-fold", "gentle-spies-deny", + "great-walls-brake", "happy-books-smoke", + "healthy-laws-divide", "heavy-forks-tie", + "heavy-ladybugs-leave", "itchy-bobcats-fly", "itchy-monkeys-reply", "itchy-rabbits-exist", + "khaki-tools-tease", + "large-balloons-brush", "large-comics-knock", "late-papayas-push", "lazy-doors-wink", "lemon-cups-wait", "lemon-masks-greet", + "little-ligers-cheat", + "loud-hotels-hunt", "lovely-coins-occur", "lovely-fans-sniff", + "many-pianos-bow", "many-swans-eat", "mean-dancers-burn", + "metal-peas-beam", "moody-lobsters-rescue", + "nasty-needles-hear", "nervous-hounds-sleep", "nice-clocks-smash", "nice-dancers-explain", + "nice-ghosts-build", + "nine-flies-move", "nine-garlics-attend", + "odd-pants-sleep", "olive-cars-rescue", + "olive-geese-rest", "perfect-pumas-protect", + "perfect-shrimps-attend", "plenty-llamas-double", + "plenty-toys-cheer", "polite-cooks-perform", "polite-donuts-fail", "polite-trainers-grin", @@ -301,31 +333,58 @@ "purple-chefs-wait", "purple-forks-fetch", "quick-weeks-explode", + "rare-pants-reply", "red-bees-try", + "red-geese-clean", + "renovate-7d08f6a", "renovate-a1c52e8", + "rotten-rings-confess", + "serious-pants-lie", + "serious-penguins-tease", + "short-terms-check", "shy-clouds-reflect", "shy-seas-sip", "silent-years-bake", "silly-swans-invent", + "six-weeks-raise", + "slow-dodos-remember", + "small-books-deliver", "small-pugs-build", + "smooth-rings-mate", "spicy-chairs-film", + "spicy-poets-sell", "spotty-badgers-wash", + "stale-eagles-reply", + "stale-stingrays-explode", + "strange-dodos-film", "strong-falcons-tickle", "stupid-drinks-trade", "stupid-eagles-shave", + "swift-steaks-fetch", + "tame-trainers-visit", "tasty-avocados-hope", "tasty-doors-switch", "ten-seals-wait", + "tender-pears-work", "thirty-coins-sneeze", "tiny-garlics-cheer", "twelve-clouds-design", + "twelve-days-walk", + "twenty-bags-sin", + "twenty-carrots-smile", + "two-dingos-dream", + "two-terms-play", + "unlucky-experts-breathe", + "violet-apes-beam", "violet-beers-cross", "warm-drinks-argue", "wet-olives-wave", "wet-timers-chew", "wicked-rings-flash", "wild-jobs-greet", + "wild-queens-grab", "yellow-numbers-own", - "yellow-rings-invent" + "yellow-rings-invent", + "young-toes-knock" ] } diff --git a/.changeset/pretty-swans-worry.md b/.changeset/pretty-swans-worry.md new file mode 100644 index 0000000000..621ae98fe5 --- /dev/null +++ b/.changeset/pretty-swans-worry.md @@ -0,0 +1,5 @@ +--- +'@backstage/core-components': patch +--- + +Fixed the type declaration of `DependencyGraphProps`, the `defs` prop now expects `JSX.Element`s. diff --git a/.changeset/rare-glasses-play.md b/.changeset/rare-glasses-play.md new file mode 100644 index 0000000000..7613f6f1bc --- /dev/null +++ b/.changeset/rare-glasses-play.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-kubernetes-react': patch +--- + +Handle mixed decimals and bigint when calculating k8s resource usage diff --git a/.changeset/rare-pants-reply.md b/.changeset/rare-pants-reply.md new file mode 100644 index 0000000000..d37192048c --- /dev/null +++ b/.changeset/rare-pants-reply.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-auth-backend-module-gcp-iap-provider': minor +--- + +**BREAKING** `gcpIapAuthenticator.initialize()` is no longer `async` diff --git a/.changeset/red-baboons-warn.md b/.changeset/red-baboons-warn.md new file mode 100644 index 0000000000..80b7cd3cad --- /dev/null +++ b/.changeset/red-baboons-warn.md @@ -0,0 +1,5 @@ +--- +'@backstage/dev-utils': patch +--- + +Moving development `dependencies` to `devDependencies` diff --git a/.changeset/renovate-0a0b7ba.md b/.changeset/renovate-0a0b7ba.md new file mode 100644 index 0000000000..dd43bcc8fa --- /dev/null +++ b/.changeset/renovate-0a0b7ba.md @@ -0,0 +1,8 @@ +--- +'@backstage/backend-common': patch +'@backstage/plugin-kubernetes-backend': patch +'@backstage/plugin-kubernetes-common': patch +'@backstage/plugin-kubernetes': patch +--- + +Updated dependency `@kubernetes/client-node` to `0.19.0`. diff --git a/.changeset/renovate-2633beb.md b/.changeset/renovate-2633beb.md new file mode 100644 index 0000000000..ff4c574c85 --- /dev/null +++ b/.changeset/renovate-2633beb.md @@ -0,0 +1,104 @@ +--- +'@backstage/app-defaults': patch +'@backstage/core-app-api': patch +'@backstage/core-components': patch +'@backstage/core-plugin-api': patch +'@backstage/dev-utils': patch +'@backstage/frontend-app-api': patch +'@backstage/frontend-plugin-api': patch +'@backstage/integration-react': patch +'@backstage/test-utils': patch +'@backstage/version-bridge': patch +'@backstage/plugin-adr': patch +'@backstage/plugin-airbrake': patch +'@backstage/plugin-allure': patch +'@backstage/plugin-analytics-module-ga': patch +'@backstage/plugin-analytics-module-ga4': patch +'@backstage/plugin-analytics-module-newrelic-browser': patch +'@backstage/plugin-apache-airflow': patch +'@backstage/plugin-api-docs-module-protoc-gen-doc': patch +'@backstage/plugin-api-docs': patch +'@backstage/plugin-apollo-explorer': patch +'@backstage/plugin-azure-devops': patch +'@backstage/plugin-azure-sites': patch +'@backstage/plugin-badges': patch +'@backstage/plugin-bazaar': patch +'@backstage/plugin-bitrise': patch +'@backstage/plugin-catalog-graph': patch +'@backstage/plugin-catalog-import': patch +'@backstage/plugin-catalog-react': patch +'@backstage/plugin-catalog-unprocessed-entities': patch +'@backstage/plugin-catalog': patch +'@backstage/plugin-circleci': patch +'@backstage/plugin-cloudbuild': patch +'@backstage/plugin-code-climate': patch +'@backstage/plugin-code-coverage': patch +'@backstage/plugin-codescene': patch +'@backstage/plugin-config-schema': patch +'@backstage/plugin-cost-insights': patch +'@backstage/plugin-devtools': patch +'@backstage/plugin-dynatrace': patch +'@backstage/plugin-entity-feedback': patch +'@backstage/plugin-entity-validation': patch +'@backstage/plugin-explore-react': patch +'@backstage/plugin-explore': patch +'@backstage/plugin-firehydrant': patch +'@backstage/plugin-fossa': patch +'@backstage/plugin-gcalendar': patch +'@backstage/plugin-gcp-projects': patch +'@backstage/plugin-git-release-manager': patch +'@backstage/plugin-github-actions': patch +'@backstage/plugin-github-deployments': patch +'@backstage/plugin-github-issues': patch +'@backstage/plugin-github-pull-requests-board': patch +'@backstage/plugin-gitops-profiles': patch +'@backstage/plugin-gocd': patch +'@backstage/plugin-graphiql': patch +'@backstage/plugin-graphql-voyager': patch +'@backstage/plugin-home-react': patch +'@backstage/plugin-home': patch +'@backstage/plugin-ilert': patch +'@backstage/plugin-jenkins': patch +'@backstage/plugin-kafka': patch +'@backstage/plugin-kubernetes-cluster': patch +'@backstage/plugin-kubernetes-react': patch +'@backstage/plugin-kubernetes': patch +'@backstage/plugin-lighthouse': patch +'@backstage/plugin-linguist': patch +'@backstage/plugin-microsoft-calendar': patch +'@backstage/plugin-newrelic-dashboard': patch +'@backstage/plugin-newrelic': patch +'@backstage/plugin-nomad': patch +'@backstage/plugin-octopus-deploy': patch +'@backstage/plugin-opencost': patch +'@backstage/plugin-org-react': patch +'@backstage/plugin-org': patch +'@backstage/plugin-pagerduty': patch +'@backstage/plugin-periskop': patch +'@backstage/plugin-permission-react': patch +'@backstage/plugin-playlist': patch +'@backstage/plugin-puppetdb': patch +'@backstage/plugin-rollbar': patch +'@backstage/plugin-scaffolder-react': patch +'@backstage/plugin-scaffolder': patch +'@backstage/plugin-search-react': patch +'@backstage/plugin-search': patch +'@backstage/plugin-sentry': patch +'@backstage/plugin-shortcuts': patch +'@backstage/plugin-sonarqube': patch +'@backstage/plugin-splunk-on-call': patch +'@backstage/plugin-stack-overflow': patch +'@backstage/plugin-stackstorm': patch +'@backstage/plugin-tech-insights': patch +'@backstage/plugin-tech-radar': patch +'@backstage/plugin-techdocs-addons-test-utils': patch +'@backstage/plugin-techdocs-module-addons-contrib': patch +'@backstage/plugin-techdocs-react': patch +'@backstage/plugin-techdocs': patch +'@backstage/plugin-todo': patch +'@backstage/plugin-user-settings': patch +'@backstage/plugin-vault': patch +'@backstage/plugin-xcmetrics': patch +--- + +Updated dependency `@testing-library/jest-dom` to `^6.0.0`. diff --git a/.changeset/renovate-37d5549.md b/.changeset/renovate-37d5549.md new file mode 100644 index 0000000000..4aae56e839 --- /dev/null +++ b/.changeset/renovate-37d5549.md @@ -0,0 +1,86 @@ +--- +'@backstage/core-app-api': patch +'@backstage/core-components': patch +'@backstage/core-plugin-api': patch +'@backstage/dev-utils': patch +'@backstage/integration-react': patch +'@backstage/plugin-adr': patch +'@backstage/plugin-airbrake': patch +'@backstage/plugin-allure': patch +'@backstage/plugin-analytics-module-ga': patch +'@backstage/plugin-analytics-module-ga4': patch +'@backstage/plugin-apache-airflow': patch +'@backstage/plugin-api-docs': patch +'@backstage/plugin-apollo-explorer': patch +'@backstage/plugin-azure-devops': patch +'@backstage/plugin-azure-sites': patch +'@backstage/plugin-bitrise': patch +'@backstage/plugin-catalog-graph': patch +'@backstage/plugin-catalog-import': patch +'@backstage/plugin-catalog-react': patch +'@backstage/plugin-catalog': patch +'@backstage/plugin-circleci': patch +'@backstage/plugin-cloudbuild': patch +'@backstage/plugin-code-climate': patch +'@backstage/plugin-code-coverage': patch +'@backstage/plugin-codescene': patch +'@backstage/plugin-config-schema': patch +'@backstage/plugin-cost-insights': patch +'@backstage/plugin-dynatrace': patch +'@backstage/plugin-entity-feedback': patch +'@backstage/plugin-entity-validation': patch +'@backstage/plugin-explore-react': patch +'@backstage/plugin-explore': patch +'@backstage/plugin-firehydrant': patch +'@backstage/plugin-fossa': patch +'@backstage/plugin-gcalendar': patch +'@backstage/plugin-gcp-projects': patch +'@backstage/plugin-git-release-manager': patch +'@backstage/plugin-github-actions': patch +'@backstage/plugin-github-deployments': patch +'@backstage/plugin-github-issues': patch +'@backstage/plugin-github-pull-requests-board': patch +'@backstage/plugin-gitops-profiles': patch +'@backstage/plugin-gocd': patch +'@backstage/plugin-graphiql': patch +'@backstage/plugin-graphql-voyager': patch +'@backstage/plugin-home-react': patch +'@backstage/plugin-home': patch +'@backstage/plugin-ilert': patch +'@backstage/plugin-jenkins': patch +'@backstage/plugin-kafka': patch +'@backstage/plugin-kubernetes-cluster': patch +'@backstage/plugin-kubernetes': patch +'@backstage/plugin-lighthouse': patch +'@backstage/plugin-linguist': patch +'@backstage/plugin-microsoft-calendar': patch +'@backstage/plugin-newrelic': patch +'@backstage/plugin-octopus-deploy': patch +'@backstage/plugin-org-react': patch +'@backstage/plugin-org': patch +'@backstage/plugin-pagerduty': patch +'@backstage/plugin-periskop': patch +'@backstage/plugin-playlist': patch +'@backstage/plugin-rollbar': patch +'@backstage/plugin-scaffolder-react': patch +'@backstage/plugin-scaffolder': patch +'@backstage/plugin-search-react': patch +'@backstage/plugin-search': patch +'@backstage/plugin-sentry': patch +'@backstage/plugin-shortcuts': patch +'@backstage/plugin-sonarqube': patch +'@backstage/plugin-splunk-on-call': patch +'@backstage/plugin-stack-overflow': patch +'@backstage/plugin-stackstorm': patch +'@backstage/plugin-tech-insights': patch +'@backstage/plugin-tech-radar': patch +'@backstage/plugin-techdocs-addons-test-utils': patch +'@backstage/plugin-techdocs-module-addons-contrib': patch +'@backstage/plugin-techdocs': patch +'@backstage/plugin-todo': patch +'@backstage/plugin-user-settings': patch +'@backstage/plugin-vault': patch +'@backstage/plugin-xcmetrics': patch +--- + +Updated dependency `@testing-library/dom` to `^9.0.0`. diff --git a/.changeset/renovate-7d08f6a.md b/.changeset/renovate-7d08f6a.md new file mode 100644 index 0000000000..4e8111f1b3 --- /dev/null +++ b/.changeset/renovate-7d08f6a.md @@ -0,0 +1,5 @@ +--- +'@backstage/config-loader': patch +--- + +Updated dependency `typescript-json-schema` to `^0.61.0`. diff --git a/.changeset/renovate-a6a783f.md b/.changeset/renovate-a6a783f.md new file mode 100644 index 0000000000..a4c6188ee6 --- /dev/null +++ b/.changeset/renovate-a6a783f.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-kubernetes': patch +--- + +Updated dependency `xterm-addon-attach` to `^0.9.0`. +Updated dependency `xterm-addon-fit` to `^0.8.0`. diff --git a/.changeset/renovate-c204e0d.md b/.changeset/renovate-c204e0d.md new file mode 100644 index 0000000000..1f3e366540 --- /dev/null +++ b/.changeset/renovate-c204e0d.md @@ -0,0 +1,5 @@ +--- +'@backstage/cli': patch +--- + +Updated dependency `@typescript-eslint/eslint-plugin` to `6.7.5`. diff --git a/.changeset/serious-ravens-serve.md b/.changeset/serious-ravens-serve.md new file mode 100644 index 0000000000..66cbd795c0 --- /dev/null +++ b/.changeset/serious-ravens-serve.md @@ -0,0 +1,5 @@ +--- +'@backstage/cli': patch +--- + +The scaffolder-module template now recommends usage of `createMockDirectory` instead of `mock-fs`. diff --git a/.changeset/shaggy-beers-collect.md b/.changeset/shaggy-beers-collect.md new file mode 100644 index 0000000000..471368d6f2 --- /dev/null +++ b/.changeset/shaggy-beers-collect.md @@ -0,0 +1,6 @@ +--- +'@backstage/dev-utils': patch +'@backstage/plugin-techdocs': patch +--- + +Added support for React 18. The new `createRoot` API from `react-dom/client` will now be used if present. diff --git a/.changeset/shiny-birds-melt.md b/.changeset/shiny-birds-melt.md new file mode 100644 index 0000000000..16591b6d2f --- /dev/null +++ b/.changeset/shiny-birds-melt.md @@ -0,0 +1,5 @@ +--- +'@backstage/core-app-api': patch +--- + +Fixed a bug in `TranslationApi` implementation where in some cases it wouldn't notify subscribers of language changes. diff --git a/.changeset/short-ears-rescue.md b/.changeset/short-ears-rescue.md new file mode 100644 index 0000000000..41968f3da4 --- /dev/null +++ b/.changeset/short-ears-rescue.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-auth-backend-module-pinniped-provider': minor +--- + +Add new Pinniped auth module and authenticator to be used alongside the new Pinniped auth provider. diff --git a/.changeset/silent-years-marry.md b/.changeset/silent-years-marry.md new file mode 100644 index 0000000000..6053261784 --- /dev/null +++ b/.changeset/silent-years-marry.md @@ -0,0 +1,8 @@ +--- +'@backstage/plugin-kubernetes-backend': minor +--- + +**BREAKING** Allow passing undefined `labelSelector` to `KubernetesFetcher` + +`KubernetesFetch` no longer auto-adds `labelSelector` when empty string was passed. +This is only applicable if you have custom ObjectProvider implementation, as build-in `KubernetesFanOutHandler` already does this diff --git a/.changeset/silly-chefs-allow.md b/.changeset/silly-chefs-allow.md new file mode 100644 index 0000000000..6a1ff5dc09 --- /dev/null +++ b/.changeset/silly-chefs-allow.md @@ -0,0 +1,5 @@ +--- +'@backstage/frontend-plugin-api': patch +--- + +Added `createExtensionOverrides` which can be used to install a collection of extensions in an app that will replace any existing ones. diff --git a/.changeset/slow-cameras-grab.md b/.changeset/slow-cameras-grab.md new file mode 100644 index 0000000000..d2ffaac73d --- /dev/null +++ b/.changeset/slow-cameras-grab.md @@ -0,0 +1,5 @@ +--- +'@backstage/frontend-app-api': minor +--- + +The hidden `'root'` extension has been removed and has instead been made an input of the `'core'` extension. The checks for rejecting configuration of the `'root'` extension to rejects configuration of the `'core'` extension instead. diff --git a/.changeset/small-avocados-live.md b/.changeset/small-avocados-live.md new file mode 100644 index 0000000000..ddb01a9dfa --- /dev/null +++ b/.changeset/small-avocados-live.md @@ -0,0 +1,5 @@ +--- +'@backstage/backend-common': patch +--- + +Adds the optional flag for useRedisSets for the Redis cache to the config. diff --git a/.changeset/spicy-poets-sell.md b/.changeset/spicy-poets-sell.md new file mode 100644 index 0000000000..4bebd71344 --- /dev/null +++ b/.changeset/spicy-poets-sell.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-jenkins': patch +--- + +Extend EntityJenkinsContent to receive columns as prop diff --git a/.changeset/stale-eagles-reply.md b/.changeset/stale-eagles-reply.md new file mode 100644 index 0000000000..4584355a59 --- /dev/null +++ b/.changeset/stale-eagles-reply.md @@ -0,0 +1,6 @@ +--- +'@backstage/config-loader': patch +'@backstage/backend-app-api': patch +--- + +Added `watch` option to configuration loaders that can be used to disable file watching by setting it to `false`. diff --git a/.changeset/strange-dodos-film.md b/.changeset/strange-dodos-film.md new file mode 100644 index 0000000000..78b9119a2b --- /dev/null +++ b/.changeset/strange-dodos-film.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-catalog-backend-module-github-org': minor +--- + +Added `catalogModuleGithubOrgEntityProvider` to ingest users and teams from multiple Github organizations. diff --git a/.changeset/sweet-buckets-fry.md b/.changeset/sweet-buckets-fry.md new file mode 100644 index 0000000000..8f17617645 --- /dev/null +++ b/.changeset/sweet-buckets-fry.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-catalog-react': patch +--- + +The `spec.type` field in entities will now always be rendered as a string. diff --git a/.changeset/swift-kings-add.md b/.changeset/swift-kings-add.md new file mode 100644 index 0000000000..9e9c158eec --- /dev/null +++ b/.changeset/swift-kings-add.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-newrelic-dashboard': patch +--- + +Fix the styles for NewRelicDashboard, add more responsiveness diff --git a/.changeset/swift-steaks-fetch.md b/.changeset/swift-steaks-fetch.md new file mode 100644 index 0000000000..80b23e7658 --- /dev/null +++ b/.changeset/swift-steaks-fetch.md @@ -0,0 +1,6 @@ +--- +'@backstage/plugin-auth-backend-module-microsoft-provider': minor +'@backstage/plugin-auth-backend': patch +--- + +Migrated the Microsoft auth provider to new `@backstage/plugin-auth-backend-module-microsoft-provider` module package. diff --git a/.changeset/tame-trainers-visit.md b/.changeset/tame-trainers-visit.md new file mode 100644 index 0000000000..5315f3e1d5 --- /dev/null +++ b/.changeset/tame-trainers-visit.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-catalog-backend-module-github': patch +--- + +Removed `catalogModuleGithubOrgEntityProvider`. Import from `@backstage/plugin-catalog-backend-module-github-org` instead. diff --git a/.changeset/tender-experts-yell.md b/.changeset/tender-experts-yell.md new file mode 100644 index 0000000000..a4d321073b --- /dev/null +++ b/.changeset/tender-experts-yell.md @@ -0,0 +1,5 @@ +--- +'@backstage/frontend-app-api': minor +--- + +Added support for installing `ExtensionOverrides` via `createApp` options. As part of this change the `plugins` option has been renamed to `features`, and the `pluginLoader` has been renamed to `featureLoader`. diff --git a/.changeset/thick-dolphins-boil.md b/.changeset/thick-dolphins-boil.md new file mode 100644 index 0000000000..dd562e620c --- /dev/null +++ b/.changeset/thick-dolphins-boil.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-catalog-import': patch +--- + +The `app.title` configuration is now properly required to be a string. diff --git a/.changeset/tiny-suns-deny.md b/.changeset/tiny-suns-deny.md new file mode 100644 index 0000000000..b00830c75c --- /dev/null +++ b/.changeset/tiny-suns-deny.md @@ -0,0 +1,5 @@ +--- +'@backstage/create-app': patch +--- + +Bump dev dependencies `lerna@7.3.0` on the template diff --git a/.changeset/twelve-snakes-sell.md b/.changeset/twelve-snakes-sell.md new file mode 100644 index 0000000000..7f91b2910f --- /dev/null +++ b/.changeset/twelve-snakes-sell.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-search-backend': patch +--- + +Set the default length limit to search query to 100. To override it, define `search.maxTermLength` in the config file. diff --git a/.changeset/twenty-carrots-smile.md b/.changeset/twenty-carrots-smile.md new file mode 100644 index 0000000000..873af7dcd3 --- /dev/null +++ b/.changeset/twenty-carrots-smile.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-scaffolder-backend': patch +--- + +Add examples for `publish:Azure` scaffolder action. diff --git a/.changeset/two-terms-play.md b/.changeset/two-terms-play.md new file mode 100644 index 0000000000..6c7edc01db --- /dev/null +++ b/.changeset/two-terms-play.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-github-issues': patch +--- + +Filters out entities that belonged to a different github instance other than the one configured by the plugin diff --git a/.changeset/violet-apes-beam.md b/.changeset/violet-apes-beam.md new file mode 100644 index 0000000000..544dcf72b2 --- /dev/null +++ b/.changeset/violet-apes-beam.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-newrelic-dashboard': patch +--- + +Fixed React Warning: "Each child in a list should have a unique 'key' prop" during the rendering of `EntityNewRelicDashboardCard` diff --git a/.changeset/wet-cows-brake.md b/.changeset/wet-cows-brake.md new file mode 100644 index 0000000000..9e694d8452 --- /dev/null +++ b/.changeset/wet-cows-brake.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-search-react': patch +--- + +The filter options passed to `SearchResultGroupLayout` are now always explicitly rendered as strings by default. diff --git a/.changeset/wild-geese-occur.md b/.changeset/wild-geese-occur.md new file mode 100644 index 0000000000..b97620e7f5 --- /dev/null +++ b/.changeset/wild-geese-occur.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-search': patch +--- + +Minor internal code cleanup. diff --git a/.changeset/wild-toys-arrive.md b/.changeset/wild-toys-arrive.md new file mode 100644 index 0000000000..4aad036a96 --- /dev/null +++ b/.changeset/wild-toys-arrive.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-newrelic-dashboard': minor +--- + +Add storybook for newrelic-dashboard plugin. diff --git a/.changeset/young-ducks-heal.md b/.changeset/young-ducks-heal.md new file mode 100644 index 0000000000..28614e47bc --- /dev/null +++ b/.changeset/young-ducks-heal.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-auth-node': patch +--- + +Adding optional audience parameter to OAuthState type declaration diff --git a/.changeset/young-toes-knock.md b/.changeset/young-toes-knock.md new file mode 100644 index 0000000000..6371dec193 --- /dev/null +++ b/.changeset/young-toes-knock.md @@ -0,0 +1,5 @@ +--- +'@backstage/plugin-opencost': patch +--- + +Fix for broken image reference. diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index e788a6fe95..25073c9556 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -70,6 +70,8 @@ yarn.lock @backstage/maintainers @backst /plugins/playlist-* @backstage/maintainers @backstage/reviewers @kuangp /plugins/rollbar @backstage/maintainers @backstage/reviewers @andrewthauer /plugins/rollbar-backend @backstage/maintainers @backstage/reviewers @andrewthauer +/plugins/scaffolder @backstage/maintainers @backstage/reviewers @backstage/scaffolder-maintainers +/plugins/scaffolder-* @backstage/maintainers @backstage/reviewers @backstage/scaffolder-maintainers /plugins/search @backstage/discoverability-maintainers /plugins/search-* @backstage/discoverability-maintainers /plugins/sonarqube @backstage/maintainers @backstage/reviewers @backstage/sda-se-reviewers diff --git a/.github/vale/Vocab/Backstage/accept.txt b/.github/vale/Vocab/Backstage/accept.txt index aadbaa3985..e6c0aa9632 100644 --- a/.github/vale/Vocab/Backstage/accept.txt +++ b/.github/vale/Vocab/Backstage/accept.txt @@ -25,6 +25,7 @@ backend's backported backporting BEPs +bigint Bigtable Billett bitbucket @@ -453,4 +454,4 @@ zsh Pulumi Lightsail PR -rebasing \ No newline at end of file +rebasing diff --git a/.github/workflows/scorecard.yml b/.github/workflows/scorecard.yml index 7d20a77f07..ab53549052 100644 --- a/.github/workflows/scorecard.yml +++ b/.github/workflows/scorecard.yml @@ -61,6 +61,6 @@ jobs: # Upload the results to GitHub's code scanning dashboard. - name: 'Upload to code-scanning' - uses: github/codeql-action/upload-sarif@2cb752a87e96af96708ab57187ab6372ee1973ab # v2.22.0 + uses: github/codeql-action/upload-sarif@fdcae64e1484d349b3366718cdfef3d404390e85 # v2.22.1 with: sarif_file: results.sarif diff --git a/.gitignore b/.gitignore index 7149dbabc1..c0ef0d2001 100644 --- a/.gitignore +++ b/.gitignore @@ -159,4 +159,7 @@ e2e-test-report/ # VS Code backing up svg files *svg.bkp -*svg.dtmp \ No newline at end of file +*svg.dtmp + +# Scripts +plugins-report.csv \ No newline at end of file diff --git a/docs/assets/plugins/create-plugin_types.png b/docs/assets/plugins/create-plugin_types.png new file mode 100644 index 0000000000..ea45d1cdd1 Binary files /dev/null and b/docs/assets/plugins/create-plugin_types.png differ diff --git a/docs/assets/my-plugin_screenshot.png b/docs/assets/plugins/my-plugin_screenshot.png similarity index 100% rename from docs/assets/my-plugin_screenshot.png rename to docs/assets/plugins/my-plugin_screenshot.png diff --git a/docs/features/software-catalog/configuration.md b/docs/features/software-catalog/configuration.md index bd914cc56c..97c75a01ff 100644 --- a/docs/features/software-catalog/configuration.md +++ b/docs/features/software-catalog/configuration.md @@ -44,6 +44,20 @@ When multiple `catalog-info.yaml` files with the same `metadata.name` property are discovered, one will be processed and all others will be skipped. This action is logged for further investigation. +### Local File (`type: file`) Configurations + +In addition to url locations, you can use the `file` location type to bring in content from the local file system. You should only use this for local development, test setups and example data, not for production data. +You are also not able to use placeholders in them like `$text`. You can however reference other files relative to the current file. See the full [catalog example data set here](https://github.com/backstage/backstage/tree/master/packages/catalog-model/examples) for an extensive example. + +Here is an example pulling in the `all.yaml` file from the examples folder. Note the use of `../../` to go up two levels from the current execution path of the backend. This is typically `packages/backend/`. + +```yaml +catalog: + locations: + - type: file + target: ../../examples/all.yaml +``` + ### Integration Processors Integrations may simply provide a mechanism to handle `url` location type for an diff --git a/docs/features/software-catalog/extending-the-model.md b/docs/features/software-catalog/extending-the-model.md index 52ef565837..fec924fa91 100644 --- a/docs/features/software-catalog/extending-the-model.md +++ b/docs/features/software-catalog/extending-the-model.md @@ -447,6 +447,9 @@ want to have an isomorphic package that houses these types. Within the Backstage main repo the package naming pattern of `-common` is used for isomorphic packages, and you may choose to adopt this pattern as well. +You can generate an isomorphic plugin package by running:`yarn new --select plugin-common` +or you can run `yarn new` and then select "plugin-common" from the list of options + There's at this point no existing templates for generating isomorphic plugins using the `@backstage/cli`. Perhaps the simplest wat to get started right now is to copy the contents of one of the existing packages in the main repository, diff --git a/docs/features/software-templates/input-examples.md b/docs/features/software-templates/input-examples.md index c44ee39269..ad56ef2d36 100644 --- a/docs/features/software-templates/input-examples.md +++ b/docs/features/software-templates/input-examples.md @@ -110,10 +110,11 @@ parameters: arrayObjects: title: Array with custom objects type: array + minItems: 0 ui:options: - addable: false - orderable: false - removable: false + addable: true + orderable: true + removable: true items: type: object properties: diff --git a/docs/features/techdocs/how-to-guides.md b/docs/features/techdocs/how-to-guides.md index 8c98ec48d4..6a70e9e2aa 100644 --- a/docs/features/techdocs/how-to-guides.md +++ b/docs/features/techdocs/how-to-guides.md @@ -525,6 +525,39 @@ techdocs: This way, all iframes where the host in the src attribute is in the `sanitizer.allowedIframeHosts` list will be displayed. +## How to render PlantUML diagram in TechDocs + +PlantUML allows you to create diagrams from plain text language. Each diagram description begins with the keyword - (@startXYZ and @endXYZ, depending on the kind of diagram). For UML Diagrams, Keywords @startuml & @enduml should be used. Further details for all types of diagrams can be found at [PlantUML Language Reference Guide](https://plantuml.com/guide). + +### UML Diagram Details:- + +#### Embedded PlantUML Diagram Example + +Here, the markdown file itself contains the diagram description. + +````md +```plantuml +@startuml +title Login Sequence + ComponentA->ComponentB: Login Request + note right of ComponentB: ComponentB logs message + ComponentB->ComponentA: Login Response +@enduml +``` +```` + +#### Referenced PlantUML Diagram Example + +Here, the markdown file refers to another file (_.puml or _.pu) which contains the diagram description. + +````md +```plantuml +!include umldiagram.puml +``` +```` + +Note: To refer external diagram files, we need to include the diagrams directory in the path. Please refer [`Dockerfile`](https://github.com/backstage/techdocs-container/blob/main/Dockerfile) for details. + ## How to add Mermaid support in TechDocs To add `Mermaid` support in TechDocs, you can use [`kroki`](https://kroki.io) diff --git a/docs/overview/architecture-overview.md b/docs/overview/architecture-overview.md index 3ba3f4ba0b..f975baf1e1 100644 --- a/docs/overview/architecture-overview.md +++ b/docs/overview/architecture-overview.md @@ -323,8 +323,11 @@ backend: cache: store: redis connection: redis://user:pass@cache.example.com:6379 + useRedisSets: true ``` +The useRedisSets flag is explained [here](https://github.com/jaredwray/keyv/tree/main/packages/redis#useredissets). + Contributions supporting other cache stores are welcome! ## Containerization diff --git a/docs/plugins/create-a-plugin.md b/docs/plugins/create-a-plugin.md index cbd789c757..481b610e4e 100644 --- a/docs/plugins/create-a-plugin.md +++ b/docs/plugins/create-a-plugin.md @@ -8,7 +8,7 @@ A Backstage Plugin adds functionality to Backstage. ## Create a Plugin -To create a new plugin, make sure you've run `yarn install` and installed +To create a new frontend plugin, make sure you've run `yarn install` and installed dependencies, then run the following on your command line (a shortcut to invoking the [`backstage-cli new --select plugin`](../local-dev/cli-commands.md#new)) @@ -18,7 +18,7 @@ from the root of your project. yarn new --select plugin ``` -![](../assets/getting-started/create-plugin_output.png) +![Example of output when creating a new plugin](../assets/getting-started/create-plugin_output.png) This will create a new Backstage Plugin based on the ID that was provided. It will be built and added to the Backstage App automatically. @@ -27,7 +27,7 @@ will be built and added to the Backstage App automatically. > should be able to see the default page for your new plugin directly by > navigating to `http://localhost:3000/my-plugin`. -![](../assets/my-plugin_screenshot.png) +![Example of new plugin running in browser](../assets/plugins/my-plugin_screenshot.png) You can also serve the plugin in isolation by running `yarn start` in the plugin directory. Or by using the yarn workspace command, for example: @@ -39,3 +39,11 @@ yarn workspace @backstage/plugin-my-plugin start # Also supports --check This method of serving the plugin provides quicker iteration speed and a faster startup and hot reloads. It is only meant for local development, and the setup for it can be found inside the plugin's `dev/` directory. + +### Other Plugin Library Package Types + +There are other plugin library package types that you can chose from. To be able to +select the type when you create a new plugin just run: `yarn new`. You'll then be asked +what type of plugin you wish to create like this: + +![List of available plugin types to pick from](../assets/plugins/create-plugin_types.png) diff --git a/docs/plugins/index.md b/docs/plugins/index.md index a582556311..755c1b8a7d 100644 --- a/docs/plugins/index.md +++ b/docs/plugins/index.md @@ -12,7 +12,7 @@ development tool as a plugin in Backstage. By following strong [design guidelines](../dls/design.md) we ensure the overall user experience stays consistent between plugins. -![plugin](../assets/my-plugin_screenshot.png) +![plugin](../assets/plugins/my-plugin_screenshot.png) ## Creating a plugin diff --git a/docs/release-notes-template.md b/docs/release-notes-template.md index 9f9a0b76ee..4861bf0b22 100644 --- a/docs/release-notes-template.md +++ b/docs/release-notes-template.md @@ -12,7 +12,7 @@ A huge thanks to the whole team of maintainers and contributors as well as the a ### -<short description>. Contributed by [@<user>](https://github.com/<user>) [#<pr>](https://github.com/backstage/backstage/pull/<pr>) +<short description>. Contributed by [@<user>](https://github.com/<user>) in [#<pr>](https://github.com/backstage/backstage/pull/<pr>) ## Security Fixes diff --git a/docs/releases/v1.19.0-next.0-changelog.md b/docs/releases/v1.19.0-next.0-changelog.md index d1861165b9..b1c85e238e 100644 --- a/docs/releases/v1.19.0-next.0-changelog.md +++ b/docs/releases/v1.19.0-next.0-changelog.md @@ -4,7 +4,7 @@ ### Minor Changes -- 7077dbf131: The new backend start command that used to be enabled by setting `EXPERIMENTAL_BACKEND_START` is now the default. To revert to the old behavior, set `LEGACY_BACKEND_START` instead. +- 7077dbf131: **BREAKING** The new backend start command that used to be enabled by setting `EXPERIMENTAL_BACKEND_START` is now the default. To revert to the old behavior set `LEGACY_BACKEND_START`, which is recommended if you haven't migrated to the new backend system. This new command is no longer based on Webpack, but instead uses Node.js loaders to transpile on the fly. Rather than hot reloading modules the entire backend is now restarted on change, but the SQLite database state is still maintained across restarts via a parent process. diff --git a/docs/releases/v1.19.0-next.2-changelog.md b/docs/releases/v1.19.0-next.2-changelog.md new file mode 100644 index 0000000000..3ac5fcfb48 --- /dev/null +++ b/docs/releases/v1.19.0-next.2-changelog.md @@ -0,0 +1,3142 @@ +# Release v1.19.0-next.2 + +## @backstage/cli@0.23.0-next.2 + +### Minor Changes + +- 8defbd5434: Update typescript-eslint to 6.7.x, adding compatibility with TypeScript 5.2. + + This includes a major update on typescript-eslint, you can see the details in the [release notes](https://typescript-eslint.io/blog/announcing-typescript-eslint-v6/). + +### Patch Changes + +- 2ef6522552: Support for the `.icon.svg` extension has been deprecated and will be removed in the future. The implementation of this extension is too tied to a particular version of MUI and the SVGO, and it makes it harder to evolve the build system. We may introduce the ability to reintroduce this kind of functionality in the future through configuration for use in internal plugins, but for now we're forced to remove it. + + To migrate existing code, rename the `.icon.svg` file to `.tsx` and replace the `<svg>` element with `<SvgIcon>` from MUI and add necessary imports. For example: + + ```tsx + import React from 'react'; + import SvgIcon from '@material-ui/core/SvgIcon'; + import { IconComponent } from '@backstage/core-plugin-api'; + + export const CodeSceneIcon = (props: SvgIconProps) => ( + <SvgIcon {...props}> + <g> + <path d="..." /> + </g> + </SvgIcon> + ); + ``` + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/config-loader@1.5.1-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/cli-node@0.1.5-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/eslint-plugin@0.1.3 + - @backstage/release-manifests@0.0.10 + - @backstage/types@1.1.1 + +## @backstage/core-app-api@1.11.0-next.2 + +### Minor Changes + +- c9d9bfeca2: URL encode some well known unsafe characters in `RouteResolver` (and therefore `useRouteRef`) + +### Patch Changes + +- acca17e91a: Wrap entire app in `<Suspense>`, enabling support for using translations outside plugins. +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + +## @backstage/frontend-app-api@0.2.0-next.2 + +### Minor Changes + +- 4461d87d5a: Removed support for the new `useRouteRef`. + +### Patch Changes + +- 5072824817: Implement `toString()` and `toJSON()` for extension instances. +- 06432f900c: Updates for `at` -> `attachTo` refactor. +- 1718ec75b7: Added support for the existing routing system. +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-graphiql@0.2.55-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + +## @backstage/frontend-plugin-api@0.2.0-next.2 + +### Minor Changes + +- 06432f900c: Extension attachment point is now configured via `attachTo: { id, input }` instead of `at: 'id/input'`. +- 4461d87d5a: Removed support for the new `useRouteRef`. + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/types@1.1.1 + +## @techdocs/cli@1.6.0-next.2 + +### Minor Changes + +- d06b30b050: Add possibility to use a mkdocs config file with a different name than `mkdocs.<yaml|yml> with the serve command using the `--mkdocs-config-file-name\` argument + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-techdocs-node@1.9.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-auth-backend-module-gcp-iap-provider@0.2.0-next.2 + +### Minor Changes + +- 6f142d5356: **BREAKING** `gcpIapAuthenticator.initialize()` is no longer `async` + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/types@1.1.1 + +## @backstage/plugin-auth-backend-module-microsoft-provider@0.1.0-next.0 + +### Minor Changes + +- 2d8f7e82c1: Migrated the Microsoft auth provider to new `@backstage/plugin-auth-backend-module-microsoft-provider` module package. + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-auth-node@0.4.0-next.2 + +### Minor Changes + +- 6f142d5356: **BREAKING**: The recently introduced `ProxyAuthenticator.initialize()` method is no longer `async` to match the way the OAuth equivalent is implemented. + +### Patch Changes + +- 8b8b1d23ae: Fixed cookie persisted scope not returned in OAuth refresh handler response. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-catalog-backend-module-github-org@0.1.0-next.0 + +### Minor Changes + +- c101e683d5: Added `catalogModuleGithubOrgEntityProvider` to ingest users and teams from multiple Github organizations. + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-catalog-backend-module-github@0.4.4-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-kubernetes-node@0.1.0-next.0 + +### Minor Changes + +- cbb0e3c3f4: A new plugin has been introduced to house the extension points for Kubernetes backend plugin; at the moment only the `KubernetesObjectsProviderExtensionPoint` is present. The `kubernetes-backend` plugin was modified to use this new extension point. + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-newrelic-dashboard@0.3.0-next.2 + +### Minor Changes + +- d7eba6cab4: Changes in `newrelic-dashboard` plugin: + + - Make DashboardSnapshotList component public + - Settle discrepancies in the exported API + - Deprecate DashboardSnapshotComponent + +### Patch Changes + +- 5194a51a1c: Fixed React Warning: "Each child in a list should have a unique 'key' prop" during the rendering of `EntityNewRelicDashboardCard` +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + +## @backstage/plugin-scaffolder-backend@1.18.0-next.2 + +### Minor Changes + +- dea0aafda7: Updated `publish:gitlab` action properties to support additional Gitlab project settings: + + - general project settings provided by gitlab project create API (new `settings` property) + - branch level settings to create additional branches and make them protected (new `branches` property) + - project level environment variables settings (new `projectVariables` property) + + Marked existed properties `repoVisibility` and `topics` as deprecated, as they are covered by `settings` property. + +### Patch Changes + +- 7dd82cc07e: Add examples for `github:issues:label` scaffolder action & improve related tests +- 733ddf7130: Add examples for `publish:Azure` scaffolder action. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.3-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + +## @backstage/plugin-techdocs-backend@1.8.0-next.2 + +### Minor Changes + +- 344cfbcfbc: Allow prepared directory clean up for custom preparers + + When using custom preparer for TechDocs, the `preparedDir` might + end up taking disk space. This requires all custom preparers to + implement a new method `shouldCleanPreparedDirectory` which indicates + whether the prepared directory should be cleaned after generation. + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-techdocs-node@1.9.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-backend-module-techdocs@0.1.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-techdocs-node@1.9.0-next.2 + +### Minor Changes + +- 344cfbcfbc: Allow prepared directory clean up for custom preparers + + When using custom preparer for TechDocs, the `preparedDir` might + end up taking disk space. This requires all custom preparers to + implement a new method `shouldCleanPreparedDirectory` which indicates + whether the prepared directory should be cleaned after generation. + +- d06b30b050: Add possibility to use a mkdocs config file with a different name than `mkdocs.<yaml|yml> with the serve command using the `--mkdocs-config-file-name\` argument + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/app-defaults@1.4.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + +## @backstage/backend-app-api@0.5.6-next.2 + +### Patch Changes + +- 74491c9602: Moved `HostDiscovery` from `@backstage/backend-common`. +- a4617c422a: Added `watch` option to configuration loaders that can be used to disable file watching by setting it to `false`. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/config-loader@1.5.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/cli-node@0.1.5-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/backend-common@0.19.8-next.2 + +### Patch Changes + +- 74491c9602: The `HostDiscovery` export has been deprecated, import it from `@backstage/backend-app-api` instead. +- b95d66d4ea: Properly close write stream when writing temporary archive for processing zip-based `.readTree()` responses. +- 0b55f773a7: Removed some unused dependencies +- 4c39e38f1e: Added `/testUtils` entry point, with a utility for mocking resolve package paths as returned by `resolvePackagePath`. +- a250ad775f: Removed `mock-fs` dev dependency. +- Updated dependencies + - @backstage/config-loader@1.5.1-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-app-api@0.5.6-next.2 + - @backstage/backend-dev-utils@0.1.2-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/types@1.1.1 + +## @backstage/backend-defaults@0.2.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-app-api@0.5.6-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/backend-openapi-utils@0.0.5-next.0 + +### Patch Changes + +- 7c83975531: Adds new public utility types for common OpenAPI values, like request and response shapes and parameters available on an endpoint. + + **deprecated** `internal` namespace + The internal namespace will continue to be exported but now uses OpenAPI format for path parameters. You should use the new utility types. + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + +## @backstage/backend-plugin-api@0.6.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/backend-tasks@0.5.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/backend-test-utils@0.2.7-next.2 + +### Patch Changes + +- a250ad775f: Added `createMockDirectory()` to help out with file system mocking in tests. +- 74491c9602: Updated to import `HostDiscovery` from `@backstage/backend-app-api`. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-app-api@0.5.6-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/catalog-client@1.4.5-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + +## @backstage/catalog-model@1.4.3-next.0 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/types@1.1.1 + +## @backstage/cli-node@0.1.5-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/types@1.1.1 + +## @backstage/config@1.1.1-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/types@1.1.1 + +## @backstage/config-loader@1.5.1-next.1 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- 30c553c1d2: Updated dependency `typescript-json-schema` to `^0.61.0`. +- a4617c422a: Added `watch` option to configuration loaders that can be used to disable file watching by setting it to `false`. +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/core-components@0.13.6-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- 8a15360bb4: Fixed overflowing messages in `WarningPanel`. +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/version-bridge@1.0.5 + +## @backstage/core-plugin-api@1.7.0-next.1 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + +## @backstage/create-app@0.5.6-next.2 + +### Patch Changes + +- Bumped create-app version. +- Updated dependencies + - @backstage/cli-common@0.1.13-next.0 + +## @backstage/dev-utils@1.0.22-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/app-defaults@1.4.4-next.2 + - @backstage/test-utils@1.4.4-next.2 + +## @backstage/errors@1.2.3-next.0 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/types@1.1.1 + +## @backstage/integration@1.7.1-next.1 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/config@1.1.1-next.0 + +## @backstage/integration-aws-node@0.1.7-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/integration-react@1.1.20-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/config@1.1.1-next.0 + +## @backstage/repo-tools@0.3.5-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/cli-node@0.1.5-next.1 + +## @backstage/test-utils@1.4.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + +## @backstage/theme@0.4.3-next.0 + +### Patch Changes + +- 5ad5344756: Added support for string `fontSize` values (e.g. `"2.5rem"`) in themes in addition to numbers. Also added an optional `fontFamily` prop for header typography variants to allow further customization. + +## @backstage/plugin-adr@0.6.8-next.2 + +### Patch Changes + +- 499e34656e: Fix icon alignment in `AdrSearchResultListItem` +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-adr-common@0.2.16-next.1 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-adr-backend@0.4.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-adr-common@0.2.16-next.1 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-adr-common@0.2.16-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-airbrake@0.3.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/dev-utils@1.0.22-next.2 + - @backstage/test-utils@1.4.4-next.2 + +## @backstage/plugin-airbrake-backend@0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-allure@0.1.41-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-analytics-module-ga@0.1.34-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-analytics-module-ga4@0.1.5-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-analytics-module-newrelic-browser@0.0.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-apache-airflow@0.2.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + +## @backstage/plugin-api-docs@0.9.12-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-apollo-explorer@0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-app-backend@0.3.54-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config-loader@1.5.1-next.1 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-app-node@0.1.6-next.2 + +## @backstage/plugin-app-node@0.1.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-auth-backend@0.19.3-next.2 + +### Patch Changes + +- 2d8f7e82c1: Migrated the Microsoft auth provider to new `@backstage/plugin-auth-backend-module-microsoft-provider` module package. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-auth-backend-module-gcp-iap-provider@0.2.0-next.2 + - @backstage/plugin-auth-backend-module-microsoft-provider@0.1.0-next.0 + - @backstage/plugin-auth-backend-module-github-provider@0.1.3-next.2 + - @backstage/plugin-auth-backend-module-gitlab-provider@0.1.3-next.2 + - @backstage/plugin-auth-backend-module-oauth2-provider@0.1.3-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-auth-backend-module-google-provider@0.1.3-next.2 + +## @backstage/plugin-auth-backend-module-github-provider@0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-auth-backend-module-gitlab-provider@0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-auth-backend-module-google-provider@0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-auth-backend-module-oauth2-provider@0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-azure-devops@0.3.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-azure-devops-common@0.3.1 + +## @backstage/plugin-azure-devops-backend@0.4.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-azure-devops-common@0.3.1 + +## @backstage/plugin-azure-sites@0.1.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-azure-sites-common@0.1.1 + +## @backstage/plugin-azure-sites-backend@0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-azure-sites-common@0.1.1 + +## @backstage/plugin-badges@0.2.49-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-badges-backend@0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-bazaar@0.2.17-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/cli@0.23.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + +## @backstage/plugin-bazaar-backend@0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-bitbucket-cloud-common@0.2.13-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/integration@1.7.1-next.1 + +## @backstage/plugin-bitrise@0.1.52-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-catalog@1.14.0-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-catalog-backend@1.14.0-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-openapi-utils@0.0.5-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-search-backend-module-catalog@0.1.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-catalog-backend-module-aws@0.2.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + +## @backstage/plugin-catalog-backend-module-azure@0.1.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + +## @backstage/plugin-catalog-backend-module-bitbucket@0.2.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-bitbucket-cloud-common@0.2.13-next.1 + +## @backstage/plugin-catalog-backend-module-bitbucket-cloud@0.1.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-bitbucket-cloud-common@0.2.13-next.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-catalog-backend-module-bitbucket-server@0.1.19-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-catalog-backend-module-gcp@0.1.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-catalog-backend-module-gerrit@0.1.22-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-catalog-backend-module-github@0.4.4-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- c101e683d5: Removed `catalogModuleGithubOrgEntityProvider`. Import from `@backstage/plugin-catalog-backend-module-github-org` instead. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-catalog-backend-module-gitlab@0.3.3-next.2 + +### Patch Changes + +- 4f70fdfc93: fix: use REST API to get root group memberships for GitLab SaaS users listing + + This API is the only one that shows `email` field for enterprise users and + allows to filter out bot users not using a license using the `is_using_seat` + field. + + We also added the annotation `gitlab.com/saml-external-uid` taking the value + of `group_saml_identity.extern_uid` of the `groups/:group-id/members` endpoint + response. This is useful in case you want to create a `SignInResolver` that + references the user with the id of your identity provider (e.g. OneLogin). + + ref: + + <https://docs.gitlab.com/ee/user/enterprise_user/#get-users-email-addresses-through-the-api> + <https://docs.gitlab.com/ee/api/members.html#limitations> + +- 0b55f773a7: Removed some unused dependencies + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-catalog-backend-module-incremental-ingestion@0.4.10-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-catalog-backend-module-ldap@0.5.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + +## @backstage/plugin-catalog-backend-module-msgraph@0.5.13-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + +## @backstage/plugin-catalog-backend-module-openapi@0.1.23-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + +## @backstage/plugin-catalog-backend-module-puppetdb@0.1.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + +## @backstage/plugin-catalog-backend-module-unprocessed@0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-catalog-common@1.0.17-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-catalog-graph@0.2.37-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-catalog-graphql@0.3.24-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-catalog-import@0.10.1-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + +## @backstage/plugin-catalog-node@1.4.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + +## @backstage/plugin-catalog-react@1.8.5-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + +## @backstage/plugin-catalog-unprocessed-entities@0.1.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-cicd-statistics@0.1.27-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + +## @backstage/plugin-cicd-statistics-module-gitlab@0.1.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-cicd-statistics@0.1.27-next.2 + - @backstage/catalog-model@1.4.3-next.0 + +## @backstage/plugin-circleci@0.3.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-cloudbuild@0.3.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-code-climate@0.1.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-code-coverage@0.2.18-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-code-coverage-backend@0.2.20-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-codescene@0.1.18-next.2 + +### Patch Changes + +- 9c9a9100b0: Internal refactor to avoid using the deprecated `.icon.svg` extension. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-config-schema@0.1.46-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-cost-insights@0.12.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-cost-insights-common@0.1.2 + +## @backstage/plugin-devtools@0.1.5-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-devtools-common@0.1.5-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + +## @backstage/plugin-devtools-backend@0.2.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/config-loader@1.5.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-devtools-common@0.1.5-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-devtools-common@0.1.5-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-dynatrace@7.0.5-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-entity-feedback@0.2.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-entity-feedback-common@0.1.3 + +## @backstage/plugin-entity-feedback-backend@0.2.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-entity-feedback-common@0.1.3 + +## @backstage/plugin-entity-validation@0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + +## @backstage/plugin-events-backend@0.2.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-events-backend-module-aws-sqs@0.2.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-events-backend-module-azure@0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-events-backend-module-bitbucket-cloud@0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-events-backend-module-gerrit@0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-events-backend-module-github@0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-events-backend-module-gitlab@0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-events-backend-test-utils@0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-events-node@0.2.15-next.2 + +## @backstage/plugin-events-node@0.2.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + +## @backstage/plugin-explore@0.4.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-explore-common@0.0.2 + - @backstage/plugin-explore-react@0.0.32-next.1 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-explore-backend@0.0.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-search-backend-module-explore@0.1.10-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-explore-common@0.0.2 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-explore-react@0.0.32-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-explore-common@0.0.2 + +## @backstage/plugin-firehydrant@0.2.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-fossa@0.2.57-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-gcalendar@0.3.19-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-gcp-projects@0.3.42-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-git-release-manager@0.3.38-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-github-actions@0.6.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-github-deployments@0.1.56-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-github-issues@0.2.14-next.2 + +### Patch Changes + +- 7bd0a8ab3c: Filters out entities that belonged to a different github instance other than the one configured by the plugin +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-github-pull-requests-board@0.1.19-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-gitops-profiles@0.3.41-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-gocd@0.1.31-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-graphiql@0.2.55-next.2 + +### Patch Changes + +- 9c9a9100b0: Internal refactor to avoid using the deprecated `.icon.svg` extension. +- 06432f900c: Updated `/alpha` exports to use new `attachTo` option. +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-graphql-backend@0.1.44-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-graphql@0.3.24-next.0 + +## @backstage/plugin-graphql-voyager@0.1.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-home@0.5.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-home-react@0.1.4-next.2 + +## @backstage/plugin-home-react@0.1.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + +## @backstage/plugin-ilert@0.2.14-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- 9c9a9100b0: Internal refactor to avoid using the deprecated `.icon.svg` extension. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-jenkins@0.8.7-next.2 + +### Patch Changes + +- 1a05cf34f6: Extend EntityJenkinsContent to receive columns as prop +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-jenkins-common@0.1.20-next.0 + +## @backstage/plugin-jenkins-backend@0.2.9-next.2 + +### Patch Changes + +- 930ac236d8: Added support for the [new backend system](https://backstage.io/docs/backend-system/) +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-jenkins-common@0.1.20-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-jenkins-common@0.1.20-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-kafka@0.3.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-kafka-backend@0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-kubernetes@0.11.0-next.2 + +### Patch Changes + +- 95518765ee: Add Kubernetes cluster plugin. Viewing Kubernetes clusters as an Admin from Backstage +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-react@0.1.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-kubernetes-backend@0.12.3-next.2 + +### Patch Changes + +- cbb0e3c3f4: A new plugin has been introduced to house the extension points for Kubernetes backend plugin; at the moment only the `KubernetesObjectsProviderExtensionPoint` is present. The `kubernetes-backend` plugin was modified to use this new extension point. +- 95518765ee: Add Kubernetes cluster plugin. Viewing Kubernetes clusters as an Admin from Backstage +- 5dac12e435: The kubernetes APIs invokes Authentication Strategies when Backstage-Kubernetes-Authorization-X-X headers are provided, this enable the possibility to invoke strategies that executes additional steps to get a kubernetes token like on pinniped or custom strategies +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-node@0.1.0-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-kubernetes-cluster@0.0.1-next.0 + +### Patch Changes + +- 95518765ee: Add Kubernetes cluster plugin. Viewing Kubernetes clusters as an Admin from Backstage +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-react@0.1.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-kubernetes-common@0.7.0-next.1 + +### Patch Changes + +- 5dac12e435: The kubernetes APIs invokes Authentication Strategies when Backstage-Kubernetes-Authorization-X-X headers are provided, this enable the possibility to invoke strategies that executes additional steps to get a kubernetes token like on pinniped or custom strategies +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-kubernetes-react@0.1.0-next.1 + +### Patch Changes + +- 95518765ee: Add Kubernetes cluster plugin. Viewing Kubernetes clusters as an Admin from Backstage +- 5dac12e435: The kubernetes APIs invokes Authentication Strategies when Backstage-Kubernetes-Authorization-X-X headers are provided, this enable the possibility to invoke strategies that executes additional steps to get a kubernetes token like on pinniped or custom strategies +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/types@1.1.1 + +## @backstage/plugin-lighthouse@0.4.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-lighthouse-common@0.1.4-next.0 + +## @backstage/plugin-lighthouse-backend@0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-lighthouse-common@0.1.4-next.0 + +## @backstage/plugin-lighthouse-common@0.1.4-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-linguist@0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-linguist-common@0.1.2 + +## @backstage/plugin-linguist-backend@0.5.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-linguist-common@0.1.2 + +## @backstage/plugin-microsoft-calendar@0.1.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-newrelic@0.3.41-next.2 + +### Patch Changes + +- ce50a15506: Fixed sorting and searching in the NewRelic table. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-nomad@0.1.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-nomad-backend@0.1.8-next.2 + +### Patch Changes + +- 6822918c50: Added support for the [new backend system](https://backstage.io/docs/backend-system/) +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-octopus-deploy@0.2.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-opencost@0.2.1-next.2 + +### Patch Changes + +- 777b9a16a4: Fix for broken image reference. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-org@0.6.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-org-react@0.1.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + +## @backstage/plugin-pagerduty@0.6.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-home-react@0.1.4-next.2 + +## @backstage/plugin-periskop@0.1.23-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-periskop-backend@0.2.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-permission-backend@0.5.29-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-permission-backend-module-allow-all-policy@0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-permission-common@0.7.9-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-permission-node@0.7.17-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-permission-react@0.4.16-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-playlist@0.1.17-next.2 + +### Patch Changes + +- 65498193e8: Updated Playlist read me with additional screenshots +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + - @backstage/plugin-playlist-common@0.1.11-next.0 + +## @backstage/plugin-playlist-backend@0.3.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-playlist-common@0.1.11-next.0 + +## @backstage/plugin-playlist-common@0.1.11-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-proxy-backend@0.4.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-puppetdb@0.1.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-rollbar@0.4.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-rollbar-backend@0.1.51-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-scaffolder@1.15.1-next.2 + +### Patch Changes + +- ff2ab02690: Make entity picker more reliable with only one available entity +- 83e4a42ccd: Display log visibility button on the template panel +- 4c70fe497d: `RepoUrlPickerRepoName` now correctly handles value changes in allowed repos. +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + - @backstage/plugin-scaffolder-react@1.5.6-next.2 + +## @backstage/plugin-scaffolder-backend-module-confluence-to-markdown@0.2.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-scaffolder-backend-module-cookiecutter@0.2.30-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-scaffolder-backend-module-gitlab@0.2.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-scaffolder-backend-module-rails@0.4.23-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-scaffolder-backend-module-sentry@0.1.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-scaffolder-backend-module-yeoman@0.2.27-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-scaffolder-common@1.4.2-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-scaffolder-node@0.2.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/types@1.1.1 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + +## @backstage/plugin-scaffolder-react@1.5.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + +## @backstage/plugin-search@1.4.1-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-search-backend@1.4.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-openapi-utils@0.0.5-next.0 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-search-backend-module-catalog@0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-search-backend-module-elasticsearch@1.3.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-search-backend-module-explore@0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-explore-common@0.0.2 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-search-backend-module-pg@0.5.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-search-backend-module-techdocs@0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-techdocs-node@1.9.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-search-backend-node@1.2.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-search-common@1.2.7-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/plugin-search-react@1.7.1-next.2 + +### Patch Changes + +- 06432f900c: Updated `/alpha` exports to use new `attachTo` option. +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/frontend-app-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-sentry@0.5.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-shortcuts@0.3.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-sonarqube@0.7.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-sonarqube-react@0.1.9-next.1 + +## @backstage/plugin-sonarqube-backend@0.2.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-sonarqube-react@0.1.9-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + +## @backstage/plugin-splunk-on-call@0.4.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-stack-overflow@0.1.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-home-react@0.1.4-next.2 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-stack-overflow-backend@0.2.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## @backstage/plugin-stackstorm@0.1.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-tech-insights@0.3.17-next.2 + +### Patch Changes + +- 21f409d776: Export `ScorecardInfo` and `ScorecardsList` components to be able to use manually queried check results directly. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-tech-insights-common@0.2.12 + +## @backstage/plugin-tech-insights-backend@0.5.20-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-tech-insights-node@0.4.12-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-tech-insights-common@0.2.12 + +## @backstage/plugin-tech-insights-backend-module-jsonfc@0.1.38-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-tech-insights-node@0.4.12-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-tech-insights-common@0.2.12 + +## @backstage/plugin-tech-insights-node@0.4.12-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-tech-insights-common@0.2.12 + +## @backstage/plugin-tech-radar@0.6.9-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-techdocs@1.7.1-next.2 + +### Patch Changes + +- 3605370af6: Improved `DocsTable` to display pagination controls dynamically, appearing only when needed. +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + +## @backstage/plugin-techdocs-addons-test-utils@1.0.22-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/plugin-techdocs@1.7.1-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/test-utils@1.4.4-next.2 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + +## @backstage/plugin-techdocs-module-addons-contrib@1.1.1-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + +## @backstage/plugin-techdocs-react@1.1.12-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/version-bridge@1.0.5 + +## @backstage/plugin-todo@0.2.28-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-todo-backend@0.3.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-openapi-utils@0.0.5-next.0 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-user-settings@0.7.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + +## @backstage/plugin-user-settings-backend@0.2.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/types@1.1.1 + +## @backstage/plugin-vault@0.1.20-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## @backstage/plugin-vault-backend@0.3.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/config@1.1.1-next.0 + +## @backstage/plugin-xcmetrics@0.2.44-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + +## example-app@0.2.88-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/cli@0.23.0-next.2 + - @backstage/frontend-app-api@0.2.0-next.2 + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/plugin-techdocs@1.7.1-next.2 + - @backstage/plugin-newrelic@0.3.41-next.2 + - @backstage/plugin-scaffolder@1.15.1-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/plugin-tech-radar@0.6.9-next.2 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/plugin-adr@0.6.8-next.2 + - @backstage/plugin-graphiql@0.2.55-next.2 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/plugin-newrelic-dashboard@0.3.0-next.2 + - @backstage/plugin-kubernetes-cluster@0.0.1-next.0 + - @backstage/plugin-kubernetes@0.11.0-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-jenkins@0.8.7-next.2 + - @backstage/plugin-tech-insights@0.3.17-next.2 + - @backstage/plugin-playlist@0.1.17-next.2 + - @backstage/app-defaults@1.4.4-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-airbrake@0.3.25-next.2 + - @backstage/plugin-apache-airflow@0.2.16-next.2 + - @backstage/plugin-api-docs@0.9.12-next.2 + - @backstage/plugin-azure-devops@0.3.7-next.2 + - @backstage/plugin-azure-sites@0.1.14-next.2 + - @backstage/plugin-badges@0.2.49-next.2 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-catalog-graph@0.2.37-next.2 + - @backstage/plugin-catalog-import@0.10.1-next.2 + - @backstage/plugin-catalog-unprocessed-entities@0.1.4-next.2 + - @backstage/plugin-circleci@0.3.25-next.2 + - @backstage/plugin-cloudbuild@0.3.25-next.2 + - @backstage/plugin-code-coverage@0.2.18-next.2 + - @backstage/plugin-cost-insights@0.12.14-next.2 + - @backstage/plugin-devtools@0.1.5-next.2 + - @backstage/plugin-dynatrace@7.0.5-next.2 + - @backstage/plugin-entity-feedback@0.2.8-next.2 + - @backstage/plugin-explore@0.4.11-next.2 + - @backstage/plugin-gcalendar@0.3.19-next.2 + - @backstage/plugin-gcp-projects@0.3.42-next.2 + - @backstage/plugin-github-actions@0.6.6-next.2 + - @backstage/plugin-gocd@0.1.31-next.2 + - @backstage/plugin-home@0.5.9-next.2 + - @backstage/plugin-kafka@0.3.25-next.2 + - @backstage/plugin-lighthouse@0.4.10-next.2 + - @backstage/plugin-linguist@0.1.10-next.2 + - @backstage/plugin-linguist-common@0.1.2 + - @backstage/plugin-microsoft-calendar@0.1.8-next.2 + - @backstage/plugin-nomad@0.1.6-next.2 + - @backstage/plugin-octopus-deploy@0.2.7-next.2 + - @backstage/plugin-org@0.6.15-next.2 + - @backstage/plugin-pagerduty@0.6.6-next.2 + - @backstage/plugin-permission-react@0.4.16-next.1 + - @backstage/plugin-puppetdb@0.1.8-next.2 + - @backstage/plugin-rollbar@0.4.25-next.2 + - @backstage/plugin-scaffolder-react@1.5.6-next.2 + - @backstage/plugin-search@1.4.1-next.2 + - @backstage/plugin-search-common@1.2.7-next.0 + - @backstage/plugin-sentry@0.5.10-next.2 + - @backstage/plugin-shortcuts@0.3.15-next.2 + - @backstage/plugin-stack-overflow@0.1.21-next.2 + - @backstage/plugin-stackstorm@0.1.7-next.2 + - @backstage/plugin-techdocs-module-addons-contrib@1.1.1-next.2 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + - @backstage/plugin-todo@0.2.28-next.2 + - @backstage/plugin-user-settings@0.7.11-next.2 + +## example-app-next@0.0.2-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/cli@0.23.0-next.2 + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/frontend-app-api@0.2.0-next.2 + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/plugin-techdocs@1.7.1-next.2 + - @backstage/plugin-newrelic@0.3.41-next.2 + - @backstage/plugin-scaffolder@1.15.1-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/plugin-tech-radar@0.6.9-next.2 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/plugin-adr@0.6.8-next.2 + - @backstage/plugin-graphiql@0.2.55-next.2 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/plugin-newrelic-dashboard@0.3.0-next.2 + - @backstage/plugin-kubernetes@0.11.0-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-jenkins@0.8.7-next.2 + - @backstage/plugin-tech-insights@0.3.17-next.2 + - @backstage/plugin-playlist@0.1.17-next.2 + - @backstage/app-defaults@1.4.4-next.2 + - app-next-example-plugin@0.0.2-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-airbrake@0.3.25-next.2 + - @backstage/plugin-apache-airflow@0.2.16-next.2 + - @backstage/plugin-api-docs@0.9.12-next.2 + - @backstage/plugin-azure-devops@0.3.7-next.2 + - @backstage/plugin-azure-sites@0.1.14-next.2 + - @backstage/plugin-badges@0.2.49-next.2 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-catalog-graph@0.2.37-next.2 + - @backstage/plugin-catalog-import@0.10.1-next.2 + - @backstage/plugin-catalog-unprocessed-entities@0.1.4-next.2 + - @backstage/plugin-circleci@0.3.25-next.2 + - @backstage/plugin-cloudbuild@0.3.25-next.2 + - @backstage/plugin-code-coverage@0.2.18-next.2 + - @backstage/plugin-cost-insights@0.12.14-next.2 + - @backstage/plugin-devtools@0.1.5-next.2 + - @backstage/plugin-dynatrace@7.0.5-next.2 + - @backstage/plugin-entity-feedback@0.2.8-next.2 + - @backstage/plugin-explore@0.4.11-next.2 + - @backstage/plugin-gcalendar@0.3.19-next.2 + - @backstage/plugin-gcp-projects@0.3.42-next.2 + - @backstage/plugin-github-actions@0.6.6-next.2 + - @backstage/plugin-gocd@0.1.31-next.2 + - @backstage/plugin-home@0.5.9-next.2 + - @backstage/plugin-kafka@0.3.25-next.2 + - @backstage/plugin-lighthouse@0.4.10-next.2 + - @backstage/plugin-linguist@0.1.10-next.2 + - @backstage/plugin-linguist-common@0.1.2 + - @backstage/plugin-microsoft-calendar@0.1.8-next.2 + - @backstage/plugin-octopus-deploy@0.2.7-next.2 + - @backstage/plugin-org@0.6.15-next.2 + - @backstage/plugin-pagerduty@0.6.6-next.2 + - @backstage/plugin-permission-react@0.4.16-next.1 + - @backstage/plugin-puppetdb@0.1.8-next.2 + - @backstage/plugin-rollbar@0.4.25-next.2 + - @backstage/plugin-scaffolder-react@1.5.6-next.2 + - @backstage/plugin-search@1.4.1-next.2 + - @backstage/plugin-search-common@1.2.7-next.0 + - @backstage/plugin-sentry@0.5.10-next.2 + - @backstage/plugin-shortcuts@0.3.15-next.2 + - @backstage/plugin-stack-overflow@0.1.21-next.2 + - @backstage/plugin-stackstorm@0.1.7-next.2 + - @backstage/plugin-techdocs-module-addons-contrib@1.1.1-next.2 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + - @backstage/plugin-todo@0.2.28-next.2 + - @backstage/plugin-user-settings@0.7.11-next.2 + +## app-next-example-plugin@0.0.2-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + +## example-backend@0.2.88-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-nomad-backend@0.1.8-next.2 + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-scaffolder-backend@1.18.0-next.2 + - @backstage/plugin-techdocs-backend@1.8.0-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/plugin-kubernetes-backend@0.12.3-next.2 + - @backstage/plugin-jenkins-backend@0.2.9-next.2 + - @backstage/plugin-auth-backend@0.19.3-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-adr-backend@0.4.3-next.2 + - @backstage/plugin-app-backend@0.3.54-next.2 + - @backstage/plugin-azure-devops-backend@0.4.3-next.2 + - @backstage/plugin-azure-sites-backend@0.1.16-next.2 + - @backstage/plugin-badges-backend@0.3.3-next.2 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.3-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-code-coverage-backend@0.2.20-next.2 + - @backstage/plugin-devtools-backend@0.2.3-next.2 + - @backstage/plugin-entity-feedback-backend@0.2.3-next.2 + - @backstage/plugin-events-backend@0.2.15-next.2 + - @backstage/plugin-explore-backend@0.0.16-next.2 + - @backstage/plugin-graphql-backend@0.1.44-next.2 + - @backstage/plugin-kafka-backend@0.3.3-next.2 + - @backstage/plugin-lighthouse-backend@0.3.3-next.2 + - @backstage/plugin-linguist-backend@0.5.3-next.2 + - @backstage/plugin-permission-backend@0.5.29-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-playlist-backend@0.3.10-next.2 + - @backstage/plugin-proxy-backend@0.4.3-next.2 + - @backstage/plugin-rollbar-backend@0.1.51-next.2 + - @backstage/plugin-scaffolder-backend-module-confluence-to-markdown@0.2.7-next.2 + - @backstage/plugin-scaffolder-backend-module-rails@0.4.23-next.2 + - @backstage/plugin-search-backend@1.4.6-next.2 + - @backstage/plugin-search-backend-module-catalog@0.1.10-next.2 + - @backstage/plugin-search-backend-module-elasticsearch@1.3.9-next.2 + - @backstage/plugin-search-backend-module-explore@0.1.10-next.2 + - @backstage/plugin-search-backend-module-pg@0.5.15-next.2 + - @backstage/plugin-search-backend-module-techdocs@0.1.10-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/plugin-tech-insights-backend@0.5.20-next.2 + - @backstage/plugin-tech-insights-backend-module-jsonfc@0.1.38-next.2 + - @backstage/plugin-tech-insights-node@0.4.12-next.2 + - @backstage/plugin-todo-backend@0.3.4-next.2 + - example-app@0.2.88-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-backend-module-unprocessed@0.3.3-next.2 + - @backstage/plugin-events-node@0.2.15-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## example-backend-next@0.0.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-nomad-backend@0.1.8-next.2 + - @backstage/plugin-scaffolder-backend@1.18.0-next.2 + - @backstage/plugin-techdocs-backend@1.8.0-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/plugin-kubernetes-backend@0.12.3-next.2 + - @backstage/plugin-jenkins-backend@0.2.9-next.2 + - @backstage/backend-defaults@0.2.6-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-adr-backend@0.4.3-next.2 + - @backstage/plugin-app-backend@0.3.54-next.2 + - @backstage/plugin-azure-devops-backend@0.4.3-next.2 + - @backstage/plugin-badges-backend@0.3.3-next.2 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.3-next.2 + - @backstage/plugin-devtools-backend@0.2.3-next.2 + - @backstage/plugin-entity-feedback-backend@0.2.3-next.2 + - @backstage/plugin-lighthouse-backend@0.3.3-next.2 + - @backstage/plugin-linguist-backend@0.5.3-next.2 + - @backstage/plugin-permission-backend@0.5.29-next.2 + - @backstage/plugin-permission-backend-module-allow-all-policy@0.1.3-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-playlist-backend@0.3.10-next.2 + - @backstage/plugin-proxy-backend@0.4.3-next.2 + - @backstage/plugin-search-backend@1.4.6-next.2 + - @backstage/plugin-search-backend-module-catalog@0.1.10-next.2 + - @backstage/plugin-search-backend-module-explore@0.1.10-next.2 + - @backstage/plugin-search-backend-module-techdocs@0.1.10-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/plugin-sonarqube-backend@0.2.8-next.2 + - @backstage/plugin-todo-backend@0.3.4-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-catalog-backend-module-unprocessed@0.3.3-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + +## @backstage/backend-plugin-manager@0.0.2-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-events-backend@0.2.15-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/cli-node@0.1.5-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-events-node@0.2.15-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + +## e2e-test@0.2.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/create-app@0.5.6-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + +## techdocs-cli-embedded-app@0.2.87-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/cli@0.23.0-next.2 + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/plugin-techdocs@1.7.1-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/app-defaults@1.4.4-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/test-utils@1.4.4-next.2 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + +## @internal/plugin-todo-list@1.0.18-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + +## @internal/plugin-todo-list-backend@1.0.18-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + +## @internal/plugin-todo-list-common@1.0.14-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-permission-common@0.7.9-next.0 diff --git a/microsite/data/plugins/dynatrace.yaml b/microsite/data/plugins/dynatrace.yaml index 9ec1fee7b3..94a2e423a6 100644 --- a/microsite/data/plugins/dynatrace.yaml +++ b/microsite/data/plugins/dynatrace.yaml @@ -1,13 +1,15 @@ --- title: Dynatrace -author: TELUS -authorUrl: https://github.com/telus +author: Dynatrace +authorUrl: https://github.com/dynatrace category: Monitoring description: View monitoring info from Dynatrace for services in your software catalog. documentation: https://github.com/backstage/backstage/tree/master/plugins/dynatrace iconUrl: /img/dynatrace.svg npmPackageName: '@backstage/plugin-dynatrace' tags: - - dynatrace - monitoring + - observability + - alerting + - problems addedDate: '2022-06-23' diff --git a/microsite/package.json b/microsite/package.json index 9d866ef2f7..3f266c189e 100644 --- a/microsite/package.json +++ b/microsite/package.json @@ -17,7 +17,7 @@ "docusaurus": "docusaurus" }, "devDependencies": { - "@docusaurus/module-type-aliases": "0.0.0-5701", + "@docusaurus/module-type-aliases": "0.0.0-5703", "@spotify/prettier-config": "^14.0.0", "@tsconfig/docusaurus": "^1.0.6", "@types/luxon": "^3.0.0", @@ -29,9 +29,9 @@ }, "prettier": "@spotify/prettier-config", "dependencies": { - "@docusaurus/core": "0.0.0-5701", - "@docusaurus/plugin-client-redirects": "0.0.0-5701", - "@docusaurus/preset-classic": "0.0.0-5701", + "@docusaurus/core": "0.0.0-5703", + "@docusaurus/plugin-client-redirects": "0.0.0-5703", + "@docusaurus/preset-classic": "0.0.0-5703", "@swc/core": "^1.3.46", "clsx": "^1.1.1", "docusaurus-plugin-sass": "^0.2.3", diff --git a/microsite/yarn.lock b/microsite/yarn.lock index 9ce77b67f6..835727014c 100644 --- a/microsite/yarn.lock +++ b/microsite/yarn.lock @@ -1689,9 +1689,9 @@ __metadata: languageName: node linkType: hard -"@docusaurus/core@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/core@npm:0.0.0-5701" +"@docusaurus/core@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/core@npm:0.0.0-5703" dependencies: "@babel/core": ^7.22.9 "@babel/generator": ^7.22.9 @@ -1703,13 +1703,13 @@ __metadata: "@babel/runtime": ^7.22.6 "@babel/runtime-corejs3": ^7.22.6 "@babel/traverse": ^7.22.8 - "@docusaurus/cssnano-preset": 0.0.0-5701 - "@docusaurus/logger": 0.0.0-5701 - "@docusaurus/mdx-loader": 0.0.0-5701 + "@docusaurus/cssnano-preset": 0.0.0-5703 + "@docusaurus/logger": 0.0.0-5703 + "@docusaurus/mdx-loader": 0.0.0-5703 "@docusaurus/react-loadable": 5.5.2 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-common": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-common": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 "@slorber/static-site-generator-webpack-plugin": ^4.0.7 "@svgr/webpack": ^6.5.1 autoprefixer: ^10.4.14 @@ -1769,41 +1769,41 @@ __metadata: react-dom: ^18.0.0 bin: docusaurus: bin/docusaurus.mjs - checksum: e94df1bbbb6d5fe19c1e65fbf5e0555d29478360da0adba6686865757fba34665c6f69d06665e6f96e958750d5e70027280ce178542e62d74a2045f8eda81c6a + checksum: 0e2912a09964778db626dc190317badb074f2f5e09157b8070f281eff69ce2e89846529584ce9bf6e6898293409c353adc80572484aceda1d2136aa2b0b334ca languageName: node linkType: hard -"@docusaurus/cssnano-preset@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/cssnano-preset@npm:0.0.0-5701" +"@docusaurus/cssnano-preset@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/cssnano-preset@npm:0.0.0-5703" dependencies: cssnano-preset-advanced: ^5.3.10 postcss: ^8.4.26 postcss-sort-media-queries: ^4.4.1 tslib: ^2.6.0 - checksum: c3b9dc09c77ed23f43f469882e0ba99c6b0c690f94f087caa8af9051fcb60b42ccc8a03f680a870fae7a8fdb95b0b79870ddb48082576a4dddd59223e3b07c18 + checksum: 5f6e2a69765fb18de7d8f5e3037bf4f08695034762fca092229ae0ba9a40e9b76048914ffbf6b1d339d496e23580f47aa419f51f446c98fca0ba8d500a06e396 languageName: node linkType: hard -"@docusaurus/logger@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/logger@npm:0.0.0-5701" +"@docusaurus/logger@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/logger@npm:0.0.0-5703" dependencies: chalk: ^4.1.2 tslib: ^2.6.0 - checksum: a3ce329648b19f079b6d9da96c9acb3198d53504e4ff000456245ca321994b6dfee85b5ef410e13ceaa7b2928bf157d2ceba41fd32a27d1f00a685585fc80a60 + checksum: 9ee30b054388e5a618876316df50b73a7c4c8300ce205ace3c09f689a1a38b85d51891a1f0613341fd038a0d06290f0675d64c3e9e5b87f1eee3cb76fd45b55c languageName: node linkType: hard -"@docusaurus/mdx-loader@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/mdx-loader@npm:0.0.0-5701" +"@docusaurus/mdx-loader@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/mdx-loader@npm:0.0.0-5703" dependencies: "@babel/parser": ^7.22.7 "@babel/traverse": ^7.22.8 - "@docusaurus/logger": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/logger": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 "@mdx-js/mdx": ^2.1.5 "@slorber/remark-comment": ^1.0.0 escape-html: ^1.0.3 @@ -1817,26 +1817,28 @@ __metadata: rehype-raw: ^6.1.1 remark-directive: ^2.0.1 remark-emoji: ^2.2.0 + remark-frontmatter: ^5.0.0 remark-gfm: ^3.0.1 stringify-object: ^3.3.0 tslib: ^2.6.0 unified: ^10.1.2 unist-util-visit: ^2.0.3 url-loader: ^4.1.1 + vfile: ^5.3.7 webpack: ^5.88.1 peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 334c0b0b27675223252184d7dc8b347ff2e2718af107dad7e8e88e0895f15d57843b054170561f6242fe356aaa7c15916a62349f6dc9fa172cd7269137fe8b36 + checksum: d57b08d7d676b9246be129af06a803fc55162359578e486456cb96a2372809c2093ef4115c926cf8e8be35e285b35d3ea444d808d46afb78edf66b49f58474fb languageName: node linkType: hard -"@docusaurus/module-type-aliases@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/module-type-aliases@npm:0.0.0-5701" +"@docusaurus/module-type-aliases@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/module-type-aliases@npm:0.0.0-5703" dependencies: "@docusaurus/react-loadable": 5.5.2 - "@docusaurus/types": 0.0.0-5701 + "@docusaurus/types": 0.0.0-5703 "@types/history": ^4.7.11 "@types/react": "*" "@types/react-router-config": "*" @@ -1846,19 +1848,19 @@ __metadata: peerDependencies: react: "*" react-dom: "*" - checksum: 1f4e5a0698c59c354a172ffcb80727f9499588827ec8796ea95892569fbcc7a5f63005ce0c1d4ffdab5c04263537a33055659f6d3765d9ab5076c4bf524339a4 + checksum: b0dbf719f3c6510b6706f36310b185bdf8a8a2ab5d3b0b76f8962b08d3b1a86783c3f4c23455c03d528500871f0a18ede4e03a0df8c7a44096b91097a5ffda7d languageName: node linkType: hard -"@docusaurus/plugin-client-redirects@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-client-redirects@npm:0.0.0-5701" +"@docusaurus/plugin-client-redirects@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-client-redirects@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/logger": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-common": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/logger": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-common": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 eta: ^2.2.0 fs-extra: ^11.1.1 lodash: ^4.17.21 @@ -1866,21 +1868,21 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 43b32620063bd0a206653365e17faf94c0cf44a094d8eed753bb3f9e6f68fe9ca9b6280aa44dcecdad163394f3bafa7dc9a53a234cab3530040047a08b4bf3dc + checksum: ac246eeb75028acd6a1d8804572fb89bac5575facf82c35ca3c8441d916980c183f5342a768d31cccc95f2034657bd25cfda24d480a2b8b4abdd693a51d9754e languageName: node linkType: hard -"@docusaurus/plugin-content-blog@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-content-blog@npm:0.0.0-5701" +"@docusaurus/plugin-content-blog@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-content-blog@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/logger": 0.0.0-5701 - "@docusaurus/mdx-loader": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-common": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/logger": 0.0.0-5703 + "@docusaurus/mdx-loader": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-common": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 cheerio: ^1.0.0-rc.12 feed: ^4.2.2 fs-extra: ^11.1.1 @@ -1894,21 +1896,21 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: a96057ab4acbededefa46ab52e05d52150b6ef9dcedad25c0b590c67fe06e5965aef3a8d04eaab168470f1975122afe7f1e1d61ecb7ecefb3b6e08c3dc75dd85 + checksum: 46e4a4fac407a8014ce0918933a476b03adca3d3b7e76b27a87bf0eeeb446f20e25db60b292f743652f3ad88232824f7a1541fcb7d27bcdbf9cb6d1c94e9a1b5 languageName: node linkType: hard -"@docusaurus/plugin-content-docs@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-content-docs@npm:0.0.0-5701" +"@docusaurus/plugin-content-docs@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-content-docs@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/logger": 0.0.0-5701 - "@docusaurus/mdx-loader": 0.0.0-5701 - "@docusaurus/module-type-aliases": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/logger": 0.0.0-5703 + "@docusaurus/mdx-loader": 0.0.0-5703 + "@docusaurus/module-type-aliases": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 "@types/react-router-config": ^5.0.7 combine-promises: ^1.1.0 fs-extra: ^11.1.1 @@ -1921,133 +1923,133 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: d0eef3361f839fd9719140c1212a4516531cb1b324420b06717dcf9e1c234a7d2e0256175a19e7a0a7e40101dc326ec0771decbfca1e24a61785d397908ff86c + checksum: b08fbbac78f76ca68fc4a8ba488f41709733727e073d5f2d1e671dab484c4d37729a657305b315052369292ec7ae83c32992e551eda1d0990c035aa84fecbac6 languageName: node linkType: hard -"@docusaurus/plugin-content-pages@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-content-pages@npm:0.0.0-5701" +"@docusaurus/plugin-content-pages@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-content-pages@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/mdx-loader": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/mdx-loader": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 fs-extra: ^11.1.1 tslib: ^2.6.0 webpack: ^5.88.1 peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 525e6a70271e25df7a19510165aec1bb4c12bdf3265e5c7f13d4c54c5ee56e0da89b11ef869da87efa9a6260054f9c46780daf6ef486d9be527b8d22401a4762 + checksum: 9d0b904259c625d82175fa3fdeae89de8503f409a7dc47c9077f35d25f72fcf76a0a6392f5e790c3bf2604896e1aa0fced00386b9df553f6ba01247ccadd6503 languageName: node linkType: hard -"@docusaurus/plugin-debug@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-debug@npm:0.0.0-5701" +"@docusaurus/plugin-debug@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-debug@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 "@microlink/react-json-view": ^1.22.2 fs-extra: ^11.1.1 tslib: ^2.6.0 peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 0203cbfef9da0ecbfcbc6e684893bf1b945e65554b55380a7a6bd5ad8e03ee1bda1c7605ff5cc484ae0a6af691104043db33b5ca1bf30254db7909e108a077c7 + checksum: b9bf04c27144dc797fa25cae6df95f5a8b15c888993194bf1b0fae06ce6ae55cf338270b7a914ef07d6551addd6261e628a465c4f277a4e13753c207e533557d languageName: node linkType: hard -"@docusaurus/plugin-google-analytics@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-google-analytics@npm:0.0.0-5701" +"@docusaurus/plugin-google-analytics@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-google-analytics@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 tslib: ^2.6.0 peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: bc43cf34912e79116141de8dcd9aa4629d810d0ade9c0fd2ebc0ab9dd235cac5aad4ffb1524eebf19c697d8385afe2dc66909fa5ec791ee592f59524a146da4c + checksum: ad98ea301caa4908197a3c460ae88dd5598c1485d8643708e8fb3f757ae3bf854efc1b5a1ab9c8ba15371c3a989704d7f9fdb55dd25d1d1b81936526068a877b languageName: node linkType: hard -"@docusaurus/plugin-google-gtag@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-google-gtag@npm:0.0.0-5701" +"@docusaurus/plugin-google-gtag@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-google-gtag@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 "@types/gtag.js": ^0.0.12 tslib: ^2.6.0 peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 456ab8a2a6e17142c61d92f353ad83ae8db3753e22f2c2f171ce73185da3e8ab9c64f2ba6ad8b7a4ae03363ac783c6231aa39567a923e406b51afd8ad5cf4a74 + checksum: 9fbdbc0569f1ff634c357d197c1442da17c4a09c03163640db1d1bde0be8612dd432e494a4f02eb43ac58dd7df2cbd335911fdb7fa315a9de95e173090daf5dc languageName: node linkType: hard -"@docusaurus/plugin-google-tag-manager@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-google-tag-manager@npm:0.0.0-5701" +"@docusaurus/plugin-google-tag-manager@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-google-tag-manager@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 tslib: ^2.6.0 peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 18239f2ddc48a493f9c0e43c0c2417e83cb8a8c63926202dfabd33bc34f2811eda9d8e827f13984ad42148900bc667772239878a24e0cfa297a89b381f2cc614 + checksum: 3ed2c6eb05087db3877ffe98cc6eca59be80889411e3cdbd981ac4d951a5efa269a1011a39a94c997d93474fd916e3634905a6537e10575e5d5a954a9bb00c5d languageName: node linkType: hard -"@docusaurus/plugin-sitemap@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/plugin-sitemap@npm:0.0.0-5701" +"@docusaurus/plugin-sitemap@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/plugin-sitemap@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/logger": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-common": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/logger": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-common": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 fs-extra: ^11.1.1 sitemap: ^7.1.1 tslib: ^2.6.0 peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 48c5f27b4b38d895253ca4d4a7afaa957b9a780c92cb87ad51aee06379f3f2426e97907bd0ff697753a673e56edc21f699bf7bbdf7302c4b9dc8ac52c2f8d669 + checksum: 1afbd2e3575ae09428fb4c53a2563e313c3e1a2323c79bdc256779c56f8d796c2c94473d055d6d7a97d477f06e35f0922bed441f7c3e1467feeb5329e1f7761b languageName: node linkType: hard -"@docusaurus/preset-classic@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/preset-classic@npm:0.0.0-5701" +"@docusaurus/preset-classic@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/preset-classic@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/plugin-content-blog": 0.0.0-5701 - "@docusaurus/plugin-content-docs": 0.0.0-5701 - "@docusaurus/plugin-content-pages": 0.0.0-5701 - "@docusaurus/plugin-debug": 0.0.0-5701 - "@docusaurus/plugin-google-analytics": 0.0.0-5701 - "@docusaurus/plugin-google-gtag": 0.0.0-5701 - "@docusaurus/plugin-google-tag-manager": 0.0.0-5701 - "@docusaurus/plugin-sitemap": 0.0.0-5701 - "@docusaurus/theme-classic": 0.0.0-5701 - "@docusaurus/theme-common": 0.0.0-5701 - "@docusaurus/theme-search-algolia": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/plugin-content-blog": 0.0.0-5703 + "@docusaurus/plugin-content-docs": 0.0.0-5703 + "@docusaurus/plugin-content-pages": 0.0.0-5703 + "@docusaurus/plugin-debug": 0.0.0-5703 + "@docusaurus/plugin-google-analytics": 0.0.0-5703 + "@docusaurus/plugin-google-gtag": 0.0.0-5703 + "@docusaurus/plugin-google-tag-manager": 0.0.0-5703 + "@docusaurus/plugin-sitemap": 0.0.0-5703 + "@docusaurus/theme-classic": 0.0.0-5703 + "@docusaurus/theme-common": 0.0.0-5703 + "@docusaurus/theme-search-algolia": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: abbe6f0968dafa0ef6a2cfb02d75a5d7b6ff9a5b90dc9d252e16ece0bb51b04378bc6199139a4f517dde85520eacaf4fb5cbe0330dcb7e7aa2ef5e466c7ee9ff + checksum: d4c2e6e02b828b248351819410fe03e94a4b4fd8489e398b60d128ba8f173548f8353a3875ff0347179ee59e84df7e3e9e1e5b0be24b84f015c8c02b650eb80c languageName: node linkType: hard @@ -2063,22 +2065,22 @@ __metadata: languageName: node linkType: hard -"@docusaurus/theme-classic@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/theme-classic@npm:0.0.0-5701" +"@docusaurus/theme-classic@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/theme-classic@npm:0.0.0-5703" dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/mdx-loader": 0.0.0-5701 - "@docusaurus/module-type-aliases": 0.0.0-5701 - "@docusaurus/plugin-content-blog": 0.0.0-5701 - "@docusaurus/plugin-content-docs": 0.0.0-5701 - "@docusaurus/plugin-content-pages": 0.0.0-5701 - "@docusaurus/theme-common": 0.0.0-5701 - "@docusaurus/theme-translations": 0.0.0-5701 - "@docusaurus/types": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-common": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/mdx-loader": 0.0.0-5703 + "@docusaurus/module-type-aliases": 0.0.0-5703 + "@docusaurus/plugin-content-blog": 0.0.0-5703 + "@docusaurus/plugin-content-docs": 0.0.0-5703 + "@docusaurus/plugin-content-pages": 0.0.0-5703 + "@docusaurus/theme-common": 0.0.0-5703 + "@docusaurus/theme-translations": 0.0.0-5703 + "@docusaurus/types": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-common": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 "@mdx-js/react": ^2.1.5 clsx: ^1.2.1 copy-text-to-clipboard: ^3.2.0 @@ -2095,21 +2097,21 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 81f54ac606f0f5a2907dcc5d0344fcb95707cd0cf3c630a547f57bb8e87a519a1f44fbb71a1eec07ef35d8f6c9b4b6e9810f31fdd02a1c72590d1e9abdf135d1 + checksum: ba078e06a07bbcc4a474f67938760852146e0cb612e44bc81b22879d374372eeea076de6e46e9f955dd351f37dadd98ced2e70b6b8a476b88684fae40855ecb9 languageName: node linkType: hard -"@docusaurus/theme-common@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/theme-common@npm:0.0.0-5701" +"@docusaurus/theme-common@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/theme-common@npm:0.0.0-5703" dependencies: - "@docusaurus/mdx-loader": 0.0.0-5701 - "@docusaurus/module-type-aliases": 0.0.0-5701 - "@docusaurus/plugin-content-blog": 0.0.0-5701 - "@docusaurus/plugin-content-docs": 0.0.0-5701 - "@docusaurus/plugin-content-pages": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-common": 0.0.0-5701 + "@docusaurus/mdx-loader": 0.0.0-5703 + "@docusaurus/module-type-aliases": 0.0.0-5703 + "@docusaurus/plugin-content-blog": 0.0.0-5703 + "@docusaurus/plugin-content-docs": 0.0.0-5703 + "@docusaurus/plugin-content-pages": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-common": 0.0.0-5703 "@types/history": ^4.7.11 "@types/react": "*" "@types/react-router-config": "*" @@ -2121,22 +2123,22 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 6543460f37ca8b9ab5efa4b94039f77a8bd6254a49d122175d6a3524079bf72e3f4993523b8ea80ce33dce4bf6a60c4c2970f5c444fde2562603638560cbe8a5 + checksum: f9b23318dbb504bcce0992de475f1ab32860620523dfe749bfdb00ac8e7fc75be705fd5177db2ce893ed269de40cef7f6a7290d44a12c6a160d9461bbca05552 languageName: node linkType: hard -"@docusaurus/theme-search-algolia@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/theme-search-algolia@npm:0.0.0-5701" +"@docusaurus/theme-search-algolia@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/theme-search-algolia@npm:0.0.0-5703" dependencies: "@docsearch/react": ^3.5.2 - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/logger": 0.0.0-5701 - "@docusaurus/plugin-content-docs": 0.0.0-5701 - "@docusaurus/theme-common": 0.0.0-5701 - "@docusaurus/theme-translations": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 - "@docusaurus/utils-validation": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/logger": 0.0.0-5703 + "@docusaurus/plugin-content-docs": 0.0.0-5703 + "@docusaurus/theme-common": 0.0.0-5703 + "@docusaurus/theme-translations": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 + "@docusaurus/utils-validation": 0.0.0-5703 algoliasearch: ^4.18.0 algoliasearch-helper: ^3.13.3 clsx: ^1.2.1 @@ -2148,23 +2150,23 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: 77c651991dd9b06e18ff2fad5a0b6947a98bfa562c4888c01ce2c8057767bf416575b177fe4cd93988c14b78b30cdd3a2f44fe7deb583115f8372a9f8456dc2e + checksum: 2e8ccc603126634488332ae108f9ac9ad3d2e1e46b5abef48720f2a25ae5cfc93850301d4ea30a6dc66034877b6abedd31229f622c6fd181347c3c14f7ba3c66 languageName: node linkType: hard -"@docusaurus/theme-translations@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/theme-translations@npm:0.0.0-5701" +"@docusaurus/theme-translations@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/theme-translations@npm:0.0.0-5703" dependencies: fs-extra: ^11.1.1 tslib: ^2.6.0 - checksum: 7c9c1405ee03633fce2ca5f7409984980881538c459204b2060410ccdaf8ac69232381e1ed851ce68f34bce32ac0fea054d8aec400f7073e66b8f3602c0a6d50 + checksum: 1f952386982008e2e7b07d6b95b1a902a57891321ae2670f13f391a541944ec2c82f5e03d3ed2c459a17113387a51cb5efe824d03037a3cc0b25251451287d1d languageName: node linkType: hard -"@docusaurus/types@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/types@npm:0.0.0-5701" +"@docusaurus/types@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/types@npm:0.0.0-5703" dependencies: "@types/history": ^4.7.11 "@types/react": "*" @@ -2177,13 +2179,13 @@ __metadata: peerDependencies: react: ^18.0.0 react-dom: ^18.0.0 - checksum: cf6c042a549002dcc5fa90cb68e590ac7b3c736dac2ae85c1b1864d4bd4b1ee3d35f82739ca08d29aba6913832a9c36cc678d72e963e335aa5e24d63a4e87b26 + checksum: 46ca6a27c8a0d1b69f744375ee2c24be2deed20c2801231a462b2e37b7a6e1f73ab17b6a5506e05f628957be8be74e4cd960780b9986c8fa4ac1757bd8c74231 languageName: node linkType: hard -"@docusaurus/utils-common@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/utils-common@npm:0.0.0-5701" +"@docusaurus/utils-common@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/utils-common@npm:0.0.0-5703" dependencies: tslib: ^2.6.0 peerDependencies: @@ -2191,28 +2193,28 @@ __metadata: peerDependenciesMeta: "@docusaurus/types": optional: true - checksum: d92c10503784241c3c3c71b136c9fb325644a2fcf11f8e4c9b4605bd4fb5544f60c828be4291b39285053acb6453c85091a78cf8394d73bb3e990f133bfba73e + checksum: 8f70f176a99bcbbde22abd759621087ad555e7967cddf85662402f6d55c84d5f44cc1a90bf4e64670fc75b6db646dca4f573b3656a1718d1596d60e0e6c2d23a languageName: node linkType: hard -"@docusaurus/utils-validation@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/utils-validation@npm:0.0.0-5701" +"@docusaurus/utils-validation@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/utils-validation@npm:0.0.0-5703" dependencies: - "@docusaurus/logger": 0.0.0-5701 - "@docusaurus/utils": 0.0.0-5701 + "@docusaurus/logger": 0.0.0-5703 + "@docusaurus/utils": 0.0.0-5703 joi: ^17.9.2 js-yaml: ^4.1.0 tslib: ^2.6.0 - checksum: 3a390346556bdd99bb2145455810462e674d51d6030333300022bd8b0bb15b6b1136e03dcbc1a92daf1175a6c5ff913b2d891db93fc17b1557f1f3aca019f8c0 + checksum: e0d6df549644d8e732daf5407ce110dbccba17dcf84fe1a80091119675d2ce515e26bf6612fefa60b7df2c65dbaeee7ceb1a9f2b947a3705fe1efc7c229794e2 languageName: node linkType: hard -"@docusaurus/utils@npm:0.0.0-5701": - version: 0.0.0-5701 - resolution: "@docusaurus/utils@npm:0.0.0-5701" +"@docusaurus/utils@npm:0.0.0-5703": + version: 0.0.0-5703 + resolution: "@docusaurus/utils@npm:0.0.0-5703" dependencies: - "@docusaurus/logger": 0.0.0-5701 + "@docusaurus/logger": 0.0.0-5703 "@svgr/webpack": ^6.5.1 escape-string-regexp: ^4.0.0 file-loader: ^6.2.0 @@ -2233,7 +2235,7 @@ __metadata: peerDependenciesMeta: "@docusaurus/types": optional: true - checksum: aeef3b1bdcd52b8c466390036fbbcc02443cc4c5d9faf0e6785f5ee0f01e1d39ab4021ea90981f6d70e56041fa57ad398cbfd5fec526e883293ae6cb71168fba + checksum: 91f53b17393e29fadb01c039f5394fc257c54bd7d80068f3a3e8a5e52d635d2e3de9fe781340de2ff4eaf691a2d4104865291c05c22ffc8b48a0894f588f3a9e languageName: node linkType: hard @@ -3068,6 +3070,15 @@ __metadata: languageName: node linkType: hard +"@types/mdast@npm:^4.0.0": + version: 4.0.1 + resolution: "@types/mdast@npm:4.0.1" + dependencies: + "@types/unist": "*" + checksum: 3d8fe54a6fb747376c4cc2f05c319730a5737b77844d8ea58d2d696417fa933cd270c20e197f531fc1b4be5e340dc416129f8b4f5fa2f0d2d0cf51850928340a + languageName: node + linkType: hard + "@types/mdx@npm:^2.0.0": version: 2.0.5 resolution: "@types/mdx@npm:2.0.5" @@ -3239,7 +3250,14 @@ __metadata: languageName: node linkType: hard -"@types/unist@npm:*, @types/unist@npm:^2.0.0": +"@types/unist@npm:*, @types/unist@npm:^3.0.0": + version: 3.0.0 + resolution: "@types/unist@npm:3.0.0" + checksum: e9d21a8fb5e332be0acef29192d82632875b2ef3e700f1bc64fdfc1520189542de85c3d4f3bcfbc2f4afdb210f4c23f68061f3fbf10744e920d4f18430d19f49 + languageName: node + linkType: hard + +"@types/unist@npm:^2.0.0": version: 2.0.6 resolution: "@types/unist@npm:2.0.6" checksum: 25cb860ff10dde48b54622d58b23e66214211a61c84c0f15f88d38b61aa1b53d4d46e42b557924a93178c501c166aa37e28d7f6d994aba13d24685326272d5db @@ -3870,10 +3888,10 @@ __metadata: version: 0.0.0-use.local resolution: "backstage-microsite@workspace:." dependencies: - "@docusaurus/core": 0.0.0-5701 - "@docusaurus/module-type-aliases": 0.0.0-5701 - "@docusaurus/plugin-client-redirects": 0.0.0-5701 - "@docusaurus/preset-classic": 0.0.0-5701 + "@docusaurus/core": 0.0.0-5703 + "@docusaurus/module-type-aliases": 0.0.0-5703 + "@docusaurus/plugin-client-redirects": 0.0.0-5703 + "@docusaurus/preset-classic": 0.0.0-5703 "@spotify/prettier-config": ^14.0.0 "@swc/core": ^1.3.46 "@tsconfig/docusaurus": ^1.0.6 @@ -5106,6 +5124,15 @@ __metadata: languageName: node linkType: hard +"devlop@npm:^1.0.0": + version: 1.1.0 + resolution: "devlop@npm:1.1.0" + dependencies: + dequal: ^2.0.0 + checksum: d2ff650bac0bb6ef08c48f3ba98640bb5fec5cce81e9957eb620408d1bab1204d382a45b785c6b3314dc867bb0684936b84c6867820da6db97cbb5d3c15dd185 + languageName: node + linkType: hard + "diff@npm:^5.0.0": version: 5.1.0 resolution: "diff@npm:5.1.0" @@ -5687,6 +5714,15 @@ __metadata: languageName: node linkType: hard +"fault@npm:^2.0.0": + version: 2.0.1 + resolution: "fault@npm:2.0.1" + dependencies: + format: ^0.2.0 + checksum: c9b30f47d95769177130a9409976a899ed31eb598450fbad5b0d39f2f5f56d5f4a9ff9257e0bee8407cb0fc3ce37165657888c6aa6d78472e403893104329b72 + languageName: node + linkType: hard + "faye-websocket@npm:^0.11.3": version: 0.11.4 resolution: "faye-websocket@npm:0.11.4" @@ -5889,6 +5925,13 @@ __metadata: languageName: node linkType: hard +"format@npm:^0.2.0": + version: 0.2.2 + resolution: "format@npm:0.2.2" + checksum: 646a60e1336250d802509cf24fb801e43bd4a70a07510c816fa133aa42cdbc9c21e66e9cc0801bb183c5b031c9d68be62e7fbb6877756e52357850f92aa28799 + languageName: node + linkType: hard + "forwarded@npm:0.2.0": version: 0.2.0 resolution: "forwarded@npm:0.2.0" @@ -7621,6 +7664,40 @@ __metadata: languageName: node linkType: hard +"mdast-util-from-markdown@npm:^2.0.0": + version: 2.0.0 + resolution: "mdast-util-from-markdown@npm:2.0.0" + dependencies: + "@types/mdast": ^4.0.0 + "@types/unist": ^3.0.0 + decode-named-character-reference: ^1.0.0 + devlop: ^1.0.0 + mdast-util-to-string: ^4.0.0 + micromark: ^4.0.0 + micromark-util-decode-numeric-character-reference: ^2.0.0 + micromark-util-decode-string: ^2.0.0 + micromark-util-normalize-identifier: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + unist-util-stringify-position: ^4.0.0 + checksum: 4e8d8a46b4b588486c41b80c39da333a91593bc8d60cd7421c6cd3c22003b8e5a62478292fb7bc97b9255b6301a2250cca32340ef43c309156e215453c5b92be + languageName: node + linkType: hard + +"mdast-util-frontmatter@npm:^2.0.0": + version: 2.0.1 + resolution: "mdast-util-frontmatter@npm:2.0.1" + dependencies: + "@types/mdast": ^4.0.0 + devlop: ^1.0.0 + escape-string-regexp: ^5.0.0 + mdast-util-from-markdown: ^2.0.0 + mdast-util-to-markdown: ^2.0.0 + micromark-extension-frontmatter: ^2.0.0 + checksum: 86a7c8d9eb183be2621d6d9134b9d33df2a3647e3255f68a9796e2425e25643ffae00a501e36c57d9c10973087b94aa5a2ffd865d33cdd274cc9b88cd2d90a2e + languageName: node + linkType: hard + "mdast-util-gfm-autolink-literal@npm:^1.0.0": version: 1.0.3 resolution: "mdast-util-gfm-autolink-literal@npm:1.0.3" @@ -7760,6 +7837,16 @@ __metadata: languageName: node linkType: hard +"mdast-util-phrasing@npm:^4.0.0": + version: 4.0.0 + resolution: "mdast-util-phrasing@npm:4.0.0" + dependencies: + "@types/mdast": ^4.0.0 + unist-util-is: ^6.0.0 + checksum: 95d5d8e18d5ea6dbfe2ee4ed1045961372efae9077e5c98e10bfef7025ee3fd9449f9a82840068ff50aa98fa43af0a0a14898ae10b5e46e96edde01e2797df34 + languageName: node + linkType: hard + "mdast-util-to-hast@npm:^12.1.0": version: 12.3.0 resolution: "mdast-util-to-hast@npm:12.3.0" @@ -7792,6 +7879,22 @@ __metadata: languageName: node linkType: hard +"mdast-util-to-markdown@npm:^2.0.0": + version: 2.1.0 + resolution: "mdast-util-to-markdown@npm:2.1.0" + dependencies: + "@types/mdast": ^4.0.0 + "@types/unist": ^3.0.0 + longest-streak: ^3.0.0 + mdast-util-phrasing: ^4.0.0 + mdast-util-to-string: ^4.0.0 + micromark-util-decode-string: ^2.0.0 + unist-util-visit: ^5.0.0 + zwitch: ^2.0.0 + checksum: 3a2cf3957e23b34e2e092e6e76ae72ee0b8745955bd811baba6814cf3a3d916c3fd52264b4b58f3bb3d512a428f84a1e998b6fc7e28434e388a9ae8fb6a9c173 + languageName: node + linkType: hard + "mdast-util-to-string@npm:^3.0.0, mdast-util-to-string@npm:^3.1.0, mdast-util-to-string@npm:^3.2.0": version: 3.2.0 resolution: "mdast-util-to-string@npm:3.2.0" @@ -7801,6 +7904,15 @@ __metadata: languageName: node linkType: hard +"mdast-util-to-string@npm:^4.0.0": + version: 4.0.0 + resolution: "mdast-util-to-string@npm:4.0.0" + dependencies: + "@types/mdast": ^4.0.0 + checksum: 35489fb5710d58cbc2d6c8b6547df161a3f81e0f28f320dfb3548a9393555daf07c310c0c497708e67ed4dfea4a06e5655799e7d631ca91420c288b4525d6c29 + languageName: node + linkType: hard + "mdn-data@npm:2.0.14": version: 2.0.14 resolution: "mdn-data@npm:2.0.14" @@ -7876,6 +7988,30 @@ __metadata: languageName: node linkType: hard +"micromark-core-commonmark@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-core-commonmark@npm:2.0.0" + dependencies: + decode-named-character-reference: ^1.0.0 + devlop: ^1.0.0 + micromark-factory-destination: ^2.0.0 + micromark-factory-label: ^2.0.0 + micromark-factory-space: ^2.0.0 + micromark-factory-title: ^2.0.0 + micromark-factory-whitespace: ^2.0.0 + micromark-util-character: ^2.0.0 + micromark-util-chunked: ^2.0.0 + micromark-util-classify-character: ^2.0.0 + micromark-util-html-tag-name: ^2.0.0 + micromark-util-normalize-identifier: ^2.0.0 + micromark-util-resolve-all: ^2.0.0 + micromark-util-subtokenize: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: 9c12fb580cf4ce71f60872043bd2794efe129f44d7b2b73afa155bbc0a66b7bc35655ba8cef438a6bd068441837ed3b6dc6ad7e5a18f815462c1750793e03a42 + languageName: node + linkType: hard + "micromark-extension-directive@npm:^2.0.0": version: 2.2.0 resolution: "micromark-extension-directive@npm:2.2.0" @@ -7891,6 +8027,18 @@ __metadata: languageName: node linkType: hard +"micromark-extension-frontmatter@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-extension-frontmatter@npm:2.0.0" + dependencies: + fault: ^2.0.0 + micromark-util-character: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: f68032df38c00ae47de15b63bcd72515bfcce39de4a9262a3a1ac9c5990f253f8e41bdc65fd17ec4bb3d144c32529ce0829571331e4901a9a413f1a53785d1e8 + languageName: node + linkType: hard + "micromark-extension-gfm-autolink-literal@npm:^1.0.0": version: 1.0.3 resolution: "micromark-extension-gfm-autolink-literal@npm:1.0.3" @@ -8069,6 +8217,17 @@ __metadata: languageName: node linkType: hard +"micromark-factory-destination@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-factory-destination@npm:2.0.0" + dependencies: + micromark-util-character: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: d36e65ed1c072ff4148b016783148ba7c68a078991154625723e24bda3945160268fb91079fb28618e1613c2b6e70390a8ddc544c45410288aa27b413593071a + languageName: node + linkType: hard + "micromark-factory-label@npm:^1.0.0": version: 1.0.2 resolution: "micromark-factory-label@npm:1.0.2" @@ -8081,6 +8240,18 @@ __metadata: languageName: node linkType: hard +"micromark-factory-label@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-factory-label@npm:2.0.0" + dependencies: + devlop: ^1.0.0 + micromark-util-character: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: c021dbd0ed367610d35f2bae21209bc804d1a6d1286ffce458fd6a717f4d7fe581a7cba7d5c2d7a63757c44eb927c80d6a571d6ea7969fae1b48ab6461d109c4 + languageName: node + linkType: hard + "micromark-factory-mdx-expression@npm:^1.0.0": version: 1.0.7 resolution: "micromark-factory-mdx-expression@npm:1.0.7" @@ -8107,6 +8278,16 @@ __metadata: languageName: node linkType: hard +"micromark-factory-space@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-factory-space@npm:2.0.0" + dependencies: + micromark-util-character: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: 4ffdcdc2f759887bbb356500cb460b3915ecddcb5d85c3618d7df68ad05d13ed02b1153ee1845677b7d8126df8f388288b84fcf0d943bd9c92bcc71cd7222e37 + languageName: node + linkType: hard + "micromark-factory-title@npm:^1.0.0": version: 1.0.2 resolution: "micromark-factory-title@npm:1.0.2" @@ -8120,6 +8301,18 @@ __metadata: languageName: node linkType: hard +"micromark-factory-title@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-factory-title@npm:2.0.0" + dependencies: + micromark-factory-space: ^2.0.0 + micromark-util-character: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: 39e1ac23af3554e6e652e56065579bc7faf21ade7b8704b29c175871b4152b7109b790bb3cae0f7e088381139c6bac9553b8400772c3d322e4fa635f813a3578 + languageName: node + linkType: hard + "micromark-factory-whitespace@npm:^1.0.0": version: 1.0.0 resolution: "micromark-factory-whitespace@npm:1.0.0" @@ -8132,6 +8325,18 @@ __metadata: languageName: node linkType: hard +"micromark-factory-whitespace@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-factory-whitespace@npm:2.0.0" + dependencies: + micromark-factory-space: ^2.0.0 + micromark-util-character: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: 9587c2546d1a58b4d5472b42adf05463f6212d0449455285662d63cd8eaed89c6b159ac82713fcee5f9dd88628c24307d9533cccd8971a2f3f4d48702f8f850a + languageName: node + linkType: hard + "micromark-util-character@npm:^1.0.0, micromark-util-character@npm:^1.1.0": version: 1.1.0 resolution: "micromark-util-character@npm:1.1.0" @@ -8142,6 +8347,16 @@ __metadata: languageName: node linkType: hard +"micromark-util-character@npm:^2.0.0": + version: 2.0.1 + resolution: "micromark-util-character@npm:2.0.1" + dependencies: + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: 318d6e16fdcbe9d89e18b8e7796568d986abbb10a9f3037b7ac9b92a236bcc962f3cd380e26a7c49df40fd1d9ca33eb546268956345b662f4c4ca4962c7695f2 + languageName: node + linkType: hard + "micromark-util-chunked@npm:^1.0.0": version: 1.0.0 resolution: "micromark-util-chunked@npm:1.0.0" @@ -8151,6 +8366,15 @@ __metadata: languageName: node linkType: hard +"micromark-util-chunked@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-chunked@npm:2.0.0" + dependencies: + micromark-util-symbol: ^2.0.0 + checksum: 324f95cccdae061332a8241936eaba6ef0782a1e355bac5c607ad2564fd3744929be7dc81651315a2921535747a33243e6a5606bcb64b7a56d49b6d74ea1a3d4 + languageName: node + linkType: hard + "micromark-util-classify-character@npm:^1.0.0": version: 1.0.0 resolution: "micromark-util-classify-character@npm:1.0.0" @@ -8162,6 +8386,17 @@ __metadata: languageName: node linkType: hard +"micromark-util-classify-character@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-classify-character@npm:2.0.0" + dependencies: + micromark-util-character: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: 086e52904deffebb793fb1c08c94aabb8901f76958142dfc3a6282890ebaa983b285e69bd602b9d507f1b758ed38e75a994d2ad9fbbefa7de2584f67a16af405 + languageName: node + linkType: hard + "micromark-util-combine-extensions@npm:^1.0.0": version: 1.0.0 resolution: "micromark-util-combine-extensions@npm:1.0.0" @@ -8172,6 +8407,16 @@ __metadata: languageName: node linkType: hard +"micromark-util-combine-extensions@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-combine-extensions@npm:2.0.0" + dependencies: + micromark-util-chunked: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: 107c47700343f365b4ed81551e18bc3458b573c500e56ac052b2490bd548adc475216e41d2271633a8867fac66fc22ba3e0a2d74a31ed79b9870ca947eb4e3ba + languageName: node + linkType: hard + "micromark-util-decode-numeric-character-reference@npm:^1.0.0": version: 1.0.0 resolution: "micromark-util-decode-numeric-character-reference@npm:1.0.0" @@ -8181,6 +8426,15 @@ __metadata: languageName: node linkType: hard +"micromark-util-decode-numeric-character-reference@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-decode-numeric-character-reference@npm:2.0.0" + dependencies: + micromark-util-symbol: ^2.0.0 + checksum: 705715a2dd6f10d85c69371b4176a0b2fec5811a14f7d26f66f358ac5adebb12975f79597b1a1a184a6dcf6799319f7cf8eb91398e47c1faa2cab2c84f155b78 + languageName: node + linkType: hard + "micromark-util-decode-string@npm:^1.0.0": version: 1.0.2 resolution: "micromark-util-decode-string@npm:1.0.2" @@ -8193,6 +8447,18 @@ __metadata: languageName: node linkType: hard +"micromark-util-decode-string@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-decode-string@npm:2.0.0" + dependencies: + decode-named-character-reference: ^1.0.0 + micromark-util-character: ^2.0.0 + micromark-util-decode-numeric-character-reference: ^2.0.0 + micromark-util-symbol: ^2.0.0 + checksum: a75daf32a4a6b549e9f19b4d833ebfeb09a32a9a1f9ce50f35dec6b6a3e4f9f121f49024ba7f9c91c55ebe792f7c7a332fc9604795181b6a612637df0df5b959 + languageName: node + linkType: hard + "micromark-util-encode@npm:^1.0.0": version: 1.0.1 resolution: "micromark-util-encode@npm:1.0.1" @@ -8200,6 +8466,13 @@ __metadata: languageName: node linkType: hard +"micromark-util-encode@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-encode@npm:2.0.0" + checksum: 853a3f33fce72aaf4ffa60b7f2b6fcfca40b270b3466e1b96561b02185d2bd8c01dd7948bc31a24ac014f4cc854e545ca9a8e9cf7ea46262f9d24c9e88551c66 + languageName: node + linkType: hard + "micromark-util-events-to-acorn@npm:^1.0.0": version: 1.2.1 resolution: "micromark-util-events-to-acorn@npm:1.2.1" @@ -8222,6 +8495,13 @@ __metadata: languageName: node linkType: hard +"micromark-util-html-tag-name@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-html-tag-name@npm:2.0.0" + checksum: d786d4486f93eb0ac5b628779809ca97c5dc60f3c9fc03eb565809831db181cf8cb7f05f9ac76852f3eb35461af0f89fa407b46f3a03f4f97a96754d8dc540d8 + languageName: node + linkType: hard + "micromark-util-normalize-identifier@npm:^1.0.0": version: 1.0.0 resolution: "micromark-util-normalize-identifier@npm:1.0.0" @@ -8231,6 +8511,15 @@ __metadata: languageName: node linkType: hard +"micromark-util-normalize-identifier@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-normalize-identifier@npm:2.0.0" + dependencies: + micromark-util-symbol: ^2.0.0 + checksum: b36da2d3fd102053dadd953ce5c558328df12a63a8ac0e5aad13d4dda8e43b6a5d4a661baafe0a1cd8a260bead4b4a8e6e0e74193dd651e8484225bd4f4e68aa + languageName: node + linkType: hard + "micromark-util-resolve-all@npm:^1.0.0": version: 1.0.0 resolution: "micromark-util-resolve-all@npm:1.0.0" @@ -8240,6 +8529,15 @@ __metadata: languageName: node linkType: hard +"micromark-util-resolve-all@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-resolve-all@npm:2.0.0" + dependencies: + micromark-util-types: ^2.0.0 + checksum: 31fe703b85572cb3f598ebe32750e59516925c7ff1f66cfe6afaebe0771a395a9eaa770787f2523d3c46082ea80e6c14f83643303740b3d650af7c96ebd30ccc + languageName: node + linkType: hard + "micromark-util-sanitize-uri@npm:^1.0.0, micromark-util-sanitize-uri@npm:^1.1.0": version: 1.1.0 resolution: "micromark-util-sanitize-uri@npm:1.1.0" @@ -8251,6 +8549,17 @@ __metadata: languageName: node linkType: hard +"micromark-util-sanitize-uri@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-sanitize-uri@npm:2.0.0" + dependencies: + micromark-util-character: ^2.0.0 + micromark-util-encode: ^2.0.0 + micromark-util-symbol: ^2.0.0 + checksum: ea4c28bbffcf2430e9aff2d18554296789a8b0a1f54ac24020d1dde76624a7f93e8f2a83e88cd5a846b6d2c4287b71b1142d1b89fa7f1b0363a9b33711a141fe + languageName: node + linkType: hard + "micromark-util-subtokenize@npm:^1.0.0": version: 1.0.2 resolution: "micromark-util-subtokenize@npm:1.0.2" @@ -8263,6 +8572,18 @@ __metadata: languageName: node linkType: hard +"micromark-util-subtokenize@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-subtokenize@npm:2.0.0" + dependencies: + devlop: ^1.0.0 + micromark-util-chunked: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: 77d9c7d59c05a20468d49ce2a3640e9cb268c083ccad02322f26c84e1094c25b44f4b8139ef0a247ca11a4fef7620c5bf82fbffd98acdb2989e79cbe7bd8f1db + languageName: node + linkType: hard + "micromark-util-symbol@npm:^1.0.0, micromark-util-symbol@npm:^1.0.1": version: 1.0.1 resolution: "micromark-util-symbol@npm:1.0.1" @@ -8270,6 +8591,13 @@ __metadata: languageName: node linkType: hard +"micromark-util-symbol@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-symbol@npm:2.0.0" + checksum: fa4a05bff575d9fbf0ad96a1013003e3bb6087ed6b34b609a141b6c0d2137b57df594aca409a95f4c5fda199f227b56a7d8b1f82cea0768df161d8a3a3660764 + languageName: node + linkType: hard + "micromark-util-types@npm:^1.0.0, micromark-util-types@npm:^1.0.1": version: 1.0.2 resolution: "micromark-util-types@npm:1.0.2" @@ -8277,6 +8605,13 @@ __metadata: languageName: node linkType: hard +"micromark-util-types@npm:^2.0.0": + version: 2.0.0 + resolution: "micromark-util-types@npm:2.0.0" + checksum: 819fef3ab5770c37893d2a60381fb2694396c8d22803b6e103c830c3a1bc1490363c2b0470bb2acaaddad776dfbc2fc1fcfde39cb63c4f54d95121611672e3d0 + languageName: node + linkType: hard + "micromark@npm:^3.0.0": version: 3.1.0 resolution: "micromark@npm:3.1.0" @@ -8302,6 +8637,31 @@ __metadata: languageName: node linkType: hard +"micromark@npm:^4.0.0": + version: 4.0.0 + resolution: "micromark@npm:4.0.0" + dependencies: + "@types/debug": ^4.0.0 + debug: ^4.0.0 + decode-named-character-reference: ^1.0.0 + devlop: ^1.0.0 + micromark-core-commonmark: ^2.0.0 + micromark-factory-space: ^2.0.0 + micromark-util-character: ^2.0.0 + micromark-util-chunked: ^2.0.0 + micromark-util-combine-extensions: ^2.0.0 + micromark-util-decode-numeric-character-reference: ^2.0.0 + micromark-util-encode: ^2.0.0 + micromark-util-normalize-identifier: ^2.0.0 + micromark-util-resolve-all: ^2.0.0 + micromark-util-sanitize-uri: ^2.0.0 + micromark-util-subtokenize: ^2.0.0 + micromark-util-symbol: ^2.0.0 + micromark-util-types: ^2.0.0 + checksum: b84ab5ab1a0b28c063c52e9c2c9d7d44b954507235c10c9492d66e0b38f7de24bf298f914a1fbdf109f2a57a88cf0412de217c84cfac5fd60e3e42a74dbac085 + languageName: node + linkType: hard + "micromatch@npm:^4.0.2, micromatch@npm:^4.0.4, micromatch@npm:^4.0.5": version: 4.0.5 resolution: "micromatch@npm:4.0.5" @@ -10176,6 +10536,18 @@ __metadata: languageName: node linkType: hard +"remark-frontmatter@npm:^5.0.0": + version: 5.0.0 + resolution: "remark-frontmatter@npm:5.0.0" + dependencies: + "@types/mdast": ^4.0.0 + mdast-util-frontmatter: ^2.0.0 + micromark-extension-frontmatter: ^2.0.0 + unified: ^11.0.0 + checksum: b36e11d528d1d0172489c74ce7961bb6073f7272e71ea1349f765fc79c4246a758aef949174d371a088c48e458af776fcfbb3b043c49cd1120ca8239aeafe16a + languageName: node + linkType: hard + "remark-gfm@npm:^3.0.1": version: 3.0.1 resolution: "remark-gfm@npm:3.0.1" @@ -10438,15 +10810,15 @@ __metadata: linkType: hard "sass@npm:^1.57.1": - version: 1.69.0 - resolution: "sass@npm:1.69.0" + version: 1.69.3 + resolution: "sass@npm:1.69.3" dependencies: chokidar: ">=3.0.0 <4.0.0" immutable: ^4.0.0 source-map-js: ">=0.6.2 <2.0.0" bin: sass: sass.js - checksum: eabea31ea3b1dd529c7eff345c8b6468afe6ab8011bd4f95caa2cffb8fb115cc055ea21de425be6197f7ed22516f5652eccb98d315d592ea152ada553f964b8a + checksum: b89a3370c7ede462b344e2136bf1407bf375855c1ec54f73b6257b18fe59dae5377eb9f7b25f21ae4a25d8f0bc41a165d8d7e5f693d8285b1aa51ac6056c4d19 languageName: node linkType: hard @@ -11386,6 +11758,21 @@ __metadata: languageName: node linkType: hard +"unified@npm:^11.0.0": + version: 11.0.3 + resolution: "unified@npm:11.0.3" + dependencies: + "@types/unist": ^3.0.0 + bail: ^2.0.0 + devlop: ^1.0.0 + extend: ^3.0.0 + is-plain-obj: ^4.0.0 + trough: ^2.0.0 + vfile: ^6.0.0 + checksum: 402d6b397b98f8966993faca0e1480f5f1825cc44df6a5236b75ab099f14b10ed808e578155c3f535e60676c12ee3f52346ca08d64343a72181d7a6b4d32011d + languageName: node + linkType: hard + "unique-filename@npm:^2.0.0": version: 2.0.1 resolution: "unique-filename@npm:2.0.1" @@ -11436,6 +11823,15 @@ __metadata: languageName: node linkType: hard +"unist-util-is@npm:^6.0.0": + version: 6.0.0 + resolution: "unist-util-is@npm:6.0.0" + dependencies: + "@types/unist": ^3.0.0 + checksum: f630a925126594af9993b091cf807b86811371e465b5049a6283e08537d3e6ba0f7e248e1e7dab52cfe33f9002606acef093441137181b327f6fe504884b20e2 + languageName: node + linkType: hard + "unist-util-position-from-estree@npm:^1.0.0, unist-util-position-from-estree@npm:^1.1.0": version: 1.1.2 resolution: "unist-util-position-from-estree@npm:1.1.2" @@ -11473,6 +11869,15 @@ __metadata: languageName: node linkType: hard +"unist-util-stringify-position@npm:^4.0.0": + version: 4.0.0 + resolution: "unist-util-stringify-position@npm:4.0.0" + dependencies: + "@types/unist": ^3.0.0 + checksum: e2e7aee4b92ddb64d314b4ac89eef7a46e4c829cbd3ee4aee516d100772b490eb6b4974f653ba0717a0071ca6ea0770bf22b0a2ea62c65fcba1d071285e96324 + languageName: node + linkType: hard + "unist-util-visit-parents@npm:^3.0.0": version: 3.1.1 resolution: "unist-util-visit-parents@npm:3.1.1" @@ -11493,6 +11898,16 @@ __metadata: languageName: node linkType: hard +"unist-util-visit-parents@npm:^6.0.0": + version: 6.0.1 + resolution: "unist-util-visit-parents@npm:6.0.1" + dependencies: + "@types/unist": ^3.0.0 + unist-util-is: ^6.0.0 + checksum: 08927647c579f63b91aafcbec9966dc4a7d0af1e5e26fc69f4e3e6a01215084835a2321b06f3cbe7bf7914a852830fc1439f0fc3d7153d8804ac3ef851ddfa20 + languageName: node + linkType: hard + "unist-util-visit@npm:^2.0.3": version: 2.0.3 resolution: "unist-util-visit@npm:2.0.3" @@ -11515,6 +11930,17 @@ __metadata: languageName: node linkType: hard +"unist-util-visit@npm:^5.0.0": + version: 5.0.0 + resolution: "unist-util-visit@npm:5.0.0" + dependencies: + "@types/unist": ^3.0.0 + unist-util-is: ^6.0.0 + unist-util-visit-parents: ^6.0.0 + checksum: 9ec42e618e7e5d0202f3c191cd30791b51641285732767ee2e6bcd035931032e3c1b29093f4d7fd0c79175bbc1f26f24f26ee49770d32be76f8730a652a857e6 + languageName: node + linkType: hard + "universalify@npm:^2.0.0": version: 2.0.0 resolution: "universalify@npm:2.0.0" @@ -11711,7 +12137,17 @@ __metadata: languageName: node linkType: hard -"vfile@npm:^5.0.0": +"vfile-message@npm:^4.0.0": + version: 4.0.2 + resolution: "vfile-message@npm:4.0.2" + dependencies: + "@types/unist": ^3.0.0 + unist-util-stringify-position: ^4.0.0 + checksum: 964e7e119f4c0e0270fc269119c41c96da20afa01acb7c9809a88365c8e0c64aa692fafbd952669382b978002ecd7ad31ef4446d85e8a22cdb62f6df20186c2d + languageName: node + linkType: hard + +"vfile@npm:^5.0.0, vfile@npm:^5.3.7": version: 5.3.7 resolution: "vfile@npm:5.3.7" dependencies: @@ -11723,6 +12159,17 @@ __metadata: languageName: node linkType: hard +"vfile@npm:^6.0.0": + version: 6.0.1 + resolution: "vfile@npm:6.0.1" + dependencies: + "@types/unist": ^3.0.0 + unist-util-stringify-position: ^4.0.0 + vfile-message: ^4.0.0 + checksum: 05ccee73aeb00402bc8a5d0708af299e9f4a33f5132805449099295085e3ca3b0d018328bad9ff44cf2e6f4cd364f1d558d3fb9b394243a25b2739207edcb0ed + languageName: node + linkType: hard + "wait-on@npm:^7.0.1": version: 7.0.1 resolution: "wait-on@npm:7.0.1" diff --git a/package.json b/package.json index 7b7d962780..b50e087aa7 100644 --- a/package.json +++ b/package.json @@ -13,6 +13,7 @@ "build:api-reports": "yarn build:api-reports:only --tsc", "build:api-reports:only": "backstage-repo-tools api-reports --allow-warnings 'packages/core-components,plugins/+(catalog|catalog-import|git-release-manager|jenkins|kubernetes)' -o ae-wrong-input-file-type --validate-release-tags", "build:api-docs": "LANG=en_EN yarn build:api-reports --docs", + "build:plugins-report": "node ./scripts/build-plugins-report", "tsc": "tsc", "tsc:full": "backstage-cli repo clean && tsc --skipLibCheck false --incremental false", "clean": "backstage-cli repo clean", @@ -51,7 +52,7 @@ "jest-haste-map@^29.4.3": "patch:jest-haste-map@npm%3A29.4.3#./.yarn/patches/jest-haste-map-npm-29.4.3-19b03fcef3.patch", "mock-fs@^5.2.0": "patch:mock-fs@npm%3A5.2.0#./.yarn/patches/mock-fs-npm-5.2.0-5103a7b507.patch" }, - "version": "1.19.0-next.1", + "version": "1.19.0-next.2", "dependencies": { "@backstage/errors": "workspace:^", "@manypkg/get-packages": "^1.1.3" diff --git a/packages/app-defaults/CHANGELOG.md b/packages/app-defaults/CHANGELOG.md index 573ef62905..ce6bdb23fa 100644 --- a/packages/app-defaults/CHANGELOG.md +++ b/packages/app-defaults/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/app-defaults +## 1.4.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + ## 1.4.4-next.1 ### Patch Changes diff --git a/packages/app-defaults/package.json b/packages/app-defaults/package.json index b583443902..7695d128e7 100644 --- a/packages/app-defaults/package.json +++ b/packages/app-defaults/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/app-defaults", "description": "Provides the default wiring of a Backstage App", - "version": "1.4.4-next.1", + "version": "1.4.4-next.2", "publishConfig": { "access": "public", "main": "dist/index.esm.js", @@ -49,7 +49,7 @@ "devDependencies": { "@backstage/cli": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@types/react": "^16.13.1 || ^17.0.0" }, diff --git a/packages/app-next-example-plugin/CHANGELOG.md b/packages/app-next-example-plugin/CHANGELOG.md index 22136e2b59..10874da64a 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.2-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + ## 0.0.2-next.1 ### Patch Changes diff --git a/packages/app-next-example-plugin/api-report.md b/packages/app-next-example-plugin/api-report.md index 68a0471b6b..83449a102f 100644 --- a/packages/app-next-example-plugin/api-report.md +++ b/packages/app-next-example-plugin/api-report.md @@ -3,11 +3,13 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { default as React_2 } from 'react'; // @public (undocumented) -const examplePlugin: BackstagePlugin; +const examplePlugin: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; export default examplePlugin; // @public (undocumented) diff --git a/packages/app-next-example-plugin/package.json b/packages/app-next-example-plugin/package.json index ad797aaeb7..6304dcd028 100644 --- a/packages/app-next-example-plugin/package.json +++ b/packages/app-next-example-plugin/package.json @@ -1,7 +1,7 @@ { "name": "app-next-example-plugin", "description": "Backstage internal example plugin", - "version": "0.0.2-next.1", + "version": "0.0.2-next.2", "publishConfig": { "access": "public", "main": "dist/index.esm.js", diff --git a/packages/app-next/CHANGELOG.md b/packages/app-next/CHANGELOG.md index b9aa117f5b..3195255f36 100644 --- a/packages/app-next/CHANGELOG.md +++ b/packages/app-next/CHANGELOG.md @@ -1,5 +1,82 @@ # example-app-next +## 0.0.2-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/cli@0.23.0-next.2 + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/frontend-app-api@0.2.0-next.2 + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/plugin-techdocs@1.7.1-next.2 + - @backstage/plugin-newrelic@0.3.41-next.2 + - @backstage/plugin-scaffolder@1.15.1-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/plugin-tech-radar@0.6.9-next.2 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/plugin-adr@0.6.8-next.2 + - @backstage/plugin-graphiql@0.2.55-next.2 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/plugin-newrelic-dashboard@0.3.0-next.2 + - @backstage/plugin-kubernetes@0.11.0-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-jenkins@0.8.7-next.2 + - @backstage/plugin-tech-insights@0.3.17-next.2 + - @backstage/plugin-playlist@0.1.17-next.2 + - @backstage/app-defaults@1.4.4-next.2 + - app-next-example-plugin@0.0.2-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-airbrake@0.3.25-next.2 + - @backstage/plugin-apache-airflow@0.2.16-next.2 + - @backstage/plugin-api-docs@0.9.12-next.2 + - @backstage/plugin-azure-devops@0.3.7-next.2 + - @backstage/plugin-azure-sites@0.1.14-next.2 + - @backstage/plugin-badges@0.2.49-next.2 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-catalog-graph@0.2.37-next.2 + - @backstage/plugin-catalog-import@0.10.1-next.2 + - @backstage/plugin-catalog-unprocessed-entities@0.1.4-next.2 + - @backstage/plugin-circleci@0.3.25-next.2 + - @backstage/plugin-cloudbuild@0.3.25-next.2 + - @backstage/plugin-code-coverage@0.2.18-next.2 + - @backstage/plugin-cost-insights@0.12.14-next.2 + - @backstage/plugin-devtools@0.1.5-next.2 + - @backstage/plugin-dynatrace@7.0.5-next.2 + - @backstage/plugin-entity-feedback@0.2.8-next.2 + - @backstage/plugin-explore@0.4.11-next.2 + - @backstage/plugin-gcalendar@0.3.19-next.2 + - @backstage/plugin-gcp-projects@0.3.42-next.2 + - @backstage/plugin-github-actions@0.6.6-next.2 + - @backstage/plugin-gocd@0.1.31-next.2 + - @backstage/plugin-home@0.5.9-next.2 + - @backstage/plugin-kafka@0.3.25-next.2 + - @backstage/plugin-lighthouse@0.4.10-next.2 + - @backstage/plugin-linguist@0.1.10-next.2 + - @backstage/plugin-linguist-common@0.1.2 + - @backstage/plugin-microsoft-calendar@0.1.8-next.2 + - @backstage/plugin-octopus-deploy@0.2.7-next.2 + - @backstage/plugin-org@0.6.15-next.2 + - @backstage/plugin-pagerduty@0.6.6-next.2 + - @backstage/plugin-permission-react@0.4.16-next.1 + - @backstage/plugin-puppetdb@0.1.8-next.2 + - @backstage/plugin-rollbar@0.4.25-next.2 + - @backstage/plugin-scaffolder-react@1.5.6-next.2 + - @backstage/plugin-search@1.4.1-next.2 + - @backstage/plugin-search-common@1.2.7-next.0 + - @backstage/plugin-sentry@0.5.10-next.2 + - @backstage/plugin-shortcuts@0.3.15-next.2 + - @backstage/plugin-stack-overflow@0.1.21-next.2 + - @backstage/plugin-stackstorm@0.1.7-next.2 + - @backstage/plugin-techdocs-module-addons-contrib@1.1.1-next.2 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + - @backstage/plugin-todo@0.2.28-next.2 + - @backstage/plugin-user-settings@0.7.11-next.2 + ## 0.0.2-next.1 ### Patch Changes diff --git a/packages/app-next/package.json b/packages/app-next/package.json index 43e8322b35..b1d158fb9f 100644 --- a/packages/app-next/package.json +++ b/packages/app-next/package.json @@ -1,6 +1,6 @@ { "name": "example-app-next", - "version": "0.0.2-next.1", + "version": "0.0.2-next.2", "private": true, "backstage": { "role": "frontend" @@ -98,8 +98,8 @@ }, "devDependencies": { "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/jquery": "^3.3.34", diff --git a/packages/app-next/src/App.tsx b/packages/app-next/src/App.tsx index d844939cf2..4d72cca14f 100644 --- a/packages/app-next/src/App.tsx +++ b/packages/app-next/src/App.tsx @@ -14,10 +14,18 @@ * limitations under the License. */ +import React from 'react'; import { createApp } from '@backstage/frontend-app-api'; import { pagesPlugin } from './examples/pagesPlugin'; import graphiqlPlugin from '@backstage/plugin-graphiql/alpha'; import techRadarPlugin from '@backstage/plugin-tech-radar/alpha'; +import userSettingsPlugin from '@backstage/plugin-user-settings/alpha'; +import { + createExtensionOverrides, + createPageExtension, +} from '@backstage/frontend-plugin-api'; +import { entityRouteRef } from '@backstage/plugin-catalog-react'; +import techdocsPlugin from '@backstage/plugin-techdocs/alpha'; /* @@ -48,16 +56,27 @@ TODO: /* app.tsx */ +const entityPageExtension = createPageExtension({ + id: 'catalog:entity', + defaultPath: '/catalog/:namespace/:kind/:name', + routeRef: entityRouteRef, + loader: async () => <div>Just a temporary mocked entity page</div>, +}); + const app = createApp({ - plugins: [graphiqlPlugin, pagesPlugin, techRadarPlugin], - // bindRoutes({ bind }) { - // bind(catalogPlugin.externalRoutes, { - // createComponent: scaffolderPlugin.routes.root, - // }); - // bind(scaffolderPlugin.externalRoutes, { - // registerComponent: catalogImportPlugin.routes.importPage, - // }); - // }, + features: [ + graphiqlPlugin, + pagesPlugin, + techRadarPlugin, + techdocsPlugin, + userSettingsPlugin, + createExtensionOverrides({ + extensions: [entityPageExtension], + }), + ], + bindRoutes({ bind }) { + bind(pagesPlugin.externalRoutes, { pageX: pagesPlugin.routes.pageX }); + }, }); // const legacyApp = createLegacyApp({ plugins: [legacyGraphiqlPlugin] }); diff --git a/packages/app-next/src/examples/pagesPlugin.tsx b/packages/app-next/src/examples/pagesPlugin.tsx index 1ec1cfa5a1..ef6b55ff4c 100644 --- a/packages/app-next/src/examples/pagesPlugin.tsx +++ b/packages/app-next/src/examples/pagesPlugin.tsx @@ -20,11 +20,17 @@ import { createPageExtension, createPlugin, } from '@backstage/frontend-plugin-api'; -import { useRouteRef, createRouteRef } from '@backstage/core-plugin-api'; +import { + useRouteRef, + createRouteRef, + createExternalRouteRef, +} from '@backstage/core-plugin-api'; import { Route, Routes } from 'react-router-dom'; const indexRouteRef = createRouteRef({ id: 'index' }); const page1RouteRef = createRouteRef({ id: 'page1' }); +export const externalPageXRouteRef = createExternalRouteRef({ id: 'pageX' }); +export const pageXRouteRef = createRouteRef({ id: 'pageX' }); // const page2RouteRef = createSubRouteRef({ // id: 'page2', // parent: page1RouteRef, @@ -50,6 +56,9 @@ const IndexPage = createPageExtension({ <div> <Link to="/search">Search</Link> </div> + <div> + <Link to="/settings">Settings</Link> + </div> </div> ); }; @@ -64,6 +73,7 @@ const Page1 = createPageExtension({ loader: async () => { const Component = () => { const indexLink = useRouteRef(indexRouteRef); + const xLink = useRouteRef(externalPageXRouteRef); // const page2Link = useRouteRef(page2RouteRef); return ( @@ -72,6 +82,7 @@ const Page1 = createPageExtension({ <Link to={indexLink()}>Go back</Link> <Link to="./page2">Page 2</Link> {/* <Link to={page2Link()}>Page 2</Link> */} + <Link to={xLink()}>Page X</Link> <div> Sub-page content: @@ -89,6 +100,26 @@ const Page1 = createPageExtension({ }, }); +const ExternalPage = createPageExtension({ + id: 'pageX', + defaultPath: '/pageX', + routeRef: pageXRouteRef, + loader: async () => { + const Component = () => { + const indexLink = useRouteRef(indexRouteRef); + // const pageXLink = useRouteRef(pageXRouteRef); + + return ( + <div> + <h1>This is page X</h1> + <Link to={indexLink()}>Go back</Link> + </div> + ); + }; + return <Component />; + }, +}); + export const pagesPlugin = createPlugin({ id: 'pages', // routes: { @@ -98,5 +129,12 @@ export const pagesPlugin = createPlugin({ // // OR // // 'page1' // }, - extensions: [IndexPage, Page1], + routes: { + page1: page1RouteRef, + pageX: pageXRouteRef, + }, + externalRoutes: { + pageX: externalPageXRouteRef, + }, + extensions: [IndexPage, Page1, ExternalPage], }); diff --git a/packages/app/CHANGELOG.md b/packages/app/CHANGELOG.md index 7b14d026a0..dc7635f51a 100644 --- a/packages/app/CHANGELOG.md +++ b/packages/app/CHANGELOG.md @@ -1,5 +1,82 @@ # example-app +## 0.2.88-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/cli@0.23.0-next.2 + - @backstage/frontend-app-api@0.2.0-next.2 + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/plugin-techdocs@1.7.1-next.2 + - @backstage/plugin-newrelic@0.3.41-next.2 + - @backstage/plugin-scaffolder@1.15.1-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/plugin-tech-radar@0.6.9-next.2 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/plugin-adr@0.6.8-next.2 + - @backstage/plugin-graphiql@0.2.55-next.2 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/plugin-newrelic-dashboard@0.3.0-next.2 + - @backstage/plugin-kubernetes-cluster@0.0.1-next.0 + - @backstage/plugin-kubernetes@0.11.0-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-jenkins@0.8.7-next.2 + - @backstage/plugin-tech-insights@0.3.17-next.2 + - @backstage/plugin-playlist@0.1.17-next.2 + - @backstage/app-defaults@1.4.4-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-airbrake@0.3.25-next.2 + - @backstage/plugin-apache-airflow@0.2.16-next.2 + - @backstage/plugin-api-docs@0.9.12-next.2 + - @backstage/plugin-azure-devops@0.3.7-next.2 + - @backstage/plugin-azure-sites@0.1.14-next.2 + - @backstage/plugin-badges@0.2.49-next.2 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-catalog-graph@0.2.37-next.2 + - @backstage/plugin-catalog-import@0.10.1-next.2 + - @backstage/plugin-catalog-unprocessed-entities@0.1.4-next.2 + - @backstage/plugin-circleci@0.3.25-next.2 + - @backstage/plugin-cloudbuild@0.3.25-next.2 + - @backstage/plugin-code-coverage@0.2.18-next.2 + - @backstage/plugin-cost-insights@0.12.14-next.2 + - @backstage/plugin-devtools@0.1.5-next.2 + - @backstage/plugin-dynatrace@7.0.5-next.2 + - @backstage/plugin-entity-feedback@0.2.8-next.2 + - @backstage/plugin-explore@0.4.11-next.2 + - @backstage/plugin-gcalendar@0.3.19-next.2 + - @backstage/plugin-gcp-projects@0.3.42-next.2 + - @backstage/plugin-github-actions@0.6.6-next.2 + - @backstage/plugin-gocd@0.1.31-next.2 + - @backstage/plugin-home@0.5.9-next.2 + - @backstage/plugin-kafka@0.3.25-next.2 + - @backstage/plugin-lighthouse@0.4.10-next.2 + - @backstage/plugin-linguist@0.1.10-next.2 + - @backstage/plugin-linguist-common@0.1.2 + - @backstage/plugin-microsoft-calendar@0.1.8-next.2 + - @backstage/plugin-nomad@0.1.6-next.2 + - @backstage/plugin-octopus-deploy@0.2.7-next.2 + - @backstage/plugin-org@0.6.15-next.2 + - @backstage/plugin-pagerduty@0.6.6-next.2 + - @backstage/plugin-permission-react@0.4.16-next.1 + - @backstage/plugin-puppetdb@0.1.8-next.2 + - @backstage/plugin-rollbar@0.4.25-next.2 + - @backstage/plugin-scaffolder-react@1.5.6-next.2 + - @backstage/plugin-search@1.4.1-next.2 + - @backstage/plugin-search-common@1.2.7-next.0 + - @backstage/plugin-sentry@0.5.10-next.2 + - @backstage/plugin-shortcuts@0.3.15-next.2 + - @backstage/plugin-stack-overflow@0.1.21-next.2 + - @backstage/plugin-stackstorm@0.1.7-next.2 + - @backstage/plugin-techdocs-module-addons-contrib@1.1.1-next.2 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + - @backstage/plugin-todo@0.2.28-next.2 + - @backstage/plugin-user-settings@0.7.11-next.2 + ## 0.2.88-next.1 ### Patch Changes diff --git a/packages/app/package.json b/packages/app/package.json index 10c7ea77d1..ce344d1aa9 100644 --- a/packages/app/package.json +++ b/packages/app/package.json @@ -1,6 +1,6 @@ { "name": "example-app", - "version": "0.2.88-next.1", + "version": "0.2.88-next.2", "private": true, "backstage": { "role": "frontend" @@ -104,8 +104,8 @@ "devDependencies": { "@backstage/test-utils": "workspace:^", "@playwright/test": "^1.32.3", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/jquery": "^3.3.34", diff --git a/packages/backend-app-api/CHANGELOG.md b/packages/backend-app-api/CHANGELOG.md index cf24e558fd..dc81b18678 100644 --- a/packages/backend-app-api/CHANGELOG.md +++ b/packages/backend-app-api/CHANGELOG.md @@ -1,5 +1,24 @@ # @backstage/backend-app-api +## 0.5.6-next.2 + +### Patch Changes + +- 74491c9602: Moved `HostDiscovery` from `@backstage/backend-common`. +- a4617c422a: Added `watch` option to configuration loaders that can be used to disable file watching by setting it to `false`. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/config-loader@1.5.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/cli-node@0.1.5-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.5.5-next.1 ### Patch Changes diff --git a/packages/backend-app-api/api-report.md b/packages/backend-app-api/api-report.md index ecfbc1fe7d..e478a91bb7 100644 --- a/packages/backend-app-api/api-report.md +++ b/packages/backend-app-api/api-report.md @@ -204,6 +204,7 @@ export function loadBackendConfig(options: { remote?: LoadConfigOptionsRemote; argv: string[]; additionalConfigs?: AppConfig[]; + watch?: boolean; }): Promise<{ config: Config; }>; diff --git a/packages/backend-app-api/package.json b/packages/backend-app-api/package.json index db04e7626c..c83a4acfd7 100644 --- a/packages/backend-app-api/package.json +++ b/packages/backend-app-api/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-app-api", "description": "Core API used by Backstage backend apps", - "version": "0.5.5-next.1", + "version": "0.5.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/backend-app-api/src/config/config.ts b/packages/backend-app-api/src/config/config.ts index 7367767870..8ecc015b66 100644 --- a/packages/backend-app-api/src/config/config.ts +++ b/packages/backend-app-api/src/config/config.ts @@ -72,6 +72,7 @@ export async function loadBackendConfig(options: { remote?: LoadConfigOptionsRemote; argv: string[]; additionalConfigs?: AppConfig[]; + watch?: boolean; }): Promise<{ config: Config }> { const args = parseArgs(options.argv); @@ -89,30 +90,35 @@ export async function loadBackendConfig(options: { configRoot: paths.targetRoot, configTargets: configTargets, remote: options.remote, - watch: { - onChange(newConfigs) { - console.info( - `Reloaded config from ${newConfigs.map(c => c.context).join(', ')}`, - ); - const configsToMerge = [...newConfigs]; - if (options.additionalConfigs) { - configsToMerge.push(...options.additionalConfigs); - } - config.setConfig(ConfigReader.fromConfigs(configsToMerge)); - }, - stopSignal: new Promise(resolve => { - if (currentCancelFunc) { - currentCancelFunc(); - } - currentCancelFunc = resolve; + watch: + options.watch ?? true + ? { + onChange(newConfigs) { + console.info( + `Reloaded config from ${newConfigs + .map(c => c.context) + .join(', ')}`, + ); + const configsToMerge = [...newConfigs]; + if (options.additionalConfigs) { + configsToMerge.push(...options.additionalConfigs); + } + config.setConfig(ConfigReader.fromConfigs(configsToMerge)); + }, + stopSignal: new Promise(resolve => { + if (currentCancelFunc) { + currentCancelFunc(); + } + currentCancelFunc = resolve; - // TODO(Rugvip): We keep this here for now to avoid breaking the old system - // since this is re-used in backend-common - if (module.hot) { - module.hot.addDisposeHandler(resolve); - } - }), - }, + // TODO(Rugvip): We keep this here for now to avoid breaking the old system + // since this is re-used in backend-common + if (module.hot) { + module.hot.addDisposeHandler(resolve); + } + }), + } + : undefined, }); console.info( `Loaded config from ${appConfigs.map(c => c.context).join(', ')}`, diff --git a/packages/backend-common/CHANGELOG.md b/packages/backend-common/CHANGELOG.md index 05aecf893b..5a84733f86 100644 --- a/packages/backend-common/CHANGELOG.md +++ b/packages/backend-common/CHANGELOG.md @@ -1,5 +1,26 @@ # @backstage/backend-common +## 0.19.8-next.2 + +### Patch Changes + +- 74491c9602: The `HostDiscovery` export has been deprecated, import it from `@backstage/backend-app-api` instead. +- b95d66d4ea: Properly close write stream when writing temporary archive for processing zip-based `.readTree()` responses. +- 0b55f773a7: Removed some unused dependencies +- 4c39e38f1e: Added `/testUtils` entry point, with a utility for mocking resolve package paths as returned by `resolvePackagePath`. +- a250ad775f: Removed `mock-fs` dev dependency. +- Updated dependencies + - @backstage/config-loader@1.5.1-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-app-api@0.5.6-next.2 + - @backstage/backend-dev-utils@0.1.2-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/types@1.1.1 + ## 0.19.7-next.1 ### Patch Changes diff --git a/packages/backend-common/api-report.md b/packages/backend-common/api-report.md index d6ac25326f..f4d430ccbd 100644 --- a/packages/backend-common/api-report.md +++ b/packages/backend-common/api-report.md @@ -546,6 +546,7 @@ export function loadBackendConfig(options: { remote?: LoadConfigOptionsRemote; additionalConfigs?: AppConfig[]; argv: string[]; + watch?: boolean; }): Promise<Config>; // @public (undocumented) diff --git a/packages/backend-common/package.json b/packages/backend-common/package.json index df6b67aada..9ca46d9473 100644 --- a/packages/backend-common/package.json +++ b/packages/backend-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-common", "description": "Common functionality library for Backstage backends", - "version": "0.19.7-next.1", + "version": "0.19.8-next.2", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { @@ -67,7 +67,7 @@ "@google-cloud/storage": "^6.0.0", "@keyv/memcache": "^1.3.5", "@keyv/redis": "^2.5.3", - "@kubernetes/client-node": "0.18.1", + "@kubernetes/client-node": "0.19.0", "@manypkg/get-packages": "^1.1.3", "@octokit/rest": "^19.0.3", "@types/cors": "^2.8.6", diff --git a/packages/backend-common/src/cache/CacheManager.test.ts b/packages/backend-common/src/cache/CacheManager.test.ts index 4578d4fed9..13a4a0d599 100644 --- a/packages/backend-common/src/cache/CacheManager.test.ts +++ b/packages/backend-common/src/cache/CacheManager.test.ts @@ -48,8 +48,10 @@ describe('CacheManager', () => { describe('CacheManager.fromConfig', () => { it('accesses the backend.cache key', () => { const getOptionalString = jest.fn(); + const getOptionalBoolean = jest.fn(); const config = defaultConfig(); config.getOptionalString = getOptionalString; + config.getOptionalBoolean = getOptionalBoolean; CacheManager.fromConfig(config); @@ -57,6 +59,9 @@ describe('CacheManager', () => { expect(getOptionalString.mock.calls[1][0]).toEqual( 'backend.cache.connection', ); + expect(getOptionalBoolean.mock.calls[0][0]).toEqual( + 'backend.cache.useRedisSets', + ); }); it('does not require the backend.cache key', () => { @@ -195,32 +200,61 @@ describe('CacheManager', () => { const mockMemcacheCalls = memcache.mock.calls.splice(-1); expect(mockMemcacheCalls[0][0]).toEqual(expectedHost); }); - }); - it('returns a Redis client when configured', () => { - const redisConnection = 'redis://127.0.0.1:6379'; - const manager = CacheManager.fromConfig( - new ConfigReader({ - backend: { - cache: { - store: 'redis', - connection: redisConnection, + it('returns a Redis client when configured', () => { + const redisConnection = 'redis://127.0.0.1:6379'; + const manager = CacheManager.fromConfig( + new ConfigReader({ + backend: { + cache: { + store: 'redis', + connection: redisConnection, + }, }, - }, - }), - ); - const expectedTtl = 3600; - manager.forPlugin('test').getClient({ defaultTtl: expectedTtl }); + }), + ); + const expectedTtl = 3600; + manager.forPlugin('test').getClient({ defaultTtl: expectedTtl }); - const cache = Keyv as unknown as jest.Mock; - const mockCacheCalls = cache.mock.calls.splice(-1); - expect(mockCacheCalls[0][0]).toMatchObject({ - ttl: expectedTtl, + const cache = Keyv as unknown as jest.Mock; + const mockCacheCalls = cache.mock.calls.splice(-1); + expect(mockCacheCalls[0][0]).toMatchObject({ + ttl: expectedTtl, + }); + expect(mockCacheCalls[0][0].store).toBeInstanceOf(KeyvRedis); + const redis = KeyvRedis as unknown as jest.Mock; + const mockRedisCalls = redis.mock.calls.splice(-1); + expect(mockRedisCalls[0][0]).toEqual(redisConnection); + }); + + it('returns a Redis client when configured with useRedisSets flag', () => { + const redisConnection = 'redis://127.0.0.1:6379'; + const useRedisSets = false; + const manager = CacheManager.fromConfig( + new ConfigReader({ + backend: { + cache: { + store: 'redis', + connection: redisConnection, + useRedisSets: useRedisSets, + }, + }, + }), + ); + const expectedTtl = 3600; + manager.forPlugin('test').getClient({ defaultTtl: expectedTtl }); + + const cache = Keyv as unknown as jest.Mock; + const mockCacheCalls = cache.mock.calls.splice(-1); + expect(mockCacheCalls[0][0]).toMatchObject({ + ttl: expectedTtl, + useRedisSets: useRedisSets, + }); + expect(mockCacheCalls[0][0].store).toBeInstanceOf(KeyvRedis); + const redis = KeyvRedis as unknown as jest.Mock; + const mockRedisCalls = redis.mock.calls.splice(-1); + expect(mockRedisCalls[0][0]).toEqual(redisConnection); }); - expect(mockCacheCalls[0][0].store).toBeInstanceOf(KeyvRedis); - const redis = KeyvRedis as unknown as jest.Mock; - const mockRedisCalls = redis.mock.calls.splice(-1); - expect(mockRedisCalls[0][0]).toEqual(redisConnection); }); describe('connection errors', () => { diff --git a/packages/backend-common/src/cache/CacheManager.ts b/packages/backend-common/src/cache/CacheManager.ts index 9101445b08..efaaf04e3a 100644 --- a/packages/backend-common/src/cache/CacheManager.ts +++ b/packages/backend-common/src/cache/CacheManager.ts @@ -55,6 +55,7 @@ export class CacheManager { private readonly logger: LoggerService; private readonly store: keyof CacheManager['storeFactories']; private readonly connection: string; + private readonly useRedisSets: boolean; private readonly errorHandler: CacheManagerOptions['onError']; /** @@ -72,15 +73,24 @@ export class CacheManager { const store = config.getOptionalString('backend.cache.store') || 'memory'; const connectionString = config.getOptionalString('backend.cache.connection') || ''; + const useRedisSets = + config.getOptionalBoolean('backend.cache.useRedisSets') ?? true; const logger = (options.logger || getRootLogger()).child({ type: 'cacheManager', }); - return new CacheManager(store, connectionString, logger, options.onError); + return new CacheManager( + store, + connectionString, + useRedisSets, + logger, + options.onError, + ); } private constructor( store: string, connectionString: string, + useRedisSets: boolean, logger: LoggerService, errorHandler: CacheManagerOptions['onError'], ) { @@ -90,6 +100,7 @@ export class CacheManager { this.logger = logger; this.store = store as keyof CacheManager['storeFactories']; this.connection = connectionString; + this.useRedisSets = useRedisSets; this.errorHandler = errorHandler; } @@ -143,6 +154,7 @@ export class CacheManager { namespace: pluginId, ttl: defaultTtl, store: new KeyvRedis(this.connection), + useRedisSets: this.useRedisSets, }); } diff --git a/packages/backend-common/src/config.ts b/packages/backend-common/src/config.ts index 53b438de5d..b452d8db70 100644 --- a/packages/backend-common/src/config.ts +++ b/packages/backend-common/src/config.ts @@ -36,6 +36,7 @@ export async function loadBackendConfig(options: { remote?: LoadConfigOptionsRemote; additionalConfigs?: AppConfig[]; argv: string[]; + watch?: boolean; }): Promise<Config> { const secretEnumerator = await createConfigSecretEnumerator({ logger: options.logger, diff --git a/packages/backend-defaults/CHANGELOG.md b/packages/backend-defaults/CHANGELOG.md index 885ea4ced9..c4e9ef1026 100644 --- a/packages/backend-defaults/CHANGELOG.md +++ b/packages/backend-defaults/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/backend-defaults +## 0.2.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-app-api@0.5.6-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + ## 0.2.5-next.1 ### Patch Changes diff --git a/packages/backend-defaults/package.json b/packages/backend-defaults/package.json index 00472e0a7d..9b901f0e74 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.5-next.1", + "version": "0.2.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/backend-next/CHANGELOG.md b/packages/backend-next/CHANGELOG.md index 8760f6cff2..b09af35602 100644 --- a/packages/backend-next/CHANGELOG.md +++ b/packages/backend-next/CHANGELOG.md @@ -1,5 +1,44 @@ # example-backend-next +## 0.0.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-nomad-backend@0.1.8-next.2 + - @backstage/plugin-scaffolder-backend@1.18.0-next.2 + - @backstage/plugin-techdocs-backend@1.8.0-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/plugin-kubernetes-backend@0.12.3-next.2 + - @backstage/plugin-jenkins-backend@0.2.9-next.2 + - @backstage/backend-defaults@0.2.6-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-adr-backend@0.4.3-next.2 + - @backstage/plugin-app-backend@0.3.54-next.2 + - @backstage/plugin-azure-devops-backend@0.4.3-next.2 + - @backstage/plugin-badges-backend@0.3.3-next.2 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.3-next.2 + - @backstage/plugin-devtools-backend@0.2.3-next.2 + - @backstage/plugin-entity-feedback-backend@0.2.3-next.2 + - @backstage/plugin-lighthouse-backend@0.3.3-next.2 + - @backstage/plugin-linguist-backend@0.5.3-next.2 + - @backstage/plugin-permission-backend@0.5.29-next.2 + - @backstage/plugin-permission-backend-module-allow-all-policy@0.1.3-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-playlist-backend@0.3.10-next.2 + - @backstage/plugin-proxy-backend@0.4.3-next.2 + - @backstage/plugin-search-backend@1.4.6-next.2 + - @backstage/plugin-search-backend-module-catalog@0.1.10-next.2 + - @backstage/plugin-search-backend-module-explore@0.1.10-next.2 + - @backstage/plugin-search-backend-module-techdocs@0.1.10-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/plugin-sonarqube-backend@0.2.8-next.2 + - @backstage/plugin-todo-backend@0.3.4-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-catalog-backend-module-unprocessed@0.3.3-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.0.16-next.1 ### Patch Changes diff --git a/packages/backend-next/package.json b/packages/backend-next/package.json index 3e5b4f8057..f057b87523 100644 --- a/packages/backend-next/package.json +++ b/packages/backend-next/package.json @@ -1,6 +1,6 @@ { "name": "example-backend-next", - "version": "0.0.16-next.1", + "version": "0.0.16-next.2", "main": "dist/index.cjs.js", "types": "src/index.ts", "license": "Apache-2.0", @@ -38,6 +38,7 @@ "@backstage/plugin-catalog-backend-module-unprocessed": "workspace:^", "@backstage/plugin-devtools-backend": "workspace:^", "@backstage/plugin-entity-feedback-backend": "workspace:^", + "@backstage/plugin-jenkins-backend": "workspace:^", "@backstage/plugin-kubernetes-backend": "workspace:^", "@backstage/plugin-lighthouse-backend": "workspace:^", "@backstage/plugin-linguist-backend": "workspace:^", diff --git a/packages/backend-next/src/index.ts b/packages/backend-next/src/index.ts index 1b4867c05e..bdfbc2c26b 100644 --- a/packages/backend-next/src/index.ts +++ b/packages/backend-next/src/index.ts @@ -29,6 +29,7 @@ backend.add( backend.add(import('@backstage/plugin-catalog-backend/alpha')); backend.add(import('@backstage/plugin-devtools-backend')); backend.add(import('@backstage/plugin-entity-feedback-backend')); +backend.add(import('@backstage/plugin-jenkins-backend')); backend.add(import('@backstage/plugin-kubernetes-backend/alpha')); backend.add(import('@backstage/plugin-lighthouse-backend')); backend.add(import('@backstage/plugin-linguist-backend')); diff --git a/packages/backend-openapi-utils/CHANGELOG.md b/packages/backend-openapi-utils/CHANGELOG.md index 65c508997b..9061bfe90b 100644 --- a/packages/backend-openapi-utils/CHANGELOG.md +++ b/packages/backend-openapi-utils/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/backend-openapi-utils +## 0.0.5-next.0 + +### Patch Changes + +- 7c83975531: Adds new public utility types for common OpenAPI values, like request and response shapes and parameters available on an endpoint. + + **deprecated** `internal` namespace + The internal namespace will continue to be exported but now uses OpenAPI format for path parameters. You should use the new utility types. + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + ## 0.0.4 ### Patch Changes diff --git a/packages/backend-openapi-utils/package.json b/packages/backend-openapi-utils/package.json index 8fa83bd584..54428236af 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.0.4", + "version": "0.0.5-next.0", "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 ce19f9a798..4e656538c8 100644 --- a/packages/backend-plugin-api/CHANGELOG.md +++ b/packages/backend-plugin-api/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/backend-plugin-api +## 0.6.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.6.5-next.1 ### Patch Changes diff --git a/packages/backend-plugin-api/package.json b/packages/backend-plugin-api/package.json index 8374a002b8..c733d394c3 100644 --- a/packages/backend-plugin-api/package.json +++ b/packages/backend-plugin-api/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-plugin-api", "description": "Core API used by Backstage backend plugins", - "version": "0.6.5-next.1", + "version": "0.6.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/backend-plugin-manager/CHANGELOG.md b/packages/backend-plugin-manager/CHANGELOG.md index 6e1499eb1b..3603dd0dc8 100644 --- a/packages/backend-plugin-manager/CHANGELOG.md +++ b/packages/backend-plugin-manager/CHANGELOG.md @@ -1,5 +1,28 @@ # @backstage/backend-plugin-manager +## 0.0.2-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-events-backend@0.2.15-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/cli-node@0.1.5-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-events-node@0.2.15-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.0.2-next.1 ### Patch Changes diff --git a/packages/backend-plugin-manager/package.json b/packages/backend-plugin-manager/package.json index 33675dda1f..5653513b80 100644 --- a/packages/backend-plugin-manager/package.json +++ b/packages/backend-plugin-manager/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-plugin-manager", "description": "Backstage plugin management backend", - "version": "0.0.2-next.1", + "version": "0.0.2-next.2", "private": true, "main": "src/index.ts", "types": "src/index.ts", diff --git a/packages/backend-tasks/CHANGELOG.md b/packages/backend-tasks/CHANGELOG.md index bd1284aaf5..2dfa563592 100644 --- a/packages/backend-tasks/CHANGELOG.md +++ b/packages/backend-tasks/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/backend-tasks +## 0.5.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.5.10-next.1 ### Patch Changes diff --git a/packages/backend-tasks/package.json b/packages/backend-tasks/package.json index 9a42aab169..a1fe6497b2 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.10-next.1", + "version": "0.5.11-next.2", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/backend-test-utils/CHANGELOG.md b/packages/backend-test-utils/CHANGELOG.md index 5bd1c6d498..c3b92ebf4f 100644 --- a/packages/backend-test-utils/CHANGELOG.md +++ b/packages/backend-test-utils/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/backend-test-utils +## 0.2.7-next.2 + +### Patch Changes + +- a250ad775f: Added `createMockDirectory()` to help out with file system mocking in tests. +- 74491c9602: Updated to import `HostDiscovery` from `@backstage/backend-app-api`. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-app-api@0.5.6-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.2.6-next.1 ### Patch Changes diff --git a/packages/backend-test-utils/package.json b/packages/backend-test-utils/package.json index 691f0a921b..edcb5b7414 100644 --- a/packages/backend-test-utils/package.json +++ b/packages/backend-test-utils/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/backend-test-utils", "description": "Test helpers library for Backstage backends", - "version": "0.2.6-next.1", + "version": "0.2.7-next.2", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/backend/CHANGELOG.md b/packages/backend/CHANGELOG.md index 07105a0417..088f05cfd1 100644 --- a/packages/backend/CHANGELOG.md +++ b/packages/backend/CHANGELOG.md @@ -1,5 +1,64 @@ # example-backend +## 0.2.88-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-nomad-backend@0.1.8-next.2 + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-scaffolder-backend@1.18.0-next.2 + - @backstage/plugin-techdocs-backend@1.8.0-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/plugin-kubernetes-backend@0.12.3-next.2 + - @backstage/plugin-jenkins-backend@0.2.9-next.2 + - @backstage/plugin-auth-backend@0.19.3-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-adr-backend@0.4.3-next.2 + - @backstage/plugin-app-backend@0.3.54-next.2 + - @backstage/plugin-azure-devops-backend@0.4.3-next.2 + - @backstage/plugin-azure-sites-backend@0.1.16-next.2 + - @backstage/plugin-badges-backend@0.3.3-next.2 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.3-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-code-coverage-backend@0.2.20-next.2 + - @backstage/plugin-devtools-backend@0.2.3-next.2 + - @backstage/plugin-entity-feedback-backend@0.2.3-next.2 + - @backstage/plugin-events-backend@0.2.15-next.2 + - @backstage/plugin-explore-backend@0.0.16-next.2 + - @backstage/plugin-graphql-backend@0.1.44-next.2 + - @backstage/plugin-kafka-backend@0.3.3-next.2 + - @backstage/plugin-lighthouse-backend@0.3.3-next.2 + - @backstage/plugin-linguist-backend@0.5.3-next.2 + - @backstage/plugin-permission-backend@0.5.29-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-playlist-backend@0.3.10-next.2 + - @backstage/plugin-proxy-backend@0.4.3-next.2 + - @backstage/plugin-rollbar-backend@0.1.51-next.2 + - @backstage/plugin-scaffolder-backend-module-confluence-to-markdown@0.2.7-next.2 + - @backstage/plugin-scaffolder-backend-module-rails@0.4.23-next.2 + - @backstage/plugin-search-backend@1.4.6-next.2 + - @backstage/plugin-search-backend-module-catalog@0.1.10-next.2 + - @backstage/plugin-search-backend-module-elasticsearch@1.3.9-next.2 + - @backstage/plugin-search-backend-module-explore@0.1.10-next.2 + - @backstage/plugin-search-backend-module-pg@0.5.15-next.2 + - @backstage/plugin-search-backend-module-techdocs@0.1.10-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/plugin-tech-insights-backend@0.5.20-next.2 + - @backstage/plugin-tech-insights-backend-module-jsonfc@0.1.38-next.2 + - @backstage/plugin-tech-insights-node@0.4.12-next.2 + - @backstage/plugin-todo-backend@0.3.4-next.2 + - example-app@0.2.88-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-backend-module-unprocessed@0.3.3-next.2 + - @backstage/plugin-events-node@0.2.15-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.2.88-next.1 ### Patch Changes diff --git a/packages/backend/package.json b/packages/backend/package.json index 8519a5ed71..cd0191f7fa 100644 --- a/packages/backend/package.json +++ b/packages/backend/package.json @@ -1,6 +1,6 @@ { "name": "example-backend", - "version": "0.2.88-next.1", + "version": "0.2.88-next.2", "main": "dist/index.cjs.js", "types": "src/index.ts", "license": "Apache-2.0", @@ -81,7 +81,7 @@ "@gitbeaker/node": "^35.1.0", "@octokit/rest": "^19.0.3", "@opentelemetry/api": "^1.4.1", - "@opentelemetry/exporter-prometheus": "^0.39.1", + "@opentelemetry/exporter-prometheus": "^0.44.0", "@opentelemetry/sdk-metrics": "^1.13.0", "azure-devops-node-api": "^11.0.1", "better-sqlite3": "^8.0.0", diff --git a/packages/backend/src/index.ts b/packages/backend/src/index.ts index b22f7d2983..8df01b050e 100644 --- a/packages/backend/src/index.ts +++ b/packages/backend/src/index.ts @@ -55,7 +55,6 @@ import search from './plugins/search'; import techdocs from './plugins/techdocs'; import techInsights from './plugins/techInsights'; import todo from './plugins/todo'; -import graphql from './plugins/graphql'; import app from './plugins/app'; import badges from './plugins/badges'; import jenkins from './plugins/jenkins'; @@ -155,7 +154,6 @@ async function main() { const todoEnv = useHotMemoize(module, () => createEnv('todo')); const kubernetesEnv = useHotMemoize(module, () => createEnv('kubernetes')); const kafkaEnv = useHotMemoize(module, () => createEnv('kafka')); - const graphqlEnv = useHotMemoize(module, () => createEnv('graphql')); const appEnv = useHotMemoize(module, () => createEnv('app')); const badgesEnv = useHotMemoize(module, () => createEnv('badges')); const jenkinsEnv = useHotMemoize(module, () => createEnv('jenkins')); @@ -190,7 +188,6 @@ async function main() { apiRouter.use('/kubernetes', await kubernetes(kubernetesEnv)); apiRouter.use('/kafka', await kafka(kafkaEnv)); apiRouter.use('/proxy', await proxy(proxyEnv)); - apiRouter.use('/graphql', await graphql(graphqlEnv)); apiRouter.use('/badges', await badges(badgesEnv)); apiRouter.use('/jenkins', await jenkins(jenkinsEnv)); apiRouter.use('/permission', await permission(permissionEnv)); diff --git a/packages/catalog-client/CHANGELOG.md b/packages/catalog-client/CHANGELOG.md index 06231c6c7a..71593b5a33 100644 --- a/packages/catalog-client/CHANGELOG.md +++ b/packages/catalog-client/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/catalog-client +## 1.4.5-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + ## 1.4.4 ### Patch Changes diff --git a/packages/catalog-client/package.json b/packages/catalog-client/package.json index b7fcdb549e..2be748fbce 100644 --- a/packages/catalog-client/package.json +++ b/packages/catalog-client/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/catalog-client", "description": "An isomorphic client for the catalog backend", - "version": "1.4.4", + "version": "1.4.5-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/packages/catalog-model/CHANGELOG.md b/packages/catalog-model/CHANGELOG.md index 3972ea9761..a6b3715d28 100644 --- a/packages/catalog-model/CHANGELOG.md +++ b/packages/catalog-model/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/catalog-model +## 1.4.3-next.0 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/types@1.1.1 + ## 1.4.2 ### Patch Changes diff --git a/packages/catalog-model/package.json b/packages/catalog-model/package.json index 4eeaee9dc6..58097decec 100644 --- a/packages/catalog-model/package.json +++ b/packages/catalog-model/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/catalog-model", "description": "Types and validators that help describe the model of a Backstage Catalog", - "version": "1.4.2", + "version": "1.4.3-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/packages/cli-node/CHANGELOG.md b/packages/cli-node/CHANGELOG.md index ab16a5d036..2d896f3e7b 100644 --- a/packages/cli-node/CHANGELOG.md +++ b/packages/cli-node/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/cli-node +## 0.1.5-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/types@1.1.1 + ## 0.1.5-next.0 ### Patch Changes diff --git a/packages/cli-node/package.json b/packages/cli-node/package.json index a1062c2783..1190d134f5 100644 --- a/packages/cli-node/package.json +++ b/packages/cli-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/cli-node", "description": "Node.js library for Backstage CLIs", - "version": "0.1.5-next.0", + "version": "0.1.5-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/packages/cli/CHANGELOG.md b/packages/cli/CHANGELOG.md index d9d7c426e3..a3a6b005c0 100644 --- a/packages/cli/CHANGELOG.md +++ b/packages/cli/CHANGELOG.md @@ -1,5 +1,45 @@ # @backstage/cli +## 0.23.0-next.2 + +### Minor Changes + +- 8defbd5434: Update typescript-eslint to 6.7.x, adding compatibility with TypeScript 5.2. + + This includes a major update on typescript-eslint, you can see the details in the [release notes](https://typescript-eslint.io/blog/announcing-typescript-eslint-v6/). + +### Patch Changes + +- 2ef6522552: Support for the `.icon.svg` extension has been deprecated and will be removed in the future. The implementation of this extension is too tied to a particular version of MUI and the SVGO, and it makes it harder to evolve the build system. We may introduce the ability to reintroduce this kind of functionality in the future through configuration for use in internal plugins, but for now we're forced to remove it. + + To migrate existing code, rename the `.icon.svg` file to `.tsx` and replace the `<svg>` element with `<SvgIcon>` from MUI and add necessary imports. For example: + + ```tsx + import React from 'react'; + import SvgIcon from '@material-ui/core/SvgIcon'; + import { IconComponent } from '@backstage/core-plugin-api'; + + export const CodeSceneIcon = (props: SvgIconProps) => ( + <SvgIcon {...props}> + <g> + <path d="..." /> + </g> + </SvgIcon> + ); + ``` + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/config-loader@1.5.1-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/cli-node@0.1.5-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/eslint-plugin@0.1.3 + - @backstage/release-manifests@0.0.10 + - @backstage/types@1.1.1 + ## 0.23.0-next.1 ### Patch Changes @@ -21,7 +61,7 @@ ### Minor Changes -- 7077dbf131: The new backend start command that used to be enabled by setting `EXPERIMENTAL_BACKEND_START` is now the default. To revert to the old behavior, set `LEGACY_BACKEND_START` instead. +- 7077dbf131: **BREAKING** The new backend start command that used to be enabled by setting `EXPERIMENTAL_BACKEND_START` is now the default. To revert to the old behavior set `LEGACY_BACKEND_START`, which is recommended if you haven't migrated to the new backend system. This new command is no longer based on Webpack, but instead uses Node.js loaders to transpile on the fly. Rather than hot reloading modules the entire backend is now restarted on change, but the SQLite database state is still maintained across restarts via a parent process. diff --git a/packages/cli/config/jest.js b/packages/cli/config/jest.js index 1756b37db2..4a8bf9694f 100644 --- a/packages/cli/config/jest.js +++ b/packages/cli/config/jest.js @@ -24,6 +24,13 @@ const envOptions = { oldTests: Boolean(process.env.BACKSTAGE_OLD_TESTS), }; +try { + require.resolve('react-dom/client'); + process.env.HAS_REACT_DOM_CLIENT = true; +} catch { + /* ignored */ +} + const transformIgnorePattern = [ '@material-ui', 'ajv', diff --git a/packages/cli/package.json b/packages/cli/package.json index f90be7c846..1a5af11de3 100644 --- a/packages/cli/package.json +++ b/packages/cli/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/cli", "description": "CLI for developing Backstage plugins and apps", - "version": "0.23.0-next.1", + "version": "0.23.0-next.2", "publishConfig": { "access": "public" }, @@ -66,7 +66,7 @@ "@swc/jest": "^0.2.22", "@types/jest": "^29.0.0", "@types/webpack-env": "^1.15.2", - "@typescript-eslint/eslint-plugin": "6.7.2", + "@typescript-eslint/eslint-plugin": "6.7.5", "@typescript-eslint/parser": "^6.7.2", "@yarnpkg/lockfile": "^1.1.0", "@yarnpkg/parsers": "^3.0.0-rc.4", @@ -158,7 +158,6 @@ "@types/http-proxy": "^1.17.4", "@types/inquirer": "^8.1.3", "@types/minimatch": "^5.0.0", - "@types/mock-fs": "^4.13.0", "@types/node": "^18.17.8", "@types/npm-packlist": "^3.0.0", "@types/recursive-readdir": "^2.2.0", @@ -169,7 +168,6 @@ "@types/terser-webpack-plugin": "^5.0.4", "@types/yarnpkg__lockfile": "^1.1.4", "del": "^7.0.0", - "mock-fs": "^5.2.0", "msw": "^1.0.0", "nodemon": "^3.0.1", "ts-node": "^10.0.0", diff --git a/packages/cli/src/commands/create-plugin/createPlugin.test.ts b/packages/cli/src/commands/create-plugin/createPlugin.test.ts index aa59f94fb4..84af6ebf69 100644 --- a/packages/cli/src/commands/create-plugin/createPlugin.test.ts +++ b/packages/cli/src/commands/create-plugin/createPlugin.test.ts @@ -16,23 +16,21 @@ import fs from 'fs-extra'; import path from 'path'; -import mockFs from 'mock-fs'; import { movePlugin } from './createPlugin'; +import { createMockDirectory } from '@backstage/backend-test-utils'; const id = 'testPluginMock'; describe('createPlugin', () => { - afterEach(() => { - mockFs.restore(); - }); + const mockDir = createMockDirectory(); describe('movePlugin', () => { it('should move the temporary plugin directory to its final place', async () => { - mockFs({ + mockDir.setContent({ [id]: {}, }); - const tempDir = id; - const pluginDir = path.join('test-temp', 'plugins', id); + const tempDir = mockDir.resolve(id); + const pluginDir = mockDir.resolve('test-temp/plugins', id); await movePlugin(tempDir, pluginDir, id); await expect(fs.pathExists(pluginDir)).resolves.toBe(true); diff --git a/packages/cli/src/commands/onboard/discovery/providers/github/GithubDiscoveryProvider.ts b/packages/cli/src/commands/onboard/discovery/providers/github/GithubDiscoveryProvider.ts index d5a3dc4a77..a24756edd7 100644 --- a/packages/cli/src/commands/onboard/discovery/providers/github/GithubDiscoveryProvider.ts +++ b/packages/cli/src/commands/onboard/discovery/providers/github/GithubDiscoveryProvider.ts @@ -113,7 +113,7 @@ export class GithubDiscoveryProvider implements Provider { const query = `query repositories($org: String!, $cursor: String) { repositoryOwner(login: $org) { login - repositories(first: 100, after: $cursor) { + repositories(first: 50, after: $cursor) { nodes { name url diff --git a/packages/cli/src/commands/versions/bump.test.ts b/packages/cli/src/commands/versions/bump.test.ts index 7af6c6160b..d00b4ce8da 100644 --- a/packages/cli/src/commands/versions/bump.test.ts +++ b/packages/cli/src/commands/versions/bump.test.ts @@ -15,10 +15,7 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; import { Command } from 'commander'; -import { resolve as resolvePath } from 'path'; -import { paths } from '../../lib/paths'; import * as runObj from '../../lib/run'; import bump, { bumpBackstageJsonVersion, createVersionFinder } from './bump'; import { @@ -30,6 +27,10 @@ import { setupServer } from 'msw/node'; import { rest } from 'msw'; import { NotFoundError } from '@backstage/errors'; import { Lockfile } from '../../lib/versioning/Lockfile'; +import { + MockDirectory, + createMockDirectory, +} from '@backstage/backend-test-utils'; // Avoid mutating the global http(s) agent used in other tests jest.mock('global-agent/bootstrap', () => {}); @@ -56,6 +57,19 @@ jest.mock('ora', () => ({ }, })); +let mockDir: MockDirectory; + +jest.mock('../../lib/paths', () => ({ + paths: { + resolveTargetRoot(filename: string) { + return mockDir.resolve(filename); + }, + get targetDir() { + return mockDir.path; + }, + }, +})); + jest.mock('../../lib/run', () => { return { run: jest.fn(), @@ -117,7 +131,17 @@ const lockfileMockResult = `${HEADER} version "1.0.0" `; +// Avoid flakes by comparing sorted log lines. File system access is async, which leads to the log line order being indeterministic +const expectLogsToMatch = ( + recievedLogs: String[], + expected: String[], +): void => { + expect(recievedLogs.filter(Boolean).sort()).toEqual(expected.sort()); +}; + describe('bump', () => { + mockDir = createMockDirectory(); + beforeEach(() => { mockFetchPackageInfo.mockImplementation(async name => ({ name: name, @@ -128,7 +152,6 @@ describe('bump', () => { }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); @@ -136,31 +159,34 @@ describe('bump', () => { setupRequestMockHandlers(worker); it('should bump backstage dependencies', async () => { - mockFs({ - '/yarn.lock': lockfileMock, - '/package.json': JSON.stringify({ + mockDir.setContent({ + 'yarn.lock': lockfileMock, + 'package.json': JSON.stringify({ workspaces: { packages: ['packages/*'], }, }), - '/packages/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '^1.0.5', + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '^1.0.5', + }, + }), }, - }), - '/packages/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '^1.0.3', - '@backstage/theme': '^1.0.0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '^1.0.3', + '@backstage/theme': '^1.0.0', + }, + }), }, - }), + }, }); - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); jest.spyOn(runObj, 'run').mockResolvedValue(undefined); worker.use( rest.get( @@ -177,7 +203,7 @@ describe('bump', () => { const { log: logs } = await withLogCollector(['log'], async () => { await bump({ pattern: null, release: 'main' } as unknown as Command); }); - expect(logs.filter(Boolean)).toEqual([ + expectLogsToMatch(logs, [ 'Using default pattern glob @backstage/*', 'Checking for updates of @backstage/core', 'Checking for updates of @backstage/theme', @@ -208,17 +234,24 @@ describe('bump', () => { expect.any(Object), ); - const lockfileContents = await fs.readFile('/yarn.lock', 'utf8'); + const lockfileContents = await fs.readFile( + mockDir.resolve('yarn.lock'), + 'utf8', + ); expect(lockfileContents).toBe(lockfileMockResult); - const packageA = await fs.readJson('/packages/a/package.json'); + const packageA = await fs.readJson( + mockDir.resolve('packages/a/package.json'), + ); expect(packageA).toEqual({ name: 'a', dependencies: { '@backstage/core': '^1.0.6', }, }); - const packageB = await fs.readJson('/packages/b/package.json'); + const packageB = await fs.readJson( + mockDir.resolve('packages/b/package.json'), + ); expect(packageB).toEqual({ name: 'b', dependencies: { @@ -229,31 +262,34 @@ describe('bump', () => { }); it('should bump backstage dependencies but not install them', async () => { - mockFs({ - '/yarn.lock': lockfileMock, - '/package.json': JSON.stringify({ + mockDir.setContent({ + 'yarn.lock': lockfileMock, + 'package.json': JSON.stringify({ workspaces: { packages: ['packages/*'], }, }), - '/packages/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '^1.0.5', + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '^1.0.5', + }, + }), }, - }), - '/packages/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '^1.0.3', - '@backstage/theme': '^1.0.0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '^1.0.3', + '@backstage/theme': '^1.0.0', + }, + }), }, - }), + }, }); - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); jest.spyOn(runObj, 'run').mockResolvedValue(undefined); worker.use( rest.get( @@ -274,7 +310,7 @@ describe('bump', () => { skipInstall: true, } as unknown as Command); }); - expect(logs.filter(Boolean)).toEqual([ + expectLogsToMatch(logs, [ 'Using default pattern glob @backstage/*', 'Checking for updates of @backstage/core', 'Checking for updates of @backstage/theme', @@ -304,17 +340,24 @@ describe('bump', () => { expect.any(Object), ); - const lockfileContents = await fs.readFile('/yarn.lock', 'utf8'); + const lockfileContents = await fs.readFile( + mockDir.resolve('yarn.lock'), + 'utf8', + ); expect(lockfileContents).toBe(lockfileMockResult); - const packageA = await fs.readJson('/packages/a/package.json'); + const packageA = await fs.readJson( + mockDir.resolve('packages/a/package.json'), + ); expect(packageA).toEqual({ name: 'a', dependencies: { '@backstage/core': '^1.0.6', }, }); - const packageB = await fs.readJson('/packages/b/package.json'); + const packageB = await fs.readJson( + mockDir.resolve('packages/b/package.json'), + ); expect(packageB).toEqual({ name: 'b', dependencies: { @@ -325,31 +368,34 @@ describe('bump', () => { }); it('should prefer dependency versions from release manifest', async () => { - mockFs({ - '/yarn.lock': lockfileMock, - '/package.json': JSON.stringify({ + mockDir.setContent({ + 'yarn.lock': lockfileMock, + 'package.json': JSON.stringify({ workspaces: { packages: ['packages/*'], }, }), - '/packages/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '^1.0.5', + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '^1.0.5', + }, + }), }, - }), - '/packages/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '^1.0.3', - '@backstage/theme': '^1.0.0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '^1.0.3', + '@backstage/theme': '^1.0.0', + }, + }), }, - }), + }, }); - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); jest.spyOn(runObj, 'run').mockResolvedValue(undefined); worker.use( rest.get( @@ -376,7 +422,7 @@ describe('bump', () => { const { log: logs } = await withLogCollector(['log'], async () => { await bump({ pattern: null, release: 'main' } as unknown as Command); }); - expect(logs.filter(Boolean)).toEqual([ + expectLogsToMatch(logs, [ 'Using default pattern glob @backstage/*', 'Checking for updates of @backstage/core', 'Checking for updates of @backstage/theme', @@ -408,17 +454,24 @@ describe('bump', () => { expect.any(Object), ); - const lockfileContents = await fs.readFile('/yarn.lock', 'utf8'); + const lockfileContents = await fs.readFile( + mockDir.resolve('yarn.lock'), + 'utf8', + ); expect(lockfileContents).toBe(lockfileMockResult); - const packageA = await fs.readJson('/packages/a/package.json'); + const packageA = await fs.readJson( + mockDir.resolve('packages/a/package.json'), + ); expect(packageA).toEqual({ name: 'a', dependencies: { '@backstage/core': '^1.0.6', }, }); - const packageB = await fs.readJson('/packages/b/package.json'); + const packageB = await fs.readJson( + mockDir.resolve('packages/b/package.json'), + ); expect(packageB).toEqual({ name: 'b', dependencies: { @@ -429,30 +482,33 @@ describe('bump', () => { }); it('should only bump packages in the manifest when a specific release is specified', async () => { - mockFs({ - '/yarn.lock': lockfileMock, - '/package.json': JSON.stringify({ + mockDir.setContent({ + 'yarn.lock': lockfileMock, + 'package.json': JSON.stringify({ workspaces: { packages: ['packages/*'], }, }), - '/packages/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '^1.0.5', + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '^1.0.5', + }, + }), }, - }), - '/packages/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '^1.0.3', - '@backstage/theme': '^1.0.0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '^1.0.3', + '@backstage/theme': '^1.0.0', + }, + }), }, - }), + }, }); - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); jest.spyOn(runObj, 'run').mockResolvedValue(undefined); worker.use( @@ -472,14 +528,18 @@ describe('bump', () => { expect(runObj.run).toHaveBeenCalledTimes(0); - const packageA = await fs.readJson('/packages/a/package.json'); + const packageA = await fs.readJson( + mockDir.resolve('packages/a/package.json'), + ); expect(packageA).toEqual({ name: 'a', dependencies: { '@backstage/core': '^1.0.5', }, }); - const packageB = await fs.readJson('/packages/b/package.json'); + const packageB = await fs.readJson( + mockDir.resolve('packages/b/package.json'), + ); expect(packageB).toEqual({ name: 'b', dependencies: { @@ -489,32 +549,36 @@ describe('bump', () => { }); }); + // eslint-disable-next-line jest/expect-expect it('should prefer versions from the highest manifest version when main is not specified', async () => { - mockFs({ - '/yarn.lock': lockfileMock, - '/package.json': JSON.stringify({ + mockDir.setContent({ + 'yarn.lock': lockfileMock, + 'package.json': JSON.stringify({ workspaces: { packages: ['packages/*'], }, }), - '/packages/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '^1.0.5', + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '^1.0.5', + }, + }), }, - }), - '/packages/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '^1.0.3', - '@backstage/theme': '^1.0.0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '^1.0.3', + '@backstage/theme': '^1.0.0', + }, + }), }, - }), + }, }); - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); jest.spyOn(runObj, 'run').mockResolvedValue(undefined); worker.use( rest.get( @@ -561,7 +625,7 @@ describe('bump', () => { const { log: logs } = await withLogCollector(['log'], async () => { await bump({ pattern: null, release: 'next' } as unknown as Command); }); - expect(logs.filter(Boolean)).toEqual([ + expectLogsToMatch(logs, [ 'Using default pattern glob @backstage/*', 'Checking for updates of @backstage/core', 'Checking for updates of @backstage/theme', @@ -609,35 +673,38 @@ describe('bump', () => { "@backstage/theme@^1.0.0": version "1.0.0" `; - mockFs({ - '/yarn.lock': customLockfileMock, - '/package.json': JSON.stringify({ + mockDir.setContent({ + 'yarn.lock': customLockfileMock, + 'package.json': JSON.stringify({ workspaces: { packages: ['packages/*'], }, }), - '/packages/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '^1.0.5', - '@backstage-extra/custom': '^1.0.1', - '@backstage-extra/custom-two': '^1.0.0', + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '^1.0.5', + '@backstage-extra/custom': '^1.0.1', + '@backstage-extra/custom-two': '^1.0.0', + }, + }), }, - }), - '/packages/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '^1.0.3', - '@backstage/theme': '^1.0.0', - '@backstage-extra/custom': '^1.1.0', - '@backstage-extra/custom-two': '^1.0.0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '^1.0.3', + '@backstage/theme': '^1.0.0', + '@backstage-extra/custom': '^1.1.0', + '@backstage-extra/custom-two': '^1.0.0', + }, + }), }, - }), + }, }); - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); jest.spyOn(runObj, 'run').mockResolvedValue(undefined); worker.use( rest.get( @@ -657,7 +724,7 @@ describe('bump', () => { release: 'main', } as any); }); - expect(logs.filter(Boolean)).toEqual([ + expectLogsToMatch(logs, [ 'Using custom pattern glob @{backstage,backstage-extra}/*', 'Checking for updates of @backstage/core', 'Checking for updates of @backstage-extra/custom', @@ -696,10 +763,15 @@ describe('bump', () => { expect.any(Object), ); - const lockfileContents = await fs.readFile('/yarn.lock', 'utf8'); + const lockfileContents = await fs.readFile( + mockDir.resolve('yarn.lock'), + 'utf8', + ); expect(lockfileContents).toEqual(customLockfileMockResult); - const packageA = await fs.readJson('/packages/a/package.json'); + const packageA = await fs.readJson( + mockDir.resolve('packages/a/package.json'), + ); expect(packageA).toEqual({ name: 'a', dependencies: { @@ -708,7 +780,9 @@ describe('bump', () => { '@backstage/core': '^1.0.6', }, }); - const packageB = await fs.readJson('/packages/b/package.json'); + const packageB = await fs.readJson( + mockDir.resolve('packages/b/package.json'), + ); expect(packageB).toEqual({ name: 'b', dependencies: { @@ -721,31 +795,34 @@ describe('bump', () => { }); it('should ignore not found packages', async () => { - mockFs({ - '/yarn.lock': lockfileMockResult, - '/package.json': JSON.stringify({ + mockDir.setContent({ + 'yarn.lock': lockfileMockResult, + 'package.json': JSON.stringify({ workspaces: { packages: ['packages/*'], }, }), - '/packages/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '^1.0.5', + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '^1.0.5', + }, + }), }, - }), - '/packages/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '^1.0.3', - '@backstage/theme': '^2.0.0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '^1.0.3', + '@backstage/theme': '^2.0.0', + }, + }), }, - }), + }, }); - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); mockFetchPackageInfo.mockRejectedValue(new NotFoundError('Nope')); jest.spyOn(runObj, 'run').mockResolvedValue(undefined); worker.use( @@ -763,7 +840,7 @@ describe('bump', () => { const { log: logs } = await withLogCollector(['log'], async () => { await bump({ pattern: null, release: 'main' } as unknown as Command); }); - expect(logs.filter(Boolean)).toEqual([ + expectLogsToMatch(logs, [ 'Using default pattern glob @backstage/*', 'Checking for updates of @backstage/core', 'Checking for updates of @backstage/theme', @@ -778,17 +855,24 @@ describe('bump', () => { expect(runObj.run).toHaveBeenCalledTimes(0); - const lockfileContents = await fs.readFile('/yarn.lock', 'utf8'); + const lockfileContents = await fs.readFile( + mockDir.resolve('yarn.lock'), + 'utf8', + ); expect(lockfileContents).toBe(lockfileMockResult); - const packageA = await fs.readJson('/packages/a/package.json'); + const packageA = await fs.readJson( + mockDir.resolve('packages/a/package.json'), + ); expect(packageA).toEqual({ name: 'a', dependencies: { '@backstage/core': '^1.0.5', // not bumped }, }); - const packageB = await fs.readJson('/packages/b/package.json'); + const packageB = await fs.readJson( + mockDir.resolve('packages/b/package.json'), + ); expect(packageB).toEqual({ name: 'b', dependencies: { @@ -798,6 +882,7 @@ describe('bump', () => { }); }); + // eslint-disable-next-line jest/expect-expect it('should log duplicates', async () => { jest.spyOn(Lockfile.prototype, 'analyze').mockReturnValue({ invalidRanges: [], @@ -826,31 +911,34 @@ describe('bump', () => { }, ], }); - mockFs({ - '/yarn.lock': lockfileMock, - '/package.json': JSON.stringify({ + mockDir.setContent({ + 'yarn.lock': lockfileMock, + 'package.json': JSON.stringify({ workspaces: { packages: ['packages/*'], }, }), - '/packages/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '^1.0.5', + packages: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '^1.0.5', + }, + }), }, - }), - '/packages/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '^1.0.3', - '@backstage/theme': '^1.0.0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '^1.0.3', + '@backstage/theme': '^1.0.0', + }, + }), }, - }), + }, }); - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); jest.spyOn(runObj, 'run').mockResolvedValue(undefined); worker.use( rest.get( @@ -867,7 +955,7 @@ describe('bump', () => { const { log: logs } = await withLogCollector(['log'], async () => { await bump({ pattern: null, release: 'main' } as unknown as Command); }); - expect(logs.filter(Boolean)).toEqual([ + expectLogsToMatch(logs, [ 'Using default pattern glob @backstage/*', 'Checking for updates of @backstage/core', 'Checking for updates of @backstage/theme', @@ -891,24 +979,23 @@ describe('bump', () => { }); describe('bumpBackstageJsonVersion', () => { + mockDir = createMockDirectory(); + afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should bump version in backstage.json', async () => { - mockFs({ - '/backstage.json': JSON.stringify({ version: '0.0.1' }), + mockDir.setContent({ + 'backstage.json': JSON.stringify({ version: '0.0.1' }), }); - paths.targetDir = '/'; - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); const { log } = await withLogCollector(async () => { await bumpBackstageJsonVersion('1.4.1'); }); - expect(await fs.readJson('/backstage.json')).toEqual({ version: '1.4.1' }); + expect(await fs.readJson(mockDir.resolve('backstage.json'))).toEqual({ + version: '1.4.1', + }); expect(log).toEqual([ 'Upgraded from release 0.0.1 to 1.4.1, please review these template changes:', undefined, @@ -918,17 +1005,15 @@ describe('bumpBackstageJsonVersion', () => { }); it("should create backstage.json if doesn't exist", async () => { - mockFs({}); - paths.targetDir = '/'; + mockDir.clear(); // empty temp test folder const latest = '1.4.1'; - jest - .spyOn(paths, 'resolveTargetRoot') - .mockImplementation((...path) => resolvePath('/', ...path)); const { log } = await withLogCollector(async () => { await bumpBackstageJsonVersion(latest); }); - expect(await fs.readJson('/backstage.json')).toEqual({ version: latest }); + expect(await fs.readJson(mockDir.resolve('backstage.json'))).toEqual({ + version: latest, + }); expect(log).toEqual([ 'Your project is now at version 1.4.1, which has been written to backstage.json', ]); diff --git a/packages/cli/src/lib/builder/plugins.test.ts b/packages/cli/src/lib/builder/plugins.test.ts index dcbdc55cc0..f6984dd67e 100644 --- a/packages/cli/src/lib/builder/plugins.test.ts +++ b/packages/cli/src/lib/builder/plugins.test.ts @@ -15,7 +15,6 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; import { NormalizedOutputOptions, OutputAsset, @@ -24,6 +23,7 @@ import { } from 'rollup'; import { forwardFileImports } from './plugins'; +import { createMockDirectory } from '@backstage/backend-test-utils'; const context = { meta: { @@ -91,16 +91,18 @@ describe('forwardFileImports', () => { ); }); - describe('with mock fs', () => { - beforeEach(() => { - mockFs({ - '/dev/src/my-module.ts': '', - '/dev/src/dir/my-image.png': 'my-image', - }); - }); + describe('with createMockDirectory', () => { + const mockDir = createMockDirectory(); - afterEach(() => { - mockFs.restore(); + beforeEach(() => { + mockDir.setContent({ + dev: { + src: { + 'my-module.ts': '', + dir: { 'my-image.png': 'my-image' }, + }, + }, + }); }); it('should extract files', async () => { @@ -111,23 +113,33 @@ describe('forwardFileImports', () => { throw new Error('options.external is not a function'); } - expect(options.external('./my-module', '/dev/src/index.ts', false)).toBe( - false, - ); expect( - options.external('./my-image.png', '/dev/src/dir/index.ts', false), + options.external( + './my-module', + mockDir.resolve('dev/src/index.ts'), + false, + ), + ).toBe(false); + expect( + options.external( + './my-image.png', + mockDir.resolve('dev', 'src', 'dir', 'index.ts'), + false, + ), ).toBe(true); - const outPath = '/dev/dist/dir/my-image.png'; + const outPath = mockDir.resolve('dev', 'dist', 'dir', 'my-image.png'); await expect(fs.pathExists(outPath)).resolves.toBe(false); await plugin.generateBundle?.call( context, - { dir: '/dev/dist' } as NormalizedOutputOptions, + { + dir: mockDir.resolve('dev/dist'), + } as NormalizedOutputOptions, { ['index.js']: { type: 'chunk', - facadeModuleId: '/dev/src/index.ts', + facadeModuleId: mockDir.resolve('dev/src/index.ts'), } as OutputChunk, }, false, // isWrite = false -> no write @@ -136,7 +148,9 @@ describe('forwardFileImports', () => { await plugin.generateBundle?.call( context, - { dir: '/dev/dist' } as NormalizedOutputOptions, + { + dir: mockDir.resolve('dev/dist'), + } as NormalizedOutputOptions, { // output assets should not cause a write ['index.js']: { type: 'asset' } as OutputAsset, @@ -150,11 +164,13 @@ describe('forwardFileImports', () => { // output chunk + isWrite -> generate files await plugin.generateBundle?.call( context, - { dir: '/dev/dist' } as NormalizedOutputOptions, + { + dir: mockDir.resolve('dev/dist'), + } as NormalizedOutputOptions, { ['index.js']: { type: 'chunk', - facadeModuleId: '/dev/src/index.ts', + facadeModuleId: mockDir.resolve('dev/src/index.ts'), } as OutputChunk, }, true, @@ -164,11 +180,13 @@ describe('forwardFileImports', () => { // should not break when triggering another write await plugin.generateBundle?.call( context, - { file: '/dev/dist/my-output.js' } as NormalizedOutputOptions, + { + file: mockDir.resolve('dev/dist/my-output.js'), + } as NormalizedOutputOptions, { ['index.js']: { type: 'chunk', - facadeModuleId: '/dev/src/index.ts', + facadeModuleId: mockDir.resolve('dev/src/index.ts'), } as OutputChunk, }, true, diff --git a/packages/cli/src/lib/bundler/config.ts b/packages/cli/src/lib/bundler/config.ts index ed20fe385a..534ffe8c58 100644 --- a/packages/cli/src/lib/bundler/config.ts +++ b/packages/cli/src/lib/bundler/config.ts @@ -81,6 +81,15 @@ async function readBuildInfo() { }; } +function hasReactDomClient() { + try { + require.resolve('react-dom/client'); + return true; + } catch { + return false; + } +} + export async function createConfig( paths: BundlingPaths, options: BundlingOptions, @@ -136,6 +145,9 @@ export async function createConfig( () => JSON.stringify(options.getFrontendAppConfigs()), true, ), + // This allows for conditional imports of react-dom/client, since there's no way + // to check for presence of it in source code without module resolution errors. + 'process.env.HAS_REACT_DOM_CLIENT': JSON.stringify(hasReactDomClient()), }), ); diff --git a/packages/cli/src/lib/new/factories/backendModule.test.ts b/packages/cli/src/lib/new/factories/backendModule.test.ts index c633b1c1b2..78ef5f96bb 100644 --- a/packages/cli/src/lib/new/factories/backendModule.test.ts +++ b/packages/cli/src/lib/new/factories/backendModule.test.ts @@ -15,39 +15,38 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { sep, resolve as resolvePath } from 'path'; -import { paths } from '../../paths'; +import { sep } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { backendModule } from './backendModule'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('backendModule factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a backend plugin', async () => { - mockFs({ - '/root': { - packages: { - backend: { - 'package.json': JSON.stringify({}), - }, + mockDir.setContent({ + packages: { + backend: { + 'package.json': JSON.stringify({}), }, - plugins: mockFs.directory(), }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + plugins: {}, }); const options = await FactoryRegistry.populateOptions(backendModule, { @@ -73,8 +72,7 @@ describe('backendModule factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ 'Creating backend module backstage-plugin-test-backend-module-tester-two', 'Checking Prerequisites:', `availability plugins${sep}test-backend-module-tester-two`, @@ -91,14 +89,14 @@ describe('backendModule factory', () => { ]); await expect( - fs.readJson('/root/packages/backend/package.json'), + fs.readJson(mockDir.resolve('packages/backend/package.json')), ).resolves.toEqual({ dependencies: { 'backstage-plugin-test-backend-module-tester-two': '^1.0.0', }, }); const moduleFile = await fs.readFile( - '/root/plugins/test-backend-module-tester-two/src/module.ts', + mockDir.resolve('plugins/test-backend-module-tester-two/src/module.ts'), 'utf-8', ); @@ -110,11 +108,11 @@ describe('backendModule factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath('/root/plugins/test-backend-module-tester-two'), + cwd: mockDir.resolve('plugins/test-backend-module-tester-two'), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath('/root/plugins/test-backend-module-tester-two'), + cwd: mockDir.resolve('plugins/test-backend-module-tester-two'), optional: true, }); }); diff --git a/packages/cli/src/lib/new/factories/backendPlugin.test.ts b/packages/cli/src/lib/new/factories/backendPlugin.test.ts index f326de88b8..5c1d496e49 100644 --- a/packages/cli/src/lib/new/factories/backendPlugin.test.ts +++ b/packages/cli/src/lib/new/factories/backendPlugin.test.ts @@ -15,39 +15,38 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { sep, resolve as resolvePath } from 'path'; -import { paths } from '../../paths'; +import { sep } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { backendPlugin } from './backendPlugin'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('backendPlugin factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a backend plugin', async () => { - mockFs({ - '/root': { - packages: { - backend: { - 'package.json': JSON.stringify({}), - }, + mockDir.setContent({ + packages: { + backend: { + 'package.json': JSON.stringify({}), }, - plugins: mockFs.directory(), }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + plugins: {}, }); const options = await FactoryRegistry.populateOptions(backendPlugin, { @@ -72,8 +71,7 @@ describe('backendPlugin factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ 'Creating backend plugin backstage-plugin-test-backend', 'Checking Prerequisites:', `availability plugins${sep}test-backend`, @@ -94,14 +92,14 @@ describe('backendPlugin factory', () => { ]); await expect( - fs.readJson('/root/packages/backend/package.json'), + fs.readJson(mockDir.resolve('packages/backend/package.json')), ).resolves.toEqual({ dependencies: { 'backstage-plugin-test-backend': '^1.0.0', }, }); const standaloneServerFile = await fs.readFile( - '/root/plugins/test-backend/src/service/standaloneServer.ts', + mockDir.resolve('plugins/test-backend/src/service/standaloneServer.ts'), 'utf-8', ); @@ -112,11 +110,11 @@ describe('backendPlugin factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath('/root/plugins/test-backend'), + cwd: mockDir.resolve('plugins/test-backend'), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath('/root/plugins/test-backend'), + cwd: mockDir.resolve('plugins/test-backend'), optional: true, }); }); diff --git a/packages/cli/src/lib/new/factories/common/tasks.test.ts b/packages/cli/src/lib/new/factories/common/tasks.test.ts index 49381676e7..60783344fc 100644 --- a/packages/cli/src/lib/new/factories/common/tasks.test.ts +++ b/packages/cli/src/lib/new/factories/common/tasks.test.ts @@ -15,32 +15,37 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; import { sep } from 'path'; -import { createMockOutputStream, mockPaths } from './testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './testUtils'; import { CreateContext } from '../../types'; import { executePluginPackageTemplate } from './tasks'; +import { createMockDirectory } from '@backstage/backend-test-utils'; + +const mockDir = createMockDirectory(); mockPaths({ - ownDir: '/own', - targetRoot: '/root', + ownDir: mockDir.resolve('own'), + targetRoot: mockDir.resolve('root'), }); describe('executePluginPackageTemplate', () => { afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should execute template', async () => { - mockFs({ - '/root': { + mockDir.setContent({ + root: { 'yarn.lock': ` some-package@^1.1.0: version "1.5.0" `, }, - '/own': { + own: { templates: { 'test-template': { 'package.json.hbs': ` @@ -78,7 +83,7 @@ some-package@^1.1.0: } as CreateContext, { templateName: 'test-template', - targetDir: '/target', + targetDir: mockDir.resolve('target'), values: { id: 'testing', makePrivate: true, @@ -87,7 +92,7 @@ some-package@^1.1.0: ); expect(modified).toBe(true); - expect(output).toEqual([ + expectLogsToMatch(output, [ 'Checking Prerequisites:', `availability ..${sep}target`, 'creating temp dir', @@ -98,7 +103,8 @@ some-package@^1.1.0: 'Installing:', `moving ..${sep}target`, ]); - await expect(fs.readFile('/target/package.json', 'utf8')).resolves.toBe(`{ + await expect(fs.readFile(mockDir.resolve('target/package.json'), 'utf8')) + .resolves.toBe(`{ "name": "my-testing-plugin", "private": true, "description": "testing", @@ -109,10 +115,10 @@ some-package@^1.1.0: } `); await expect( - fs.readFile('/target/subdir/templated.txt', 'utf8'), + fs.readFile(mockDir.resolve('target/subdir/templated.txt'), 'utf8'), ).resolves.toBe('Hello testing!'); await expect( - fs.readFile('/target/subdir/not-templated.txt', 'utf8'), + fs.readFile(mockDir.resolve('target/subdir/not-templated.txt'), 'utf8'), ).resolves.toBe('Hello {{id}}!'); }); }); diff --git a/packages/cli/src/lib/new/factories/common/testUtils.ts b/packages/cli/src/lib/new/factories/common/testUtils.ts index 01081a7486..1ade13a996 100644 --- a/packages/cli/src/lib/new/factories/common/testUtils.ts +++ b/packages/cli/src/lib/new/factories/common/testUtils.ts @@ -73,3 +73,11 @@ export function createMockOutputStream() { } as unknown as WriteStream & { fd: any }, ] as const; } + +// Avoid flakes by comparing sorted log lines. File system access is async, which leads to the log line order being indeterministic +export function expectLogsToMatch( + recievedLogs: String[], + expected: String[], +): void { + expect(recievedLogs.filter(Boolean).sort()).toEqual(expected.sort()); +} diff --git a/packages/cli/src/lib/new/factories/frontendPlugin.test.ts b/packages/cli/src/lib/new/factories/frontendPlugin.test.ts index 8390eb192e..94d4a7eb4c 100644 --- a/packages/cli/src/lib/new/factories/frontendPlugin.test.ts +++ b/packages/cli/src/lib/new/factories/frontendPlugin.test.ts @@ -15,13 +15,16 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { sep, resolve as resolvePath } from 'path'; -import { paths } from '../../paths'; +import { sep } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { frontendPlugin } from './frontendPlugin'; +import { createMockDirectory } from '@backstage/backend-test-utils'; const appTsxContent = ` import { createApp } from '@backstage/app-defaults'; @@ -34,33 +37,29 @@ const router = ( `; describe('frontendPlugin factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a frontend plugin', async () => { - mockFs({ - '/root': { - packages: { - app: { - 'package.json': JSON.stringify({}), - src: { - 'App.tsx': appTsxContent, - }, + mockDir.setContent({ + packages: { + app: { + 'package.json': JSON.stringify({}), + src: { + 'App.tsx': appTsxContent, }, }, - plugins: mockFs.directory(), }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + plugins: {}, }); const options = await FactoryRegistry.populateOptions(frontendPlugin, { @@ -85,8 +84,7 @@ describe('frontendPlugin factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ 'Creating frontend plugin backstage-plugin-test', 'Checking Prerequisites:', `availability plugins${sep}test`, @@ -114,15 +112,16 @@ describe('frontendPlugin factory', () => { ]); await expect( - fs.readJson('/root/packages/app/package.json'), + fs.readJson(mockDir.resolve('packages/app/package.json')), ).resolves.toEqual({ dependencies: { 'backstage-plugin-test': '^1.0.0', }, }); - await expect(fs.readFile('/root/packages/app/src/App.tsx', 'utf8')).resolves - .toBe(` + await expect( + fs.readFile(mockDir.resolve('packages/app/src/App.tsx'), 'utf8'), + ).resolves.toBe(` import { createApp } from '@backstage/app-defaults'; import { TestPage } from 'backstage-plugin-test'; @@ -136,32 +135,27 @@ const router = ( expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath('/root/plugins/test'), + cwd: mockDir.resolve('plugins/test'), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath('/root/plugins/test'), + cwd: mockDir.resolve('plugins/test'), optional: true, }); }); it('should create a frontend plugin with more options and codeowners', async () => { - mockFs({ - '/root': { - CODEOWNERS: '', - packages: { - app: { - 'package.json': JSON.stringify({}), - src: { - 'App.tsx': appTsxContent, - }, + mockDir.setContent({ + CODEOWNERS: '', + packages: { + app: { + 'package.json': JSON.stringify({}), + src: { + 'App.tsx': appTsxContent, }, }, - plugins: mockFs.directory(), }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + plugins: {}, }); const options = await FactoryRegistry.populateOptions(frontendPlugin, { @@ -183,15 +177,16 @@ const router = ( }); await expect( - fs.readJson('/root/packages/app/package.json'), + fs.readJson(mockDir.resolve('packages/app/package.json')), ).resolves.toEqual({ dependencies: { '@internal/plugin-test': '^1.0.0', }, }); - await expect(fs.readFile('/root/packages/app/src/App.tsx', 'utf8')).resolves - .toBe(` + await expect( + fs.readFile(mockDir.resolve('packages/app/src/App.tsx'), 'utf8'), + ).resolves.toBe(` import { createApp } from '@backstage/app-defaults'; import { TestPage } from '@internal/plugin-test'; @@ -205,11 +200,11 @@ const router = ( expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath('/root/plugins/test'), + cwd: mockDir.resolve('plugins/test'), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath('/root/plugins/test'), + cwd: mockDir.resolve('plugins/test'), optional: true, }); }); diff --git a/packages/cli/src/lib/new/factories/nodeLibraryPackage.test.ts b/packages/cli/src/lib/new/factories/nodeLibraryPackage.test.ts index d0b08f4f06..e3673d21ba 100644 --- a/packages/cli/src/lib/new/factories/nodeLibraryPackage.test.ts +++ b/packages/cli/src/lib/new/factories/nodeLibraryPackage.test.ts @@ -15,36 +15,35 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { resolve as resolvePath, join as joinPath } from 'path'; -import { paths } from '../../paths'; +import { join as joinPath } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { nodeLibraryPackage } from './nodeLibraryPackage'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('nodeLibraryPackage factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a node library package', async () => { const expectedNodeLibraryPackageName = 'test'; - mockFs({ - '/root': { - packages: mockFs.directory(), - }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + mockDir.setContent({ + packages: {}, }); const options = await FactoryRegistry.populateOptions(nodeLibraryPackage, { @@ -69,8 +68,7 @@ describe('nodeLibraryPackage factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ `Creating node-library package ${expectedNodeLibraryPackageName}`, 'Checking Prerequisites:', `availability ${joinPath('packages', expectedNodeLibraryPackageName)}`, @@ -87,7 +85,11 @@ describe('nodeLibraryPackage factory', () => { await expect( fs.readJson( - `/root/packages/${expectedNodeLibraryPackageName}/package.json`, + mockDir.resolve( + 'packages', + expectedNodeLibraryPackageName, + 'package.json', + ), ), ).resolves.toEqual( expect.objectContaining({ @@ -99,11 +101,11 @@ describe('nodeLibraryPackage factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath(`/root/packages/${expectedNodeLibraryPackageName}`), + cwd: mockDir.resolve('packages', expectedNodeLibraryPackageName), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath(`/root/packages/${expectedNodeLibraryPackageName}`), + cwd: mockDir.resolve('packages', expectedNodeLibraryPackageName), optional: true, }); }); @@ -111,14 +113,9 @@ describe('nodeLibraryPackage factory', () => { it('should create a node library plugin with options and codeowners', async () => { const expectedNodeLibraryPackageName = 'test'; - mockFs({ - '/root': { - CODEOWNERS: '', - packages: mockFs.directory(), - }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + mockDir.setContent({ + CODEOWNERS: '', + packages: {}, }); const options = await FactoryRegistry.populateOptions(nodeLibraryPackage, { @@ -141,11 +138,11 @@ describe('nodeLibraryPackage factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath(`/root/${expectedNodeLibraryPackageName}`), + cwd: mockDir.resolve(expectedNodeLibraryPackageName), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath(`/root/${expectedNodeLibraryPackageName}`), + cwd: mockDir.resolve(expectedNodeLibraryPackageName), optional: true, }); }); diff --git a/packages/cli/src/lib/new/factories/pluginCommon.test.ts b/packages/cli/src/lib/new/factories/pluginCommon.test.ts index 25b6b51905..d85e490510 100644 --- a/packages/cli/src/lib/new/factories/pluginCommon.test.ts +++ b/packages/cli/src/lib/new/factories/pluginCommon.test.ts @@ -15,34 +15,33 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { sep, resolve as resolvePath } from 'path'; -import { paths } from '../../paths'; +import { sep } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { pluginCommon } from './pluginCommon'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('pluginCommon factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a common plugin package', async () => { - mockFs({ - '/root': { - plugins: mockFs.directory(), - }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + mockDir.setContent({ + plugins: {}, }); const options = await FactoryRegistry.populateOptions(pluginCommon, { @@ -67,8 +66,7 @@ describe('pluginCommon factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ 'Creating backend plugin backstage-plugin-test-common', 'Checking Prerequisites:', `availability plugins${sep}test-common`, @@ -84,7 +82,7 @@ describe('pluginCommon factory', () => { ]); await expect( - fs.readJson('/root/plugins/test-common/package.json'), + fs.readJson(mockDir.resolve('plugins/test-common/package.json')), ).resolves.toEqual( expect.objectContaining({ name: 'backstage-plugin-test-common', @@ -96,11 +94,11 @@ describe('pluginCommon factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath('/root/plugins/test-common'), + cwd: mockDir.resolve('plugins/test-common'), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath('/root/plugins/test-common'), + cwd: mockDir.resolve('plugins/test-common'), optional: true, }); }); diff --git a/packages/cli/src/lib/new/factories/pluginNode.test.ts b/packages/cli/src/lib/new/factories/pluginNode.test.ts index 50971ff191..d8d9ea33ab 100644 --- a/packages/cli/src/lib/new/factories/pluginNode.test.ts +++ b/packages/cli/src/lib/new/factories/pluginNode.test.ts @@ -15,34 +15,33 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { sep, resolve as resolvePath } from 'path'; -import { paths } from '../../paths'; +import { sep } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { pluginNode } from './pluginNode'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('pluginNode factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a node plugin package', async () => { - mockFs({ - '/root': { - plugins: mockFs.directory(), - }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + mockDir.setContent({ + plugins: {}, }); const options = await FactoryRegistry.populateOptions(pluginNode, { @@ -67,8 +66,7 @@ describe('pluginNode factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ 'Creating Node.js plugin library backstage-plugin-test-node', 'Checking Prerequisites:', `availability plugins${sep}test-node`, @@ -84,7 +82,7 @@ describe('pluginNode factory', () => { ]); await expect( - fs.readJson('/root/plugins/test-node/package.json'), + fs.readJson(mockDir.resolve('plugins/test-node/package.json')), ).resolves.toEqual( expect.objectContaining({ name: 'backstage-plugin-test-node', @@ -96,11 +94,11 @@ describe('pluginNode factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath('/root/plugins/test-node'), + cwd: mockDir.resolve('plugins/test-node'), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath('/root/plugins/test-node'), + cwd: mockDir.resolve('plugins/test-node'), optional: true, }); }); diff --git a/packages/cli/src/lib/new/factories/pluginWeb.test.ts b/packages/cli/src/lib/new/factories/pluginWeb.test.ts index bcd62f3bcd..ff4211d8fa 100644 --- a/packages/cli/src/lib/new/factories/pluginWeb.test.ts +++ b/packages/cli/src/lib/new/factories/pluginWeb.test.ts @@ -15,34 +15,33 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { sep, resolve as resolvePath } from 'path'; -import { paths } from '../../paths'; +import { sep } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { pluginWeb } from './pluginWeb'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('pluginWeb factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a react plugin package', async () => { - mockFs({ - '/root': { - plugins: mockFs.directory(), - }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + mockDir.setContent({ + plugins: {}, }); const options = await FactoryRegistry.populateOptions(pluginWeb, { @@ -67,8 +66,7 @@ describe('pluginWeb factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ 'Creating web plugin library backstage-plugin-test-react', 'Checking Prerequisites:', `availability plugins${sep}test-react`, @@ -91,7 +89,7 @@ describe('pluginWeb factory', () => { ]); await expect( - fs.readJson('/root/plugins/test-react/package.json'), + fs.readJson(mockDir.resolve('plugins/test-react/package.json')), ).resolves.toEqual( expect.objectContaining({ name: 'backstage-plugin-test-react', @@ -103,11 +101,11 @@ describe('pluginWeb factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath('/root/plugins/test-react'), + cwd: mockDir.resolve('plugins/test-react'), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath('/root/plugins/test-react'), + cwd: mockDir.resolve('plugins/test-react'), optional: true, }); }); diff --git a/packages/cli/src/lib/new/factories/scaffolderModule.test.ts b/packages/cli/src/lib/new/factories/scaffolderModule.test.ts index 38d1207a3f..b43946228b 100644 --- a/packages/cli/src/lib/new/factories/scaffolderModule.test.ts +++ b/packages/cli/src/lib/new/factories/scaffolderModule.test.ts @@ -15,34 +15,33 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { sep, resolve as resolvePath } from 'path'; -import { paths } from '../../paths'; +import { sep } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { scaffolderModule } from './scaffolderModule'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('scaffolderModule factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a scaffolder backend module package', async () => { - mockFs({ - '/root': { - plugins: mockFs.directory(), - }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + mockDir.setContent({ + plugins: {}, }); const options = await FactoryRegistry.populateOptions(scaffolderModule, { @@ -67,8 +66,7 @@ describe('scaffolderModule factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ 'Creating module backstage-plugin-scaffolder-backend-module-test', 'Checking Prerequisites:', `availability plugins${sep}scaffolder-backend-module-test`, @@ -87,7 +85,9 @@ describe('scaffolderModule factory', () => { ]); await expect( - fs.readJson('/root/plugins/scaffolder-backend-module-test/package.json'), + fs.readJson( + mockDir.resolve('plugins/scaffolder-backend-module-test/package.json'), + ), ).resolves.toEqual( expect.objectContaining({ name: 'backstage-plugin-scaffolder-backend-module-test', @@ -99,11 +99,11 @@ describe('scaffolderModule factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath('/root/plugins/scaffolder-backend-module-test'), + cwd: mockDir.resolve('plugins/scaffolder-backend-module-test'), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath('/root/plugins/scaffolder-backend-module-test'), + cwd: mockDir.resolve('plugins/scaffolder-backend-module-test'), optional: true, }); }); diff --git a/packages/cli/src/lib/new/factories/webLibraryPackage.test.ts b/packages/cli/src/lib/new/factories/webLibraryPackage.test.ts index 50fef44a67..b0c8461189 100644 --- a/packages/cli/src/lib/new/factories/webLibraryPackage.test.ts +++ b/packages/cli/src/lib/new/factories/webLibraryPackage.test.ts @@ -15,36 +15,35 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { resolve as resolvePath, join as joinPath } from 'path'; -import { paths } from '../../paths'; +import { join as joinPath } from 'path'; import { Task } from '../../tasks'; import { FactoryRegistry } from '../FactoryRegistry'; -import { createMockOutputStream, mockPaths } from './common/testUtils'; +import { + createMockOutputStream, + expectLogsToMatch, + mockPaths, +} from './common/testUtils'; import { webLibraryPackage } from './webLibraryPackage'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('webLibraryPackage factory', () => { + const mockDir = createMockDirectory(); + beforeEach(() => { mockPaths({ - targetRoot: '/root', + targetRoot: mockDir.path, }); }); afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should create a web library package', async () => { const expectedwebLibraryPackageName = 'test'; - mockFs({ - '/root': { - packages: mockFs.directory(), - }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + mockDir.setContent({ + packages: {}, }); const options = await FactoryRegistry.populateOptions(webLibraryPackage, { @@ -69,8 +68,7 @@ describe('webLibraryPackage factory', () => { expect(modified).toBe(true); - expect(output).toEqual([ - '', + expectLogsToMatch(output, [ `Creating web-library package ${expectedwebLibraryPackageName}`, 'Checking Prerequisites:', `availability ${joinPath('packages', expectedwebLibraryPackageName)}`, @@ -87,7 +85,11 @@ describe('webLibraryPackage factory', () => { await expect( fs.readJson( - `/root/packages/${expectedwebLibraryPackageName}/package.json`, + mockDir.resolve( + 'packages', + expectedwebLibraryPackageName, + 'package.json', + ), ), ).resolves.toEqual( expect.objectContaining({ @@ -99,11 +101,11 @@ describe('webLibraryPackage factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath(`/root/packages/${expectedwebLibraryPackageName}`), + cwd: mockDir.resolve('packages', expectedwebLibraryPackageName), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath(`/root/packages/${expectedwebLibraryPackageName}`), + cwd: mockDir.resolve('packages', expectedwebLibraryPackageName), optional: true, }); }); @@ -111,14 +113,9 @@ describe('webLibraryPackage factory', () => { it('should create a web library plugin with options and codeowners', async () => { const expectedwebLibraryPackageName = 'test'; - mockFs({ - '/root': { - CODEOWNERS: '', - packages: mockFs.directory(), - }, - [paths.resolveOwn('templates')]: mockFs.load( - paths.resolveOwn('templates'), - ), + mockDir.setContent({ + CODEOWNERS: '', + packages: {}, }); const options = await FactoryRegistry.populateOptions(webLibraryPackage, { @@ -141,11 +138,11 @@ describe('webLibraryPackage factory', () => { expect(Task.forCommand).toHaveBeenCalledTimes(2); expect(Task.forCommand).toHaveBeenCalledWith('yarn install', { - cwd: resolvePath(`/root/${expectedwebLibraryPackageName}`), + cwd: mockDir.resolve(expectedwebLibraryPackageName), optional: true, }); expect(Task.forCommand).toHaveBeenCalledWith('yarn lint --fix', { - cwd: resolvePath(`/root/${expectedwebLibraryPackageName}`), + cwd: mockDir.resolve(expectedwebLibraryPackageName), optional: true, }); }); diff --git a/packages/cli/src/lib/role.test.ts b/packages/cli/src/lib/role.test.ts index adca2d70b8..8163512b76 100644 --- a/packages/cli/src/lib/role.test.ts +++ b/packages/cli/src/lib/role.test.ts @@ -14,10 +14,20 @@ * limitations under the License. */ -import mockFs from 'mock-fs'; +import { createMockDirectory } from '@backstage/backend-test-utils'; import { Command } from 'commander'; import { findRoleFromCommand } from './role'; +const mockDir = createMockDirectory(); + +jest.mock('./paths', () => ({ + paths: { + resolveTarget(filename: string) { + return mockDir.resolve(filename); + }, + }, +})); + describe('findRoleFromCommand', () => { function mkCommand(args: string) { const parsed = new Command() @@ -27,7 +37,7 @@ describe('findRoleFromCommand', () => { } beforeEach(() => { - mockFs({ + mockDir.setContent({ 'package.json': JSON.stringify({ name: 'test', backstage: { @@ -37,10 +47,6 @@ describe('findRoleFromCommand', () => { }); }); - afterEach(() => { - mockFs.restore(); - }); - it('provides role info by role', async () => { await expect(findRoleFromCommand(mkCommand(''))).resolves.toEqual( 'web-library', diff --git a/packages/cli/src/lib/tasks.test.ts b/packages/cli/src/lib/tasks.test.ts index fb1f38536f..1119adb7f7 100644 --- a/packages/cli/src/lib/tasks.test.ts +++ b/packages/cli/src/lib/tasks.test.ts @@ -15,14 +15,11 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; -import { resolve as resolvePath } from 'path'; import { templatingTask } from './tasks'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('templatingTask', () => { - afterEach(() => { - mockFs.restore(); - }); + const mockDir = createMockDirectory(); it('should template a directory with mix of regular files and templates', async () => { // Testing template directory @@ -36,7 +33,7 @@ describe('templatingTask', () => { const testVersionFileContent = "version: {{pluginVersion}} {{versionQuery 'mock-pkg'}}"; - mockFs({ + mockDir.setContent({ [tmplDir]: { sub: { 'version.txt.hbs': testVersionFileContent, @@ -47,8 +44,8 @@ describe('templatingTask', () => { }); await templatingTask( - tmplDir, - destDir, + mockDir.resolve(tmplDir), + mockDir.resolve(destDir), { pluginVersion: '0.0.0', }, @@ -57,10 +54,10 @@ describe('templatingTask', () => { ); await expect( - fs.readFile(resolvePath(destDir, 'test.txt'), 'utf8'), + fs.readFile(mockDir.resolve(destDir, 'test.txt'), 'utf8'), ).resolves.toBe(testFileContent); await expect( - fs.readFile(resolvePath(destDir, 'sub/version.txt'), 'utf8'), + fs.readFile(mockDir.resolve(destDir, 'sub/version.txt'), 'utf8'), ).resolves.toBe('version: 0.0.0 ^0.1.2'); }); }); diff --git a/packages/cli/src/lib/version.test.ts b/packages/cli/src/lib/version.test.ts index 604129679b..6b1aa391d5 100644 --- a/packages/cli/src/lib/version.test.ts +++ b/packages/cli/src/lib/version.test.ts @@ -14,15 +14,13 @@ * limitations under the License. */ -import mockFs from 'mock-fs'; import { packageVersions, createPackageVersionProvider } from './version'; import { Lockfile } from './versioning'; import corePluginApiPkg from '@backstage/core-plugin-api/package.json'; +import { createMockDirectory } from '@backstage/backend-test-utils'; describe('createPackageVersionProvider', () => { - afterEach(() => { - mockFs.restore(); - }); + const mockDir = createMockDirectory(); const HEADER = `# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. # yarn lockfile v1 @@ -30,7 +28,7 @@ describe('createPackageVersionProvider', () => { `; it('should provide package versions', async () => { - mockFs({ + mockDir.setContent({ 'yarn.lock': `${HEADER} "a@^0.1.0": version "0.1.5" @@ -55,7 +53,8 @@ describe('createPackageVersionProvider', () => { `, }); - const lockfile = await Lockfile.load('yarn.lock'); + const lockfilePath = mockDir.resolve('yarn.lock'); + const lockfile = await Lockfile.load(lockfilePath); const provider = createPackageVersionProvider(lockfile); expect(provider('a', '0.1.5')).toBe('^0.1.0'); diff --git a/packages/cli/src/lib/versioning/Lockfile.test.ts b/packages/cli/src/lib/versioning/Lockfile.test.ts index 909f8be9aa..a4267acdb7 100644 --- a/packages/cli/src/lib/versioning/Lockfile.test.ts +++ b/packages/cli/src/lib/versioning/Lockfile.test.ts @@ -15,9 +15,9 @@ */ import fs from 'fs-extra'; -import mockFs from 'mock-fs'; import { BackstagePackage } from '@backstage/cli-node'; import { Lockfile } from './Lockfile'; +import { createMockDirectory } from '@backstage/backend-test-utils'; const LEGACY_HEADER = `# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. # yarn lockfile v1 @@ -76,16 +76,14 @@ const mockBDedup = `${LEGACY_HEADER} `; describe('Lockfile', () => { - afterEach(() => { - mockFs.restore(); - }); + const mockDir = createMockDirectory(); it('should load and serialize mockA', async () => { - mockFs({ - '/yarn.lock': mockA, + mockDir.setContent({ + 'yarn.lock': mockA, }); - const lockfile = await Lockfile.load('/yarn.lock'); + const lockfile = await Lockfile.load(mockDir.resolve('yarn.lock')); expect(lockfile.get('a')).toEqual([ { range: '^1', version: '1.0.1', dataKey: 'a@^1' }, ]); @@ -97,11 +95,12 @@ describe('Lockfile', () => { }); it('should deduplicate and save mockA', async () => { - mockFs({ - '/yarn.lock': mockA, + mockDir.setContent({ + 'yarn.lock': mockA, }); - const lockfile = await Lockfile.load('/yarn.lock'); + const lockfilePath = mockDir.resolve('yarn.lock'); + const lockfile = await Lockfile.load(lockfilePath); const result = lockfile.analyze({ localPackages: new Map() }); expect(result).toEqual({ invalidRanges: [], @@ -120,17 +119,17 @@ describe('Lockfile', () => { lockfile.replaceVersions(result.newVersions); expect(lockfile.toString()).toBe(mockADedup); - await expect(fs.readFile('/yarn.lock', 'utf8')).resolves.toBe(mockA); - await expect(lockfile.save('/yarn.lock')).resolves.toBeUndefined(); - await expect(fs.readFile('/yarn.lock', 'utf8')).resolves.toBe(mockADedup); + await expect(fs.readFile(lockfilePath, 'utf8')).resolves.toBe(mockA); + await expect(lockfile.save(lockfilePath)).resolves.toBeUndefined(); + await expect(fs.readFile(lockfilePath, 'utf8')).resolves.toBe(mockADedup); }); it('should deduplicate mockB', async () => { - mockFs({ - '/yarn.lock': mockB, + mockDir.setContent({ + 'yarn.lock': mockB, }); - const lockfile = await Lockfile.load('/yarn.lock'); + const lockfile = await Lockfile.load(mockDir.resolve('yarn.lock')); const result = lockfile.analyze({ localPackages: new Map() }); expect(result).toEqual({ invalidRanges: [], @@ -226,16 +225,14 @@ b@^2: `; describe('New Lockfile', () => { - afterEach(() => { - mockFs.restore(); - }); + const mockDir = createMockDirectory(); it('should load and serialize mockANew', async () => { - mockFs({ - '/yarn.lock': mockANew, + mockDir.setContent({ + 'yarn.lock': mockANew, }); - const lockfile = await Lockfile.load('/yarn.lock'); + const lockfile = await Lockfile.load(mockDir.resolve('yarn.lock')); expect(lockfile.get('a')).toEqual([ { range: '^1', version: '1.0.1', dataKey: 'a@^1' }, ]); @@ -248,11 +245,12 @@ describe('New Lockfile', () => { }); it('should deduplicate and save mockANew', async () => { - mockFs({ - '/yarn.lock': mockANew, + mockDir.setContent({ + 'yarn.lock': mockANew, }); - const lockfile = await Lockfile.load('/yarn.lock'); + const lockfilePath = mockDir.resolve('yarn.lock'); + const lockfile = await Lockfile.load(lockfilePath); const result = lockfile.analyze({ localPackages: new Map() }); expect(result).toEqual({ invalidRanges: [], @@ -271,19 +269,20 @@ describe('New Lockfile', () => { lockfile.replaceVersions(result.newVersions); expect(lockfile.toString()).toBe(mockANewDedup); - await expect(fs.readFile('/yarn.lock', 'utf8')).resolves.toBe(mockANew); - await expect(lockfile.save('/yarn.lock')).resolves.toBeUndefined(); - await expect(fs.readFile('/yarn.lock', 'utf8')).resolves.toBe( + await expect(fs.readFile(lockfilePath, 'utf8')).resolves.toBe(mockANew); + await expect(lockfile.save(lockfilePath)).resolves.toBeUndefined(); + await expect(fs.readFile(lockfilePath, 'utf8')).resolves.toBe( mockANewDedup, ); }); it('should deduplicate and save mockANewLocal', async () => { - mockFs({ - '/yarn.lock': mockANewLocal, + mockDir.setContent({ + 'yarn.lock': mockANewLocal, }); - const lockfile = await Lockfile.load('/yarn.lock'); + const lockfilePath = mockDir.resolve('yarn.lock'); + const lockfile = await Lockfile.load(lockfilePath); const result = lockfile.analyze({ localPackages: new Map([ [ @@ -311,11 +310,11 @@ describe('New Lockfile', () => { lockfile.replaceVersions(result.newVersions); expect(lockfile.toString()).toBe(mockANewLocalDedup); - await expect(fs.readFile('/yarn.lock', 'utf8')).resolves.toBe( + await expect(fs.readFile(lockfilePath, 'utf8')).resolves.toBe( mockANewLocal, ); - await expect(lockfile.save('/yarn.lock')).resolves.toBeUndefined(); - await expect(fs.readFile('/yarn.lock', 'utf8')).resolves.toBe( + await expect(lockfile.save(lockfilePath)).resolves.toBeUndefined(); + await expect(fs.readFile(lockfilePath, 'utf8')).resolves.toBe( mockANewLocalDedup, ); }); diff --git a/packages/cli/src/lib/versioning/packages.test.ts b/packages/cli/src/lib/versioning/packages.test.ts index 5a255532f9..23ff927c48 100644 --- a/packages/cli/src/lib/versioning/packages.test.ts +++ b/packages/cli/src/lib/versioning/packages.test.ts @@ -14,12 +14,11 @@ * limitations under the License. */ -import mockFs from 'mock-fs'; -import path from 'path'; import * as runObj from '../run'; import * as yarn from '../yarn'; import { fetchPackageInfo, mapDependencies } from './packages'; import { NotFoundError } from '../errors'; +import { createMockDirectory } from '@backstage/backend-test-utils'; jest.mock('../run', () => { return { @@ -96,34 +95,41 @@ describe('fetchPackageInfo', () => { }); describe('mapDependencies', () => { + const mockDir = createMockDirectory(); + afterEach(() => { - mockFs.restore(); jest.resetAllMocks(); }); it('should read dependencies', async () => { - mockFs({ - '/root/package.json': JSON.stringify({ + mockDir.setContent({ + 'package.json': JSON.stringify({ workspaces: { packages: ['pkgs/*'], }, }), - '/root/pkgs/a/package.json': JSON.stringify({ - name: 'a', - dependencies: { - '@backstage/core': '1 || 2', + pkgs: { + a: { + 'package.json': JSON.stringify({ + name: 'a', + dependencies: { + '@backstage/core': '1 || 2', + }, + }), }, - }), - '/root/pkgs/b/package.json': JSON.stringify({ - name: 'b', - dependencies: { - '@backstage/core': '3', - '@backstage/cli': '^0', + b: { + 'package.json': JSON.stringify({ + name: 'b', + dependencies: { + '@backstage/core': '3', + '@backstage/cli': '^0', + }, + }), }, - }), + }, }); - const dependencyMap = await mapDependencies('/root', '@backstage/*'); + const dependencyMap = await mapDependencies(mockDir.path, '@backstage/*'); expect(Array.from(dependencyMap)).toEqual([ [ '@backstage/core', @@ -131,12 +137,12 @@ describe('mapDependencies', () => { { name: 'a', range: '1 || 2', - location: path.resolve('/root/pkgs/a'), + location: mockDir.resolve('pkgs/a'), }, { name: 'b', range: '3', - location: path.resolve('/root/pkgs/b'), + location: mockDir.resolve('pkgs/b'), }, ], ], @@ -146,7 +152,7 @@ describe('mapDependencies', () => { { name: 'b', range: '^0', - location: path.resolve('/root/pkgs/b'), + location: mockDir.resolve('pkgs/b'), }, ], ], diff --git a/packages/cli/templates/scaffolder-module/src/actions/example/example.test.ts b/packages/cli/templates/scaffolder-module/src/actions/example/example.test.ts index 3f91a8f49d..242f93c2f3 100644 --- a/packages/cli/templates/scaffolder-module/src/actions/example/example.test.ts +++ b/packages/cli/templates/scaffolder-module/src/actions/example/example.test.ts @@ -22,7 +22,7 @@ describe('acme:example', () => { logStream: new PassThrough(), output: jest.fn(), createTemporaryDirectory() { - // Usage of mock-fs is recommended for testing of filesystem operations + // Usage of createMockDirectory is recommended for testing of filesystem operations throw new Error('Not implemented'); }, }); diff --git a/packages/config-loader/CHANGELOG.md b/packages/config-loader/CHANGELOG.md index 1ee39cb9c6..8e25cf28fa 100644 --- a/packages/config-loader/CHANGELOG.md +++ b/packages/config-loader/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/config-loader +## 1.5.1-next.1 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- 30c553c1d2: Updated dependency `typescript-json-schema` to `^0.61.0`. +- a4617c422a: Added `watch` option to configuration loaders that can be used to disable file watching by setting it to `false`. +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 1.5.1-next.0 ### Patch Changes diff --git a/packages/config-loader/api-report.md b/packages/config-loader/api-report.md index 8cd469d4d7..9f55a27bf7 100644 --- a/packages/config-loader/api-report.md +++ b/packages/config-loader/api-report.md @@ -27,6 +27,8 @@ export interface BaseConfigSourcesOptions { rootDir?: string; // (undocumented) substitutionFunc?: EnvFunc; + // (undocumented) + watch?: boolean; } // @public @@ -142,6 +144,7 @@ export class FileConfigSource implements ConfigSource { export interface FileConfigSourceOptions { path: string; substitutionFunc?: EnvFunc; + watch?: boolean; } // @public @deprecated diff --git a/packages/config-loader/package.json b/packages/config-loader/package.json index 730ca5f01b..3ddd84fdb5 100644 --- a/packages/config-loader/package.json +++ b/packages/config-loader/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/config-loader", "description": "Config loading functionality used by Backstage backend, and CLI", - "version": "1.5.1-next.0", + "version": "1.5.1-next.1", "publishConfig": { "access": "public", "main": "dist/index.cjs.js", @@ -47,7 +47,7 @@ "lodash": "^4.17.21", "minimist": "^1.2.5", "node-fetch": "^2.6.7", - "typescript-json-schema": "^0.55.0", + "typescript-json-schema": "^0.61.0", "yaml": "^2.0.0" }, "devDependencies": { diff --git a/packages/config-loader/src/loader.ts b/packages/config-loader/src/loader.ts index 8b6fd2a953..55cf123f11 100644 --- a/packages/config-loader/src/loader.ts +++ b/packages/config-loader/src/loader.ts @@ -107,6 +107,7 @@ export async function loadConfig( remote: options.remote && { reloadInterval: { seconds: options.remote.reloadIntervalSeconds }, }, + watch: Boolean(options.watch), rootDir: options.configRoot, argv: options.configTargets.flatMap(t => [ '--config', diff --git a/packages/config-loader/src/sources/ConfigSources.ts b/packages/config-loader/src/sources/ConfigSources.ts index d60e9d53e9..43123f87ea 100644 --- a/packages/config-loader/src/sources/ConfigSources.ts +++ b/packages/config-loader/src/sources/ConfigSources.ts @@ -71,6 +71,7 @@ export interface ClosableConfig extends Config { * @public */ export interface BaseConfigSourcesOptions { + watch?: boolean; rootDir?: string; remote?: Pick<RemoteConfigSourceOptions, 'reloadInterval'>; substitutionFunc?: SubstitutionFunc; @@ -159,6 +160,7 @@ export class ConfigSources { }); } return FileConfigSource.create({ + watch: options.watch, path: arg.target, substitutionFunc: options.substitutionFunc, }); @@ -170,6 +172,7 @@ export class ConfigSources { argSources.push( FileConfigSource.create({ + watch: options.watch, path: defaultPath, substitutionFunc: options.substitutionFunc, }), @@ -177,6 +180,7 @@ export class ConfigSources { if (fs.pathExistsSync(localPath)) { argSources.push( FileConfigSource.create({ + watch: options.watch, path: localPath, substitutionFunc: options.substitutionFunc, }), diff --git a/packages/config-loader/src/sources/FileConfigSource.ts b/packages/config-loader/src/sources/FileConfigSource.ts index 1de0fbf2d8..74266de227 100644 --- a/packages/config-loader/src/sources/FileConfigSource.ts +++ b/packages/config-loader/src/sources/FileConfigSource.ts @@ -39,6 +39,11 @@ export interface FileConfigSourceOptions { */ path: string; + /** + * Set to `false` to disable file watching, defaults to `true`. + */ + watch?: boolean; + /** * A substitution function to use instead of the default environment substitution. */ @@ -89,10 +94,12 @@ export class FileConfigSource implements ConfigSource { readonly #path: string; readonly #substitutionFunc?: SubstitutionFunc; + readonly #watch?: boolean; private constructor(options: FileConfigSourceOptions) { this.#path = options.path; this.#substitutionFunc = options.substitutionFunc; + this.#watch = options.watch ?? true; } // Work is duplicated across each read, in practice that should not @@ -104,20 +111,27 @@ export class FileConfigSource implements ConfigSource { const signal = options?.signal; const configFileName = basename(this.#path); - // Keep track of watched paths, since this is simpler than resetting the watcher - const watchedPaths = new Array<string>(); - const watcher = chokidar.watch(this.#path, { - usePolling: process.env.NODE_ENV === 'test', - }); + let watchedPaths: Array<string> | null = null; + let watcher: FSWatcher | null = null; + + if (this.#watch) { + // Keep track of watched paths, since this is simpler than resetting the watcher + watchedPaths = new Array<string>(); + watcher = chokidar.watch(this.#path, { + usePolling: process.env.NODE_ENV === 'test', + }); + } const dir = dirname(this.#path); const transformer = createConfigTransformer({ substitutionFunc: this.#substitutionFunc, readFile: async path => { const fullPath = resolvePath(dir, path); - // Any files discovered while reading this config should be watched too - watcher.add(fullPath); - watchedPaths.push(fullPath); + if (watcher && watchedPaths) { + // Any files discovered while reading this config should be watched too + watcher.add(fullPath); + watchedPaths.push(fullPath); + } const data = await readFile(fullPath); if (data === undefined) { @@ -131,12 +145,15 @@ export class FileConfigSource implements ConfigSource { // This is the entry point for reading the file, called initially and on change const readConfigFile = async (): Promise<ConfigSourceData[]> => { - // We clear the watched files every time we initiate a new read - watcher.unwatch(watchedPaths); - watchedPaths.length = 0; + if (watcher && watchedPaths) { + // We clear the watched files every time we initiate a new read + watcher.unwatch(watchedPaths); + watchedPaths.length = 0; + + watcher.add(this.#path); + watchedPaths.push(this.#path); + } - watcher.add(this.#path); - watchedPaths.push(this.#path); const content = await readFile(this.#path); if (content === undefined) { throw new NotFoundError(`Config file "${this.#path}" does not exist`); @@ -157,18 +174,20 @@ export class FileConfigSource implements ConfigSource { const onAbort = () => { signal?.removeEventListener('abort', onAbort); - watcher.close(); + if (watcher) watcher.close(); }; signal?.addEventListener('abort', onAbort); yield { configs: await readConfigFile() }; - for (;;) { - const event = await this.#waitForEvent(watcher, signal); - if (event === 'abort') { - return; + if (watcher) { + for (;;) { + const event = await this.#waitForEvent(watcher, signal); + if (event === 'abort') { + return; + } + yield { configs: await readConfigFile() }; } - yield { configs: await readConfigFile() }; } } diff --git a/packages/config/CHANGELOG.md b/packages/config/CHANGELOG.md index a5dfb07366..8f0f5202f4 100644 --- a/packages/config/CHANGELOG.md +++ b/packages/config/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/config +## 1.1.1-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/types@1.1.1 + ## 1.1.0 ### Minor Changes diff --git a/packages/config/package.json b/packages/config/package.json index d917df849b..538429e569 100644 --- a/packages/config/package.json +++ b/packages/config/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/config", "description": "Config API used by Backstage core, backend, and CLI", - "version": "1.1.0", + "version": "1.1.1-next.0", "publishConfig": { "access": "public", "main": "dist/index.cjs.js", diff --git a/packages/core-app-api/CHANGELOG.md b/packages/core-app-api/CHANGELOG.md index 20c6013ee0..35bbee7183 100644 --- a/packages/core-app-api/CHANGELOG.md +++ b/packages/core-app-api/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/core-app-api +## 1.11.0-next.2 + +### Minor Changes + +- c9d9bfeca2: URL encode some well known unsafe characters in `RouteResolver` (and therefore `useRouteRef`) + +### Patch Changes + +- acca17e91a: Wrap entire app in `<Suspense>`, enabling support for using translations outside plugins. +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + ## 1.10.1-next.1 ### Patch Changes diff --git a/packages/core-app-api/package.json b/packages/core-app-api/package.json index 5852076136..b566ff6fe6 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.10.1-next.1", + "version": "1.11.0-next.2", "publishConfig": { "access": "public" }, @@ -64,8 +64,8 @@ "devDependencies": { "@backstage/cli": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/packages/core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi.test.ts b/packages/core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi.test.ts index 224430752c..d5b812c5d7 100644 --- a/packages/core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi.test.ts +++ b/packages/core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi.test.ts @@ -377,8 +377,7 @@ describe('I18nextTranslationApi', () => { }, }); }); - - expect(translations).toEqual(['foo', null, 'Föö', null, 'Føø']); + expect(translations).toEqual(['foo', 'Föö', 'Føø']); }); describe('formatting', () => { diff --git a/packages/core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi.ts b/packages/core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi.ts index 01e75d6df2..d0ef35568f 100644 --- a/packages/core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi.ts +++ b/packages/core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi.ts @@ -241,7 +241,6 @@ export class I18nextTranslationApi implements TranslationApi { return new ObservableImpl<TranslationSnapshot<TMessages>>(subscriber => { let loadTicket = {}; // To check for stale loads - let lastSnapshotWasReady = false; const loadResource = () => { loadTicket = {}; @@ -250,8 +249,7 @@ export class I18nextTranslationApi implements TranslationApi { () => { if (ticket === loadTicket) { const snapshot = this.#createSnapshot(internalRef); - if (snapshot.ready || lastSnapshotWasReady) { - lastSnapshotWasReady = snapshot.ready; + if (snapshot.ready) { subscriber.next(snapshot); } } @@ -266,12 +264,9 @@ export class I18nextTranslationApi implements TranslationApi { const onChange = () => { const snapshot = this.#createSnapshot(internalRef); - if (lastSnapshotWasReady && !snapshot.ready) { - lastSnapshotWasReady = snapshot.ready; + if (snapshot.ready) { subscriber.next(snapshot); - } - - if (!snapshot.ready) { + } else { loadResource(); } }; diff --git a/packages/core-app-api/src/app/AppRouter.tsx b/packages/core-app-api/src/app/AppRouter.tsx index b799983a3b..9d07be1ffd 100644 --- a/packages/core-app-api/src/app/AppRouter.tsx +++ b/packages/core-app-api/src/app/AppRouter.tsx @@ -70,7 +70,7 @@ function SignInPageWrapper({ }) { const [identityApi, setIdentityApi] = useState<IdentityApi>(); const configApi = useApi(configApiRef); - const basePath = getBasePath(configApi); + const basePath = readBasePath(configApi); if (!identityApi) { return <Component onSignInSuccess={setIdentityApi} />; diff --git a/packages/core-app-api/src/routing/RouteResolver.beta.test.ts b/packages/core-app-api/src/routing/RouteResolver.beta.test.ts index c0ee452d28..09e6389e7f 100644 --- a/packages/core-app-api/src/routing/RouteResolver.beta.test.ts +++ b/packages/core-app-api/src/routing/RouteResolver.beta.test.ts @@ -31,9 +31,8 @@ jest.mock('react-router-dom', () => jest.requireActual('react-router-dom-beta'), ); -const element = () => null; const rest = { - element, + element: null, caseSensitive: false, children: [MATCH_ALL_ROUTE], plugins: new Set<BackstagePlugin>(), diff --git a/packages/core-app-api/src/routing/RouteResolver.compat.test.ts b/packages/core-app-api/src/routing/RouteResolver.compat.test.ts index 0b4bf588a2..39949b4cd6 100644 --- a/packages/core-app-api/src/routing/RouteResolver.compat.test.ts +++ b/packages/core-app-api/src/routing/RouteResolver.compat.test.ts @@ -25,9 +25,8 @@ import { } from '@backstage/core-plugin-api'; import { MATCH_ALL_ROUTE } from './collectors'; -const element = () => null; const rest = { - element, + element: null, caseSensitive: false, children: [MATCH_ALL_ROUTE], plugins: new Set<BackstagePlugin>(), diff --git a/packages/core-app-api/src/routing/RouteResolver.stable.test.ts b/packages/core-app-api/src/routing/RouteResolver.stable.test.ts index 05f7678078..f1f9ec7137 100644 --- a/packages/core-app-api/src/routing/RouteResolver.stable.test.ts +++ b/packages/core-app-api/src/routing/RouteResolver.stable.test.ts @@ -31,9 +31,8 @@ jest.mock('react-router-dom', () => jest.requireActual('react-router-dom-stable'), ); -const element = () => null; const rest = { - element, + element: null, caseSensitive: false, children: [MATCH_ALL_ROUTE], plugins: new Set<BackstagePlugin>(), diff --git a/packages/core-app-api/src/routing/RoutingProvider.beta.test.tsx b/packages/core-app-api/src/routing/RoutingProvider.beta.test.tsx index c3a5bab89e..0f7a5cd3ad 100644 --- a/packages/core-app-api/src/routing/RoutingProvider.beta.test.tsx +++ b/packages/core-app-api/src/routing/RoutingProvider.beta.test.tsx @@ -353,7 +353,9 @@ describe('v1 consumer', () => { initialProps: { routeRef: routeRef1 as AnyRouteRef, }, - wrapper: ({ children }: React.PropsWithChildren<{}>) => ( + wrapper: ({ + children, + }: React.PropsWithChildren<{ routeRef: AnyRouteRef }>) => ( <RoutingProvider routePaths={ new Map<RouteRef<any>, string>([ diff --git a/packages/core-app-api/src/routing/RoutingProvider.stable.test.tsx b/packages/core-app-api/src/routing/RoutingProvider.stable.test.tsx index 84a33842c9..495fc20b15 100644 --- a/packages/core-app-api/src/routing/RoutingProvider.stable.test.tsx +++ b/packages/core-app-api/src/routing/RoutingProvider.stable.test.tsx @@ -385,7 +385,9 @@ describe('v1 consumer', () => { initialProps: { routeRef: routeRef1 as AnyRouteRef, }, - wrapper: ({ children }: React.PropsWithChildren<{}>) => ( + wrapper: ({ + children, + }: React.PropsWithChildren<{ routeRef: AnyRouteRef }>) => ( <RoutingProvider routePaths={ new Map<RouteRef<any>, string>([ diff --git a/packages/core-components/CHANGELOG.md b/packages/core-components/CHANGELOG.md index 1cab780f55..b6a2f05cd1 100644 --- a/packages/core-components/CHANGELOG.md +++ b/packages/core-components/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/core-components +## 0.13.6-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- 8a15360bb4: Fixed overflowing messages in `WarningPanel`. +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/version-bridge@1.0.5 + ## 0.13.6-next.1 ### Patch Changes diff --git a/packages/core-components/api-report.md b/packages/core-components/api-report.md index 44a8b33e04..d40179dc62 100644 --- a/packages/core-components/api-report.md +++ b/packages/core-components/api-report.md @@ -249,7 +249,7 @@ export interface DependencyGraphProps<NodeData, EdgeData> acyclicer?: 'greedy'; align?: DependencyGraphTypes.Alignment; curve?: 'curveStepBefore' | 'curveMonotoneX'; - defs?: SVGDefsElement | SVGDefsElement[]; + defs?: JSX.Element | JSX.Element[]; direction?: DependencyGraphTypes.Direction; edgeMargin?: number; edgeRanks?: number; diff --git a/packages/core-components/package.json b/packages/core-components/package.json index 7cec756d2a..3bbaa8ee6a 100644 --- a/packages/core-components/package.json +++ b/packages/core-components/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/core-components", "description": "Core components used by Backstage plugins and apps", - "version": "0.13.6-next.1", + "version": "0.13.6-next.2", "publishConfig": { "access": "public", "main": "dist/index.esm.js", @@ -86,8 +86,8 @@ "@backstage/cli": "workspace:^", "@backstage/core-app-api": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/packages/core-components/src/components/DependencyGraph/DependencyGraph.tsx b/packages/core-components/src/components/DependencyGraph/DependencyGraph.tsx index 4928292424..3dd1025b8f 100644 --- a/packages/core-components/src/components/DependencyGraph/DependencyGraph.tsx +++ b/packages/core-components/src/components/DependencyGraph/DependencyGraph.tsx @@ -144,7 +144,7 @@ export interface DependencyGraphProps<NodeData, EdgeData> * {@link https://developer.mozilla.org/en-US/docs/Web/SVG/Element/defs | Defs} shared by rendered SVG to be used by * {@link DependencyGraphProps.renderNode} and/or {@link DependencyGraphProps.renderLabel} */ - defs?: SVGDefsElement | SVGDefsElement[]; + defs?: JSX.Element | JSX.Element[]; /** * Controls zoom behavior of graph * diff --git a/packages/core-components/src/components/Table/Table.tsx b/packages/core-components/src/components/Table/Table.tsx index 9f2b04c214..e4ee9b5995 100644 --- a/packages/core-components/src/components/Table/Table.tsx +++ b/packages/core-components/src/components/Table/Table.tsx @@ -455,7 +455,7 @@ export function Table<T extends object = {}>(props: TableProps<T>) { const hasFilters = !!filters?.length; const Toolbar = useCallback( - toolbarProps => { + (toolbarProps: any /* no type for this in material-table */) => { return ( <TableToolbar setSearch={setSearch} @@ -472,7 +472,7 @@ export function Table<T extends object = {}>(props: TableProps<T>) { const hasNoRows = typeof data !== 'function' && data.length === 0; const columnCount = columns.length; const Body = useCallback( - bodyProps => { + (bodyProps: any /* no type for this in material-table */) => { if (isLoading) { return ( <tbody data-testid="loading-indicator"> diff --git a/packages/core-components/src/components/WarningPanel/WarningPanel.tsx b/packages/core-components/src/components/WarningPanel/WarningPanel.tsx index 7e8248115f..f4dc298b1e 100644 --- a/packages/core-components/src/components/WarningPanel/WarningPanel.tsx +++ b/packages/core-components/src/components/WarningPanel/WarningPanel.tsx @@ -69,6 +69,9 @@ export type WarningPanelClassKey = const useStyles = makeStyles<BackstageTheme>( theme => ({ + content: { + lineBreak: 'anywhere', + }, panel: { backgroundColor: ({ severity }: WarningProps) => getWarningBackgroundColor( @@ -168,6 +171,7 @@ export function WarningPanel(props: WarningProps) { > <AccordionSummary expandIcon={<ExpandMoreIconStyled severity={severity} />} + classes={{ content: classes.content }} className={classes.summary} > <ErrorOutlineStyled severity={severity} /> diff --git a/packages/core-components/src/layout/Sidebar/Items.tsx b/packages/core-components/src/layout/Sidebar/Items.tsx index c40d45f8b4..aba4c79181 100644 --- a/packages/core-components/src/layout/Sidebar/Items.tsx +++ b/packages/core-components/src/layout/Sidebar/Items.tsx @@ -312,7 +312,11 @@ const sidebarSubmenuType = React.createElement(SidebarSubmenu).type; // properly yet, matching for example /foobar with /foo. export const WorkaroundNavLink = React.forwardRef< HTMLAnchorElement, - NavLinkProps & { activeStyle?: CSSProperties; activeClassName?: string } + NavLinkProps & { + children?: ReactNode; + activeStyle?: CSSProperties; + activeClassName?: string; + } >(function WorkaroundNavLinkWithRef( { to, @@ -361,7 +365,10 @@ export const WorkaroundNavLink = React.forwardRef< /** * Common component used by SidebarItem & SidebarItemWithSubmenu */ -const SidebarItemBase = forwardRef<any, SidebarItemProps>((props, ref) => { +const SidebarItemBase = forwardRef< + any, + SidebarItemProps & { children: ReactNode } +>((props, ref) => { const { icon: Icon, text, @@ -553,7 +560,10 @@ const SidebarItemWithSubmenu = ({ * @remarks * If children contain a `SidebarSubmenu` component the `SidebarItem` will have a expandable submenu */ -export const SidebarItem = forwardRef<any, SidebarItemProps>((props, ref) => { +export const SidebarItem = forwardRef< + any, + SidebarItemProps & { children: ReactNode } +>((props, ref) => { // Filter children for SidebarSubmenu components const [submenu] = useElementFilter(props.children, elements => // Directly comparing child.type with SidebarSubmenu will not work with in diff --git a/packages/core-components/src/layout/Sidebar/MobileSidebar.tsx b/packages/core-components/src/layout/Sidebar/MobileSidebar.tsx index e124036648..88d653cea5 100644 --- a/packages/core-components/src/layout/Sidebar/MobileSidebar.tsx +++ b/packages/core-components/src/layout/Sidebar/MobileSidebar.tsx @@ -25,7 +25,7 @@ import Typography from '@material-ui/core/Typography'; import CloseIcon from '@material-ui/icons/Close'; import MenuIcon from '@material-ui/icons/Menu'; import { orderBy } from 'lodash'; -import React, { useEffect, useState, useContext } from 'react'; +import React, { useEffect, useState, useContext, ReactNode } from 'react'; import { useLocation } from 'react-router-dom'; import { SidebarOpenStateProvider } from './SidebarOpenStateContext'; import { SidebarGroup } from './SidebarGroup'; @@ -206,8 +206,7 @@ export const MobileSidebar = (props: MobileSidebarProps) => { onClose={() => setSelectedMenuItemIndex(-1)} > {sidebarGroups[selectedMenuItemIndex] && - (sidebarGroups[selectedMenuItemIndex].props - .children as React.ReactChildren)} + (sidebarGroups[selectedMenuItemIndex].props.children as ReactNode)} </OverlayMenu> <BottomNavigation className={classes.root} diff --git a/packages/core-components/src/layout/Sidebar/Sidebar.stories.tsx b/packages/core-components/src/layout/Sidebar/Sidebar.stories.tsx index f647166250..342a9b2a29 100644 --- a/packages/core-components/src/layout/Sidebar/Sidebar.stories.tsx +++ b/packages/core-components/src/layout/Sidebar/Sidebar.stories.tsx @@ -59,7 +59,7 @@ const handleSearch = (input: string) => { export const SampleSidebar = () => ( <SidebarPage> <Sidebar> - <SidebarGroup label="Menu" icon={MenuIcon}> + <SidebarGroup label="Menu" icon={<MenuIcon />}> <SidebarSearchField onSearch={handleSearch} to="/search" /> <SidebarDivider /> <SidebarItem icon={HomeOutlinedIcon} to="#" text="Plugins" /> diff --git a/packages/core-components/src/layout/TabbedCard/TabbedCard.tsx b/packages/core-components/src/layout/TabbedCard/TabbedCard.tsx index a09ea11b3d..4e75878a7d 100644 --- a/packages/core-components/src/layout/TabbedCard/TabbedCard.tsx +++ b/packages/core-components/src/layout/TabbedCard/TabbedCard.tsx @@ -96,7 +96,9 @@ export function TabbedCard(props: PropsWithChildren<Props>) { } else { React.Children.map(children, child => { if ( - React.isValidElement<{ children?: unknown; value?: unknown }>(child) && + React.isValidElement<{ children?: ReactNode; value?: unknown }>( + child, + ) && child?.props.value === value ) { selectedTabContent = child?.props.children; diff --git a/packages/core-plugin-api/CHANGELOG.md b/packages/core-plugin-api/CHANGELOG.md index d206487074..3c1516c646 100644 --- a/packages/core-plugin-api/CHANGELOG.md +++ b/packages/core-plugin-api/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/core-plugin-api +## 1.7.0-next.1 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + ## 1.7.0-next.0 ### Minor Changes diff --git a/packages/core-plugin-api/package.json b/packages/core-plugin-api/package.json index 55cce18b69..81f77e7dcf 100644 --- a/packages/core-plugin-api/package.json +++ b/packages/core-plugin-api/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/core-plugin-api", "description": "Core API used by Backstage plugins", - "version": "1.7.0-next.0", + "version": "1.7.0-next.1", "publishConfig": { "access": "public" }, @@ -62,8 +62,8 @@ "@backstage/cli": "workspace:^", "@backstage/core-app-api": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0" diff --git a/packages/core-plugin-api/src/extensions/useElementFilter.test.tsx b/packages/core-plugin-api/src/extensions/useElementFilter.test.tsx index 8795ecdded..9a3760d019 100644 --- a/packages/core-plugin-api/src/extensions/useElementFilter.test.tsx +++ b/packages/core-plugin-api/src/extensions/useElementFilter.test.tsx @@ -41,7 +41,12 @@ const FeatureFlagComponent = (_props: { }) => null; attachComponentData(FeatureFlagComponent, 'core.featureFlagged', true); const mockFeatureFlagsApi = new LocalStorageFeatureFlags(); -const Wrapper = ({ children }: { children?: React.ReactNode }) => ( +const Wrapper = ({ + children, +}: { + children?: React.ReactNode; + tree?: ReactNode; +}) => ( <TestApiProvider apis={[[featureFlagsApiRef, mockFeatureFlagsApi]]}> {children} </TestApiProvider> diff --git a/packages/core-plugin-api/src/translation/useTranslationRef.test.tsx b/packages/core-plugin-api/src/translation/useTranslationRef.test.tsx index a8dbdc0402..19f0516906 100644 --- a/packages/core-plugin-api/src/translation/useTranslationRef.test.tsx +++ b/packages/core-plugin-api/src/translation/useTranslationRef.test.tsx @@ -303,7 +303,12 @@ describe('useTranslationRef', () => { const translationApi = I18nextTranslationApi.create({ languageApi }); const { result, rerender } = renderHook( - ({ translationRef }) => useTranslationRef(translationRef), + ({ + translationRef, + }: { + translationRef: TranslationRef; + children?: ReactNode; + }) => useTranslationRef(translationRef), { wrapper: ({ children }) => ( <TestApiProvider diff --git a/packages/create-app/CHANGELOG.md b/packages/create-app/CHANGELOG.md index fed5a6b936..2ad4280db0 100644 --- a/packages/create-app/CHANGELOG.md +++ b/packages/create-app/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/create-app +## 0.5.6-next.2 + +### Patch Changes + +- Bumped create-app version. +- Updated dependencies + - @backstage/cli-common@0.1.13-next.0 + ## 0.5.6-next.1 ### Patch Changes diff --git a/packages/create-app/package.json b/packages/create-app/package.json index 56764b6be9..467ceb1cfe 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.6-next.1", + "version": "0.5.6-next.2", "publishConfig": { "access": "public" }, diff --git a/packages/create-app/src/lib/tasks.test.ts b/packages/create-app/src/lib/tasks.test.ts index e122374004..c436bf5ad2 100644 --- a/packages/create-app/src/lib/tasks.test.ts +++ b/packages/create-app/src/lib/tasks.test.ts @@ -103,6 +103,7 @@ describe('tasks', () => { const mockDir = createMockDirectory(); + const origCwd = process.cwd(); const realChdir = process.chdir; // If anyone calls chdir then make it resolve within the tmpdir const mockChdir = jest.spyOn(process, 'chdir'); @@ -130,6 +131,10 @@ describe('tasks', () => { mockChdir.mockReset(); }); + afterAll(() => { + realChdir(origCwd); + }); + describe('checkAppExistsTask', () => { it('should do nothing if the directory does not exist', async () => { const dir = 'projects/'; diff --git a/packages/create-app/templates/default-app/lerna.json b/packages/create-app/templates/default-app/lerna.json index 322929db1d..529a62fe38 100644 --- a/packages/create-app/templates/default-app/lerna.json +++ b/packages/create-app/templates/default-app/lerna.json @@ -1,6 +1,6 @@ { "packages": ["packages/*", "plugins/*"], "npmClient": "yarn", - "useWorkspaces": true, - "version": "0.1.0" + "version": "0.1.0", + "$schema": "node_modules/lerna/schemas/lerna-schema.json" } diff --git a/packages/create-app/templates/default-app/package.json.hbs b/packages/create-app/templates/default-app/package.json.hbs index 844a7bca9d..b74957dd56 100644 --- a/packages/create-app/templates/default-app/package.json.hbs +++ b/packages/create-app/templates/default-app/package.json.hbs @@ -36,7 +36,7 @@ "@playwright/test": "^1.32.3", "@spotify/prettier-config": "^12.0.0", "concurrently": "^8.0.0", - "lerna": "^4.0.0", + "lerna": "^7.3.0", "node-gyp": "^9.0.0", "prettier": "^2.3.2", "typescript": "~5.2.0" diff --git a/packages/dev-utils/CHANGELOG.md b/packages/dev-utils/CHANGELOG.md index 300d3dad2f..3869ee9281 100644 --- a/packages/dev-utils/CHANGELOG.md +++ b/packages/dev-utils/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/dev-utils +## 1.0.22-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/app-defaults@1.4.4-next.2 + - @backstage/test-utils@1.4.4-next.2 + ## 1.0.22-next.1 ### Patch Changes diff --git a/packages/dev-utils/package.json b/packages/dev-utils/package.json index dec37f3cea..bbb55d9b14 100644 --- a/packages/dev-utils/package.json +++ b/packages/dev-utils/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/dev-utils", "description": "Utilities for developing Backstage plugins.", - "version": "1.0.22-next.1", + "version": "1.0.22-next.2", "publishConfig": { "access": "public", "main": "dist/index.esm.js", @@ -40,25 +40,25 @@ "@backstage/core-plugin-api": "workspace:^", "@backstage/integration-react": "workspace:^", "@backstage/plugin-catalog-react": "workspace:^", - "@backstage/test-utils": "workspace:^", "@backstage/theme": "workspace:^", "@material-ui/core": "^4.12.2", "@material-ui/icons": "^4.9.1", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", - "@testing-library/react": "^12.1.3", - "@testing-library/user-event": "^14.0.0", "@types/react": "^16.13.1 || ^17.0.0", - "react-use": "^17.2.4", - "zen-observable": "^0.10.0" + "react-use": "^17.2.4" }, "peerDependencies": { - "react": "^16.13.1 || ^17.0.0", - "react-dom": "^16.13.1 || ^17.0.0", + "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/cli": "workspace:^" + "@backstage/cli": "workspace:^", + "@backstage/test-utils": "workspace:^", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", + "@testing-library/react": "^12.1.3", + "@testing-library/user-event": "^14.0.0", + "zen-observable": "^0.10.0" }, "files": [ "dist" diff --git a/packages/dev-utils/src/devApp/render.tsx b/packages/dev-utils/src/devApp/render.tsx index 5f2b21b8d2..335308ff5e 100644 --- a/packages/dev-utils/src/devApp/render.tsx +++ b/packages/dev-utils/src/devApp/render.tsx @@ -45,9 +45,19 @@ import { import { Box } from '@material-ui/core'; import BookmarkIcon from '@material-ui/icons/Bookmark'; import React, { ComponentType, ReactNode, PropsWithChildren } from 'react'; -import ReactDOM from 'react-dom'; import { createRoutesFromChildren, Route } from 'react-router-dom'; import { SidebarThemeSwitcher } from './SidebarThemeSwitcher'; +import 'react-dom'; + +let ReactDOM: + | typeof import('react-dom') + // TODO: replace with import('react-dom/client') when repo is migrated to 18 + | { createRoot(el: HTMLElement): { render(el: JSX.Element): void } }; +if (process.env.HAS_REACT_DOM_CLIENT) { + ReactDOM = require('react-dom/client'); +} else { + ReactDOM = require('react-dom'); +} export function isReactRouterBeta(): boolean { const [obj] = createRoutesFromChildren(<Route index element={<div />} />); @@ -235,7 +245,11 @@ export class DevAppBuilder { window.location.pathname = this.defaultPage; } - ReactDOM.render(<DevApp />, document.getElementById('root')); + if ('createRoot' in ReactDOM) { + ReactDOM.createRoot(document.getElementById('root')!).render(<DevApp />); + } else { + ReactDOM.render(<DevApp />, document.getElementById('root')); + } } } diff --git a/packages/e2e-test/CHANGELOG.md b/packages/e2e-test/CHANGELOG.md index 4c47b33e86..846f7e62a4 100644 --- a/packages/e2e-test/CHANGELOG.md +++ b/packages/e2e-test/CHANGELOG.md @@ -1,5 +1,14 @@ # e2e-test +## 0.2.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/create-app@0.5.6-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + ## 0.2.8-next.1 ### Patch Changes diff --git a/packages/e2e-test/package.json b/packages/e2e-test/package.json index 8b1499446a..9d5654098d 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.8-next.1", + "version": "0.2.8-next.2", "private": true, "backstage": { "role": "cli" diff --git a/packages/errors/CHANGELOG.md b/packages/errors/CHANGELOG.md index 689b3617fc..2568ca095e 100644 --- a/packages/errors/CHANGELOG.md +++ b/packages/errors/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/errors +## 1.2.3-next.0 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/types@1.1.1 + ## 1.2.2 ### Patch Changes diff --git a/packages/errors/package.json b/packages/errors/package.json index f073553b51..c064765aca 100644 --- a/packages/errors/package.json +++ b/packages/errors/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/errors", "description": "Common utilities for error handling within Backstage", - "version": "1.2.2", + "version": "1.2.3-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/packages/frontend-app-api/CHANGELOG.md b/packages/frontend-app-api/CHANGELOG.md index 90d7ba70d2..12983fdcd6 100644 --- a/packages/frontend-app-api/CHANGELOG.md +++ b/packages/frontend-app-api/CHANGELOG.md @@ -1,5 +1,27 @@ # @backstage/frontend-app-api +## 0.2.0-next.2 + +### Minor Changes + +- 4461d87d5a: Removed support for the new `useRouteRef`. + +### Patch Changes + +- 5072824817: Implement `toString()` and `toJSON()` for extension instances. +- 06432f900c: Updates for `at` -> `attachTo` refactor. +- 1718ec75b7: Added support for the existing routing system. +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-graphiql@0.2.55-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + ## 0.2.0-next.1 ### Patch Changes diff --git a/packages/frontend-app-api/api-report.md b/packages/frontend-app-api/api-report.md index 2e77ef904b..74c34be5f4 100644 --- a/packages/frontend-app-api/api-report.md +++ b/packages/frontend-app-api/api-report.md @@ -3,17 +3,22 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AppRouteBinder } from '@backstage/core-app-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { Config } from '@backstage/config'; import { ConfigApi } from '@backstage/core-plugin-api'; import { ExtensionDataRef } from '@backstage/frontend-plugin-api'; +import { ExtensionOverrides } from '@backstage/frontend-plugin-api'; import { JSX as JSX_2 } from 'react'; // @public (undocumented) export function createApp(options: { - plugins: BackstagePlugin[]; + features?: (BackstagePlugin | ExtensionOverrides)[]; configLoader?: () => Promise<ConfigApi>; - pluginLoader?: (ctx: { config: ConfigApi }) => Promise<BackstagePlugin[]>; + bindRoutes?(context: { bind: AppRouteBinder }): void; + featureLoader?: (ctx: { + config: ConfigApi; + }) => Promise<(BackstagePlugin | ExtensionOverrides)[]>; }): { createRoot(): JSX_2.Element; }; diff --git a/packages/frontend-app-api/package.json b/packages/frontend-app-api/package.json index 477cf8f736..7a1c5aa79f 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.2.0-next.1", + "version": "0.2.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -25,7 +25,7 @@ "devDependencies": { "@backstage/cli": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3" }, "configSchema": "config.d.ts", diff --git a/packages/frontend-app-api/src/extensions/Core.tsx b/packages/frontend-app-api/src/extensions/Core.tsx index 4a66afe38d..6efe3984dc 100644 --- a/packages/frontend-app-api/src/extensions/Core.tsx +++ b/packages/frontend-app-api/src/extensions/Core.tsx @@ -27,7 +27,22 @@ export const Core = createExtension({ apis: createExtensionInput({ api: coreExtensionData.apiFactory, }), + themes: createExtensionInput({ + theme: coreExtensionData.theme, + }), + root: createExtensionInput( + { + element: coreExtensionData.reactElement, + }, + { singleton: true }, + ), + }, + output: { + root: coreExtensionData.reactElement, + }, + factory({ bind, inputs }) { + bind({ + root: inputs.root.element, + }); }, - output: {}, - factory() {}, }); diff --git a/packages/frontend-app-api/src/extensions/CoreLayout.tsx b/packages/frontend-app-api/src/extensions/CoreLayout.tsx index 9b0b8b25d1..bf0f382cfc 100644 --- a/packages/frontend-app-api/src/extensions/CoreLayout.tsx +++ b/packages/frontend-app-api/src/extensions/CoreLayout.tsx @@ -24,7 +24,7 @@ import { SidebarPage } from '@backstage/core-components'; export const CoreLayout = createExtension({ id: 'core.layout', - attachTo: { id: 'root', input: 'default' }, + attachTo: { id: 'core', input: 'root' }, inputs: { nav: createExtensionInput( { diff --git a/packages/frontend-app-api/src/extensions/CoreRoutes.tsx b/packages/frontend-app-api/src/extensions/CoreRoutes.tsx index 5006a87cac..8d22b40eec 100644 --- a/packages/frontend-app-api/src/extensions/CoreRoutes.tsx +++ b/packages/frontend-app-api/src/extensions/CoreRoutes.tsx @@ -39,7 +39,7 @@ export const CoreRoutes = createExtension({ const Routes = () => { const element = useRoutes( inputs.routes.map(route => ({ - path: route.path, + path: `${route.path}/*`, element: route.element, })), ); diff --git a/packages/frontend-app-api/src/routing/extractRouteInfoFromInstanceTree.test.ts b/packages/frontend-app-api/src/routing/extractRouteInfoFromInstanceTree.test.ts index a510adf1b7..e70f588e0e 100644 --- a/packages/frontend-app-api/src/routing/extractRouteInfoFromInstanceTree.test.ts +++ b/packages/frontend-app-api/src/routing/extractRouteInfoFromInstanceTree.test.ts @@ -48,7 +48,7 @@ function createTestExtension(options: { id: options.id, attachTo: options.parent ? { id: options.parent, input: 'children' } - : { id: 'core.routes', input: 'children' }, + : { id: 'core.routes', input: 'routes' }, output: { element: coreExtensionData.reactElement, path: coreExtensionData.routePath.optional(), @@ -74,12 +74,12 @@ function routeInfoFromExtensions(extensions: Extension<unknown>[]) { id: 'test', extensions, }); - const { rootInstances } = createInstances({ + const { coreInstance } = createInstances({ config: new MockConfigApi({}), - plugins: [plugin], + features: [plugin], }); - return extractRouteInfoFromInstanceTree(rootInstances); + return extractRouteInfoFromInstanceTree(coreInstance); } function sortedEntries<T>(map: Map<RouteRef, T>): [RouteRef, T][] { @@ -305,6 +305,7 @@ describe('discovery', () => { }), createTestExtension({ id: 'fooEmpty', + parent: 'foo', }), createTestExtension({ id: 'page3', diff --git a/packages/frontend-app-api/src/routing/extractRouteInfoFromInstanceTree.ts b/packages/frontend-app-api/src/routing/extractRouteInfoFromInstanceTree.ts index 30305b0d2c..fa9f87dce0 100644 --- a/packages/frontend-app-api/src/routing/extractRouteInfoFromInstanceTree.ts +++ b/packages/frontend-app-api/src/routing/extractRouteInfoFromInstanceTree.ts @@ -42,7 +42,7 @@ export function joinPaths(...paths: string[]): string { return normalized; } -export function extractRouteInfoFromInstanceTree(roots: ExtensionInstance[]): { +export function extractRouteInfoFromInstanceTree(core: ExtensionInstance): { routePaths: Map<RouteRef, string>; routeParents: Map<RouteRef, RouteRef | undefined>; routeObjects: BackstageRouteObject[]; @@ -151,9 +151,7 @@ export function extractRouteInfoFromInstanceTree(roots: ExtensionInstance[]): { } } - for (const root of roots) { - visit(root); - } + visit(core); return { routePaths, routeParents, routeObjects }; } diff --git a/packages/frontend-app-api/src/wiring/createApp.test.tsx b/packages/frontend-app-api/src/wiring/createApp.test.tsx index abd0fe9b00..65f278b49b 100644 --- a/packages/frontend-app-api/src/wiring/createApp.test.tsx +++ b/packages/frontend-app-api/src/wiring/createApp.test.tsx @@ -16,6 +16,7 @@ import { createExtension, + createExtensionOverrides, createPageExtension, createPlugin, createThemeExtension, @@ -25,38 +26,44 @@ import { screen } from '@testing-library/react'; import { MockConfigApi, renderWithEffects } from '@backstage/test-utils'; import React from 'react'; import { createRouteRef } from '@backstage/core-plugin-api'; -import { createExtensionInstance } from './createExtensionInstance'; + +const extBaseConfig = { + id: 'test', + attachTo: { id: 'root', input: 'default' }, + output: {}, + factory() {}, +}; describe('createInstances', () => { - it('throws an error when a root extension is parametrized', () => { + it('throws an error when a core extension is parametrized', () => { const config = new MockConfigApi({ app: { extensions: [ { - root: {}, + core: {}, }, ], }, }); - const plugins = [ + const features = [ createPlugin({ id: 'plugin', extensions: [], }), ]; - expect(() => createInstances({ config, plugins })).toThrow( - "A 'root' extension configuration was detected, but the root extension is not configurable", + expect(() => createInstances({ config, features })).toThrow( + "A 'core' extension configuration was detected, but the core extension is not configurable", ); }); - it('throws an error when a root extension is overridden', () => { + it('throws an error when a core extension is overridden', () => { const config = new MockConfigApi({}); - const plugins = [ + const features = [ createPlugin({ id: 'plugin', extensions: [ createExtension({ - id: 'root', + id: 'core', attachTo: { id: 'core.routes', input: 'route' }, inputs: {}, output: {}, @@ -65,8 +72,8 @@ describe('createInstances', () => { ], }), ]; - expect(() => createInstances({ config, plugins })).toThrow( - "The following plugin(s) are overriding the 'root' extension which is forbidden: plugin", + expect(() => createInstances({ config, features })).toThrow( + "The following plugin(s) are overriding the 'core' extension which is forbidden: plugin", ); }); @@ -97,12 +104,32 @@ describe('createInstances', () => { extensions: [ExtensionA, ExtensionB, ExtensionB], }); - const plugins = [PluginA, PluginB]; + const features = [PluginA, PluginB]; - expect(() => createInstances({ config, plugins })).toThrow( + expect(() => createInstances({ config, features })).toThrow( "The following extensions are duplicated: The extension 'A' was provided 2 time(s) by the plugin 'A' and 1 time(s) by the plugin 'B', The extension 'B' was provided 2 time(s) by the plugin 'B'", ); }); + + it('throws an error when duplicated extension overrides are detected', () => { + expect(() => + createInstances({ + config: new MockConfigApi({}), + features: [ + createExtensionOverrides({ + extensions: [ + createExtension({ ...extBaseConfig, id: 'a' }), + createExtension({ ...extBaseConfig, id: 'a' }), + createExtension({ ...extBaseConfig, id: 'b' }), + ], + }), + createExtensionOverrides({ + extensions: [createExtension({ ...extBaseConfig, id: 'b' })], + }), + ], + }), + ).toThrow('The following extensions had duplicate overrides: a, b'); + }); }); describe('createApp', () => { @@ -114,7 +141,7 @@ describe('createApp', () => { extensions: [{ 'themes.light': false }, { 'themes.dark': false }], }, }), - plugins: [ + features: [ createPlugin({ id: 'test', extensions: [ @@ -135,30 +162,14 @@ describe('createApp', () => { }); it('should log an app', () => { - const { rootInstances } = createInstances({ + const { coreInstance } = createInstances({ config: new MockConfigApi({}), - plugins: [], - }); - const root = createExtensionInstance({ - extension: createExtension({ - id: 'root', - attachTo: { id: '', input: '' }, - output: {}, - factory() {}, - }), - config: undefined, - attachments: new Map([['children', rootInstances]]), + features: [], }); - expect(String(root)).toMatchInlineSnapshot(` - "<root> - children [ - <core> - themes [ - <themes.light out=[core.theme] /> - <themes.dark out=[core.theme] /> - ] - </core> + expect(String(coreInstance)).toMatchInlineSnapshot(` + "<core out=[core.reactElement]> + root [ <core.layout out=[core.reactElement]> content [ <core.routes out=[core.reactElement] /> @@ -168,49 +179,24 @@ describe('createApp', () => { ] </core.layout> ] - </root>" + themes [ + <themes.light out=[core.theme] /> + <themes.dark out=[core.theme] /> + ] + </core>" `); }); it('should serialize an app as JSON', () => { - const { rootInstances } = createInstances({ + const { coreInstance } = createInstances({ config: new MockConfigApi({}), - plugins: [], - }); - const root = createExtensionInstance({ - extension: createExtension({ - id: 'root', - attachTo: { id: '', input: '' }, - output: {}, - factory() {}, - }), - config: undefined, - attachments: new Map([['children', rootInstances]]), + features: [], }); - expect(JSON.parse(JSON.stringify(root))).toMatchInlineSnapshot(` + expect(JSON.parse(JSON.stringify(coreInstance))).toMatchInlineSnapshot(` { "attachments": { - "children": [ - { - "attachments": { - "themes": [ - { - "id": "themes.light", - "output": [ - "core.theme", - ], - }, - { - "id": "themes.dark", - "output": [ - "core.theme", - ], - }, - ], - }, - "id": "core", - }, + "root": [ { "attachments": { "content": [ @@ -236,8 +222,25 @@ describe('createApp', () => { ], }, ], + "themes": [ + { + "id": "themes.light", + "output": [ + "core.theme", + ], + }, + { + "id": "themes.dark", + "output": [ + "core.theme", + ], + }, + ], }, - "id": "root", + "id": "core", + "output": [ + "core.reactElement", + ], } `); }); diff --git a/packages/frontend-app-api/src/wiring/createApp.tsx b/packages/frontend-app-api/src/wiring/createApp.tsx index 02f3d17d7c..f262ecde72 100644 --- a/packages/frontend-app-api/src/wiring/createApp.tsx +++ b/packages/frontend-app-api/src/wiring/createApp.tsx @@ -20,6 +20,7 @@ import { BackstagePlugin, coreExtensionData, ExtensionDataRef, + ExtensionOverrides, } from '@backstage/frontend-plugin-api'; import { Core } from '../extensions/Core'; import { CoreRoutes } from '../extensions/CoreRoutes'; @@ -51,11 +52,12 @@ import { identityApiRef, AppTheme, } from '@backstage/core-plugin-api'; -import { getAvailablePlugins } from './discovery'; +import { getAvailableFeatures } from './discovery'; import { ApiFactoryRegistry, ApiProvider, ApiResolver, + AppRouteBinder, AppThemeSelector, } from '@backstage/core-app-api'; @@ -75,6 +77,12 @@ import { overrideBaseUrlConfigs } from '../../../core-app-api/src/app/overrideBa // eslint-disable-next-line @backstage/no-relative-monorepo-imports import { RoutingProvider } from '../../../core-app-api/src/routing/RoutingProvider'; // eslint-disable-next-line @backstage/no-relative-monorepo-imports +import { resolveRouteBindings } from '../../../core-app-api/src/app/resolveRouteBindings'; +// eslint-disable-next-line @backstage/no-relative-monorepo-imports +import { AppLanguageSelector } from '../../../core-app-api/src/apis/implementations/AppLanguageApi/AppLanguageSelector'; +// eslint-disable-next-line @backstage/no-relative-monorepo-imports +import { I18nextTranslationApi } from '../../../core-app-api/src/apis/implementations/TranslationApi/I18nextTranslationApi'; +// eslint-disable-next-line @backstage/no-relative-monorepo-imports import { apis as defaultApis, components as defaultComponents, @@ -85,6 +93,10 @@ import { SidebarItem } from '@backstage/core-components'; import { DarkTheme, LightTheme } from '../extensions/themes'; import { extractRouteInfoFromInstanceTree } from '../routing/extractRouteInfoFromInstanceTree'; import { getOrCreateGlobalSingleton } from '@backstage/version-bridge'; +import { + appLanguageApiRef, + translationApiRef, +} from '@backstage/core-plugin-api/alpha'; /** @public */ export interface ExtensionTreeNode { @@ -104,9 +116,9 @@ export interface ExtensionTree { export function createExtensionTree(options: { config: Config; }): ExtensionTree { - const plugins = getAvailablePlugins(); + const features = getAvailableFeatures(); const { instances } = createInstances({ - plugins, + features, config: options.config, }); @@ -172,7 +184,7 @@ export function createExtensionTree(options: { * @internal */ export function createInstances(options: { - plugins: BackstagePlugin[]; + features: (BackstagePlugin | ExtensionOverrides)[]; config: Config; }) { const builtinExtensions = [ @@ -187,7 +199,7 @@ export function createInstances(options: { // pull in default extension instance from discovered packages // apply config to adjust default extension instances and add more const extensionParams = mergeExtensionParameters({ - sources: options.plugins, + features: options.features, builtinExtensions, parameters: readAppExtensionParameters(options.config), }); @@ -249,20 +261,21 @@ export function createInstances(options: { return newInstance; } - const rootConfigs = attachmentMap.get('root')?.get('default') ?? []; - - const rootInstances = rootConfigs.map(instanceParams => - createInstance(instanceParams), + const coreInstance = createInstance( + extensionParams.find(p => p.extension.id === 'core')!, ); - return { instances, rootInstances }; + return { coreInstance, instances }; } /** @public */ export function createApp(options: { - plugins: BackstagePlugin[]; + features?: (BackstagePlugin | ExtensionOverrides)[]; configLoader?: () => Promise<ConfigApi>; - pluginLoader?: (ctx: { config: ConfigApi }) => Promise<BackstagePlugin[]>; + bindRoutes?(context: { bind: AppRouteBinder }): void; + featureLoader?: (ctx: { + config: ConfigApi; + }) => Promise<(BackstagePlugin | ExtensionOverrides)[]>; }): { createRoot(): JSX.Element; } { @@ -273,43 +286,39 @@ export function createApp(options: { overrideBaseUrlConfigs(defaultConfigLoaderSync()), ); - const discoveredPlugins = getAvailablePlugins(); - const loadedPlugins = (await options.pluginLoader?.({ config })) ?? []; - const allPlugins = Array.from( - new Set([...discoveredPlugins, ...options.plugins, ...loadedPlugins]), + const discoveredFeatures = getAvailableFeatures(); + const loadedFeatures = (await options.featureLoader?.({ config })) ?? []; + const allFeatures = Array.from( + new Set([ + ...discoveredFeatures, + ...(options.features ?? []), + ...loadedFeatures, + ]), ); - const { rootInstances } = createInstances({ - plugins: allPlugins, + const { coreInstance } = createInstances({ + features: allFeatures, config, }); - const routeInfo = extractRouteInfoFromInstanceTree(rootInstances); - - const coreInstance = rootInstances.find(({ id }) => id === 'core'); - if (!coreInstance) { - throw Error('Unable to find core extension instance'); - } - - const apiHolder = createApiHolder(coreInstance, config); - - const appContext = createLegacyAppContext(allPlugins); - - const rootElements = rootInstances - .map(e => ( - <React.Fragment key={e.id}> - {e.getData(coreExtensionData.reactElement)} - </React.Fragment> - )) - .filter((x): x is JSX.Element => !!x); + const appContext = createLegacyAppContext( + allFeatures.filter( + (f): f is BackstagePlugin => f.$$type === '@backstage/BackstagePlugin', + ), + ); const App = () => ( - <ApiProvider apis={apiHolder}> + <ApiProvider apis={createApiHolder(coreInstance, config)}> <AppContextProvider appContext={appContext}> <AppThemeProvider> - <RoutingProvider {...routeInfo} routeBindings={new Map(/* TODO */)}> + <RoutingProvider + {...extractRouteInfoFromInstanceTree(coreInstance)} + routeBindings={resolveRouteBindings(options.bindRoutes)} + > {/* TODO: set base path using the logic from AppRouter */} - <BrowserRouter>{rootElements}</BrowserRouter> + <BrowserRouter> + {coreInstance.getData(coreExtensionData.reactElement)} + </BrowserRouter> </RoutingProvider> </AppThemeProvider> </AppContextProvider> @@ -463,6 +472,21 @@ function createApiHolder( factory: () => configApi, }); + factoryRegistry.register('static', { + api: appLanguageApiRef, + deps: {}, + factory: () => AppLanguageSelector.createWithStorage(), + }); + + factoryRegistry.register('default', { + api: translationApiRef, + deps: { languageApi: appLanguageApiRef }, + factory: ({ languageApi }) => + I18nextTranslationApi.create({ + languageApi, + }), + }); + // TODO: ship these as default extensions instead for (const factory of defaultApis as AnyApiFactory[]) { if (!factoryRegistry.register('app', factory)) { diff --git a/packages/frontend-app-api/src/wiring/createExtensionInstance.test.ts b/packages/frontend-app-api/src/wiring/createExtensionInstance.test.ts index 6550d76608..6e69e99cb7 100644 --- a/packages/frontend-app-api/src/wiring/createExtensionInstance.test.ts +++ b/packages/frontend-app-api/src/wiring/createExtensionInstance.test.ts @@ -250,6 +250,92 @@ describe('createExtensionInstance', () => { ); }); + it('should refuse to create an instance with undeclared inputs', () => { + expect(() => + createExtensionInstance({ + attachments: new Map([ + [ + 'declared', + [ + createExtensionInstance({ + attachments: new Map(), + config: { output: 'many1' }, + extension: simpleExtension, + }), + ], + ], + [ + 'undeclared', + [ + createExtensionInstance({ + attachments: new Map(), + config: { output: 'many1' }, + extension: simpleExtension, + }), + ], + ], + ]), + config: undefined, + extension: createExtension({ + id: 'core.test', + attachTo: { id: 'ignored', input: 'ignored' }, + inputs: { + declared: createExtensionInput({ + test: testDataRef, + }), + }, + output: {}, + factory() {}, + }), + }), + ).toThrow( + "Failed to instantiate extension 'core.test', received undeclared input 'undeclared' from extension 'core.test'", + ); + }); + + it('should refuse to create an instance with multiple undeclared inputs', () => { + expect(() => + createExtensionInstance({ + attachments: new Map([ + [ + 'undeclared1', + [ + createExtensionInstance({ + attachments: new Map(), + config: { output: 'many1' }, + extension: simpleExtension, + }), + ], + ], + [ + 'undeclared2', + [ + createExtensionInstance({ + attachments: new Map(), + config: { output: 'many1' }, + extension: simpleExtension, + }), + createExtensionInstance({ + attachments: new Map(), + config: { output: 'many1' }, + extension: simpleExtension, + }), + ], + ], + ]), + config: undefined, + extension: createExtension({ + id: 'core.test', + attachTo: { id: 'ignored', input: 'ignored' }, + output: {}, + factory() {}, + }), + }), + ).toThrow( + "Failed to instantiate extension 'core.test', received undeclared inputs 'undeclared1' from extension 'core.test' and 'undeclared2' from extensions 'core.test', 'core.test'", + ); + }); + it('should refuse to create an instance with multiple inputs for required singleton', () => { expect(() => createExtensionInstance({ diff --git a/packages/frontend-app-api/src/wiring/createExtensionInstance.ts b/packages/frontend-app-api/src/wiring/createExtensionInstance.ts index 9aec3078bc..5a325dc0a0 100644 --- a/packages/frontend-app-api/src/wiring/createExtensionInstance.ts +++ b/packages/frontend-app-api/src/wiring/createExtensionInstance.ts @@ -60,6 +60,24 @@ function resolveInputs( inputMap: AnyExtensionInputMap, attachments: Map<string, ExtensionInstance[]>, ) { + const undeclaredAttachments = Array.from(attachments.entries()).filter( + ([inputName]) => inputMap[inputName] === undefined, + ); + if (undeclaredAttachments.length > 0) { + throw new Error( + `received undeclared input${ + undeclaredAttachments.length > 1 ? 's' : '' + } ${undeclaredAttachments + .map( + ([k, exts]) => + `'${k}' from extension${exts.length > 1 ? 's' : ''} '${exts + .map(e => e.id) + .join("', '")}'`, + ) + .join(' and ')}`, + ); + } + return mapValues(inputMap, (input, inputName) => { const attachedInstances = attachments.get(inputName) ?? []; if (input.config.singleton) { diff --git a/packages/frontend-app-api/src/wiring/discovery.test.ts b/packages/frontend-app-api/src/wiring/discovery.test.ts index 5f1c4df718..54294bbd45 100644 --- a/packages/frontend-app-api/src/wiring/discovery.test.ts +++ b/packages/frontend-app-api/src/wiring/discovery.test.ts @@ -15,25 +15,25 @@ */ import { createPlugin } from '@backstage/frontend-plugin-api'; -import { getAvailablePlugins } from './discovery'; +import { getAvailableFeatures } from './discovery'; const globalSpy = jest.fn(); Object.defineProperty(global, '__@backstage/discovered__', { get: globalSpy, }); -describe('getAvailablePlugins', () => { +describe('getAvailableFeatures', () => { afterEach(jest.resetAllMocks); it('should discover nothing with undefined global', () => { - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); }); it('should discover nothing with empty global', () => { globalSpy.mockReturnValue({ modules: [], }); - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); }); it('should discover a plugin', () => { @@ -41,24 +41,24 @@ describe('getAvailablePlugins', () => { globalSpy.mockReturnValue({ modules: [{ default: testPlugin }], }); - expect(getAvailablePlugins()).toEqual([testPlugin]); + expect(getAvailableFeatures()).toEqual([testPlugin]); }); it('should ignore garbage', () => { globalSpy.mockReturnValueOnce({ modules: [{ default: null }] }); - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); globalSpy.mockReturnValueOnce({ modules: [{ default: undefined }] }); - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); globalSpy.mockReturnValueOnce({ modules: [{ default: Symbol() }] }); - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); globalSpy.mockReturnValueOnce({ modules: [{ default: () => {} }] }); - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); globalSpy.mockReturnValueOnce({ modules: [{ default: 0 }] }); - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); globalSpy.mockReturnValueOnce({ modules: [{ default: false }] }); - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); globalSpy.mockReturnValueOnce({ modules: [{ default: true }] }); - expect(getAvailablePlugins()).toEqual([]); + expect(getAvailableFeatures()).toEqual([]); }); it('should discover multiple plugins', () => { @@ -72,7 +72,7 @@ describe('getAvailablePlugins', () => { { default: test3Plugin }, ], }); - expect(getAvailablePlugins()).toEqual([ + expect(getAvailableFeatures()).toEqual([ test1Plugin, test2Plugin, test3Plugin, diff --git a/packages/frontend-app-api/src/wiring/discovery.ts b/packages/frontend-app-api/src/wiring/discovery.ts index 6d0b9282ea..14786c93d9 100644 --- a/packages/frontend-app-api/src/wiring/discovery.ts +++ b/packages/frontend-app-api/src/wiring/discovery.ts @@ -14,7 +14,10 @@ * limitations under the License. */ -import { BackstagePlugin } from '@backstage/frontend-plugin-api'; +import { + BackstagePlugin, + ExtensionOverrides, +} from '@backstage/frontend-plugin-api'; interface DiscoveryGlobal { modules: Array<{ name: string; default: unknown }>; @@ -23,19 +26,27 @@ interface DiscoveryGlobal { /** * @public */ -export function getAvailablePlugins(): BackstagePlugin[] { +export function getAvailableFeatures(): ( + | BackstagePlugin + | ExtensionOverrides +)[] { const discovered = ( window as { '__@backstage/discovered__'?: DiscoveryGlobal } )['__@backstage/discovered__']; return ( - discovered?.modules.map(m => m.default).filter(isBackstagePlugin) ?? [] + discovered?.modules.map(m => m.default).filter(isBackstageFeature) ?? [] ); } -function isBackstagePlugin(obj: unknown): obj is BackstagePlugin { +function isBackstageFeature( + obj: unknown, +): obj is BackstagePlugin | ExtensionOverrides { if (obj !== null && typeof obj === 'object' && '$$type' in obj) { - return obj.$$type === '@backstage/BackstagePlugin'; + return ( + obj.$$type === '@backstage/BackstagePlugin' || + obj.$$type === '@backstage/ExtensionOverrides' + ); } return false; } diff --git a/packages/frontend-app-api/src/wiring/parameters.test.ts b/packages/frontend-app-api/src/wiring/parameters.test.ts index 97ae941744..4ee420f667 100644 --- a/packages/frontend-app-api/src/wiring/parameters.test.ts +++ b/packages/frontend-app-api/src/wiring/parameters.test.ts @@ -15,7 +15,11 @@ */ import { ConfigReader } from '@backstage/config'; -import { createPlugin, Extension } from '@backstage/frontend-plugin-api'; +import { + createExtensionOverrides, + createPlugin, + Extension, +} from '@backstage/frontend-plugin-api'; import { JsonValue } from '@backstage/types'; import { expandShorthandExtensionParameters, @@ -23,10 +27,14 @@ import { readAppExtensionParameters, } from './parameters'; -function makeExt(id: string, status: 'disabled' | 'enabled' = 'enabled') { +function makeExt( + id: string, + status: 'disabled' | 'enabled' = 'enabled', + attachId: string = 'root', +) { return { id, - attachTo: { id: 'root', input: 'default' }, + attachTo: { id: attachId, input: 'default' }, disabled: status === 'disabled', } as Extension<unknown>; } @@ -35,7 +43,7 @@ describe('mergeExtensionParameters', () => { it('should filter out disabled extension instances', () => { expect( mergeExtensionParameters({ - sources: [], + features: [], builtinExtensions: [makeExt('a', 'disabled')], parameters: [], }), @@ -47,7 +55,7 @@ describe('mergeExtensionParameters', () => { const b = makeExt('b'); expect( mergeExtensionParameters({ - sources: [], + features: [], builtinExtensions: [a, b], parameters: [], }), @@ -63,7 +71,7 @@ describe('mergeExtensionParameters', () => { const pluginA = createPlugin({ id: 'test', extensions: [a] }); expect( mergeExtensionParameters({ - sources: [pluginA], + features: [pluginA], builtinExtensions: [b], parameters: [ { @@ -88,7 +96,7 @@ describe('mergeExtensionParameters', () => { const plugin = createPlugin({ id: 'test', extensions: [a, b] }); expect( mergeExtensionParameters({ - sources: [plugin], + features: [plugin], builtinExtensions: [], parameters: [ { @@ -126,7 +134,7 @@ describe('mergeExtensionParameters', () => { const b = makeExt('b', 'disabled'); expect( mergeExtensionParameters({ - sources: [createPlugin({ id: 'empty', extensions: [] })], + features: [createPlugin({ id: 'empty', extensions: [] })], builtinExtensions: [a, b], parameters: [ { @@ -144,6 +152,61 @@ describe('mergeExtensionParameters', () => { { extension: a, attachTo: { id: 'root', input: 'default' } }, ]); }); + + it('should apply extension overrides', () => { + const a = makeExt('a'); + const b = makeExt('b'); + const plugin = createPlugin({ id: 'test', extensions: [a, b] }); + const aOverride = makeExt('a', 'enabled', 'other'); + const bOverride = makeExt('b', 'disabled', 'other'); + const cOverride = makeExt('c'); + + const result = mergeExtensionParameters({ + features: [ + plugin, + createExtensionOverrides({ + extensions: [aOverride, bOverride, cOverride], + }), + ], + builtinExtensions: [], + parameters: [], + }); + + expect(result.length).toBe(2); + expect(result[0].extension).toBe(aOverride); + expect(result[0].attachTo).toEqual({ id: 'other', input: 'default' }); + expect(result[0].config).toEqual(undefined); + expect(result[0].source).toBe(plugin); + + expect(result[1]).toEqual({ + extension: cOverride, + attachTo: { id: 'root', input: 'default' }, + config: undefined, + source: undefined, + }); + }); + + it('should use order from configuration when rather than overrides', () => { + const a = makeExt('a', 'disabled'); + const b = makeExt('b', 'disabled'); + const c = makeExt('c', 'disabled'); + const aOverride = makeExt('c', 'disabled'); + const bOverride = makeExt('b', 'disabled'); + const cOverride = makeExt('a', 'disabled'); + + const result = mergeExtensionParameters({ + features: [ + createPlugin({ id: 'test', extensions: [a, b, c] }), + createExtensionOverrides({ + extensions: [cOverride, bOverride, aOverride], + }), + ], + builtinExtensions: [], + parameters: ['b', 'c', 'a'].map(id => ({ id, disabled: false })), + }); + + expect(result.map(r => r.extension.id)).toEqual(['b', 'c', 'a']); + }); }); describe('readAppExtensionParameters', () => { diff --git a/packages/frontend-app-api/src/wiring/parameters.ts b/packages/frontend-app-api/src/wiring/parameters.ts index 9474a01d79..911f12f416 100644 --- a/packages/frontend-app-api/src/wiring/parameters.ts +++ b/packages/frontend-app-api/src/wiring/parameters.ts @@ -15,7 +15,13 @@ */ import { Config } from '@backstage/config'; -import { BackstagePlugin, Extension } from '@backstage/frontend-plugin-api'; +import { + BackstagePlugin, + Extension, + ExtensionOverrides, +} from '@backstage/frontend-plugin-api'; +// eslint-disable-next-line @backstage/no-relative-monorepo-imports +import { toInternalExtensionOverrides } from '../../../frontend-plugin-api/src/wiring/createExtensionOverrides'; import { JsonValue } from '@backstage/types'; export interface ExtensionParameters { @@ -208,29 +214,61 @@ export interface ExtensionInstanceParameters { /** @internal */ export function mergeExtensionParameters(options: { - sources: BackstagePlugin[]; + features: (BackstagePlugin | ExtensionOverrides)[]; builtinExtensions: Extension<unknown>[]; parameters: Array<ExtensionParameters>; }): ExtensionInstanceParameters[] { - const { sources, builtinExtensions, parameters } = options; + const { builtinExtensions, parameters } = options; - const pluginExtensions = sources.flatMap(source => { + const plugins = options.features.filter( + (f): f is BackstagePlugin => f.$$type === '@backstage/BackstagePlugin', + ); + const overrides = options.features.filter( + (f): f is ExtensionOverrides => + f.$$type === '@backstage/ExtensionOverrides', + ); + + const pluginExtensions = plugins.flatMap(source => { return source.extensions.map(extension => ({ ...extension, source })); }); + const overrideExtensions = overrides.flatMap( + override => toInternalExtensionOverrides(override).extensions, + ); - // Prevent root override - if (pluginExtensions.some(({ id }) => id === 'root')) { - const rootPluginIds = pluginExtensions - .filter(({ id }) => id === 'root') + // Prevent core override + if (pluginExtensions.some(({ id }) => id === 'core')) { + const pluginIds = pluginExtensions + .filter(({ id }) => id === 'core') .map(({ source }) => source.id); throw new Error( - `The following plugin(s) are overriding the 'root' extension which is forbidden: ${rootPluginIds.join( + `The following plugin(s) are overriding the 'core' extension which is forbidden: ${pluginIds.join( ',', )}`, ); } - const overrides = [ + if (overrideExtensions.some(({ id }) => id === 'root')) { + throw new Error( + `An extension override is overriding the 'root' extension which is forbidden`, + ); + } + const overrideExtensionIds = overrideExtensions.map(({ id }) => id); + if (overrideExtensionIds.length !== new Set(overrideExtensionIds).size) { + const counts = new Map<string, number>(); + for (const id of overrideExtensionIds) { + counts.set(id, (counts.get(id) ?? 0) + 1); + } + const duplicated = Array.from(counts.entries()) + .filter(([, count]) => count > 1) + .map(([id]) => id); + throw new Error( + `The following extensions had duplicate overrides: ${duplicated.join( + ', ', + )}`, + ); + } + + const configuredExtensions = [ ...pluginExtensions.map(({ source, ...extension }) => ({ extension, params: { @@ -251,8 +289,33 @@ export function mergeExtensionParameters(options: { })), ]; + // Install all extension overrides + for (const extension of overrideExtensions) { + // Check if our override is overriding an extension that already exists + const index = configuredExtensions.findIndex( + e => e.extension.id === extension.id, + ); + if (index !== -1) { + // Only implementation, attachment point and default disabled status are overridden, the source is kept + configuredExtensions[index].extension = extension; + configuredExtensions[index].params.attachTo = extension.attachTo; + configuredExtensions[index].params.disabled = extension.disabled; + } else { + // Add the extension as a new one when not overriding an existing one + configuredExtensions.push({ + extension, + params: { + source: undefined, + attachTo: extension.attachTo, + disabled: extension.disabled, + config: undefined, + }, + }); + } + } + const duplicatedExtensionIds = new Set<string>(); - const duplicatedExtensionData = overrides.reduce< + const duplicatedExtensionData = configuredExtensions.reduce< Record<string, Record<string, number>> >((data, { extension, params }) => { const extensionId = extension.id; @@ -289,18 +352,18 @@ export function mergeExtensionParameters(options: { for (const overrideParam of parameters) { const extensionId = overrideParam.id; - // Prevent root parametrization - if (extensionId === 'root') { + // Prevent core parametrization + if (extensionId === 'core') { throw new Error( - "A 'root' extension configuration was detected, but the root extension is not configurable", + "A 'core' extension configuration was detected, but the core extension is not configurable", ); } - const existingIndex = overrides.findIndex( + const existingIndex = configuredExtensions.findIndex( e => e.extension.id === extensionId, ); if (existingIndex !== -1) { - const existing = overrides[existingIndex]; + const existing = configuredExtensions[existingIndex]; if (overrideParam.attachTo) { existing.params.attachTo = overrideParam.attachTo; } @@ -314,8 +377,8 @@ export function mergeExtensionParameters(options: { existing.params.disabled = Boolean(overrideParam.disabled); if (!existing.params.disabled) { // bump - overrides.splice(existingIndex, 1); - overrides.push(existing); + configuredExtensions.splice(existingIndex, 1); + configuredExtensions.push(existing); } } } else { @@ -323,7 +386,7 @@ export function mergeExtensionParameters(options: { } } - return overrides + return configuredExtensions .filter(override => !override.params.disabled) .map(param => ({ extension: param.extension, diff --git a/packages/frontend-plugin-api/CHANGELOG.md b/packages/frontend-plugin-api/CHANGELOG.md index 2295989418..056ff0b143 100644 --- a/packages/frontend-plugin-api/CHANGELOG.md +++ b/packages/frontend-plugin-api/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/frontend-plugin-api +## 0.2.0-next.2 + +### Minor Changes + +- 06432f900c: Extension attachment point is now configured via `attachTo: { id, input }` instead of `at: 'id/input'`. +- 4461d87d5a: Removed support for the new `useRouteRef`. + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/types@1.1.1 + ## 0.1.1-next.1 ### Patch Changes diff --git a/packages/frontend-plugin-api/api-report.md b/packages/frontend-plugin-api/api-report.md index 18baf88e5d..071b617851 100644 --- a/packages/frontend-plugin-api/api-report.md +++ b/packages/frontend-plugin-api/api-report.md @@ -7,6 +7,8 @@ import { AnyApiFactory } from '@backstage/core-plugin-api'; import { AnyApiRef } from '@backstage/core-plugin-api'; +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { AppTheme } from '@backstage/core-plugin-api'; import { IconComponent } from '@backstage/core-plugin-api'; import { JsonObject } from '@backstage/types'; @@ -40,13 +42,20 @@ export type AnyExtensionInputMap = { }; // @public (undocumented) -export interface BackstagePlugin { +export interface BackstagePlugin< + Routes extends AnyRoutes = AnyRoutes, + ExternalRoutes extends AnyExternalRoutes = AnyExternalRoutes, +> { // (undocumented) $$type: '@backstage/BackstagePlugin'; // (undocumented) extensions: Extension<unknown>[]; // (undocumented) + externalRoutes: ExternalRoutes; + // (undocumented) id: string; + // (undocumented) + routes: Routes; } // @public (undocumented) @@ -159,6 +168,11 @@ export interface CreateExtensionOptions< output: TOutput; } +// @public (undocumented) +export function createExtensionOverrides( + options: ExtensionOverridesOptions, +): ExtensionOverrides; + // @public export function createNavItemExtension(options: { id: string; @@ -200,7 +214,12 @@ export function createPageExtension< ): Extension<TConfig>; // @public (undocumented) -export function createPlugin(options: PluginOptions): BackstagePlugin; +export function createPlugin< + Routes extends AnyRoutes = AnyRoutes, + ExternalRoutes extends AnyExternalRoutes = AnyExternalRoutes, +>( + options: PluginOptions<Routes, ExternalRoutes>, +): BackstagePlugin<Routes, ExternalRoutes>; // @public (undocumented) export function createSchemaFromZod<TOutput, TInput>( @@ -313,6 +332,18 @@ export type ExtensionInputValues< >; }; +// @public (undocumented) +export interface ExtensionOverrides { + // (undocumented) + $$type: '@backstage/ExtensionOverrides'; +} + +// @public (undocumented) +export interface ExtensionOverridesOptions { + // (undocumented) + extensions: Extension<unknown>[]; +} + // @public (undocumented) export type NavTarget = { title: string; @@ -321,11 +352,18 @@ export type NavTarget = { }; // @public (undocumented) -export interface PluginOptions { +export interface PluginOptions< + Routes extends AnyRoutes, + ExternalRoutes extends AnyExternalRoutes, +> { // (undocumented) extensions?: Extension<unknown>[]; // (undocumented) + externalRoutes?: ExternalRoutes; + // (undocumented) id: string; + // (undocumented) + routes?: Routes; } // @public (undocumented) diff --git a/packages/frontend-plugin-api/package.json b/packages/frontend-plugin-api/package.json index 7785b03b7d..d80e2baee4 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.1.1-next.1", + "version": "0.2.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -26,7 +26,7 @@ "@backstage/cli": "workspace:^", "@backstage/frontend-app-api": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3" }, "files": [ diff --git a/packages/frontend-plugin-api/src/wiring/createExtensionOverrides.test.ts b/packages/frontend-plugin-api/src/wiring/createExtensionOverrides.test.ts new file mode 100644 index 0000000000..fa430a7834 --- /dev/null +++ b/packages/frontend-plugin-api/src/wiring/createExtensionOverrides.test.ts @@ -0,0 +1,82 @@ +/* + * 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 { createExtension } from './createExtension'; +import { + createExtensionOverrides, + toInternalExtensionOverrides, +} from './createExtensionOverrides'; + +describe('createExtensionOverrides', () => { + it('should create overrides without extensions', () => { + expect(createExtensionOverrides({ extensions: [] })).toMatchInlineSnapshot(` + { + "$$type": "@backstage/ExtensionOverrides", + "extensions": [], + "version": "v1", + } + `); + }); + + it('should create overrides with extensions', () => { + expect( + createExtensionOverrides({ + extensions: [ + createExtension({ + id: 'a', + attachTo: { id: 'core', input: 'apis' }, + output: {}, + factory() {}, + }), + ], + }), + ).toMatchInlineSnapshot(` + { + "$$type": "@backstage/ExtensionOverrides", + "extensions": [ + { + "$$type": "@backstage/Extension", + "attachTo": { + "id": "core", + "input": "apis", + }, + "disabled": false, + "factory": [Function], + "id": "a", + "inputs": {}, + "output": {}, + }, + ], + "version": "v1", + } + `); + }); + + it('should convert to internal overrides', () => { + const overrides = createExtensionOverrides({ + extensions: [ + createExtension({ + id: 'a', + attachTo: { id: 'core', input: 'apis' }, + output: {}, + factory() {}, + }), + ], + }); + const internal = toInternalExtensionOverrides(overrides); + expect(internal).toBe(overrides); + }); +}); diff --git a/packages/frontend-plugin-api/src/wiring/createExtensionOverrides.ts b/packages/frontend-plugin-api/src/wiring/createExtensionOverrides.ts new file mode 100644 index 0000000000..2c64229eb9 --- /dev/null +++ b/packages/frontend-plugin-api/src/wiring/createExtensionOverrides.ts @@ -0,0 +1,62 @@ +/* + * 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 { Extension } from './createExtension'; + +/** @public */ +export interface ExtensionOverridesOptions { + extensions: Extension<unknown>[]; +} + +/** @public */ +export interface ExtensionOverrides { + $$type: '@backstage/ExtensionOverrides'; +} + +/** @internal */ +export interface InternalExtensionOverrides extends ExtensionOverrides { + version: string; + extensions: Extension<unknown>[]; +} + +/** @public */ +export function createExtensionOverrides( + options: ExtensionOverridesOptions, +): ExtensionOverrides { + return { + $$type: '@backstage/ExtensionOverrides', + version: 'v1', + extensions: options.extensions, + } as InternalExtensionOverrides; +} + +/** @internal */ +export function toInternalExtensionOverrides( + overrides: ExtensionOverrides, +): InternalExtensionOverrides { + const internal = overrides as InternalExtensionOverrides; + if (internal.$$type !== '@backstage/ExtensionOverrides') { + throw new Error( + `Invalid translation resource, bad type '${internal.$$type}'`, + ); + } + if (internal.version !== 'v1') { + throw new Error( + `Invalid translation resource, bad version '${internal.version}'`, + ); + } + return internal; +} diff --git a/packages/frontend-plugin-api/src/wiring/createPlugin.test.ts b/packages/frontend-plugin-api/src/wiring/createPlugin.test.ts index 589ac59d75..7f73c45544 100644 --- a/packages/frontend-plugin-api/src/wiring/createPlugin.test.ts +++ b/packages/frontend-plugin-api/src/wiring/createPlugin.test.ts @@ -85,7 +85,7 @@ const TechDocsPage = createExtension({ const outputExtension = createExtension({ id: 'test.output', - attachTo: { id: 'root', input: 'default' }, + attachTo: { id: 'core', input: 'root' }, inputs: { names: createExtensionInput({ name: nameExtensionDataRef, @@ -104,14 +104,14 @@ const outputExtension = createExtension({ }); function createTestAppRoot({ - plugins, + features, config = {}, }: { - plugins: BackstagePlugin[]; + features: BackstagePlugin[]; config: JsonObject; }) { return createApp({ - plugins: plugins, + features, configLoader: async () => new MockConfigApi(config), }).createRoot(); } @@ -132,7 +132,7 @@ describe('createPlugin', () => { await renderWithEffects( createTestAppRoot({ - plugins: [plugin], + features: [plugin], config: { app: { extensions: [{ 'core.layout': false }] } }, }), ); @@ -157,7 +157,7 @@ describe('createPlugin', () => { await renderWithEffects( createTestAppRoot({ - plugins: [plugin], + features: [plugin], config: { app: { extensions: [ diff --git a/packages/frontend-plugin-api/src/wiring/createPlugin.ts b/packages/frontend-plugin-api/src/wiring/createPlugin.ts index bd8e9954ef..3afb5cedff 100644 --- a/packages/frontend-plugin-api/src/wiring/createPlugin.ts +++ b/packages/frontend-plugin-api/src/wiring/createPlugin.ts @@ -14,26 +14,44 @@ * limitations under the License. */ +import { AnyExternalRoutes, AnyRoutes } from '@backstage/core-plugin-api'; import { Extension } from './createExtension'; /** @public */ -export interface PluginOptions { +export interface PluginOptions< + Routes extends AnyRoutes, + ExternalRoutes extends AnyExternalRoutes, +> { id: string; + routes?: Routes; + externalRoutes?: ExternalRoutes; extensions?: Extension<unknown>[]; } /** @public */ -export interface BackstagePlugin { +export interface BackstagePlugin< + Routes extends AnyRoutes = AnyRoutes, + ExternalRoutes extends AnyExternalRoutes = AnyExternalRoutes, +> { $$type: '@backstage/BackstagePlugin'; id: string; extensions: Extension<unknown>[]; + routes: Routes; + externalRoutes: ExternalRoutes; } /** @public */ -export function createPlugin(options: PluginOptions): BackstagePlugin { +export function createPlugin< + Routes extends AnyRoutes = AnyRoutes, + ExternalRoutes extends AnyExternalRoutes = AnyExternalRoutes, +>( + options: PluginOptions<Routes, ExternalRoutes>, +): BackstagePlugin<Routes, ExternalRoutes> { return { ...options, - $$type: '@backstage/BackstagePlugin', + routes: options.routes ?? ({} as Routes), + externalRoutes: options.externalRoutes ?? ({} as ExternalRoutes), extensions: options.extensions ?? [], + $$type: '@backstage/BackstagePlugin', }; } diff --git a/packages/frontend-plugin-api/src/wiring/index.ts b/packages/frontend-plugin-api/src/wiring/index.ts index b7f0acefd9..4e4104de97 100644 --- a/packages/frontend-plugin-api/src/wiring/index.ts +++ b/packages/frontend-plugin-api/src/wiring/index.ts @@ -38,3 +38,8 @@ export { type BackstagePlugin, type PluginOptions, } from './createPlugin'; +export { + createExtensionOverrides, + type ExtensionOverrides, + type ExtensionOverridesOptions, +} from './createExtensionOverrides'; diff --git a/packages/integration-aws-node/CHANGELOG.md b/packages/integration-aws-node/CHANGELOG.md index e62b3ff7fe..e1004246ff 100644 --- a/packages/integration-aws-node/CHANGELOG.md +++ b/packages/integration-aws-node/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/integration-aws-node +## 0.1.7-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.1.6 ### Patch Changes diff --git a/packages/integration-aws-node/package.json b/packages/integration-aws-node/package.json index cfe691b85c..38948f03ad 100644 --- a/packages/integration-aws-node/package.json +++ b/packages/integration-aws-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/integration-aws-node", "description": "Helpers for fetching AWS account credentials", - "version": "0.1.6", + "version": "0.1.7-next.0", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/packages/integration-react/CHANGELOG.md b/packages/integration-react/CHANGELOG.md index 8ef2df3709..9374887da8 100644 --- a/packages/integration-react/CHANGELOG.md +++ b/packages/integration-react/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/integration-react +## 1.1.20-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/config@1.1.1-next.0 + ## 1.1.20-next.1 ### Patch Changes diff --git a/packages/integration-react/package.json b/packages/integration-react/package.json index 9631220e5f..7a919ed13a 100644 --- a/packages/integration-react/package.json +++ b/packages/integration-react/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/integration-react", "description": "Frontend package for managing integrations towards external systems", - "version": "1.1.20-next.1", + "version": "1.1.20-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -47,8 +47,8 @@ "@backstage/core-components": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "msw": "^1.0.0" }, "files": [ diff --git a/packages/integration/CHANGELOG.md b/packages/integration/CHANGELOG.md index 961e6eb869..93332a6b23 100644 --- a/packages/integration/CHANGELOG.md +++ b/packages/integration/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/integration +## 1.7.1-next.1 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/config@1.1.1-next.0 + ## 1.7.1-next.0 ### Patch Changes diff --git a/packages/integration/package.json b/packages/integration/package.json index d5a500acc7..45d9474336 100644 --- a/packages/integration/package.json +++ b/packages/integration/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/integration", "description": "Helpers for managing integrations towards external systems", - "version": "1.7.1-next.0", + "version": "1.7.1-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/packages/repo-tools/CHANGELOG.md b/packages/repo-tools/CHANGELOG.md index 0864fd7347..fc5cae179c 100644 --- a/packages/repo-tools/CHANGELOG.md +++ b/packages/repo-tools/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/repo-tools +## 0.3.5-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/cli-node@0.1.5-next.1 + ## 0.3.5-next.0 ### Patch Changes diff --git a/packages/repo-tools/package.json b/packages/repo-tools/package.json index 8fc04fce71..304df34bec 100644 --- a/packages/repo-tools/package.json +++ b/packages/repo-tools/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/repo-tools", "description": "CLI for Backstage repo tooling ", - "version": "0.3.5-next.0", + "version": "0.3.5-next.1", "publishConfig": { "access": "public" }, diff --git a/packages/techdocs-cli-embedded-app/CHANGELOG.md b/packages/techdocs-cli-embedded-app/CHANGELOG.md index 45494ccba1..f54090b226 100644 --- a/packages/techdocs-cli-embedded-app/CHANGELOG.md +++ b/packages/techdocs-cli-embedded-app/CHANGELOG.md @@ -1,5 +1,24 @@ # techdocs-cli-embedded-app +## 0.2.87-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/cli@0.23.0-next.2 + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/plugin-techdocs@1.7.1-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/app-defaults@1.4.4-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/test-utils@1.4.4-next.2 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + ## 0.2.87-next.1 ### Patch Changes diff --git a/packages/techdocs-cli-embedded-app/package.json b/packages/techdocs-cli-embedded-app/package.json index 21eee41e19..86e85f9173 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.87-next.1", + "version": "0.2.87-next.2", "private": true, "backstage": { "role": "frontend" @@ -36,8 +36,8 @@ }, "devDependencies": { "@backstage/cli": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/react": "*", diff --git a/packages/techdocs-cli/CHANGELOG.md b/packages/techdocs-cli/CHANGELOG.md index abafa808fc..a6592085bb 100644 --- a/packages/techdocs-cli/CHANGELOG.md +++ b/packages/techdocs-cli/CHANGELOG.md @@ -1,5 +1,20 @@ # @techdocs/cli +## 1.6.0-next.2 + +### Minor Changes + +- d06b30b050: Add possibility to use a mkdocs config file with a different name than `mkdocs.<yaml|yml> with the serve command using the `--mkdocs-config-file-name` argument + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-techdocs-node@1.9.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/config@1.1.1-next.0 + ## 1.5.2-next.1 ### Patch Changes diff --git a/packages/techdocs-cli/package.json b/packages/techdocs-cli/package.json index 14120ab801..516a7d108e 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.5.2-next.1", + "version": "1.6.0-next.2", "publishConfig": { "access": "public" }, diff --git a/packages/test-utils/CHANGELOG.md b/packages/test-utils/CHANGELOG.md index 4cab843d01..9b9b90f838 100644 --- a/packages/test-utils/CHANGELOG.md +++ b/packages/test-utils/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/test-utils +## 1.4.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + ## 1.4.4-next.1 ### Patch Changes diff --git a/packages/test-utils/package.json b/packages/test-utils/package.json index b972a6a824..5f7bbb6af8 100644 --- a/packages/test-utils/package.json +++ b/packages/test-utils/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/test-utils", "description": "Utilities to test Backstage plugins and apps.", - "version": "1.4.4-next.1", + "version": "1.4.4-next.2", "publishConfig": { "access": "public" }, @@ -68,7 +68,7 @@ }, "devDependencies": { "@backstage/cli": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "msw": "^1.0.0" }, "files": [ diff --git a/packages/theme/CHANGELOG.md b/packages/theme/CHANGELOG.md index 445bc6055a..cf7d552883 100644 --- a/packages/theme/CHANGELOG.md +++ b/packages/theme/CHANGELOG.md @@ -1,5 +1,11 @@ # @backstage/theme +## 0.4.3-next.0 + +### Patch Changes + +- 5ad5344756: Added support for string `fontSize` values (e.g. `"2.5rem"`) in themes in addition to numbers. Also added an optional `fontFamily` prop for header typography variants to allow further customization. + ## 0.4.2 ### Patch Changes diff --git a/packages/theme/package.json b/packages/theme/package.json index 98be3baddd..2129067042 100644 --- a/packages/theme/package.json +++ b/packages/theme/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/theme", "description": "material-ui theme for use with Backstage.", - "version": "0.4.2", + "version": "0.4.3-next.0", "publishConfig": { "access": "public", "main": "dist/index.esm.js", diff --git a/packages/version-bridge/package.json b/packages/version-bridge/package.json index f14b263747..851128d025 100644 --- a/packages/version-bridge/package.json +++ b/packages/version-bridge/package.json @@ -42,7 +42,7 @@ }, "devDependencies": { "@backstage/cli": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0" }, diff --git a/plugins/adr-backend/CHANGELOG.md b/plugins/adr-backend/CHANGELOG.md index e2acb92554..44743f856a 100644 --- a/plugins/adr-backend/CHANGELOG.md +++ b/plugins/adr-backend/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-adr-backend +## 0.4.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-adr-common@0.2.16-next.1 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.4.2-next.1 ### Patch Changes diff --git a/plugins/adr-backend/package.json b/plugins/adr-backend/package.json index 580e3064af..444e238158 100644 --- a/plugins/adr-backend/package.json +++ b/plugins/adr-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-adr-backend", - "version": "0.4.2-next.1", + "version": "0.4.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/adr-common/CHANGELOG.md b/plugins/adr-common/CHANGELOG.md index 961562e016..32ac484e17 100644 --- a/plugins/adr-common/CHANGELOG.md +++ b/plugins/adr-common/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-adr-common +## 0.2.16-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.2.16-next.0 ### Patch Changes diff --git a/plugins/adr-common/package.json b/plugins/adr-common/package.json index 5e8e236b42..d1c32a852a 100644 --- a/plugins/adr-common/package.json +++ b/plugins/adr-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-adr-common", "description": "Common functionalities for the adr plugin", - "version": "0.2.16-next.0", + "version": "0.2.16-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/adr/CHANGELOG.md b/plugins/adr/CHANGELOG.md index 950e2c7ca3..a52862b7f7 100644 --- a/plugins/adr/CHANGELOG.md +++ b/plugins/adr/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-adr +## 0.6.8-next.2 + +### Patch Changes + +- 499e34656e: Fix icon alignment in `AdrSearchResultListItem` +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-adr-common@0.2.16-next.1 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.6.8-next.1 ### Patch Changes diff --git a/plugins/adr/alpha-api-report.md b/plugins/adr/alpha-api-report.md index 9d0bd071b1..6dd1c8043f 100644 --- a/plugins/adr/alpha-api-report.md +++ b/plugins/adr/alpha-api-report.md @@ -3,6 +3,8 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { Extension } from '@backstage/frontend-plugin-api'; import { TranslationRef } from '@backstage/core-plugin-api/alpha'; @@ -24,7 +26,7 @@ export const adrTranslationRef: TranslationRef< >; // @alpha (undocumented) -const _default: BackstagePlugin; +const _default: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; export default _default; // (No @packageDocumentation comment for this package) diff --git a/plugins/adr/package.json b/plugins/adr/package.json index 94d8250993..72511596e7 100644 --- a/plugins/adr/package.json +++ b/plugins/adr/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-adr", - "version": "0.6.8-next.1", + "version": "0.6.8-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -71,8 +71,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/git-url-parse": "^9.0.0", diff --git a/plugins/airbrake-backend/CHANGELOG.md b/plugins/airbrake-backend/CHANGELOG.md index ba6e94f7eb..948861944a 100644 --- a/plugins/airbrake-backend/CHANGELOG.md +++ b/plugins/airbrake-backend/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-airbrake-backend +## 0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.3.2-next.1 ### Patch Changes diff --git a/plugins/airbrake-backend/package.json b/plugins/airbrake-backend/package.json index e7bbcc9310..cccacd8197 100644 --- a/plugins/airbrake-backend/package.json +++ b/plugins/airbrake-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-airbrake-backend", - "version": "0.3.2-next.1", + "version": "0.3.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/airbrake/CHANGELOG.md b/plugins/airbrake/CHANGELOG.md index 712f785b2e..f930cc50df 100644 --- a/plugins/airbrake/CHANGELOG.md +++ b/plugins/airbrake/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-airbrake +## 0.3.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/dev-utils@1.0.22-next.2 + - @backstage/test-utils@1.4.4-next.2 + ## 0.3.25-next.1 ### Patch Changes diff --git a/plugins/airbrake/package.json b/plugins/airbrake/package.json index 003da7d232..e308bee851 100644 --- a/plugins/airbrake/package.json +++ b/plugins/airbrake/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-airbrake", - "version": "0.3.25-next.1", + "version": "0.3.25-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -52,8 +52,8 @@ "@backstage/cli": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/allure/CHANGELOG.md b/plugins/allure/CHANGELOG.md index 956f4d79fa..591036d45e 100644 --- a/plugins/allure/CHANGELOG.md +++ b/plugins/allure/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-allure +## 0.1.41-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.1.41-next.1 ### Patch Changes diff --git a/plugins/allure/package.json b/plugins/allure/package.json index fde188d1c8..f3f02f86dd 100644 --- a/plugins/allure/package.json +++ b/plugins/allure/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-allure", "description": "A Backstage plugin that integrates with Allure", - "version": "0.1.41-next.1", + "version": "0.1.41-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -51,8 +51,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/analytics-module-ga/CHANGELOG.md b/plugins/analytics-module-ga/CHANGELOG.md index 251990d5c3..05f2a97e4a 100644 --- a/plugins/analytics-module-ga/CHANGELOG.md +++ b/plugins/analytics-module-ga/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-analytics-module-ga +## 0.1.34-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.1.34-next.1 ### Patch Changes diff --git a/plugins/analytics-module-ga/package.json b/plugins/analytics-module-ga/package.json index e0e7c19ff2..0b79da313f 100644 --- a/plugins/analytics-module-ga/package.json +++ b/plugins/analytics-module-ga/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-analytics-module-ga", - "version": "0.1.34-next.1", + "version": "0.1.34-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -49,8 +49,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/react": "^16.13.1 || ^17.0.0", diff --git a/plugins/analytics-module-ga4/CHANGELOG.md b/plugins/analytics-module-ga4/CHANGELOG.md index d79ec11dea..d50658a59f 100644 --- a/plugins/analytics-module-ga4/CHANGELOG.md +++ b/plugins/analytics-module-ga4/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-analytics-module-ga4 +## 0.1.5-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.1.5-next.1 ### Patch Changes diff --git a/plugins/analytics-module-ga4/package.json b/plugins/analytics-module-ga4/package.json index ab9611f5e8..db8259cdfb 100644 --- a/plugins/analytics-module-ga4/package.json +++ b/plugins/analytics-module-ga4/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-analytics-module-ga4", - "version": "0.1.5-next.1", + "version": "0.1.5-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -46,8 +46,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/jest": "^28.1.3", diff --git a/plugins/analytics-module-newrelic-browser/CHANGELOG.md b/plugins/analytics-module-newrelic-browser/CHANGELOG.md index 7bfaf1c262..b22d4e64fc 100644 --- a/plugins/analytics-module-newrelic-browser/CHANGELOG.md +++ b/plugins/analytics-module-newrelic-browser/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-analytics-module-newrelic-browser +## 0.0.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/config@1.1.1-next.0 + ## 0.0.3-next.1 ### Patch Changes diff --git a/plugins/analytics-module-newrelic-browser/package.json b/plugins/analytics-module-newrelic-browser/package.json index c27be5f94e..040462ad20 100644 --- a/plugins/analytics-module-newrelic-browser/package.json +++ b/plugins/analytics-module-newrelic-browser/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-analytics-module-newrelic-browser", - "version": "0.0.3-next.1", + "version": "0.0.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -37,7 +37,7 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/apache-airflow/CHANGELOG.md b/plugins/apache-airflow/CHANGELOG.md index 4c0f6a418d..cd7d737b8e 100644 --- a/plugins/apache-airflow/CHANGELOG.md +++ b/plugins/apache-airflow/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-apache-airflow +## 0.2.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + ## 0.2.16-next.1 ### Patch Changes diff --git a/plugins/apache-airflow/package.json b/plugins/apache-airflow/package.json index 28f8f81ab0..1b314c9004 100644 --- a/plugins/apache-airflow/package.json +++ b/plugins/apache-airflow/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-apache-airflow", - "version": "0.2.16-next.1", + "version": "0.2.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -49,8 +49,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/api-docs-module-protoc-gen-doc/package.json b/plugins/api-docs-module-protoc-gen-doc/package.json index e0ad10f4f0..c7a952bc4f 100644 --- a/plugins/api-docs-module-protoc-gen-doc/package.json +++ b/plugins/api-docs-module-protoc-gen-doc/package.json @@ -42,7 +42,7 @@ }, "devDependencies": { "@backstage/cli": "workspace:^", - "@testing-library/jest-dom": "^5.16.4" + "@testing-library/jest-dom": "^6.0.0" }, "files": [ "dist" diff --git a/plugins/api-docs/CHANGELOG.md b/plugins/api-docs/CHANGELOG.md index 021c55b807..609a552a55 100644 --- a/plugins/api-docs/CHANGELOG.md +++ b/plugins/api-docs/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-api-docs +## 0.9.12-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.9.12-next.1 ### Patch Changes diff --git a/plugins/api-docs/package.json b/plugins/api-docs/package.json index f257d85d82..fb00aa8683 100644 --- a/plugins/api-docs/package.json +++ b/plugins/api-docs/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-api-docs", "description": "A Backstage plugin that helps represent API entities in the frontend", - "version": "0.9.12-next.1", + "version": "0.9.12-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -61,8 +61,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/swagger-ui-react": "^4.18.0", diff --git a/plugins/apollo-explorer/CHANGELOG.md b/plugins/apollo-explorer/CHANGELOG.md index 869e487cff..5b7905e69f 100644 --- a/plugins/apollo-explorer/CHANGELOG.md +++ b/plugins/apollo-explorer/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-apollo-explorer +## 0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.1.16-next.1 ### Patch Changes diff --git a/plugins/apollo-explorer/package.json b/plugins/apollo-explorer/package.json index 6c7eb11c50..c15726029d 100644 --- a/plugins/apollo-explorer/package.json +++ b/plugins/apollo-explorer/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-apollo-explorer", - "version": "0.1.16-next.1", + "version": "0.1.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -49,8 +49,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/app-backend/CHANGELOG.md b/plugins/app-backend/CHANGELOG.md index d54709fbc2..7478189eba 100644 --- a/plugins/app-backend/CHANGELOG.md +++ b/plugins/app-backend/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-app-backend +## 0.3.54-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config-loader@1.5.1-next.1 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-app-node@0.1.6-next.2 + ## 0.3.53-next.1 ### Patch Changes diff --git a/plugins/app-backend/package.json b/plugins/app-backend/package.json index 0874b66a27..a8425c5186 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.53-next.1", + "version": "0.3.54-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/app-node/CHANGELOG.md b/plugins/app-node/CHANGELOG.md index d1d2284dce..b6bb4d4425 100644 --- a/plugins/app-node/CHANGELOG.md +++ b/plugins/app-node/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-app-node +## 0.1.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + ## 0.1.5-next.1 ### Patch Changes diff --git a/plugins/app-node/package.json b/plugins/app-node/package.json index 5e21650501..f25333588a 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.5-next.1", + "version": "0.1.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-gcp-iap-provider/CHANGELOG.md b/plugins/auth-backend-module-gcp-iap-provider/CHANGELOG.md index 8c14e20d07..4c57589972 100644 --- a/plugins/auth-backend-module-gcp-iap-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-gcp-iap-provider/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-auth-backend-module-gcp-iap-provider +## 0.2.0-next.2 + +### Minor Changes + +- 6f142d5356: **BREAKING** `gcpIapAuthenticator.initialize()` is no longer `async` + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/types@1.1.1 + ## 0.1.2-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 7e9cd78fa4..65f4c1c0ed 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.1.2-next.1", + "version": "0.2.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-gcp-iap-provider/src/authenticator.test.ts b/plugins/auth-backend-module-gcp-iap-provider/src/authenticator.test.ts index 51efbe1a04..5f90d3a379 100644 --- a/plugins/auth-backend-module-gcp-iap-provider/src/authenticator.test.ts +++ b/plugins/auth-backend-module-gcp-iap-provider/src/authenticator.test.ts @@ -29,7 +29,7 @@ jest.mock('./helpers', () => ({ describe('GcpIapProvider', () => { it('should find default JWT header', async () => { - const ctx = await gcpIapAuthenticator.initialize({ + const ctx = gcpIapAuthenticator.initialize({ config: mockServices.rootConfig({ data: { audience: 'my-audience' } }), }); await expect( @@ -50,7 +50,7 @@ describe('GcpIapProvider', () => { it('should find custom JWT header', async () => { const jwtHeader = 'x-custom-header'; - const ctx = await gcpIapAuthenticator.initialize({ + const ctx = gcpIapAuthenticator.initialize({ config: mockServices.rootConfig({ data: { audience: 'my-audience', jwtHeader }, }), @@ -70,7 +70,7 @@ describe('GcpIapProvider', () => { }); it('should throw if header is missing', async () => { - const ctx = await gcpIapAuthenticator.initialize({ + const ctx = gcpIapAuthenticator.initialize({ config: mockServices.rootConfig({ data: { audience: 'my-audience' }, }), diff --git a/plugins/auth-backend-module-gcp-iap-provider/src/authenticator.ts b/plugins/auth-backend-module-gcp-iap-provider/src/authenticator.ts index ca104ded86..9bb68fcbb3 100644 --- a/plugins/auth-backend-module-gcp-iap-provider/src/authenticator.ts +++ b/plugins/auth-backend-module-gcp-iap-provider/src/authenticator.ts @@ -29,7 +29,7 @@ export const gcpIapAuthenticator = createProxyAuthenticator({ defaultProfileTransform: async (result: GcpIapResult) => { return { profile: { email: result.iapToken.email } }; }, - async initialize({ config }) { + initialize({ config }) { const audience = config.getString('audience'); const jwtHeader = config.getOptionalString('jwtHeader') ?? DEFAULT_IAP_JWT_HEADER; diff --git a/plugins/auth-backend-module-github-provider/CHANGELOG.md b/plugins/auth-backend-module-github-provider/CHANGELOG.md index d98d330281..4bebdabd8b 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.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + ## 0.1.2-next.1 ### Patch Changes diff --git a/plugins/auth-backend-module-github-provider/package.json b/plugins/auth-backend-module-github-provider/package.json index 25563c32c5..a9bcc1f21f 100644 --- a/plugins/auth-backend-module-github-provider/package.json +++ b/plugins/auth-backend-module-github-provider/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend-module-github-provider", "description": "The github-provider backend module for the auth plugin.", - "version": "0.1.2-next.1", + "version": "0.1.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-gitlab-provider/CHANGELOG.md b/plugins/auth-backend-module-gitlab-provider/CHANGELOG.md index cafc7ec1a4..eca91f503e 100644 --- a/plugins/auth-backend-module-gitlab-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-gitlab-provider/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-auth-backend-module-gitlab-provider +## 0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + ## 0.1.2-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 e039faf1a2..375b386fb8 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.2-next.1", + "version": "0.1.3-next.2", "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 974a3c1dfe..c06c8dfee0 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.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + ## 0.1.2-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 46adb1148e..74a6688e7c 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.2-next.1", + "version": "0.1.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-microsoft-provider/.eslintrc.js b/plugins/auth-backend-module-microsoft-provider/.eslintrc.js new file mode 100644 index 0000000000..e2a53a6ad2 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/.eslintrc.js @@ -0,0 +1 @@ +module.exports = require('@backstage/cli/config/eslint-factory')(__dirname); diff --git a/plugins/auth-backend-module-microsoft-provider/CHANGELOG.md b/plugins/auth-backend-module-microsoft-provider/CHANGELOG.md new file mode 100644 index 0000000000..c9b6227920 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/CHANGELOG.md @@ -0,0 +1,14 @@ +# @backstage/plugin-auth-backend-module-microsoft-provider + +## 0.1.0-next.0 + +### Minor Changes + +- 2d8f7e82c1: Migrated the Microsoft auth provider to new `@backstage/plugin-auth-backend-module-microsoft-provider` module package. + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 diff --git a/plugins/auth-backend-module-microsoft-provider/README.md b/plugins/auth-backend-module-microsoft-provider/README.md new file mode 100644 index 0000000000..5154f1644b --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/README.md @@ -0,0 +1,8 @@ +# Auth Module: Microsoft Provider + +This module provides an Microsoft auth provider implementation for `@backstage/plugin-auth-backend`. + +## Links + +- [Repository](https://gitlab.com/backstage/backstage/tree/master/plugins/auth-backend-module-microsoft-provider) +- [Backstage Project Homepage](https://backstage.io) diff --git a/plugins/auth-backend-module-microsoft-provider/api-report.md b/plugins/auth-backend-module-microsoft-provider/api-report.md new file mode 100644 index 0000000000..60192c5cbc --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/api-report.md @@ -0,0 +1,29 @@ +## API Report File for "@backstage/plugin-auth-backend-module-microsoft-provider" + +> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). + +```ts +import { BackendFeature } from '@backstage/backend-plugin-api'; +import { OAuthAuthenticator } from '@backstage/plugin-auth-node'; +import { OAuthAuthenticatorResult } from '@backstage/plugin-auth-node'; +import { PassportOAuthAuthenticatorHelper } from '@backstage/plugin-auth-node'; +import { PassportProfile } from '@backstage/plugin-auth-node'; +import { SignInResolverFactory } from '@backstage/plugin-auth-node'; + +// @public (undocumented) +export const authModuleMicrosoftProvider: () => BackendFeature; + +// @public (undocumented) +export const microsoftAuthenticator: OAuthAuthenticator< + PassportOAuthAuthenticatorHelper, + PassportProfile +>; + +// @public +export namespace microsoftSignInResolvers { + const emailMatchingUserEntityAnnotation: SignInResolverFactory< + OAuthAuthenticatorResult<PassportProfile>, + unknown + >; +} +``` diff --git a/plugins/auth-backend-module-microsoft-provider/catalog-info.yaml b/plugins/auth-backend-module-microsoft-provider/catalog-info.yaml new file mode 100644 index 0000000000..1742fc9ed6 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/catalog-info.yaml @@ -0,0 +1,10 @@ +apiVersion: backstage.io/v1alpha1 +kind: Component +metadata: + name: backstage-plugin-auth-backend-module-microsoft-provider + title: '@backstage/plugin-auth-backend-module-microsoft-provider' + description: The microsoft-provider backend module for the auth plugin. +spec: + lifecycle: experimental + type: backstage-backend-plugin-module + owner: maintainers diff --git a/plugins/auth-backend-module-microsoft-provider/config.d.ts b/plugins/auth-backend-module-microsoft-provider/config.d.ts new file mode 100644 index 0000000000..5f1fa958e5 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/config.d.ts @@ -0,0 +1,34 @@ +/* + * 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. + */ + +export interface Config { + auth?: { + providers?: { + /** @visibility frontend */ + microsoft?: { + [authEnv: string]: { + clientId: string; + /** + * @visibility secret + */ + tenantId: string; + clientSecret: string; + callbackUrl?: string; + }; + }; + }; + }; +} diff --git a/plugins/auth-backend-module-microsoft-provider/dev/index.ts b/plugins/auth-backend-module-microsoft-provider/dev/index.ts new file mode 100644 index 0000000000..e701470af8 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/dev/index.ts @@ -0,0 +1,26 @@ +/* + * 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 { createBackend } from '@backstage/backend-defaults'; +import authPlugin from '@backstage/plugin-auth-backend'; +import { authModuleMicrosoftProvider } from '../src'; + +const backend = createBackend(); + +backend.add(authPlugin); +backend.add(authModuleMicrosoftProvider); + +backend.start(); diff --git a/plugins/auth-backend-module-microsoft-provider/package.json b/plugins/auth-backend-module-microsoft-provider/package.json new file mode 100644 index 0000000000..8555af2cbe --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/package.json @@ -0,0 +1,45 @@ +{ + "name": "@backstage/plugin-auth-backend-module-microsoft-provider", + "description": "The microsoft-provider backend module for the auth plugin.", + "version": "0.1.0-next.0", + "main": "src/index.ts", + "types": "src/index.ts", + "license": "Apache-2.0", + "publishConfig": { + "access": "public", + "main": "dist/index.cjs.js", + "types": "dist/index.d.ts" + }, + "backstage": { + "role": "backend-plugin-module" + }, + "scripts": { + "start": "backstage-cli package start", + "build": "backstage-cli package build", + "lint": "backstage-cli package lint", + "test": "backstage-cli package test", + "clean": "backstage-cli package clean", + "prepack": "backstage-cli package prepack", + "postpack": "backstage-cli package postpack" + }, + "dependencies": { + "@backstage/backend-common": "workspace:^", + "@backstage/backend-plugin-api": "workspace:^", + "@backstage/plugin-auth-node": "workspace:^", + "express": "^4.18.2", + "passport": "^0.6.0", + "passport-microsoft": "^1.0.0" + }, + "devDependencies": { + "@backstage/backend-defaults": "workspace:^", + "@backstage/backend-test-utils": "workspace:^", + "@backstage/cli": "workspace:^", + "@backstage/plugin-auth-backend": "workspace:^", + "supertest": "^6.3.3" + }, + "configSchema": "config.d.ts", + "files": [ + "dist", + "config.d.ts" + ] +} diff --git a/plugins/auth-backend-module-microsoft-provider/src/authenticator.ts b/plugins/auth-backend-module-microsoft-provider/src/authenticator.ts new file mode 100644 index 0000000000..bf2d7fcaba --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/src/authenticator.ts @@ -0,0 +1,74 @@ +/* + * 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 { Strategy as MicrosoftStrategy } from 'passport-microsoft'; +import { + createOAuthAuthenticator, + PassportOAuthAuthenticatorHelper, + PassportOAuthDoneCallback, + PassportProfile, +} from '@backstage/plugin-auth-node'; + +/** @public */ +export const microsoftAuthenticator = createOAuthAuthenticator({ + defaultProfileTransform: + PassportOAuthAuthenticatorHelper.defaultProfileTransform, + initialize({ callbackUrl, config }) { + const clientId = config.getString('clientId'); + const clientSecret = config.getString('clientSecret'); + const tenantId = config.getString('tenantId'); + + return PassportOAuthAuthenticatorHelper.from( + new MicrosoftStrategy( + { + clientID: clientId, + clientSecret: clientSecret, + callbackURL: callbackUrl, + tenant: tenantId, + scope: ['user.read'], + }, + ( + accessToken: string, + refreshToken: string, + params: any, + fullProfile: PassportProfile, + done: PassportOAuthDoneCallback, + ) => { + done( + undefined, + { fullProfile, params, accessToken }, + { refreshToken }, + ); + }, + ), + ); + }, + + async start(input, helper) { + return helper.start(input, { + accessType: 'offline', + prompt: 'consent', + }); + }, + + async authenticate(input, helper) { + return helper.authenticate(input); + }, + + async refresh(input, helper) { + return helper.refresh(input); + }, +}); diff --git a/plugins/auth-backend-module-microsoft-provider/src/index.ts b/plugins/auth-backend-module-microsoft-provider/src/index.ts new file mode 100644 index 0000000000..ae4fbf5926 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/src/index.ts @@ -0,0 +1,25 @@ +/* + * 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. + */ + +/** + * The gitlab-provider backend module for the auth plugin. + * + * @packageDocumentation + */ + +export { microsoftAuthenticator } from './authenticator'; +export { authModuleMicrosoftProvider } from './module'; +export { microsoftSignInResolvers } from './resolvers'; diff --git a/plugins/auth-backend-module-microsoft-provider/src/module.test.ts b/plugins/auth-backend-module-microsoft-provider/src/module.test.ts new file mode 100644 index 0000000000..ee7ed8f7f3 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/src/module.test.ts @@ -0,0 +1,81 @@ +/* + * 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 { mockServices, startTestBackend } from '@backstage/backend-test-utils'; +import authPlugin from '@backstage/plugin-auth-backend'; +import { decodeOAuthState } from '@backstage/plugin-auth-node'; +import request from 'supertest'; +import { authModuleMicrosoftProvider } from './module'; + +describe('authModuleMicrosoftProvider', () => { + it('should start', async () => { + const { server } = await startTestBackend({ + features: [ + authPlugin, + authModuleMicrosoftProvider, + mockServices.rootConfig.factory({ + data: { + app: { + baseUrl: 'http://localhost:3000', + }, + auth: { + providers: { + microsoft: { + development: { + clientId: 'my-client-id', + clientSecret: 'my-client-secret', + tenantId: 'my-tenant-id', + }, + }, + }, + }, + }, + }), + ], + }); + + const agent = request.agent(server); + + const res = await agent.get('/api/auth/microsoft/start?env=development'); + + expect(res.status).toEqual(302); + + const nonceCookie = agent.jar.getCookie('microsoft-nonce', { + domain: 'localhost', + path: '/api/auth/microsoft/handler', + script: false, + secure: false, + }); + expect(nonceCookie).toBeDefined(); + + const startUrl = new URL(res.get('location')); + expect(startUrl.origin).toBe('https://login.microsoftonline.com'); + expect(startUrl.pathname).toBe('/my-tenant-id/oauth2/v2.0/authorize'); + expect(Object.fromEntries(startUrl.searchParams)).toEqual({ + prompt: 'consent', + response_type: 'code', + scope: 'user.read', + client_id: 'my-client-id', + redirect_uri: `http://localhost:${server.port()}/api/auth/microsoft/handler/frame`, + state: expect.any(String), + }); + + expect(decodeOAuthState(startUrl.searchParams.get('state')!)).toEqual({ + env: 'development', + nonce: decodeURIComponent(nonceCookie.value), + }); + }); +}); diff --git a/plugins/auth-backend-module-microsoft-provider/src/module.ts b/plugins/auth-backend-module-microsoft-provider/src/module.ts new file mode 100644 index 0000000000..4d5c5968a2 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/src/module.ts @@ -0,0 +1,48 @@ +/* + * 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 { createBackendModule } from '@backstage/backend-plugin-api'; +import { + authProvidersExtensionPoint, + commonSignInResolvers, + createOAuthProviderFactory, +} from '@backstage/plugin-auth-node'; +import { microsoftAuthenticator } from './authenticator'; +import { microsoftSignInResolvers } from './resolvers'; + +/** @public */ +export const authModuleMicrosoftProvider = createBackendModule({ + pluginId: 'auth', + moduleId: 'microsoft-provider', + register(reg) { + reg.registerInit({ + deps: { + providers: authProvidersExtensionPoint, + }, + async init({ providers }) { + providers.registerProvider({ + providerId: 'microsoft', + factory: createOAuthProviderFactory({ + authenticator: microsoftAuthenticator, + signInResolverFactories: { + ...microsoftSignInResolvers, + ...commonSignInResolvers, + }, + }), + }); + }, + }); + }, +}); diff --git a/plugins/auth-backend-module-microsoft-provider/src/resolvers.ts b/plugins/auth-backend-module-microsoft-provider/src/resolvers.ts new file mode 100644 index 0000000000..7ef4a57175 --- /dev/null +++ b/plugins/auth-backend-module-microsoft-provider/src/resolvers.ts @@ -0,0 +1,53 @@ +/* + * 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 { + OAuthAuthenticatorResult, + createSignInResolverFactory, + PassportProfile, + SignInInfo, +} from '@backstage/plugin-auth-node'; + +/** + * Available sign-in resolvers for the Microsoft auth provider. + * + * @public + */ +export namespace microsoftSignInResolvers { + /** + * Looks up the user by matching their Microsoft username to the entity name. + */ + export const emailMatchingUserEntityAnnotation = createSignInResolverFactory({ + create() { + return async ( + info: SignInInfo<OAuthAuthenticatorResult<PassportProfile>>, + ctx, + ) => { + const { profile } = info; + + if (!profile.email) { + throw new Error('Microsoft profile contained no email'); + } + + return ctx.signInWithCatalogUser({ + annotations: { + 'microsoft.com/email': profile.email, + }, + }); + }; + }, + }); +} diff --git a/packages/backend/src/plugins/graphql.ts b/plugins/auth-backend-module-microsoft-provider/src/types.d.ts similarity index 65% rename from packages/backend/src/plugins/graphql.ts rename to plugins/auth-backend-module-microsoft-provider/src/types.d.ts index c9aafa70ff..ca6ae9ac40 100644 --- a/packages/backend/src/plugins/graphql.ts +++ b/plugins/auth-backend-module-microsoft-provider/src/types.d.ts @@ -14,15 +14,12 @@ * limitations under the License. */ -import { createRouter } from '@backstage/plugin-graphql-backend'; -import { Router } from 'express'; -import { PluginEnvironment } from '../types'; +declare module 'passport-microsoft' { + import { Request } from 'express'; + import { StrategyCreated } from 'passport'; -export default async function createPlugin( - env: PluginEnvironment, -): Promise<Router> { - return await createRouter({ - logger: env.logger, - config: env.config, - }); + export class Strategy { + constructor(options: any, verify: any); + authenticate(this: StrategyCreated<this>, req: Request, options?: any): any; + } } diff --git a/plugins/auth-backend-module-oauth2-provider/CHANGELOG.md b/plugins/auth-backend-module-oauth2-provider/CHANGELOG.md index f2437a2e73..2588afe13a 100644 --- a/plugins/auth-backend-module-oauth2-provider/CHANGELOG.md +++ b/plugins/auth-backend-module-oauth2-provider/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-auth-backend-module-oauth2-provider +## 0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + ## 0.1.2-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 3e53ba5954..1f610405a0 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.2-next.1", + "version": "0.1.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-backend-module-pinniped-provider/.eslintrc.js b/plugins/auth-backend-module-pinniped-provider/.eslintrc.js new file mode 100644 index 0000000000..e2a53a6ad2 --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/.eslintrc.js @@ -0,0 +1 @@ +module.exports = require('@backstage/cli/config/eslint-factory')(__dirname); diff --git a/plugins/auth-backend-module-pinniped-provider/README.md b/plugins/auth-backend-module-pinniped-provider/README.md new file mode 100644 index 0000000000..bdb340d426 --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/README.md @@ -0,0 +1,7 @@ +# Auth Module: Pinniped Provider + +This module provides an Pinniped auth provider implementation for `@backstage/plugin-auth-backend`. + +## Links + +- [Backstage](https://backstage.io) diff --git a/plugins/auth-backend-module-pinniped-provider/api-report.md b/plugins/auth-backend-module-pinniped-provider/api-report.md new file mode 100644 index 0000000000..b9b993bd1e --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/api-report.md @@ -0,0 +1,28 @@ +## API Report File for "@backstage/plugin-auth-backend-module-pinniped-provider" + +> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). + +```ts +import { BackendFeature } from '@backstage/backend-plugin-api'; +import { BaseClient } from 'openid-client'; +import { OAuthAuthenticator } from '@backstage/plugin-auth-node'; +import { Strategy } from 'openid-client'; +import { TokenSet } from 'openid-client'; + +// @public (undocumented) +export const authModulePinnipedProvider: () => BackendFeature; + +// @public (undocumented) +export const pinnipedAuthenticator: OAuthAuthenticator< + Promise<{ + providerStrategy: Strategy< + { + tokenset: TokenSet; + }, + BaseClient + >; + client: BaseClient; + }>, + unknown +>; +``` diff --git a/plugins/auth-backend-module-pinniped-provider/catalog-info.yaml b/plugins/auth-backend-module-pinniped-provider/catalog-info.yaml new file mode 100644 index 0000000000..9d1ef1c299 --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/catalog-info.yaml @@ -0,0 +1,10 @@ +apiVersion: backstage.io/v1alpha1 +kind: Component +metadata: + name: backstage-plugin-auth-backend-module-pinniped-provider + title: '@backstage/plugin-auth-backend-module-pinniped-provider' + description: The pinniped-provider backend module for the auth plugin. +spec: + lifecycle: experimental + type: backstage-backend-plugin-module + owner: maintainers diff --git a/plugins/auth-backend-module-pinniped-provider/dev/index.ts b/plugins/auth-backend-module-pinniped-provider/dev/index.ts new file mode 100644 index 0000000000..bd09f77a1f --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/dev/index.ts @@ -0,0 +1,26 @@ +/* + * 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 { createBackend } from '@backstage/backend-defaults'; +import authPlugin from '@backstage/plugin-auth-backend'; +import { authModulePinnipedProvider } from '../src'; + +const backend = createBackend(); + +backend.add(authPlugin); +backend.add(authModulePinnipedProvider); + +backend.start(); diff --git a/plugins/auth-backend-module-pinniped-provider/package.json b/plugins/auth-backend-module-pinniped-provider/package.json new file mode 100644 index 0000000000..3d7dcf97d9 --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/package.json @@ -0,0 +1,49 @@ +{ + "name": "@backstage/plugin-auth-backend-module-pinniped-provider", + "description": "The pinniped-provider backend module for the auth plugin.", + "version": "0.0.0", + "main": "src/index.ts", + "types": "src/index.ts", + "license": "Apache-2.0", + "publishConfig": { + "access": "public", + "main": "dist/index.cjs.js", + "types": "dist/index.d.ts" + }, + "backstage": { + "role": "backend-plugin-module" + }, + "scripts": { + "start": "backstage-cli package start", + "build": "backstage-cli package build", + "lint": "backstage-cli package lint", + "test": "backstage-cli package test", + "clean": "backstage-cli package clean", + "prepack": "backstage-cli package prepack", + "postpack": "backstage-cli package postpack" + }, + "dependencies": { + "@backstage/backend-common": "workspace:^", + "@backstage/backend-plugin-api": "workspace:^", + "@backstage/plugin-auth-node": "workspace:^", + "openid-client": "^5.4.3" + }, + "devDependencies": { + "@backstage/backend-defaults": "workspace:^", + "@backstage/backend-test-utils": "workspace:^", + "@backstage/cli": "workspace:^", + "@backstage/config": "workspace:^", + "@backstage/plugin-auth-backend": "workspace:^", + "cookie-parser": "^1.4.6", + "express": "^4.18.2", + "express-promise-router": "^4.1.1", + "express-session": "^1.17.3", + "jose": "^4.14.6", + "msw": "^1.3.0", + "passport": "^0.6.0", + "supertest": "^6.3.3" + }, + "files": [ + "dist" + ] +} diff --git a/plugins/auth-backend-module-pinniped-provider/src/authenticator.test.ts b/plugins/auth-backend-module-pinniped-provider/src/authenticator.test.ts new file mode 100644 index 0000000000..f908c1ea13 --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/src/authenticator.test.ts @@ -0,0 +1,503 @@ +/* + * 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 { + OAuthAuthenticatorAuthenticateInput, + OAuthAuthenticatorRefreshInput, + OAuthAuthenticatorStartInput, + OAuthState, + decodeOAuthState, + encodeOAuthState, +} from '@backstage/plugin-auth-node'; +import { pinnipedAuthenticator } from './authenticator'; +import { setupServer } from 'msw/node'; +import { setupRequestMockHandlers } from '@backstage/backend-test-utils'; +import { ConfigReader } from '@backstage/config'; +import { JWK, SignJWT, exportJWK, generateKeyPair } from 'jose'; +import { rest } from 'msw'; +import express from 'express'; + +describe('pinnipedAuthenticator', () => { + let implementation: any; + let oauthState: OAuthState; + let idToken: string; + let publicKey: JWK; + + const mswServer = setupServer(); + setupRequestMockHandlers(mswServer); + + const issuerMetadata = { + issuer: 'https://pinniped.test', + authorization_endpoint: 'https://pinniped.test/oauth2/authorize', + token_endpoint: 'https://pinniped.test/oauth2/token', + revocation_endpoint: 'https://pinniped.test/oauth2/revoke_token', + userinfo_endpoint: 'https://pinniped.test/idp/userinfo.openid', + introspection_endpoint: 'https://pinniped.test/introspect.oauth2', + jwks_uri: 'https://pinniped.test/jwks.json', + scopes_supported: [ + 'openid', + 'offline_access', + 'pinniped:request-audience', + 'username', + 'groups', + ], + claims_supported: ['email', 'username', 'groups', 'additionalClaims'], + response_types_supported: ['code'], + id_token_signing_alg_values_supported: ['RS256', 'RS512', 'HS256'], + token_endpoint_auth_signing_alg_values_supported: [ + 'RS256', + 'RS512', + 'HS256', + ], + request_object_signing_alg_values_supported: ['RS256', 'RS512', 'HS256'], + }; + + const clusterScopedIdToken = 'dummy-token'; + + beforeAll(async () => { + const keyPair = await generateKeyPair('ES256'); + const privateKey = await exportJWK(keyPair.privateKey); + publicKey = await exportJWK(keyPair.publicKey); + publicKey.alg = privateKey.alg = 'ES256'; + + idToken = await new SignJWT({ + sub: 'test', + iss: 'https://pinniped.test', + iat: Date.now(), + aud: 'clientId', + exp: Date.now() + 10000, + }) + .setProtectedHeader({ alg: privateKey.alg, kid: privateKey.kid }) + .sign(keyPair.privateKey); + }); + + beforeEach(() => { + jest.clearAllMocks(); + + mswServer.use( + rest.get( + 'https://federationDomain.test/.well-known/openid-configuration', + (_req, res, ctx) => + res( + ctx.status(200), + ctx.set('Content-Type', 'application/json'), + ctx.json(issuerMetadata), + ), + ), + rest.get('https://pinniped.test/jwks.json', async (_req, res, ctx) => + res(ctx.status(200), ctx.json({ keys: [{ ...publicKey }] })), + ), + rest.post('https://pinniped.test/oauth2/token', async (req, res, ctx) => { + const formBody = new URLSearchParams(await req.text()); + const isGrantTypeTokenExchange = + formBody.get('grant_type') === + 'urn:ietf:params:oauth:grant-type:token-exchange'; + const hasValidTokenExchangeParams = + formBody.get('subject_token') === 'accessToken' && + formBody.get('audience') === 'test_cluster' && + formBody.get('subject_token_type') === + 'urn:ietf:params:oauth:token-type:access_token' && + formBody.get('requested_token_type') === + 'urn:ietf:params:oauth:token-type:jwt'; + + return res( + req.headers.get('Authorization') && + (!isGrantTypeTokenExchange || hasValidTokenExchangeParams) + ? ctx.json({ + access_token: isGrantTypeTokenExchange + ? clusterScopedIdToken + : 'accessToken', + refresh_token: 'refreshToken', + ...(!isGrantTypeTokenExchange && { id_token: idToken }), + scope: 'testScope', + }) + : ctx.status(401), + ); + }), + ); + + implementation = pinnipedAuthenticator.initialize({ + callbackUrl: 'https://backstage.test/callback', + config: new ConfigReader({ + federationDomain: 'https://federationDomain.test', + clientId: 'clientId', + clientSecret: 'clientSecret', + }), + }); + + oauthState = { + nonce: 'nonce', + env: 'env', + }; + }); + + describe('#start', () => { + let fakeSession: Record<string, any>; + let startRequest: OAuthAuthenticatorStartInput; + + beforeEach(() => { + fakeSession = {}; + startRequest = { + state: encodeOAuthState(oauthState), + req: { + method: 'GET', + url: 'test', + session: fakeSession, + }, + } as unknown as OAuthAuthenticatorStartInput; + }); + + it('redirects to authorization endpoint returned from OIDC metadata endpoint', async () => { + const startResponse = await pinnipedAuthenticator.start( + startRequest, + implementation, + ); + const url = new URL(startResponse.url); + + expect(url.protocol).toBe('https:'); + expect(url.hostname).toBe('pinniped.test'); + expect(url.pathname).toBe('/oauth2/authorize'); + }); + + it('initiates authorization code grant', async () => { + const startResponse = await pinnipedAuthenticator.start( + startRequest, + implementation, + ); + const { searchParams } = new URL(startResponse.url); + + expect(searchParams.get('response_type')).toBe('code'); + }); + + it('persists audience parameter in oauth state', async () => { + startRequest.req.query = { audience: 'test-cluster' }; + const startResponse = await pinnipedAuthenticator.start( + startRequest, + implementation, + ); + const { searchParams } = new URL(startResponse.url); + const stateParam = searchParams.get('state'); + const decodedState = decodeOAuthState(stateParam!); + + expect(decodedState).toMatchObject({ + nonce: 'nonce', + env: 'env', + audience: 'test-cluster', + }); + }); + + it('passes client ID from config', async () => { + const startResponse = await pinnipedAuthenticator.start( + startRequest, + implementation, + ); + const { searchParams } = new URL(startResponse.url); + + expect(searchParams.get('client_id')).toBe('clientId'); + }); + + it('passes callback URL from config', async () => { + const startResponse = await pinnipedAuthenticator.start( + startRequest, + implementation, + ); + const { searchParams } = new URL(startResponse.url); + + expect(searchParams.get('redirect_uri')).toBe( + 'https://backstage.test/callback', + ); + }); + + it('generates PKCE challenge', async () => { + const startResponse = await pinnipedAuthenticator.start( + startRequest, + implementation, + ); + const { searchParams } = new URL(startResponse.url); + + expect(searchParams.get('code_challenge_method')).toBe('S256'); + expect(searchParams.get('code_challenge')).not.toBeNull(); + }); + + it('stores PKCE verifier in session', async () => { + await pinnipedAuthenticator.start(startRequest, implementation); + expect(fakeSession['oidc:pinniped.test'].code_verifier).toBeDefined(); + }); + + it('requests sufficient scopes for token exchange by default', async () => { + const startResponse = await pinnipedAuthenticator.start( + startRequest, + implementation, + ); + const { searchParams } = new URL(startResponse.url); + const scopes = searchParams.get('scope')?.split(' ') ?? []; + + expect(scopes).toEqual( + expect.arrayContaining([ + 'openid', + 'pinniped:request-audience', + 'username', + 'offline_access', + ]), + ); + }); + + it('encodes OAuth state in query param', async () => { + const startResponse = await pinnipedAuthenticator.start( + startRequest, + implementation, + ); + const { searchParams } = new URL(startResponse.url); + const stateParam = searchParams.get('state'); + const decodedState = decodeOAuthState(stateParam!); + + expect(decodedState).toMatchObject(oauthState); + }); + + it('fails when request has no session', async () => { + return expect( + pinnipedAuthenticator.start( + { + state: encodeOAuthState(oauthState), + req: { + method: 'GET', + url: 'test', + }, + } as unknown as OAuthAuthenticatorStartInput, + implementation, + ), + ).rejects.toThrow('authentication requires session support'); + }); + }); + + describe('#authenticate', () => { + let handlerRequest: OAuthAuthenticatorAuthenticateInput; + + beforeEach(() => { + handlerRequest = { + req: { + method: 'GET', + url: `https://test?code=authorization_code&state=${encodeOAuthState( + oauthState, + )}`, + session: { + 'oidc:pinniped.test': { + state: encodeOAuthState(oauthState), + }, + }, + } as unknown as express.Request, + }; + }); + + it('exchanges authorization code for access token', async () => { + const handlerResponse = await pinnipedAuthenticator.authenticate( + handlerRequest, + implementation, + ); + const accessToken = handlerResponse.session.accessToken; + + expect(accessToken).toEqual('accessToken'); + }); + + it('exchanges authorization code for refresh token', async () => { + const handlerResponse = await pinnipedAuthenticator.authenticate( + handlerRequest, + implementation, + ); + const refreshToken = handlerResponse.session.refreshToken; + + expect(refreshToken).toEqual('refreshToken'); + }); + + it('returns granted scope', async () => { + const handlerResponse = await pinnipedAuthenticator.authenticate( + handlerRequest, + implementation, + ); + const responseScope = handlerResponse.session.scope; + + expect(responseScope).toEqual('testScope'); + }); + + it('returns cluster-scoped ID token when audience is specified', async () => { + oauthState.audience = 'test_cluster'; + handlerRequest = { + req: { + method: 'GET', + url: `https://test?code=authorization_code&state=${encodeOAuthState( + oauthState, + )}`, + session: { + 'oidc:pinniped.test': { + state: encodeOAuthState(oauthState), + }, + }, + } as unknown as express.Request, + }; + + const handlerResponse = await pinnipedAuthenticator.authenticate( + handlerRequest, + implementation, + ); + + expect(handlerResponse.session.idToken).toEqual(clusterScopedIdToken); + }); + + it('fails on network error during token exchange', async () => { + mswServer.use( + rest.post( + 'https://pinniped.test/oauth2/token', + async (req, res, ctx) => { + const formBody = new URLSearchParams(await req.text()); + const isGrantTypeTokenExchange = + formBody.get('grant_type') === + 'urn:ietf:params:oauth:grant-type:token-exchange'; + const hasValidTokenExchangeParams = + formBody.get('subject_token') === 'accessToken' && + formBody.get('audience') === 'test_cluster' && + formBody.get('subject_token_type') === + 'urn:ietf:params:oauth:token-type:access_token' && + formBody.get('requested_token_type') === + 'urn:ietf:params:oauth:token-type:jwt'; + + mswServer.use( + rest.post( + 'https://pinniped.test/oauth2/token', + async (_req, response, _ctx) => + response.networkError('Connection timed out'), + ), + ); + + return res( + req.headers.get('Authorization') && + (!isGrantTypeTokenExchange || hasValidTokenExchangeParams) + ? ctx.json({ + access_token: isGrantTypeTokenExchange + ? clusterScopedIdToken + : 'accessToken', + refresh_token: 'refreshToken', + ...(!isGrantTypeTokenExchange && { id_token: idToken }), + scope: 'testScope', + }) + : ctx.status(401), + ); + }, + ), + ); + + oauthState.audience = 'test_cluster'; + handlerRequest = { + req: { + method: 'GET', + url: `https://test?code=authorization_code&state=${encodeOAuthState( + oauthState, + )}`, + session: { + 'oidc:pinniped.test': { + state: encodeOAuthState(oauthState), + }, + }, + } as unknown as express.Request, + }; + + await expect( + pinnipedAuthenticator.authenticate(handlerRequest, implementation), + ).rejects.toThrow( + `Failed to get cluster specific ID token for "test_cluster": Error: RFC8693 token exchange failed with error: NetworkError: Connection timed out`, + ); + }); + + it('fails without authorization code', async () => { + handlerRequest.req.url = 'https://test.com'; + return expect( + pinnipedAuthenticator.authenticate(handlerRequest, implementation), + ).rejects.toThrow('Unexpected redirect'); + }); + + it('fails without oauth state', async () => { + return expect( + pinnipedAuthenticator.authenticate( + { + req: { + method: 'GET', + url: `https://test?code=authorization_code}`, + session: { + ['oidc:pinniped.test']: { + state: { handle: 'sessionid', code_verifier: 'foo' }, + }, + }, + } as unknown as express.Request, + }, + implementation, + ), + ).rejects.toThrow( + 'Authentication rejected, state missing from the response', + ); + }); + + it('fails when request has no session', async () => { + return expect( + pinnipedAuthenticator.authenticate( + { + req: { + method: 'GET', + url: 'https://test.com', + } as unknown as express.Request, + }, + implementation, + ), + ).rejects.toThrow('authentication requires session support'); + }); + }); + + describe('#refresh', () => { + let refreshRequest: OAuthAuthenticatorRefreshInput; + + beforeEach(() => { + refreshRequest = { + scope: '', + refreshToken: 'otherRefreshToken', + req: {} as express.Request, + }; + }); + + it('gets new refresh token', async () => { + const refreshResponse = await pinnipedAuthenticator.refresh( + refreshRequest, + implementation, + ); + + expect(refreshResponse.session.refreshToken).toBe('refreshToken'); + }); + + it('gets access token', async () => { + const refreshResponse = await pinnipedAuthenticator.refresh( + refreshRequest, + implementation, + ); + + expect(refreshResponse.session.accessToken).toBe('accessToken'); + }); + + it('gets id token', async () => { + const refreshResponse = await pinnipedAuthenticator.refresh( + refreshRequest, + implementation, + ); + + expect(refreshResponse.session.idToken).toBe(idToken); + }); + }); +}); diff --git a/plugins/auth-backend-module-pinniped-provider/src/authenticator.ts b/plugins/auth-backend-module-pinniped-provider/src/authenticator.ts new file mode 100644 index 0000000000..83c4204ad0 --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/src/authenticator.ts @@ -0,0 +1,195 @@ +/* + * 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 { PassportDoneCallback } from '@backstage/plugin-auth-node'; +import { + createOAuthAuthenticator, + decodeOAuthState, + encodeOAuthState, +} from '@backstage/plugin-auth-node'; +import { + Client, + Issuer, + TokenSet, + Strategy as OidcStrategy, +} from 'openid-client'; + +const rfc8693TokenExchange = async ({ + subject_token, + target_audience, + ctx, +}: { + subject_token: string; + target_audience: string; + ctx: Promise<{ + providerStrategy: OidcStrategy<{}>; + client: Client; + }>; +}): Promise<string | undefined> => { + const { client } = await ctx; + return client + .grant({ + grant_type: 'urn:ietf:params:oauth:grant-type:token-exchange', + subject_token, + audience: target_audience, + subject_token_type: 'urn:ietf:params:oauth:token-type:access_token', + requested_token_type: 'urn:ietf:params:oauth:token-type:jwt', + }) + .then(tokenset => tokenset.access_token) + .catch(err => { + throw new Error(`RFC8693 token exchange failed with error: ${err}`); + }); +}; + +/** @public */ +export const pinnipedAuthenticator = createOAuthAuthenticator({ + defaultProfileTransform: async (_r, _c) => ({ profile: {} }), + async initialize({ callbackUrl, config }) { + const issuer = await Issuer.discover( + `${config.getString( + 'federationDomain', + )}/.well-known/openid-configuration`, + ); + const client = new issuer.Client({ + access_type: 'offline', // this option must be passed to provider to receive a refresh token + client_id: config.getString('clientId'), + client_secret: config.getString('clientSecret'), + redirect_uris: [callbackUrl], + response_types: ['code'], + scope: config.getOptionalString('scope') || '', + id_token_signed_response_alg: 'ES256', + }); + const providerStrategy = new OidcStrategy( + { + client, + passReqToCallback: false, + }, + ( + tokenset: TokenSet, + done: PassportDoneCallback< + { tokenset: TokenSet }, + { + refreshToken?: string; + } + >, + ) => { + done(undefined, { tokenset }, {}); + }, + ); + + return { providerStrategy, client }; + }, + + async start(input, ctx) { + const { providerStrategy } = await ctx; + const stringifiedAudience = input.req.query?.audience as string; + const decodedState = decodeOAuthState(input.state); + const state = { ...decodedState, audience: stringifiedAudience }; + const options: Record<string, string> = { + scope: + input.scope || + 'openid pinniped:request-audience username offline_access', + state: encodeOAuthState(state), + }; + + return new Promise((resolve, reject) => { + const strategy = Object.create(providerStrategy); + strategy.redirect = (url: string) => { + resolve({ url }); + }; + strategy.error = (error: Error) => { + reject(error); + }; + strategy.authenticate(input.req, { ...options }); + }); + }, + + async authenticate(input, ctx) { + const { providerStrategy } = await ctx; + const { req } = input; + const { searchParams } = new URL(req.url, 'https://pinniped.com'); + const stateParam = searchParams.get('state'); + const audience = stateParam + ? decodeOAuthState(stateParam).audience + : undefined; + + return new Promise((resolve, reject) => { + const strategy = Object.create(providerStrategy); + strategy.success = (user: any) => { + (audience + ? rfc8693TokenExchange({ + subject_token: user.tokenset.access_token, + target_audience: audience, + ctx, + }).catch(err => + reject( + new Error( + `Failed to get cluster specific ID token for "${audience}": ${err}`, + ), + ), + ) + : Promise.resolve(user.tokenset.id_token) + ).then(idToken => { + resolve({ + fullProfile: { provider: '', id: '', displayName: '' }, + session: { + accessToken: user.tokenset.access_token!, + tokenType: user.tokenset.token_type ?? 'bearer', + scope: user.tokenset.scope!, + idToken, + refreshToken: user.tokenset.refresh_token, + }, + }); + }); + }; + + strategy.fail = (info: any) => { + reject(new Error(`Authentication rejected, ${info.message || ''}`)); + }; + + strategy.error = (error: Error) => { + reject(error); + }; + + strategy.redirect = () => { + reject(new Error('Unexpected redirect')); + }; + + strategy.authenticate(req); + }); + }, + + async refresh(input, ctx) { + const { client } = await ctx; + const tokenset = await client.refresh(input.refreshToken); + + return new Promise((resolve, reject) => { + if (!tokenset.access_token) { + reject(new Error('Refresh Failed')); + } + + resolve({ + fullProfile: { provider: '', id: '', displayName: '' }, + session: { + accessToken: tokenset.access_token!, + tokenType: tokenset.token_type ?? 'bearer', + scope: tokenset.scope!, + idToken: tokenset.id_token, + refreshToken: tokenset.refresh_token, + }, + }); + }); + }, +}); diff --git a/plugins/auth-backend-module-pinniped-provider/src/config.d.ts b/plugins/auth-backend-module-pinniped-provider/src/config.d.ts new file mode 100644 index 0000000000..50685abfb0 --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/src/config.d.ts @@ -0,0 +1,34 @@ +/* + * 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. + */ + +export interface Config { + /** Configuration options for the auth plugin */ + auth?: { + providers?: { + pinniped?: { + [authEnv: string]: { + clientId: string; + federationDomain: string; + /** + * @visibility secret + */ + clientSecret: string; + scope?: string; + }; + }; + }; + }; +} diff --git a/plugins/auth-backend-module-pinniped-provider/src/index.ts b/plugins/auth-backend-module-pinniped-provider/src/index.ts new file mode 100644 index 0000000000..9a2ca6727e --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/src/index.ts @@ -0,0 +1,24 @@ +/* + * 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. + */ + +/** + * The pinniped-provider backend module for the auth plugin. + * + * @packageDocumentation + */ + +export { pinnipedAuthenticator } from './authenticator'; +export { authModulePinnipedProvider } from './module'; diff --git a/plugins/auth-backend-module-pinniped-provider/src/module.test.ts b/plugins/auth-backend-module-pinniped-provider/src/module.test.ts new file mode 100644 index 0000000000..ed285cff86 --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/src/module.test.ts @@ -0,0 +1,260 @@ +/* + * 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 { setupRequestMockHandlers } from '@backstage/backend-test-utils'; +import request from 'supertest'; +import { setupServer } from 'msw/node'; +import { rest } from 'msw'; +import { Server } from 'http'; +import express from 'express'; +import cookieParser from 'cookie-parser'; +import session from 'express-session'; +import passport from 'passport'; +import { AddressInfo } from 'net'; +import { + AuthProviderRouteHandlers, + createOAuthRouteHandlers, +} from '@backstage/plugin-auth-node'; +import Router from 'express-promise-router'; +import { pinnipedAuthenticator } from './authenticator'; +import { ConfigReader } from '@backstage/config'; +import { JWK, SignJWT, exportJWK, generateKeyPair } from 'jose'; + +describe('authModulePinnipedProvider', () => { + let app: express.Express; + let backstageServer: Server; + let appUrl: string; + let providerRouteHandler: AuthProviderRouteHandlers; + let idToken: string; + let publicKey: JWK; + + const mswServer = setupServer(); + setupRequestMockHandlers(mswServer); + + const issuerMetadata = { + issuer: 'https://pinniped.test', + authorization_endpoint: 'https://pinniped.test/oauth2/authorize', + token_endpoint: 'https://pinniped.test/oauth2/token', + revocation_endpoint: 'https://pinniped.test/oauth2/revoke_token', + userinfo_endpoint: 'https://pinniped.test/idp/userinfo.openid', + introspection_endpoint: 'https://pinniped.test/introspect.oauth2', + jwks_uri: 'https://pinniped.test/jwks.json', + scopes_supported: [ + 'openid', + 'offline_access', + 'pinniped:request-audience', + 'username', + 'groups', + ], + claims_supported: ['email', 'username', 'groups', 'additionalClaims'], + response_types_supported: ['code'], + id_token_signing_alg_values_supported: ['RS256', 'RS512', 'HS256'], + token_endpoint_auth_signing_alg_values_supported: [ + 'RS256', + 'RS512', + 'HS256', + ], + request_object_signing_alg_values_supported: ['RS256', 'RS512', 'HS256'], + }; + + const clusterScopedIdToken = 'dummy-token'; + + beforeAll(async () => { + const keyPair = await generateKeyPair('ES256'); + const privateKey = await exportJWK(keyPair.privateKey); + publicKey = await exportJWK(keyPair.publicKey); + publicKey.alg = privateKey.alg = 'ES256'; + + idToken = await new SignJWT({ + sub: 'test', + iss: 'https://pinniped.test', + iat: Date.now(), + aud: 'clientId', + exp: Date.now() + 10000, + }) + .setProtectedHeader({ alg: privateKey.alg, kid: privateKey.kid }) + .sign(keyPair.privateKey); + }); + + beforeEach(async () => { + jest.clearAllMocks(); + + mswServer.use( + rest.get( + 'https://federationDomain.test/.well-known/openid-configuration', + (_req, res, ctx) => + res( + ctx.status(200), + ctx.set('Content-Type', 'application/json'), + ctx.json(issuerMetadata), + ), + ), + rest.get( + 'https://pinniped.test/oauth2/authorize', + async (req, res, ctx) => { + const callbackUrl = new URL( + req.url.searchParams.get('redirect_uri')!, + ); + callbackUrl.searchParams.set('code', 'authorization_code'); + callbackUrl.searchParams.set( + 'state', + req.url.searchParams.get('state')!, + ); + callbackUrl.searchParams.set('scope', 'test-scope'); + return res( + ctx.status(302), + ctx.set('Location', callbackUrl.toString()), + ); + }, + ), + rest.get('https://pinniped.test/jwks.json', async (_req, res, ctx) => + res(ctx.status(200), ctx.json({ keys: [{ ...publicKey }] })), + ), + rest.post('https://pinniped.test/oauth2/token', async (req, res, ctx) => { + const formBody = new URLSearchParams(await req.text()); + const isGrantTypeTokenExchange = + formBody.get('grant_type') === + 'urn:ietf:params:oauth:grant-type:token-exchange'; + const hasValidTokenExchangeParams = + formBody.get('subject_token') === 'accessToken' && + formBody.get('audience') === 'test_cluster' && + formBody.get('subject_token_type') === + 'urn:ietf:params:oauth:token-type:access_token' && + formBody.get('requested_token_type') === + 'urn:ietf:params:oauth:token-type:jwt'; + + return res( + req.headers.get('Authorization') && + (!isGrantTypeTokenExchange || hasValidTokenExchangeParams) + ? ctx.json({ + access_token: isGrantTypeTokenExchange + ? clusterScopedIdToken + : 'accessToken', + refresh_token: 'refreshToken', + ...(!isGrantTypeTokenExchange && { id_token: idToken }), + scope: 'testScope', + }) + : ctx.status(401), + ); + }), + ); + + const secret = 'secret'; + app = express() + .use(cookieParser(secret)) + .use( + session({ + secret, + saveUninitialized: false, + resave: false, + cookie: { secure: false }, + }), + ) + .use(passport.initialize()) + .use(passport.session()); + await new Promise(resolve => { + backstageServer = app.listen(0, '0.0.0.0', () => { + appUrl = `http://127.0.0.1:${ + (backstageServer.address() as AddressInfo).port + }`; + resolve(null); + }); + }); + + mswServer.use(rest.all(`${appUrl}/*`, req => req.passthrough())); + + providerRouteHandler = createOAuthRouteHandlers({ + authenticator: pinnipedAuthenticator, + appUrl, + baseUrl: `${appUrl}/api/auth`, + isOriginAllowed: _ => true, + providerId: 'pinniped', + config: new ConfigReader({ + federationDomain: 'https://federationDomain.test', + clientId: 'clientId', + clientSecret: 'clientSecret', + }), + resolverContext: { + issueToken: async _ => ({ token: '' }), + findCatalogUser: async _ => ({ + entity: { + apiVersion: '', + kind: '', + metadata: { name: '' }, + }, + }), + signInWithCatalogUser: async _ => ({ token: '' }), + }, + }); + + const router = Router(); + router + .use( + '/api/auth/pinniped/start', + providerRouteHandler.start.bind(providerRouteHandler), + ) + .use( + '/api/auth/pinniped/handler/frame', + providerRouteHandler.frameHandler.bind(providerRouteHandler), + ); + app.use(router); + }); + + afterEach(() => { + backstageServer.close(); + }); + + it('should start', async () => { + const agent = request.agent(backstageServer); + const startResponse = await agent.get( + `/api/auth/pinniped/start?env=development&audience=test_cluster`, + ); + + expect(startResponse.status).toBe(302); + }); + + it('/handler/frame exchanges authorization code from #start for Cluster Specific ID token', async () => { + const agent = request.agent(''); + + // make /start request with audience parameter + const startResponse = await agent.get( + `${appUrl}/api/auth/pinniped/start?env=development&audience=test_cluster`, + ); + // follow redirect to authorization endpoint + const authorizationResponse = await agent.get( + startResponse.header.location, + ); + // follow redirect to token_endpoint + const handlerResponse = await agent.get( + authorizationResponse.header.location, + ); + + expect(handlerResponse.text).toContain( + encodeURIComponent( + JSON.stringify({ + type: 'authorization_response', + response: { + profile: {}, + providerInfo: { + idToken: clusterScopedIdToken, + accessToken: 'accessToken', + scope: 'testScope', + }, + }, + }), + ), + ); + }); +}); diff --git a/plugins/auth-backend-module-pinniped-provider/src/module.ts b/plugins/auth-backend-module-pinniped-provider/src/module.ts new file mode 100644 index 0000000000..5fff30e82e --- /dev/null +++ b/plugins/auth-backend-module-pinniped-provider/src/module.ts @@ -0,0 +1,46 @@ +/* + * 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 { createBackendModule } from '@backstage/backend-plugin-api'; +import { + authProvidersExtensionPoint, + commonSignInResolvers, + createOAuthProviderFactory, +} from '@backstage/plugin-auth-node'; +import { pinnipedAuthenticator } from './authenticator'; + +/** @public */ +export const authModulePinnipedProvider = createBackendModule({ + pluginId: 'auth', + moduleId: 'pinniped-provider', + register(reg) { + reg.registerInit({ + deps: { + providers: authProvidersExtensionPoint, + }, + async init({ providers }) { + providers.registerProvider({ + providerId: 'pinniped', + factory: createOAuthProviderFactory({ + authenticator: pinnipedAuthenticator, + signInResolverFactories: { + ...commonSignInResolvers, + }, + }), + }); + }, + }); + }, +}); diff --git a/plugins/auth-backend/CHANGELOG.md b/plugins/auth-backend/CHANGELOG.md index f2eadd6c3d..8f00fb0e9a 100644 --- a/plugins/auth-backend/CHANGELOG.md +++ b/plugins/auth-backend/CHANGELOG.md @@ -1,5 +1,27 @@ # @backstage/plugin-auth-backend +## 0.19.3-next.2 + +### Patch Changes + +- 2d8f7e82c1: Migrated the Microsoft auth provider to new `@backstage/plugin-auth-backend-module-microsoft-provider` module package. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-auth-backend-module-gcp-iap-provider@0.2.0-next.2 + - @backstage/plugin-auth-backend-module-microsoft-provider@0.1.0-next.0 + - @backstage/plugin-auth-backend-module-github-provider@0.1.3-next.2 + - @backstage/plugin-auth-backend-module-gitlab-provider@0.1.3-next.2 + - @backstage/plugin-auth-backend-module-oauth2-provider@0.1.3-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-auth-backend-module-google-provider@0.1.3-next.2 + ## 0.19.2-next.1 ### Patch Changes diff --git a/plugins/auth-backend/api-report.md b/plugins/auth-backend/api-report.md index 6372c2ee60..41536f2a3f 100644 --- a/plugins/auth-backend/api-report.md +++ b/plugins/auth-backend/api-report.md @@ -538,9 +538,9 @@ export const providers: Readonly<{ | undefined, ) => AuthProviderFactory_2; resolvers: Readonly<{ - emailLocalPartMatchingUserEntityName: () => SignInResolver<unknown>; - emailMatchingUserEntityProfileEmail: () => SignInResolver<unknown>; - emailMatchingUserEntityAnnotation(): SignInResolver<OAuthResult>; + emailMatchingUserEntityProfileEmail: () => SignInResolver_2<OAuthResult>; + emailLocalPartMatchingUserEntityName: () => SignInResolver_2<OAuthResult>; + emailMatchingUserEntityAnnotation: () => SignInResolver_2<OAuthResult>; }>; }>; oauth2: Readonly<{ diff --git a/plugins/auth-backend/config.d.ts b/plugins/auth-backend/config.d.ts index e719468ac1..f8953e1588 100644 --- a/plugins/auth-backend/config.d.ts +++ b/plugins/auth-backend/config.d.ts @@ -179,18 +179,6 @@ export interface Config { }; }; /** @visibility frontend */ - microsoft?: { - [authEnv: string]: { - clientId: string; - /** - * @visibility secret - */ - clientSecret: string; - tenantId: string; - callbackUrl?: string; - }; - }; - /** @visibility frontend */ onelogin?: { [authEnv: string]: { clientId: string; diff --git a/plugins/auth-backend/package.json b/plugins/auth-backend/package.json index 398814564e..355c8eb554 100644 --- a/plugins/auth-backend/package.json +++ b/plugins/auth-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-auth-backend", "description": "A Backstage backend plugin that handles authentication", - "version": "0.19.2-next.1", + "version": "0.19.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -42,6 +42,7 @@ "@backstage/plugin-auth-backend-module-github-provider": "workspace:^", "@backstage/plugin-auth-backend-module-gitlab-provider": "workspace:^", "@backstage/plugin-auth-backend-module-google-provider": "workspace:^", + "@backstage/plugin-auth-backend-module-microsoft-provider": "workspace:^", "@backstage/plugin-auth-backend-module-oauth2-provider": "workspace:^", "@backstage/plugin-auth-node": "workspace:^", "@backstage/plugin-catalog-node": "workspace:^", diff --git a/plugins/auth-backend/src/providers/microsoft/__testUtils__/fake.test.ts b/plugins/auth-backend/src/providers/microsoft/__testUtils__/fake.test.ts deleted file mode 100644 index dee37f0f6b..0000000000 --- a/plugins/auth-backend/src/providers/microsoft/__testUtils__/fake.test.ts +++ /dev/null @@ -1,90 +0,0 @@ -/* - * 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 { FakeMicrosoftAPI } from './fake'; - -describe('FakeMicrosoftAPI', () => { - const api = new FakeMicrosoftAPI(); - - describe('#token', () => { - it('exchanges auth codes', () => { - const { access_token } = api.token( - new URLSearchParams({ - grant_type: 'authorization_code', - code: api.generateAuthCode('User.Read'), - }), - ); - - expect(api.tokenHasScope(access_token, 'User.Read')).toBe(true); - }); - - it('supports scopes for the first requested audience only', () => { - const { access_token } = api.token( - new URLSearchParams({ - grant_type: 'authorization_code', - code: api.generateAuthCode('someaudience/somescope User.Read'), - }), - ); - - expect(api.tokenHasScope(access_token, 'User.Read')).toBe(false); - }); - - it('special openid scopes do not count towards the 1-audience limit', () => { - const { access_token } = api.token( - new URLSearchParams({ - grant_type: 'authorization_code', - code: api.generateAuthCode('openid offline_access User.Read'), - }), - ); - - expect(api.tokenHasScope(access_token, 'User.Read')).toBe(true); - }); - - it('refreshes tokens', () => { - const { access_token } = api.token( - new URLSearchParams({ - grant_type: 'refresh_token', - refresh_token: api.generateRefreshToken( - 'email openid profile User.Read', - ), - }), - ); - - expect( - api.tokenHasScope(access_token, 'email openid profile User.Read'), - ).toBe(true); - }); - it('requires `openid` scope for ID token', () => { - const { id_token } = api.token( - new URLSearchParams({ - grant_type: 'authorization_code', - code: api.generateAuthCode('User.Read'), - }), - ); - - expect(id_token).toBeUndefined(); - }); - it('requires `offline_access` scope for refresh token', () => { - const { refresh_token } = api.token( - new URLSearchParams({ - grant_type: 'authorization_code', - code: api.generateAuthCode('User.Read'), - }), - ); - - expect(refresh_token).toBeUndefined(); - }); - }); -}); diff --git a/plugins/auth-backend/src/providers/microsoft/__testUtils__/fake.ts b/plugins/auth-backend/src/providers/microsoft/__testUtils__/fake.ts deleted file mode 100644 index 9b3ca09c57..0000000000 --- a/plugins/auth-backend/src/providers/microsoft/__testUtils__/fake.ts +++ /dev/null @@ -1,126 +0,0 @@ -/* - * 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 { decodeJwt } from 'jose'; - -type Claims = { aud: string; scp: string }; - -export class FakeMicrosoftAPI { - generateAccessToken(scope: string): string { - return this.tokenWithClaims(this.allClaimsForScope(scope)).access_token; - } - generateAuthCode(scope: string): string { - return this.encodeClaims(this.allClaimsForScope(scope)); - } - generateRefreshToken(scope: string): string { - return this.encodeClaims(this.allClaimsForScope(scope)); - } - token(formData: URLSearchParams): { - access_token: string; - scope: string; - refresh_token?: string; - id_token?: string; - } { - const scopeParameter = formData.get('scope'); - const claims = - (scopeParameter && this.allClaimsForScope(scopeParameter)) ?? - formData.get('grant_type') === 'refresh_token' - ? this.decodeClaims(formData.get('refresh_token')!) - : this.decodeClaims(formData.get('code')!); - return { - ...this.tokenWithClaims(claims), - ...(this.hasScope(claims, 'offline_access') && { - refresh_token: this.encodeClaims(claims), - }), - ...(this.hasScope(claims, 'openid') && { - id_token: 'header.e30K.microsoft', - }), - }; - } - tokenHasScope(token: string, scope: string): boolean { - const { aud, scp } = decodeJwt(token); - return this.hasScope({ aud: aud as string, scp: scp as string }, scope); - } - private tokenWithClaims(claims: Claims): { - access_token: string; - scope: string; - } { - const filteredClaims = { - ...claims, - scp: claims.scp - .split(' ') - .filter(s => s !== 'offline_access') - .join(' '), - }; - return { - access_token: `header.${Buffer.from( - JSON.stringify(filteredClaims), - ).toString('base64')}.signature`, - scope: this.scopeFromClaims(filteredClaims), - }; - } - private allClaimsForScope(scope: string): Claims { - const scopes = scope.split(' ').map(this.parseScope); - const firstAudience = scopes - .map(({ aud }) => aud) - .find(aud => aud !== 'openid'); - return { - aud: firstAudience ?? '00000003-0000-0000-c000-000000000000', - scp: scopes - .filter(({ aud }) => aud === 'openid' || aud === firstAudience) - .map(({ scp }) => scp) - .join(' '), - }; - } - // auth codes and refresh tokens in this fake system are base64-encoded JSON - // strings of claims - private encodeClaims(claims: Claims): string { - return Buffer.from(JSON.stringify(claims)).toString('base64'); - } - private decodeClaims(encoded: string): Claims { - return JSON.parse(Buffer.from(encoded, 'base64').toString()); - } - private hasScope(claims: Claims, scope: string): boolean { - return this.scopeFromClaims(claims).includes(scope); - } - private parseScope(s: string): Claims { - if (s.includes('/')) { - const [aud, scp] = s.split('/'); - return { aud, scp }; - } - switch (s) { - case 'email': - case 'openid': - case 'offline_access': - case 'profile': { - return { aud: 'openid', scp: s }; - } - default: - return { aud: '00000003-0000-0000-c000-000000000000', scp: s }; - } - } - private scopeFromClaims(claims: Claims): string { - return claims.scp - .split(' ') - .map(this.parseScope) - .map(({ aud, scp }) => - aud === 'openid' || - claims.aud === '00000003-0000-0000-c000-000000000000' - ? scp - : `${claims.aud}/${scp}`, - ) - .join(' '); - } -} diff --git a/plugins/auth-backend/src/providers/microsoft/provider.test.ts b/plugins/auth-backend/src/providers/microsoft/provider.test.ts deleted file mode 100644 index 7bbfd085d6..0000000000 --- a/plugins/auth-backend/src/providers/microsoft/provider.test.ts +++ /dev/null @@ -1,450 +0,0 @@ -/* - * 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 { microsoft } from './provider'; -import { getVoidLogger } from '@backstage/backend-common'; -import { setupRequestMockHandlers } from '@backstage/backend-test-utils'; -import { ConfigReader } from '@backstage/config'; -import { rest } from 'msw'; -import { setupServer } from 'msw/node'; -import { AuthProviderRouteHandlers, AuthResolverContext } from '../types'; -import express from 'express'; -import crypto from 'crypto'; -import { FakeMicrosoftAPI } from './__testUtils__/fake'; - -describe('MicrosoftAuthProvider', () => { - const nonce = 'AAAAAAAAAAAAAAAAAAAAAA=='; // 16 bytes of zeros in base64 - const state = Buffer.from( - `nonce=${encodeURIComponent(nonce)}&env=development`, - ).toString('hex'); - const mockBackstageToken = `header.${Buffer.from( - JSON.stringify({ sub: 'user:default/mock' }), - 'utf8', - ).toString('base64')}.backstage`; - - const server = setupServer(); - const microsoftApi = new FakeMicrosoftAPI(); - let provider: AuthProviderRouteHandlers; - let response: jest.Mocked<express.Response>; - - setupRequestMockHandlers(server); - - beforeEach(() => { - provider = microsoft.create({ - signIn: { - resolver: microsoft.resolvers.emailMatchingUserEntityAnnotation(), - }, - })({ - providerId: 'microsoft', - baseUrl: 'http://backstage.test/api/auth', - appUrl: 'http://backstage.test', - isOriginAllowed: _ => true, - globalConfig: { - baseUrl: 'http://backstage.test/api/auth', - appUrl: 'http://backstage.test', - isOriginAllowed: _ => true, - }, - config: new ConfigReader({ - development: { - tenantId: 'tenantId', - clientId: 'clientId', - clientSecret: 'clientSecret', - }, - }), - logger: getVoidLogger(), - resolverContext: { - issueToken: jest.fn(), - findCatalogUser: jest.fn(), - signInWithCatalogUser: async _ => ({ - token: mockBackstageToken, - }), - } as AuthResolverContext, - }) as AuthProviderRouteHandlers; - - server.use( - rest.post( - 'https://login.microsoftonline.com/tenantId/oauth2/v2.0/token', - async (req, res, ctx) => { - return res( - ctx.json({ - ...microsoftApi.token(new URLSearchParams(await req.text())), - token_type: 'Bearer', - expires_in: 123, - ext_expires_in: 123, - }), - ); - }, - ), - rest.get('https://graph.microsoft.com/v1.0/me/', (req, res, ctx) => { - if ( - !microsoftApi.tokenHasScope( - req.headers.get('authorization')!.replace(/^Bearer /, ''), - 'User.Read', - ) - ) { - return res(ctx.status(403)); - } - return res( - ctx.json({ - id: 'conrad', - displayName: 'Conrad', - surname: 'Ribas', - givenName: 'Francisco', - mail: 'conrad@example.com', - }), - ); - }), - rest.get( - 'https://graph.microsoft.com/v1.0/me/photos/*', - async (req, res, ctx) => { - if ( - !microsoftApi.tokenHasScope( - req.headers.get('authorization')!.replace(/^Bearer /, ''), - 'User.Read', - ) - ) { - return res(ctx.status(403)); - } - const imageBuffer = new Uint8Array([104, 111, 119, 100, 121]).buffer; - return res( - ctx.set('Content-Length', imageBuffer.byteLength.toString()), - ctx.set('Content-Type', 'image/jpeg'), - ctx.body(imageBuffer), - ); - }, - ), - ); - response = { - cookie: jest.fn(), - end: jest.fn(), - json: jest.fn(), - setHeader: jest.fn(), - status: jest.fn(), - } as unknown as jest.Mocked<express.Response>; - response.status.mockReturnValue(response); - }); - - describe('#start', () => { - const randomBytes = jest.spyOn( - crypto, - 'randomBytes', - ) as unknown as jest.MockedFunction<(size: number) => Buffer>; - - afterEach(() => { - randomBytes.mockRestore(); - }); - - it('redirects to authorize URL', async () => { - randomBytes.mockReturnValue(Buffer.from(nonce, 'base64')); - - await provider.start( - { - query: { - env: 'development', - scope: 'email openid profile User.Read', - }, - } as unknown as express.Request, - response, - ); - - expect(response.setHeader).toHaveBeenCalledWith( - 'Location', - 'https://login.microsoftonline.com/tenantId/oauth2/v2.0/authorize' + - '?response_type=code' + - `&redirect_uri=${encodeURIComponent( - 'http://backstage.test/api/auth/microsoft/handler/frame', - )}` + - `&scope=${encodeURIComponent('email openid profile User.Read')}` + - `&state=${state}` + - '&client_id=clientId', - ); - }); - }); - - describe('#handle', () => { - it('returns provider info and profile with photo data', async () => { - await provider.frameHandler( - { - query: { - env: 'development', - code: microsoftApi.generateAuthCode( - 'email openid profile User.Read', - ), - state, - }, - cookies: { - 'microsoft-nonce': nonce, - }, - } as unknown as express.Request, - response, - ); - - expect(response.end).toHaveBeenCalledWith( - expect.stringContaining( - encodeURIComponent( - JSON.stringify({ - type: 'authorization_response', - response: { - providerInfo: { - accessToken: microsoftApi.generateAccessToken( - 'email openid profile User.Read', - ), - scope: 'email openid profile User.Read', - expiresInSeconds: 123, - idToken: 'header.e30K.microsoft', - }, - profile: { - email: 'conrad@example.com', - picture: 'data:image/jpeg;base64,aG93ZHk=', - displayName: 'Conrad', - }, - backstageIdentity: { - token: mockBackstageToken, - identity: { - type: 'user', - userEntityRef: 'user:default/mock', - ownershipEntityRefs: [], - }, - }, - }, - }), - ), - ), - ); - }); - - it('returns access token for non-microsoft graph scope', async () => { - await provider.frameHandler( - { - query: { - env: 'development', - code: microsoftApi.generateAuthCode('aks-audience/user.read'), - state, - }, - cookies: { - 'microsoft-nonce': nonce, - }, - } as unknown as express.Request, - response, - ); - - expect(response.end).toHaveBeenCalledWith( - expect.stringContaining( - encodeURIComponent( - JSON.stringify({ - type: 'authorization_response', - response: { - providerInfo: { - accessToken: microsoftApi.generateAccessToken( - 'aks-audience/user.read', - ), - scope: 'aks-audience/user.read', - expiresInSeconds: 123, - }, - profile: {}, - }, - }), - ), - ), - ); - }); - - it('sets refresh token', async () => { - await provider.frameHandler( - { - query: { - env: 'development', - code: microsoftApi.generateAuthCode( - 'email offline_access openid profile User.Read', - ), - state, - }, - cookies: { - 'microsoft-nonce': nonce, - }, - } as unknown as express.Request, - response, - ); - - expect(response.cookie).toHaveBeenCalledWith( - 'microsoft-refresh-token', - microsoftApi.generateRefreshToken( - 'email offline_access openid profile User.Read', - ), - { - domain: 'backstage.test', - httpOnly: true, - maxAge: 86400000000, - path: '/api/auth/microsoft', - sameSite: 'lax', - secure: false, - }, - ); - }); - - it('omits photo data when fetching it fails', async () => { - server.use( - rest.get('https://graph.microsoft.com/v1.0/me/photos/*', (_, res) => - res.networkError('remote hung up'), - ), - ); - - await provider.frameHandler( - { - query: { - env: 'development', - code: microsoftApi.generateAuthCode( - 'email openid profile User.Read', - ), - state, - }, - cookies: { - 'microsoft-nonce': nonce, - }, - } as unknown as express.Request, - response, - ); - - expect(response.end).toHaveBeenCalledWith( - expect.stringContaining( - encodeURIComponent( - JSON.stringify({ - type: 'authorization_response', - response: { - providerInfo: { - accessToken: microsoftApi.generateAccessToken( - 'email openid profile User.Read', - ), - scope: 'email openid profile User.Read', - expiresInSeconds: 123, - idToken: 'header.e30K.microsoft', - }, - profile: { - email: 'conrad@example.com', - displayName: 'Conrad', - }, - backstageIdentity: { - token: mockBackstageToken, - identity: { - type: 'user', - userEntityRef: 'user:default/mock', - ownershipEntityRefs: [], - }, - }, - }, - }), - ), - ), - ); - }); - }); - - describe('#refresh', () => { - it('returns provider info and profile with photo data', async () => { - await provider.refresh!( - { - query: { - env: 'development', - scope: 'email openid profile User.Read', - }, - header: jest.fn(_ => 'XMLHttpRequest'), - cookies: { - 'microsoft-refresh-token': microsoftApi.generateRefreshToken( - 'email openid profile User.Read', - ), - }, - get: jest.fn(), - } as unknown as express.Request, - response, - ); - - expect(response.json).toHaveBeenCalledWith( - expect.objectContaining({ - providerInfo: { - accessToken: microsoftApi.generateAccessToken( - 'email openid profile User.Read', - ), - scope: 'email openid profile User.Read', - expiresInSeconds: 123, - idToken: 'header.e30K.microsoft', - }, - profile: { - email: 'conrad@example.com', - picture: 'data:image/jpeg;base64,aG93ZHk=', - displayName: 'Conrad', - }, - }), - ); - }); - - it('returns access token for non-microsoft graph scope', async () => { - await provider.refresh!( - { - query: { - env: 'development', - scope: 'aks-audience/user.read', - }, - header: jest.fn(_ => 'XMLHttpRequest'), - cookies: { - 'microsoft-refresh-token': microsoftApi.generateRefreshToken( - 'aks-audience/user.read', - ), - }, - get: jest.fn(), - } as unknown as express.Request, - response, - ); - - expect(response.json).toHaveBeenCalledWith({ - providerInfo: { - accessToken: microsoftApi.generateAccessToken( - 'aks-audience/user.read', - ), - expiresInSeconds: 123, - scope: 'aks-audience/user.read', - }, - profile: {}, - }); - }); - - it('returns backstage identity', async () => { - await provider.refresh!( - { - query: { - env: 'development', - scope: 'email openid profile User.Read', - }, - header: jest.fn(_ => 'XMLHttpRequest'), - cookies: { - 'microsoft-refresh-token': microsoftApi.generateRefreshToken( - 'email openid profile User.Read', - ), - }, - get: jest.fn(), - } as unknown as express.Request, - response, - ); - - expect(response.json).toHaveBeenCalledWith( - expect.objectContaining({ - backstageIdentity: expect.objectContaining({ - token: mockBackstageToken, - }), - }), - ); - }); - }); -}); diff --git a/plugins/auth-backend/src/providers/microsoft/provider.ts b/plugins/auth-backend/src/providers/microsoft/provider.ts index 8fc8459f10..8947c7432b 100644 --- a/plugins/auth-backend/src/providers/microsoft/provider.ts +++ b/plugins/auth-backend/src/providers/microsoft/provider.ts @@ -14,218 +14,25 @@ * limitations under the License. */ -import express from 'express'; -import passport from 'passport'; -import { Strategy as MicrosoftStrategy } from 'passport-microsoft'; -import { - encodeState, - OAuthAdapter, - OAuthEnvironmentHandler, - OAuthHandlers, - OAuthProviderOptions, - OAuthRefreshRequest, - OAuthResponse, - OAuthResult, - OAuthStartRequest, -} from '../../lib/oauth'; -import { - executeFetchUserProfileStrategy, - executeFrameHandlerStrategy, - executeRedirectStrategy, - executeRefreshTokenStrategy, - makeProfileInfo, - PassportDoneCallback, -} from '../../lib/passport'; -import { - AuthHandler, - OAuthStartResponse, - SignInResolver, - AuthResolverContext, -} from '../types'; +import { SignInResolver, AuthHandler } from '../types'; +import { OAuthResult } from '../../lib/oauth'; import { createAuthProviderIntegration } from '../createAuthProviderIntegration'; import { - commonByEmailLocalPartResolver, - commonByEmailResolver, -} from '../resolvers'; -import { LoggerService } from '@backstage/backend-plugin-api'; -import fetch from 'node-fetch'; -import { decodeJwt } from 'jose'; -import { Profile as PassportProfile } from 'passport'; -import { BACKSTAGE_SESSION_EXPIRATION } from '../../lib/session'; - -type PrivateInfo = { - refreshToken: string; -}; - -type Options = OAuthProviderOptions & { - signInResolver?: SignInResolver<OAuthResult>; - authHandler: AuthHandler<OAuthResult>; - logger: LoggerService; - resolverContext: AuthResolverContext; - authorizationUrl?: string; - tokenUrl?: string; -}; - -export class MicrosoftAuthProvider implements OAuthHandlers { - private readonly _strategy: MicrosoftStrategy; - private readonly signInResolver?: SignInResolver<OAuthResult>; - private readonly authHandler: AuthHandler<OAuthResult>; - private readonly logger: LoggerService; - private readonly resolverContext: AuthResolverContext; - - constructor(options: Options) { - this.signInResolver = options.signInResolver; - this.authHandler = options.authHandler; - this.logger = options.logger; - this.resolverContext = options.resolverContext; - - this._strategy = new MicrosoftStrategy( - { - clientID: options.clientId, - clientSecret: options.clientSecret, - callbackURL: options.callbackUrl, - authorizationURL: options.authorizationUrl, - tokenURL: options.tokenUrl, - passReqToCallback: false, - skipUserProfile: ( - accessToken: string, - done: (err: unknown, skip: boolean) => void, - ) => { - done(null, this.skipUserProfile(accessToken)); - }, - }, - ( - accessToken: any, - refreshToken: any, - params: any, - fullProfile: passport.Profile, - done: PassportDoneCallback<OAuthResult, PrivateInfo>, - ) => { - done(undefined, { fullProfile, accessToken, params }, { refreshToken }); - }, - ); - } - - private skipUserProfile = (accessToken: string): boolean => { - const { aud, scp } = decodeJwt(accessToken); - const hasGraphReadScope = - aud === '00000003-0000-0000-c000-000000000000' && - (scp as string) - .split(' ') - .map(s => s.toLowerCase()) - .includes('user.read'); - return !hasGraphReadScope; - }; - - async start(req: OAuthStartRequest): Promise<OAuthStartResponse> { - return await executeRedirectStrategy(req, this._strategy, { - scope: req.scope, - state: encodeState(req.state), - }); - } - - async handler(req: express.Request) { - const { result, privateInfo } = await executeFrameHandlerStrategy< - OAuthResult, - PrivateInfo - >(req, this._strategy); - - return { - response: await this.handleResult(result), - refreshToken: privateInfo.refreshToken, - }; - } - - async refresh(req: OAuthRefreshRequest) { - const { accessToken, refreshToken, params } = - await executeRefreshTokenStrategy( - this._strategy, - req.refreshToken, - req.scope, - ); - - return { - response: await this.handleResult({ - params, - accessToken, - ...(!this.skipUserProfile(accessToken) && { - fullProfile: await executeFetchUserProfileStrategy( - this._strategy, - accessToken, - ), - }), - }), - refreshToken, - }; - } - - private async handleResult(result: { - fullProfile?: PassportProfile; - params: { - id_token?: string; - scope: string; - expires_in: number; - }; - accessToken: string; - refreshToken?: string; - }): Promise<OAuthResponse> { - let profile = {}; - if (result.fullProfile) { - const photo = await this.getUserPhoto(result.accessToken); - result.fullProfile.photos = photo ? [{ value: photo }] : undefined; - ({ profile } = await this.authHandler( - result as OAuthResult, - this.resolverContext, - )); - } - - const expiresInSeconds = - result.params.expires_in === undefined - ? BACKSTAGE_SESSION_EXPIRATION - : Math.min(result.params.expires_in, BACKSTAGE_SESSION_EXPIRATION); - - return { - providerInfo: { - accessToken: result.accessToken, - scope: result.params.scope, - expiresInSeconds, - ...{ idToken: result.params.id_token }, - }, - profile, - ...(result.fullProfile && - this.signInResolver && { - backstageIdentity: await this.signInResolver( - { result: result as OAuthResult, profile }, - this.resolverContext, - ), - }), - }; - } - - private async getUserPhoto(accessToken: string): Promise<string | undefined> { - try { - const res = await fetch( - 'https://graph.microsoft.com/v1.0/me/photos/48x48/$value', - { - headers: { - Authorization: `Bearer ${accessToken}`, - }, - }, - ); - const data = await res.buffer(); - - return `data:image/jpeg;base64,${data.toString('base64')}`; - } catch (error) { - this.logger.warn( - `Could not retrieve user profile photo from Microsoft Graph API: ${error}`, - ); - return undefined; - } - } -} + commonSignInResolvers, + createOAuthProviderFactory, +} from '@backstage/plugin-auth-node'; +import { + adaptLegacyOAuthHandler, + adaptLegacyOAuthSignInResolver, + adaptOAuthSignInResolverToLegacy, +} from '../../lib/legacy'; +import { + microsoftAuthenticator, + microsoftSignInResolvers, +} from '@backstage/plugin-auth-backend-module-microsoft-provider'; /** - * Auth provider integration for Microsoft auth + * Auth provider integration for GitLab auth * * @public */ @@ -241,75 +48,21 @@ export const microsoft = createAuthProviderIntegration({ * Configure sign-in for this provider, without it the provider can not be used to sign users in. */ signIn?: { - /** - * Maps an auth result to a Backstage identity for the user. - */ resolver: SignInResolver<OAuthResult>; }; }) { - return ({ providerId, globalConfig, config, logger, resolverContext }) => - OAuthEnvironmentHandler.mapConfig(config, envConfig => { - const clientId = envConfig.getString('clientId'); - const clientSecret = envConfig.getString('clientSecret'); - const tenantId = envConfig.getString('tenantId'); - - const customCallbackUrl = envConfig.getOptionalString('callbackUrl'); - const callbackUrl = - customCallbackUrl || - `${globalConfig.baseUrl}/${providerId}/handler/frame`; - const authorizationUrl = `https://login.microsoftonline.com/${tenantId}/oauth2/v2.0/authorize`; - const tokenUrl = `https://login.microsoftonline.com/${tenantId}/oauth2/v2.0/token`; - - const authHandler: AuthHandler<OAuthResult> = options?.authHandler - ? options.authHandler - : async ({ fullProfile, params }) => ({ - profile: makeProfileInfo(fullProfile ?? {}, params.id_token), - }); - - const provider = new MicrosoftAuthProvider({ - clientId, - clientSecret, - callbackUrl, - authorizationUrl, - tokenUrl, - authHandler, - signInResolver: options?.signIn?.resolver, - logger, - resolverContext, - }); - - return OAuthAdapter.fromConfig(globalConfig, provider, { - providerId, - callbackUrl, - }); - }); - }, - resolvers: { - /** - * Looks up the user by matching their email local part to the entity name. - */ - emailLocalPartMatchingUserEntityName: () => commonByEmailLocalPartResolver, - /** - * Looks up the user by matching their email to the entity email. - */ - emailMatchingUserEntityProfileEmail: () => commonByEmailResolver, - /** - * Looks up the user by matching their email to the `microsoft.com/email` annotation. - */ - emailMatchingUserEntityAnnotation(): SignInResolver<OAuthResult> { - return async (info, ctx) => { - const { profile } = info; - - if (!profile.email) { - throw new Error('Microsoft profile contained no email'); - } - - return ctx.signInWithCatalogUser({ - annotations: { - 'microsoft.com/email': profile.email, - }, - }); - }; - }, + return createOAuthProviderFactory({ + authenticator: microsoftAuthenticator, + profileTransform: adaptLegacyOAuthHandler(options?.authHandler), + signInResolver: adaptLegacyOAuthSignInResolver(options?.signIn?.resolver), + }); }, + resolvers: adaptOAuthSignInResolverToLegacy({ + emailLocalPartMatchingUserEntityName: + commonSignInResolvers.emailLocalPartMatchingUserEntityName(), + emailMatchingUserEntityProfileEmail: + commonSignInResolvers.emailMatchingUserEntityProfileEmail(), + emailMatchingUserEntityAnnotation: + microsoftSignInResolvers.emailMatchingUserEntityAnnotation(), + }), }); diff --git a/plugins/auth-backend/src/service/standaloneServer.ts b/plugins/auth-backend/src/service/standaloneServer.ts index abda3a341c..0c311d5949 100644 --- a/plugins/auth-backend/src/service/standaloneServer.ts +++ b/plugins/auth-backend/src/service/standaloneServer.ts @@ -18,7 +18,7 @@ import { createServiceBuilder, loadBackendConfig, ServerTokenManager, - SingleHostDiscovery, + HostDiscovery, useHotMemoize, } from '@backstage/backend-common'; import { Server } from 'http'; @@ -35,7 +35,7 @@ export async function startStandaloneServer( ): Promise<Server> { const logger = options.logger.child({ service: 'auth-backend' }); const config = await loadBackendConfig({ logger, argv: process.argv }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const database = useHotMemoize(module, () => { const knex = Knex({ diff --git a/plugins/auth-node/CHANGELOG.md b/plugins/auth-node/CHANGELOG.md index 2dcd93dc51..9c5bf12cac 100644 --- a/plugins/auth-node/CHANGELOG.md +++ b/plugins/auth-node/CHANGELOG.md @@ -1,5 +1,23 @@ # @backstage/plugin-auth-node +## 0.4.0-next.2 + +### Minor Changes + +- 6f142d5356: **BREAKING**: The recently introduced `ProxyAuthenticator.initialize()` method is no longer `async` to match the way the OAuth equivalent is implemented. + +### Patch Changes + +- 8b8b1d23ae: Fixed cookie persisted scope not returned in OAuth refresh handler response. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.3.2-next.1 ### Patch Changes diff --git a/plugins/auth-node/api-report.md b/plugins/auth-node/api-report.md index a782847d7a..4b1a8a1f27 100644 --- a/plugins/auth-node/api-report.md +++ b/plugins/auth-node/api-report.md @@ -399,6 +399,7 @@ export type OAuthState = { scope?: string; redirectUrl?: string; flow?: string; + audience?: string; }; // @public (undocumented) @@ -550,7 +551,7 @@ export interface ProxyAuthenticator<TContext, TResult> { // (undocumented) defaultProfileTransform: ProfileTransform<TResult>; // (undocumented) - initialize(ctx: { config: Config }): Promise<TContext>; + initialize(ctx: { config: Config }): TContext; } // @public (undocumented) diff --git a/plugins/auth-node/package.json b/plugins/auth-node/package.json index 91ae1b5e6a..9174e91d4c 100644 --- a/plugins/auth-node/package.json +++ b/plugins/auth-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-auth-node", - "version": "0.3.2-next.1", + "version": "0.4.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/auth-node/src/oauth/state.ts b/plugins/auth-node/src/oauth/state.ts index fc747d08a5..28f7d2fd2e 100644 --- a/plugins/auth-node/src/oauth/state.ts +++ b/plugins/auth-node/src/oauth/state.ts @@ -29,6 +29,7 @@ export type OAuthState = { scope?: string; redirectUrl?: string; flow?: string; + audience?: string; }; /** @public */ diff --git a/plugins/auth-node/src/proxy/types.ts b/plugins/auth-node/src/proxy/types.ts index 969b022abb..0f52feaac4 100644 --- a/plugins/auth-node/src/proxy/types.ts +++ b/plugins/auth-node/src/proxy/types.ts @@ -21,7 +21,7 @@ import { ProfileTransform } from '../types'; /** @public */ export interface ProxyAuthenticator<TContext, TResult> { defaultProfileTransform: ProfileTransform<TResult>; - initialize(ctx: { config: Config }): Promise<TContext>; + initialize(ctx: { config: Config }): TContext; authenticate( options: { req: Request }, ctx: TContext, diff --git a/plugins/azure-devops-backend/CHANGELOG.md b/plugins/azure-devops-backend/CHANGELOG.md index f38133089c..7303ae4de7 100644 --- a/plugins/azure-devops-backend/CHANGELOG.md +++ b/plugins/azure-devops-backend/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-azure-devops-backend +## 0.4.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-azure-devops-common@0.3.1 + ## 0.4.2-next.1 ### Patch Changes diff --git a/plugins/azure-devops-backend/package.json b/plugins/azure-devops-backend/package.json index 1da72ae8dc..7a81effc70 100644 --- a/plugins/azure-devops-backend/package.json +++ b/plugins/azure-devops-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-azure-devops-backend", - "version": "0.4.2-next.1", + "version": "0.4.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/azure-devops/CHANGELOG.md b/plugins/azure-devops/CHANGELOG.md index eee90fe4b2..c136b8c5c7 100644 --- a/plugins/azure-devops/CHANGELOG.md +++ b/plugins/azure-devops/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-azure-devops +## 0.3.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-azure-devops-common@0.3.1 + ## 0.3.7-next.1 ### Patch Changes diff --git a/plugins/azure-devops/package.json b/plugins/azure-devops/package.json index f47811bf58..45dccce464 100644 --- a/plugins/azure-devops/package.json +++ b/plugins/azure-devops/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-azure-devops", - "version": "0.3.7-next.1", + "version": "0.3.7-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/azure-sites-backend/CHANGELOG.md b/plugins/azure-sites-backend/CHANGELOG.md index fe92430af1..08309c6073 100644 --- a/plugins/azure-sites-backend/CHANGELOG.md +++ b/plugins/azure-sites-backend/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-azure-sites-backend +## 0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-azure-sites-common@0.1.1 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/azure-sites-backend/package.json b/plugins/azure-sites-backend/package.json index d1c9c6c2b7..5063a671d2 100644 --- a/plugins/azure-sites-backend/package.json +++ b/plugins/azure-sites-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-azure-sites-backend", - "version": "0.1.15-next.1", + "version": "0.1.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/azure-sites/CHANGELOG.md b/plugins/azure-sites/CHANGELOG.md index 3f044f2243..c4746dba08 100644 --- a/plugins/azure-sites/CHANGELOG.md +++ b/plugins/azure-sites/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-azure-sites +## 0.1.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-azure-sites-common@0.1.1 + ## 0.1.14-next.1 ### Patch Changes diff --git a/plugins/azure-sites/package.json b/plugins/azure-sites/package.json index d7a4826be1..ee97dae742 100644 --- a/plugins/azure-sites/package.json +++ b/plugins/azure-sites/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-azure-sites", - "version": "0.1.14-next.1", + "version": "0.1.14-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -56,8 +56,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/badges-backend/CHANGELOG.md b/plugins/badges-backend/CHANGELOG.md index 3081811eca..40fa6773f0 100644 --- a/plugins/badges-backend/CHANGELOG.md +++ b/plugins/badges-backend/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-badges-backend +## 0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.3.2-next.1 ### Patch Changes diff --git a/plugins/badges-backend/package.json b/plugins/badges-backend/package.json index 4137092f17..e539075ff2 100644 --- a/plugins/badges-backend/package.json +++ b/plugins/badges-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-badges-backend", "description": "A Backstage backend plugin that generates README badges for your entities", - "version": "0.3.2-next.1", + "version": "0.3.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/badges-backend/src/service/router-obfuscated.test.ts b/plugins/badges-backend/src/service/router-obfuscated.test.ts index 3c9ec0d2b6..49d0368c7f 100644 --- a/plugins/badges-backend/src/service/router-obfuscated.test.ts +++ b/plugins/badges-backend/src/service/router-obfuscated.test.ts @@ -20,7 +20,7 @@ import { getVoidLogger, PluginEndpointDiscovery, ServerTokenManager, - SingleHostDiscovery, + HostDiscovery, } from '@backstage/backend-common'; import { CatalogApi } from '@backstage/catalog-client'; import type { Entity } from '@backstage/catalog-model'; @@ -138,7 +138,7 @@ describe('createRouter', () => { }; beforeAll(async () => { - discovery = SingleHostDiscovery.fromConfig(config); + discovery = HostDiscovery.fromConfig(config); const tokenManager = ServerTokenManager.noop(); const router = await createRouter({ badgeBuilder, diff --git a/plugins/badges-backend/src/service/router.test.ts b/plugins/badges-backend/src/service/router.test.ts index 2ecae6b452..6ccb8e3be7 100644 --- a/plugins/badges-backend/src/service/router.test.ts +++ b/plugins/badges-backend/src/service/router.test.ts @@ -20,7 +20,7 @@ import { getVoidLogger, PluginEndpointDiscovery, ServerTokenManager, - SingleHostDiscovery, + HostDiscovery, } from '@backstage/backend-common'; import { CatalogApi } from '@backstage/catalog-client'; import type { Entity } from '@backstage/catalog-model'; @@ -113,7 +113,7 @@ describe('createRouter', () => { }, ); - discovery = SingleHostDiscovery.fromConfig(config); + discovery = HostDiscovery.fromConfig(config); const tokenManager = ServerTokenManager.noop(); const router = await createRouter({ badgeBuilder, diff --git a/plugins/badges-backend/src/service/standaloneServer.ts b/plugins/badges-backend/src/service/standaloneServer.ts index b07e1fa3b1..75185c4aef 100644 --- a/plugins/badges-backend/src/service/standaloneServer.ts +++ b/plugins/badges-backend/src/service/standaloneServer.ts @@ -20,7 +20,7 @@ import { createServiceBuilder, loadBackendConfig, ServerTokenManager, - SingleHostDiscovery, + HostDiscovery, useHotMemoize, } from '@backstage/backend-common'; import { createRouter } from './router'; @@ -39,7 +39,7 @@ export async function startStandaloneServer( ): Promise<Server> { const logger = options.logger.child({ service: 'badges-backend' }); const config = await loadBackendConfig({ logger, argv: process.argv }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const database = useHotMemoize(module, () => { return Knex({ client: 'better-sqlite3', diff --git a/plugins/badges/CHANGELOG.md b/plugins/badges/CHANGELOG.md index c20dd1af3e..75de6d7e62 100644 --- a/plugins/badges/CHANGELOG.md +++ b/plugins/badges/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-badges +## 0.2.49-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.2.49-next.1 ### Patch Changes diff --git a/plugins/badges/package.json b/plugins/badges/package.json index d0565cdaf9..e52a8a1c3c 100644 --- a/plugins/badges/package.json +++ b/plugins/badges/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-badges", "description": "A Backstage plugin that generates README badges for your entities", - "version": "0.2.49-next.1", + "version": "0.2.49-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -52,7 +52,7 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.16.5" + "@testing-library/jest-dom": "^6.0.0" }, "files": [ "dist" diff --git a/plugins/bazaar-backend/CHANGELOG.md b/plugins/bazaar-backend/CHANGELOG.md index 3f3bfb6eaf..8561a42918 100644 --- a/plugins/bazaar-backend/CHANGELOG.md +++ b/plugins/bazaar-backend/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-bazaar-backend +## 0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.3.2-next.1 ### Patch Changes diff --git a/plugins/bazaar-backend/package.json b/plugins/bazaar-backend/package.json index 28358525ee..ff466356ce 100644 --- a/plugins/bazaar-backend/package.json +++ b/plugins/bazaar-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-bazaar-backend", - "version": "0.3.2-next.1", + "version": "0.3.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/bazaar/CHANGELOG.md b/plugins/bazaar/CHANGELOG.md index d7c48b8802..28af791ac4 100644 --- a/plugins/bazaar/CHANGELOG.md +++ b/plugins/bazaar/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-bazaar +## 0.2.17-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/cli@0.23.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + ## 0.2.17-next.1 ### Patch Changes diff --git a/plugins/bazaar/package.json b/plugins/bazaar/package.json index 4a6ac9530d..b035ec8fd9 100644 --- a/plugins/bazaar/package.json +++ b/plugins/bazaar/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-bazaar", - "version": "0.2.17-next.1", + "version": "0.2.17-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -43,7 +43,7 @@ "@material-ui/icons": "^4.9.1", "@material-ui/lab": "4.0.0-alpha.61", "@material-ui/pickers": "^3.3.10", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@types/react": "^16.13.1 || ^17.0.0", "luxon": "^3.0.0", "material-ui-search-bar": "^1.0.0", @@ -58,7 +58,7 @@ "devDependencies": { "@backstage/cli": "workspace:^", "@backstage/dev-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1" + "@testing-library/jest-dom": "^6.0.0" }, "files": [ "dist" diff --git a/plugins/bitbucket-cloud-common/CHANGELOG.md b/plugins/bitbucket-cloud-common/CHANGELOG.md index 439fda1b41..c7fc10f98f 100644 --- a/plugins/bitbucket-cloud-common/CHANGELOG.md +++ b/plugins/bitbucket-cloud-common/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-bitbucket-cloud-common +## 0.2.13-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/integration@1.7.1-next.1 + ## 0.2.13-next.0 ### Patch Changes diff --git a/plugins/bitbucket-cloud-common/package.json b/plugins/bitbucket-cloud-common/package.json index 5a109f3fb5..63c197ecbd 100644 --- a/plugins/bitbucket-cloud-common/package.json +++ b/plugins/bitbucket-cloud-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-bitbucket-cloud-common", "description": "Common functionalities for bitbucket-cloud plugins", - "version": "0.2.13-next.0", + "version": "0.2.13-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/bitrise/CHANGELOG.md b/plugins/bitrise/CHANGELOG.md index 6a1c85393c..814ef241c2 100644 --- a/plugins/bitrise/CHANGELOG.md +++ b/plugins/bitrise/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-bitrise +## 0.1.52-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.1.52-next.1 ### Patch Changes diff --git a/plugins/bitrise/package.json b/plugins/bitrise/package.json index bc88d84191..5a00a4e4b8 100644 --- a/plugins/bitrise/package.json +++ b/plugins/bitrise/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-bitrise", "description": "A Backstage plugin that integrates towards Bitrise", - "version": "0.1.52-next.1", + "version": "0.1.52-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -55,8 +55,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/recharts": "^1.8.15", diff --git a/plugins/catalog-backend-module-aws/CHANGELOG.md b/plugins/catalog-backend-module-aws/CHANGELOG.md index cba33bfb38..8db117460c 100644 --- a/plugins/catalog-backend-module-aws/CHANGELOG.md +++ b/plugins/catalog-backend-module-aws/CHANGELOG.md @@ -1,5 +1,23 @@ # @backstage/plugin-catalog-backend-module-aws +## 0.2.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + ## 0.2.8-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-aws/package.json b/plugins/catalog-backend-module-aws/package.json index c4891dd2b7..246def8c94 100644 --- a/plugins/catalog-backend-module-aws/package.json +++ b/plugins/catalog-backend-module-aws/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-aws", "description": "A Backstage catalog backend module that helps integrate towards AWS", - "version": "0.2.8-next.1", + "version": "0.2.9-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-azure/CHANGELOG.md b/plugins/catalog-backend-module-azure/CHANGELOG.md index 6d1613bf1e..57cfff7cb2 100644 --- a/plugins/catalog-backend-module-azure/CHANGELOG.md +++ b/plugins/catalog-backend-module-azure/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-catalog-backend-module-azure +## 0.1.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + ## 0.1.24-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-azure/package.json b/plugins/catalog-backend-module-azure/package.json index f8849b4925..f7353a1f37 100644 --- a/plugins/catalog-backend-module-azure/package.json +++ b/plugins/catalog-backend-module-azure/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-azure", "description": "A Backstage catalog backend module that helps integrate towards Azure", - "version": "0.1.24-next.1", + "version": "0.1.25-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-bitbucket-cloud/CHANGELOG.md b/plugins/catalog-backend-module-bitbucket-cloud/CHANGELOG.md index 4a989d8214..bfd363123a 100644 --- a/plugins/catalog-backend-module-bitbucket-cloud/CHANGELOG.md +++ b/plugins/catalog-backend-module-bitbucket-cloud/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-catalog-backend-module-bitbucket-cloud +## 0.1.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-bitbucket-cloud-common@0.2.13-next.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.1.20-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-bitbucket-cloud/package.json b/plugins/catalog-backend-module-bitbucket-cloud/package.json index 40f83d3717..5f8acc82ca 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.1.20-next.1", + "version": "0.1.21-next.2", "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 db98df3fc1..4501171eda 100644 --- a/plugins/catalog-backend-module-bitbucket-server/CHANGELOG.md +++ b/plugins/catalog-backend-module-bitbucket-server/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-catalog-backend-module-bitbucket-server +## 0.1.19-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.1.18-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-bitbucket-server/package.json b/plugins/catalog-backend-module-bitbucket-server/package.json index d86127555f..1e937da6ea 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.18-next.1", + "version": "0.1.19-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-bitbucket/CHANGELOG.md b/plugins/catalog-backend-module-bitbucket/CHANGELOG.md index 756ad9f1dd..ffca76bddc 100644 --- a/plugins/catalog-backend-module-bitbucket/CHANGELOG.md +++ b/plugins/catalog-backend-module-bitbucket/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-catalog-backend-module-bitbucket +## 0.2.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-bitbucket-cloud-common@0.2.13-next.1 + ## 0.2.20-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-bitbucket/package.json b/plugins/catalog-backend-module-bitbucket/package.json index 41827dc369..a85596ea32 100644 --- a/plugins/catalog-backend-module-bitbucket/package.json +++ b/plugins/catalog-backend-module-bitbucket/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-bitbucket", "description": "A Backstage catalog backend module that helps integrate towards Bitbucket", - "version": "0.2.20-next.1", + "version": "0.2.21-next.2", "deprecated": true, "main": "src/index.ts", "types": "src/index.ts", diff --git a/plugins/catalog-backend-module-gcp/CHANGELOG.md b/plugins/catalog-backend-module-gcp/CHANGELOG.md index 0b50b8bf3b..e9509a5d02 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.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.1.5-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-gcp/package.json b/plugins/catalog-backend-module-gcp/package.json index dc3ae7395d..cf297b186d 100644 --- a/plugins/catalog-backend-module-gcp/package.json +++ b/plugins/catalog-backend-module-gcp/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-gcp", "description": "A Backstage catalog backend module that helps integrate towards GCP", - "version": "0.1.5-next.1", + "version": "0.1.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-gerrit/CHANGELOG.md b/plugins/catalog-backend-module-gerrit/CHANGELOG.md index cbfd993b9f..a6b8cb8167 100644 --- a/plugins/catalog-backend-module-gerrit/CHANGELOG.md +++ b/plugins/catalog-backend-module-gerrit/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-catalog-backend-module-gerrit +## 0.1.22-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.1.21-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-gerrit/package.json b/plugins/catalog-backend-module-gerrit/package.json index 9690978a3b..d4baf186d0 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.21-next.1", + "version": "0.1.22-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-github-org/.eslintrc.js b/plugins/catalog-backend-module-github-org/.eslintrc.js new file mode 100644 index 0000000000..e2a53a6ad2 --- /dev/null +++ b/plugins/catalog-backend-module-github-org/.eslintrc.js @@ -0,0 +1 @@ +module.exports = require('@backstage/cli/config/eslint-factory')(__dirname); diff --git a/plugins/catalog-backend-module-github-org/CHANGELOG.md b/plugins/catalog-backend-module-github-org/CHANGELOG.md new file mode 100644 index 0000000000..7dbac7fcc5 --- /dev/null +++ b/plugins/catalog-backend-module-github-org/CHANGELOG.md @@ -0,0 +1,17 @@ +# @backstage/plugin-catalog-backend-module-github-org + +## 0.1.0-next.0 + +### Minor Changes + +- c101e683d5: Added `catalogModuleGithubOrgEntityProvider` to ingest users and teams from multiple Github organizations. + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-catalog-backend-module-github@0.4.4-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 diff --git a/plugins/catalog-backend-module-github-org/README.md b/plugins/catalog-backend-module-github-org/README.md new file mode 100644 index 0000000000..6b03dc299d --- /dev/null +++ b/plugins/catalog-backend-module-github-org/README.md @@ -0,0 +1,5 @@ +# @backstage/plugin-catalog-backend-module-github-org + +The github-org backend module for the catalog plugin. + +_This plugin was created through the Backstage CLI_ diff --git a/plugins/catalog-backend-module-github-org/api-report.md b/plugins/catalog-backend-module-github-org/api-report.md new file mode 100644 index 0000000000..e39c98182c --- /dev/null +++ b/plugins/catalog-backend-module-github-org/api-report.md @@ -0,0 +1,30 @@ +## API Report File for "@backstage/plugin-catalog-backend-module-github-org" + +> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). + +```ts +import { BackendFeature } from '@backstage/backend-plugin-api'; +import { ExtensionPoint } from '@backstage/backend-plugin-api'; +import { GithubMultiOrgEntityProvider } from '@backstage/plugin-catalog-backend-module-github'; +import { TeamTransformer } from '@backstage/plugin-catalog-backend-module-github'; +import { UserTransformer } from '@backstage/plugin-catalog-backend-module-github'; + +// @public +const catalogModuleGithubOrgEntityProvider: () => BackendFeature; +export default catalogModuleGithubOrgEntityProvider; + +export { GithubMultiOrgEntityProvider }; + +// @public +export interface GithubOrgEntityProviderTransformsExtensionPoint { + setTeamTransformer(transformer: TeamTransformer): void; + setUserTransformer(transformer: UserTransformer): void; +} + +// @public +export const githubOrgEntityProviderTransformsExtensionPoint: ExtensionPoint<GithubOrgEntityProviderTransformsExtensionPoint>; + +export { TeamTransformer }; + +export { UserTransformer }; +``` diff --git a/plugins/catalog-backend-module-github-org/catalog-info.yaml b/plugins/catalog-backend-module-github-org/catalog-info.yaml new file mode 100644 index 0000000000..a785727e76 --- /dev/null +++ b/plugins/catalog-backend-module-github-org/catalog-info.yaml @@ -0,0 +1,10 @@ +apiVersion: backstage.io/v1alpha1 +kind: Component +metadata: + name: backstage-plugin-catalog-backend-module-github-org + title: '@backstage/plugin-catalog-backend-module-github-org' + description: A Backstage catalog backend module that ingests users and teams from multiple Github organizations +spec: + lifecycle: experimental + type: backstage-backend-plugin-module + owner: catalog-maintainers diff --git a/plugins/catalog-backend-module-github-org/package.json b/plugins/catalog-backend-module-github-org/package.json new file mode 100644 index 0000000000..d970f3013a --- /dev/null +++ b/plugins/catalog-backend-module-github-org/package.json @@ -0,0 +1,41 @@ +{ + "name": "@backstage/plugin-catalog-backend-module-github-org", + "description": "The github-org backend module for the catalog plugin.", + "version": "0.1.0-next.0", + "main": "src/index.ts", + "types": "src/index.ts", + "license": "Apache-2.0", + "publishConfig": { + "access": "public", + "main": "dist/index.cjs.js", + "types": "dist/index.d.ts" + }, + "backstage": { + "role": "backend-plugin-module" + }, + "scripts": { + "start": "backstage-cli package start", + "build": "backstage-cli package build", + "lint": "backstage-cli package lint", + "test": "backstage-cli package test", + "clean": "backstage-cli package clean", + "prepack": "backstage-cli package prepack", + "postpack": "backstage-cli package postpack" + }, + "dependencies": { + "@backstage/backend-common": "workspace:^", + "@backstage/backend-plugin-api": "workspace:^", + "@backstage/backend-tasks": "workspace:^", + "@backstage/config": "workspace:^", + "@backstage/plugin-catalog-backend-module-github": "workspace:^", + "@backstage/plugin-catalog-node": "workspace:^" + }, + "devDependencies": { + "@backstage/backend-test-utils": "workspace:^", + "@backstage/cli": "workspace:^", + "luxon": "^3.0.0" + }, + "files": [ + "dist" + ] +} diff --git a/plugins/catalog-backend-module-github-org/src/index.ts b/plugins/catalog-backend-module-github-org/src/index.ts new file mode 100644 index 0000000000..03d22b1a79 --- /dev/null +++ b/plugins/catalog-backend-module-github-org/src/index.ts @@ -0,0 +1,36 @@ +/* + * 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. + */ + +/** + * The github-org backend module for the catalog plugin. + * + * @packageDocumentation + */ +export { + catalogModuleGithubOrgEntityProvider as default, + type GithubOrgEntityProviderTransformsExtensionPoint, + githubOrgEntityProviderTransformsExtensionPoint, +} from './module'; +/** + * + * TODO(djamaile): GithubMultiOrgEntityProvider should be mirgated over to this module. + * Afterwards, mark it as deprecated in catalog-backend-module-github and export them there from this module. + */ +export { + GithubMultiOrgEntityProvider, + type TeamTransformer, + type UserTransformer, +} from '@backstage/plugin-catalog-backend-module-github'; diff --git a/plugins/catalog-backend-module-github/src/module/catalogModuleGithubOrgEntityProvider.test.ts b/plugins/catalog-backend-module-github-org/src/module.test.ts similarity index 96% rename from plugins/catalog-backend-module-github/src/module/catalogModuleGithubOrgEntityProvider.test.ts rename to plugins/catalog-backend-module-github-org/src/module.test.ts index 1b8b115a96..9f8e9119d9 100644 --- a/plugins/catalog-backend-module-github/src/module/catalogModuleGithubOrgEntityProvider.test.ts +++ b/plugins/catalog-backend-module-github-org/src/module.test.ts @@ -19,7 +19,7 @@ import { mockServices, startTestBackend } from '@backstage/backend-test-utils'; import { EntityProvider } from '@backstage/plugin-catalog-node'; import { catalogProcessingExtensionPoint } from '@backstage/plugin-catalog-node/alpha'; import { Duration } from 'luxon'; -import { catalogModuleGithubOrgEntityProvider } from './catalogModuleGithubOrgEntityProvider'; +import { catalogModuleGithubOrgEntityProvider } from './module'; describe('catalogModuleGithubOrgEntityProvider', () => { it('should register provider at the catalog extension point', async () => { diff --git a/plugins/catalog-backend-module-github/src/module/catalogModuleGithubOrgEntityProvider.ts b/plugins/catalog-backend-module-github-org/src/module.ts similarity index 97% rename from plugins/catalog-backend-module-github/src/module/catalogModuleGithubOrgEntityProvider.ts rename to plugins/catalog-backend-module-github-org/src/module.ts index 4838be54e1..e510464bb7 100644 --- a/plugins/catalog-backend-module-github/src/module/catalogModuleGithubOrgEntityProvider.ts +++ b/plugins/catalog-backend-module-github-org/src/module.ts @@ -35,7 +35,7 @@ import { catalogProcessingExtensionPoint } from '@backstage/plugin-catalog-node/ /** * Interface for {@link githubOrgEntityProviderTransformsExtensionPoint}. * - * @alpha + * @public */ export interface GithubOrgEntityProviderTransformsExtensionPoint { /** @@ -52,9 +52,9 @@ export interface GithubOrgEntityProviderTransformsExtensionPoint { } /** - * Extension point for runtime configuration of {@link catalogModuleGithubOrgEntityProvider}. + * Extension point for runtime configuration of catalogModuleGithubOrgEntityProvider. * - * @alpha + * @public */ export const githubOrgEntityProviderTransformsExtensionPoint = createExtensionPoint<GithubOrgEntityProviderTransformsExtensionPoint>({ @@ -64,7 +64,7 @@ export const githubOrgEntityProviderTransformsExtensionPoint = /** * Registers the `GithubMultiOrgEntityProvider` with the catalog processing extension point. * - * @alpha + * @public */ export const catalogModuleGithubOrgEntityProvider = createBackendModule({ pluginId: 'catalog', diff --git a/plugins/catalog-backend-module-github/CHANGELOG.md b/plugins/catalog-backend-module-github/CHANGELOG.md index 1cb45ad261..b5d563617c 100644 --- a/plugins/catalog-backend-module-github/CHANGELOG.md +++ b/plugins/catalog-backend-module-github/CHANGELOG.md @@ -1,5 +1,24 @@ # @backstage/plugin-catalog-backend-module-github +## 0.4.4-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- c101e683d5: Removed `catalogModuleGithubOrgEntityProvider`. Import from `@backstage/plugin-catalog-backend-module-github-org` instead. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.4.3-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-github/alpha-api-report.md b/plugins/catalog-backend-module-github/alpha-api-report.md index 3bf72c449b..cd5344f728 100644 --- a/plugins/catalog-backend-module-github/alpha-api-report.md +++ b/plugins/catalog-backend-module-github/alpha-api-report.md @@ -4,25 +4,10 @@ ```ts import { BackendFeature } from '@backstage/backend-plugin-api'; -import { ExtensionPoint } from '@backstage/backend-plugin-api'; -import { TeamTransformer } from '@backstage/plugin-catalog-backend-module-github'; -import { UserTransformer } from '@backstage/plugin-catalog-backend-module-github'; // @alpha const catalogModuleGithubEntityProvider: () => BackendFeature; export default catalogModuleGithubEntityProvider; -// @alpha -export const catalogModuleGithubOrgEntityProvider: () => BackendFeature; - -// @alpha -export interface GithubOrgEntityProviderTransformsExtensionPoint { - setTeamTransformer(transformer: TeamTransformer): void; - setUserTransformer(transformer: UserTransformer): void; -} - -// @alpha -export const githubOrgEntityProviderTransformsExtensionPoint: ExtensionPoint<GithubOrgEntityProviderTransformsExtensionPoint>; - // (No @packageDocumentation comment for this package) ``` diff --git a/plugins/catalog-backend-module-github/package.json b/plugins/catalog-backend-module-github/package.json index ddcc010cee..0d3bc4191b 100644 --- a/plugins/catalog-backend-module-github/package.json +++ b/plugins/catalog-backend-module-github/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-github", "description": "A Backstage catalog backend module that helps integrate towards GitHub", - "version": "0.4.3-next.1", + "version": "0.4.4-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-github/src/lib/github.ts b/plugins/catalog-backend-module-github/src/lib/github.ts index 073e6c1587..cf6b400443 100644 --- a/plugins/catalog-backend-module-github/src/lib/github.ts +++ b/plugins/catalog-backend-module-github/src/lib/github.ts @@ -462,7 +462,7 @@ export async function getOrganizationRepositories( query repositories($org: String!, $catalogPathRef: String!, $cursor: String) { repositoryOwner(login: $org) { login - repositories(first: 100, after: $cursor) { + repositories(first: 50, after: $cursor) { nodes { name catalogInfoFile: object(expression: $catalogPathRef) { diff --git a/plugins/catalog-backend-module-github/src/module/index.ts b/plugins/catalog-backend-module-github/src/module/index.ts index 7e8a214ca3..9c9331763c 100644 --- a/plugins/catalog-backend-module-github/src/module/index.ts +++ b/plugins/catalog-backend-module-github/src/module/index.ts @@ -15,8 +15,3 @@ */ export { catalogModuleGithubEntityProvider as default } from './catalogModuleGithubEntityProvider'; -export { - catalogModuleGithubOrgEntityProvider, - githubOrgEntityProviderTransformsExtensionPoint, - type GithubOrgEntityProviderTransformsExtensionPoint, -} from './catalogModuleGithubOrgEntityProvider'; diff --git a/plugins/catalog-backend-module-gitlab/CHANGELOG.md b/plugins/catalog-backend-module-gitlab/CHANGELOG.md index 6a3633aa8a..790320f5db 100644 --- a/plugins/catalog-backend-module-gitlab/CHANGELOG.md +++ b/plugins/catalog-backend-module-gitlab/CHANGELOG.md @@ -1,5 +1,35 @@ # @backstage/plugin-catalog-backend-module-gitlab +## 0.3.3-next.2 + +### Patch Changes + +- 4f70fdfc93: fix: use REST API to get root group memberships for GitLab SaaS users listing + + This API is the only one that shows `email` field for enterprise users and + allows to filter out bot users not using a license using the `is_using_seat` + field. + + We also added the annotation `gitlab.com/saml-external-uid` taking the value + of `group_saml_identity.extern_uid` of the `groups/:group-id/members` endpoint + response. This is useful in case you want to create a `SignInResolver` that + references the user with the id of your identity provider (e.g. OneLogin). + + ref: + + https://docs.gitlab.com/ee/user/enterprise_user/#get-users-email-addresses-through-the-api + https://docs.gitlab.com/ee/api/members.html#limitations + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.3.2-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-gitlab/package.json b/plugins/catalog-backend-module-gitlab/package.json index b9c5fd5e45..d5a8069460 100644 --- a/plugins/catalog-backend-module-gitlab/package.json +++ b/plugins/catalog-backend-module-gitlab/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-gitlab", "description": "A Backstage catalog backend module that helps integrate towards GitLab", - "version": "0.3.2-next.1", + "version": "0.3.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-incremental-ingestion/CHANGELOG.md b/plugins/catalog-backend-module-incremental-ingestion/CHANGELOG.md index 870514fc08..cf18c6dddc 100644 --- a/plugins/catalog-backend-module-incremental-ingestion/CHANGELOG.md +++ b/plugins/catalog-backend-module-incremental-ingestion/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-catalog-backend-module-incremental-ingestion +## 0.4.10-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.4.9-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-incremental-ingestion/package.json b/plugins/catalog-backend-module-incremental-ingestion/package.json index b588872f72..1aa470dcc3 100644 --- a/plugins/catalog-backend-module-incremental-ingestion/package.json +++ b/plugins/catalog-backend-module-incremental-ingestion/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-incremental-ingestion", "description": "An entity provider for streaming large asset sources into the catalog", - "version": "0.4.9-next.1", + "version": "0.4.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-ldap/CHANGELOG.md b/plugins/catalog-backend-module-ldap/CHANGELOG.md index cdf7473ff9..cb7b48d509 100644 --- a/plugins/catalog-backend-module-ldap/CHANGELOG.md +++ b/plugins/catalog-backend-module-ldap/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-catalog-backend-module-ldap +## 0.5.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + ## 0.5.20-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-ldap/package.json b/plugins/catalog-backend-module-ldap/package.json index d38d746563..ac8693251f 100644 --- a/plugins/catalog-backend-module-ldap/package.json +++ b/plugins/catalog-backend-module-ldap/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-ldap", "description": "A Backstage catalog backend module that helps integrate towards LDAP", - "version": "0.5.20-next.1", + "version": "0.5.21-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-msgraph/CHANGELOG.md b/plugins/catalog-backend-module-msgraph/CHANGELOG.md index 7d7f6f3039..b759abb9ab 100644 --- a/plugins/catalog-backend-module-msgraph/CHANGELOG.md +++ b/plugins/catalog-backend-module-msgraph/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-catalog-backend-module-msgraph +## 0.5.13-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + ## 0.5.12-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-msgraph/package.json b/plugins/catalog-backend-module-msgraph/package.json index 112d0b7c34..d02dddcaea 100644 --- a/plugins/catalog-backend-module-msgraph/package.json +++ b/plugins/catalog-backend-module-msgraph/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-msgraph", "description": "A Backstage catalog backend module that helps integrate towards Microsoft Graph", - "version": "0.5.12-next.1", + "version": "0.5.13-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-openapi/CHANGELOG.md b/plugins/catalog-backend-module-openapi/CHANGELOG.md index b103bd920d..90fe155927 100644 --- a/plugins/catalog-backend-module-openapi/CHANGELOG.md +++ b/plugins/catalog-backend-module-openapi/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-catalog-backend-module-openapi +## 0.1.23-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + ## 0.1.22-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-openapi/package.json b/plugins/catalog-backend-module-openapi/package.json index 52659c8d03..2230782402 100644 --- a/plugins/catalog-backend-module-openapi/package.json +++ b/plugins/catalog-backend-module-openapi/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-openapi", "description": "A Backstage catalog backend module that helps with OpenAPI specifications", - "version": "0.1.22-next.1", + "version": "0.1.23-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-puppetdb/CHANGELOG.md b/plugins/catalog-backend-module-puppetdb/CHANGELOG.md index 7e74c43039..67e1696141 100644 --- a/plugins/catalog-backend-module-puppetdb/CHANGELOG.md +++ b/plugins/catalog-backend-module-puppetdb/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-catalog-backend-module-puppetdb +## 0.1.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.1.10-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-puppetdb/package.json b/plugins/catalog-backend-module-puppetdb/package.json index 3ec71d1042..381d1fcfb4 100644 --- a/plugins/catalog-backend-module-puppetdb/package.json +++ b/plugins/catalog-backend-module-puppetdb/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-puppetdb", "description": "A Backstage catalog backend module that helps integrate towards PuppetDB", - "version": "0.1.10-next.1", + "version": "0.1.11-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-scaffolder-entity-model/CHANGELOG.md b/plugins/catalog-backend-module-scaffolder-entity-model/CHANGELOG.md index 1be951bf47..2dc4e82d31 100644 --- a/plugins/catalog-backend-module-scaffolder-entity-model/CHANGELOG.md +++ b/plugins/catalog-backend-module-scaffolder-entity-model/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-catalog-backend-module-scaffolder-entity-model +## 0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + ## 0.1.2-next.1 ### 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 35f573ec1e..b49a308146 100644 --- a/plugins/catalog-backend-module-scaffolder-entity-model/package.json +++ b/plugins/catalog-backend-module-scaffolder-entity-model/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-scaffolder-entity-model", "description": "Adds support for the scaffolder specific entity model (e.g. the Template kind) to the catalog backend plugin.", - "version": "0.1.2-next.1", + "version": "0.1.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend-module-unprocessed/CHANGELOG.md b/plugins/catalog-backend-module-unprocessed/CHANGELOG.md index 2c229f113e..21b25797bc 100644 --- a/plugins/catalog-backend-module-unprocessed/CHANGELOG.md +++ b/plugins/catalog-backend-module-unprocessed/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-catalog-backend-module-unprocessed +## 0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + ## 0.3.2-next.1 ### Patch Changes diff --git a/plugins/catalog-backend-module-unprocessed/package.json b/plugins/catalog-backend-module-unprocessed/package.json index 2a923fdf87..5c45699175 100644 --- a/plugins/catalog-backend-module-unprocessed/package.json +++ b/plugins/catalog-backend-module-unprocessed/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend-module-unprocessed", "description": "Backstage Catalog module to view unprocessed entities", - "version": "0.3.2-next.1", + "version": "0.3.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend/CHANGELOG.md b/plugins/catalog-backend/CHANGELOG.md index 6e74d0d408..ca34451992 100644 --- a/plugins/catalog-backend/CHANGELOG.md +++ b/plugins/catalog-backend/CHANGELOG.md @@ -1,5 +1,29 @@ # @backstage/plugin-catalog-backend +## 1.14.0-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-openapi-utils@0.0.5-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-search-backend-module-catalog@0.1.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 1.14.0-next.1 ### Patch Changes diff --git a/plugins/catalog-backend/package.json b/plugins/catalog-backend/package.json index 7badc3d540..49f4d7a7b1 100644 --- a/plugins/catalog-backend/package.json +++ b/plugins/catalog-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-backend", "description": "The Backstage backend plugin that provides the Backstage catalog", - "version": "1.14.0-next.1", + "version": "1.14.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-backend/src/service/standaloneServer.ts b/plugins/catalog-backend/src/service/standaloneServer.ts index e48515fb8b..cff4fa1f94 100644 --- a/plugins/catalog-backend/src/service/standaloneServer.ts +++ b/plugins/catalog-backend/src/service/standaloneServer.ts @@ -19,7 +19,7 @@ import { DatabaseManager, loadBackendConfig, ServerTokenManager, - SingleHostDiscovery, + HostDiscovery, UrlReaders, useHotMemoize, } from '@backstage/backend-common'; @@ -53,7 +53,7 @@ export async function startStandaloneServer( ); return manager.forPlugin('catalog'); }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const tokenManager = ServerTokenManager.fromConfig(config, { logger, }); diff --git a/plugins/catalog-common/CHANGELOG.md b/plugins/catalog-common/CHANGELOG.md index b33835b2b6..e3ad0c858f 100644 --- a/plugins/catalog-common/CHANGELOG.md +++ b/plugins/catalog-common/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-catalog-common +## 1.0.17-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.0.16 ### Patch Changes diff --git a/plugins/catalog-common/package.json b/plugins/catalog-common/package.json index ce78ffd5f0..35529e2cd1 100644 --- a/plugins/catalog-common/package.json +++ b/plugins/catalog-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-common", "description": "Common functionalities for the catalog plugin", - "version": "1.0.16", + "version": "1.0.17-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-graph/CHANGELOG.md b/plugins/catalog-graph/CHANGELOG.md index a9fc8ea29d..2dfa6dffe4 100644 --- a/plugins/catalog-graph/CHANGELOG.md +++ b/plugins/catalog-graph/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-catalog-graph +## 0.2.37-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + ## 0.2.37-next.1 ### Patch Changes diff --git a/plugins/catalog-graph/package.json b/plugins/catalog-graph/package.json index 77cdee4476..909ed5329d 100644 --- a/plugins/catalog-graph/package.json +++ b/plugins/catalog-graph/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-catalog-graph", - "version": "0.2.37-next.1", + "version": "0.2.37-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -57,8 +57,8 @@ "@backstage/dev-utils": "workspace:^", "@backstage/plugin-catalog": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0" diff --git a/plugins/catalog-graph/src/components/CatalogGraphPage/CurveFilter.tsx b/plugins/catalog-graph/src/components/CatalogGraphPage/CurveFilter.tsx index 6cda334cf1..2f3278dc6b 100644 --- a/plugins/catalog-graph/src/components/CatalogGraphPage/CurveFilter.tsx +++ b/plugins/catalog-graph/src/components/CatalogGraphPage/CurveFilter.tsx @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -import { Select } from '@backstage/core-components'; +import { Select, SelectedItems } from '@backstage/core-components'; import { Box } from '@material-ui/core'; import React, { useCallback } from 'react'; @@ -31,7 +31,10 @@ export type Props = { const curves: Array<Curve> = ['curveMonotoneX', 'curveStepBefore']; export const CurveFilter = ({ value, onChange }: Props) => { - const handleChange = useCallback(v => onChange(v as Curve), [onChange]); + const handleChange = useCallback( + (v: SelectedItems) => onChange(v as Curve), + [onChange], + ); return ( <Box pb={1} pt={1}> diff --git a/plugins/catalog-graph/src/components/CatalogGraphPage/DirectionFilter.tsx b/plugins/catalog-graph/src/components/CatalogGraphPage/DirectionFilter.tsx index 815ed1f292..c614ed2b58 100644 --- a/plugins/catalog-graph/src/components/CatalogGraphPage/DirectionFilter.tsx +++ b/plugins/catalog-graph/src/components/CatalogGraphPage/DirectionFilter.tsx @@ -13,7 +13,7 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -import { Select } from '@backstage/core-components'; +import { Select, SelectedItems } from '@backstage/core-components'; import { Box } from '@material-ui/core'; import React, { useCallback } from 'react'; import { Direction } from '../EntityRelationsGraph'; @@ -31,7 +31,10 @@ export type Props = { }; export const DirectionFilter = ({ value, onChange }: Props) => { - const handleChange = useCallback(v => onChange(v as Direction), [onChange]); + const handleChange = useCallback( + (v: SelectedItems) => onChange(v as Direction), + [onChange], + ); return ( <Box pb={1} pt={1}> diff --git a/plugins/catalog-graph/src/components/EntityRelationsGraph/EntityRelationsGraph.test.tsx b/plugins/catalog-graph/src/components/EntityRelationsGraph/EntityRelationsGraph.test.tsx index 2556cd06d7..0ba9a3375a 100644 --- a/plugins/catalog-graph/src/components/EntityRelationsGraph/EntityRelationsGraph.test.tsx +++ b/plugins/catalog-graph/src/components/EntityRelationsGraph/EntityRelationsGraph.test.tsx @@ -29,7 +29,44 @@ import userEvent from '@testing-library/user-event'; import React, { FunctionComponent } from 'react'; import { EntityRelationsGraph } from './EntityRelationsGraph'; -describe('<EntityRelationsGraph/>', () => { +/* + The tests in this file have been disabled for the following error: + + TypeError: Cannot read properties of null (reading 'document') + + at document (../../../node_modules/d3-drag/src/nodrag.js:5:19) + at SVGSVGElement.mousedowned (../../../node_modules/d3-zoom/src/zoom.js:279:16) + at SVGSVGElement.call (../../../node_modules/d3-selection/src/selection/on.js:3:14) + at SVGSVGElement.callTheUserObjectsOperation (../../../node_modules/jsdom/lib/jsdom/living/generated/EventListener.js:26:30) + at innerInvokeEventListeners (../../../node_modules/jsdom/lib/jsdom/living/events/EventTarget-impl.js:350:25) + at invokeEventListeners (../../../node_modules/jsdom/lib/jsdom/living/events/EventTarget-impl.js:286:3) + at SVGElementImpl._dispatch (../../../node_modules/jsdom/lib/jsdom/living/events/EventTarget-impl.js:233:9) + at SVGElementImpl.dispatchEvent (../../../node_modules/jsdom/lib/jsdom/living/events/EventTarget-impl.js:104:17) + at SVGElement.dispatchEvent (../../../node_modules/jsdom/lib/jsdom/living/generated/EventTarget.js:241:34) + at ../../../node_modules/@testing-library/user-event/dist/cjs/event/dispatchEvent.js:47:43 + at cb (../../../node_modules/@testing-library/react/dist/pure.js:66:16) + at batchedUpdates$1 (../../../node_modules/react-dom/cjs/react-dom.development.js:22380:12) + at act (../../../node_modules/react-dom/cjs/react-dom-test-utils.development.js:1042:14) + at Object.eventWrapper (../../../node_modules/@testing-library/react/dist/pure.js:65:26) + at Object.wrapEvent (../../../node_modules/@testing-library/user-event/dist/cjs/event/wrapEvent.js:29:24) + at Object.dispatchEvent (../../../node_modules/@testing-library/user-event/dist/cjs/event/dispatchEvent.js:47:22) + at Object.dispatchUIEvent (../../../node_modules/@testing-library/user-event/dist/cjs/event/dispatchEvent.js:24:26) + at Mouse.down (../../../node_modules/@testing-library/user-event/dist/cjs/system/pointer/mouse.js:83:34) + at PointerHost.press (../../../node_modules/@testing-library/user-event/dist/cjs/system/pointer/index.js:39:24) + at pointerAction (../../../node_modules/@testing-library/user-event/dist/cjs/pointer/index.js:59:43) + at Object.pointer (../../../node_modules/@testing-library/user-event/dist/cjs/pointer/index.js:35:15) + at ../../../node_modules/@testing-library/react/dist/pure.js:59:16 + + This has started happening after upgrading to the later version of @testing-library/user-event, and the d3-drag library + where it happens seems to be unmaintained. Skipping for now. + + https://github.com/d3/d3-drag/issues/79#issuecomment-1631409544 + + https://github.com/d3/d3-drag/issues/89 +*/ + +// eslint-disable-next-line jest/no-disabled-tests +describe.skip('<EntityRelationsGraph/>', () => { let Wrapper: FunctionComponent<React.PropsWithChildren<{}>>; const entities: { [ref: string]: Entity } = { 'b:d/c': { diff --git a/plugins/catalog-graphql/CHANGELOG.md b/plugins/catalog-graphql/CHANGELOG.md index e34136f8eb..867d52cb4b 100644 --- a/plugins/catalog-graphql/CHANGELOG.md +++ b/plugins/catalog-graphql/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-catalog-graphql +## 0.3.24-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.3.23 ### Patch Changes diff --git a/plugins/catalog-graphql/README.md b/plugins/catalog-graphql/README.md index e05672e3a5..021d0d1b20 100644 --- a/plugins/catalog-graphql/README.md +++ b/plugins/catalog-graphql/README.md @@ -1,11 +1,3 @@ # Catalog GraphQL Plugin -## Getting Started - -This is the Catalog GraphQL plugin. - -It provides the `catalog` part of the GraphQL schema. - -To register it with the GraphQL backend, be sure to follow the [Getting Started](../graphql-backend/README.md#getting-started) guide of the GraphQL plugin. - -<!-- TODO: Need to make the GraphQL plugin compatible with non forked repos > +This package has been deprecated, consider using [@frontside/backstage-plugin-graphql-backend](https://www.npmjs.com/package/@frontside/backstage-plugin-graphql-backend) instead. diff --git a/plugins/catalog-graphql/package.json b/plugins/catalog-graphql/package.json index e853f308f3..75f08a6bf9 100644 --- a/plugins/catalog-graphql/package.json +++ b/plugins/catalog-graphql/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-graphql", - "description": "An experimental Backstage catalog GraphQL module", - "version": "0.3.23", + "description": "Deprecated, consider using @frontside/backstage-plugin-graphql-backend instead", + "version": "0.3.24-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-import/CHANGELOG.md b/plugins/catalog-import/CHANGELOG.md index 97a6070230..2043cca0f4 100644 --- a/plugins/catalog-import/CHANGELOG.md +++ b/plugins/catalog-import/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-catalog-import +## 0.10.1-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + ## 0.10.1-next.1 ### Patch Changes diff --git a/plugins/catalog-import/package.json b/plugins/catalog-import/package.json index a982b13373..9c550ebee9 100644 --- a/plugins/catalog-import/package.json +++ b/plugins/catalog-import/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-import", "description": "A Backstage plugin the helps you import entities into your catalog", - "version": "0.10.1-next.1", + "version": "0.10.1-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -65,8 +65,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/catalog-import/src/components/DefaultImportPage/DefaultImportPage.tsx b/plugins/catalog-import/src/components/DefaultImportPage/DefaultImportPage.tsx index c777953808..16000465b9 100644 --- a/plugins/catalog-import/src/components/DefaultImportPage/DefaultImportPage.tsx +++ b/plugins/catalog-import/src/components/DefaultImportPage/DefaultImportPage.tsx @@ -36,7 +36,7 @@ export const DefaultImportPage = () => { const theme = useTheme(); const configApi = useApi(configApiRef); const isMobile = useMediaQuery(theme.breakpoints.down('sm')); - const appTitle = configApi.getOptional('app.title') || 'Backstage'; + const appTitle = configApi.getOptionalString('app.title') || 'Backstage'; const contentItems = [ <Grid item xs={12} md={4} lg={6} xl={8}> diff --git a/plugins/catalog-import/src/components/ImportInfoCard/ImportInfoCard.tsx b/plugins/catalog-import/src/components/ImportInfoCard/ImportInfoCard.tsx index f7086fce19..26b6b8eb52 100644 --- a/plugins/catalog-import/src/components/ImportInfoCard/ImportInfoCard.tsx +++ b/plugins/catalog-import/src/components/ImportInfoCard/ImportInfoCard.tsx @@ -43,7 +43,7 @@ export const ImportInfoCard = (props: ImportInfoCardProps) => { } = props; const configApi = useApi(configApiRef); - const appTitle = configApi.getOptional('app.title') || 'Backstage'; + const appTitle = configApi.getOptionalString('app.title') || 'Backstage'; const catalogImportApi = useApi(catalogImportApiRef); const hasGithubIntegration = configApi.has('integrations.github'); diff --git a/plugins/catalog-import/src/components/StepReviewLocation/StepReviewLocation.tsx b/plugins/catalog-import/src/components/StepReviewLocation/StepReviewLocation.tsx index 74ebd973d0..b0db174787 100644 --- a/plugins/catalog-import/src/components/StepReviewLocation/StepReviewLocation.tsx +++ b/plugins/catalog-import/src/components/StepReviewLocation/StepReviewLocation.tsx @@ -42,7 +42,7 @@ export const StepReviewLocation = ({ const configApi = useApi(configApiRef); const analytics = useAnalytics(); - const appTitle = configApi.getOptional('app.title') || 'Backstage'; + const appTitle = configApi.getOptionalString('app.title') || 'Backstage'; const [submitted, setSubmitted] = useState(false); const [error, setError] = useState<string>(); diff --git a/plugins/catalog-node/CHANGELOG.md b/plugins/catalog-node/CHANGELOG.md index 0126011e83..a60a3e21aa 100644 --- a/plugins/catalog-node/CHANGELOG.md +++ b/plugins/catalog-node/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-catalog-node +## 1.4.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + ## 1.4.6-next.1 ### Patch Changes diff --git a/plugins/catalog-node/package.json b/plugins/catalog-node/package.json index 61e9823ea6..cbc17219c5 100644 --- a/plugins/catalog-node/package.json +++ b/plugins/catalog-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog-node", "description": "The plugin-catalog-node module for @backstage/plugin-catalog-backend", - "version": "1.4.6-next.1", + "version": "1.4.7-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/catalog-react/CHANGELOG.md b/plugins/catalog-react/CHANGELOG.md index 467f134119..3e65e4b55c 100644 --- a/plugins/catalog-react/CHANGELOG.md +++ b/plugins/catalog-react/CHANGELOG.md @@ -1,5 +1,24 @@ # @backstage/plugin-catalog-react +## 1.8.5-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + ## 1.8.5-next.1 ### Patch Changes diff --git a/plugins/catalog-react/package.json b/plugins/catalog-react/package.json index 56205f8102..4d52a96ccc 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.8.5-next.1", + "version": "1.8.5-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -82,8 +82,8 @@ "@backstage/plugin-catalog-common": "workspace:^", "@backstage/plugin-scaffolder-common": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/catalog-react/src/components/EntityPeekAheadPopover/EntityPeekAheadPopover.tsx b/plugins/catalog-react/src/components/EntityPeekAheadPopover/EntityPeekAheadPopover.tsx index 91d60d4f13..077274a6e9 100644 --- a/plugins/catalog-react/src/components/EntityPeekAheadPopover/EntityPeekAheadPopover.tsx +++ b/plugins/catalog-react/src/components/EntityPeekAheadPopover/EntityPeekAheadPopover.tsx @@ -164,7 +164,7 @@ export const EntityPeekAheadPopover = (props: EntityPeekAheadPopoverProps) => { {entity.metadata.description} </Typography> )} - <Typography>{entity.spec?.type}</Typography> + <Typography>{entity.spec?.type?.toString()}</Typography> <Box marginTop="0.5em"> {(entity.metadata.tags || []) .slice(0, maxTagChips) diff --git a/plugins/catalog-react/src/components/InspectEntityDialog/components/OverviewPage.tsx b/plugins/catalog-react/src/components/InspectEntityDialog/components/OverviewPage.tsx index 09b944605f..d2eb6d4266 100644 --- a/plugins/catalog-react/src/components/InspectEntityDialog/components/OverviewPage.tsx +++ b/plugins/catalog-react/src/components/InspectEntityDialog/components/OverviewPage.tsx @@ -74,7 +74,10 @@ export function OverviewPage(props: { entity: AlphaEntity }) { </ListItem> {spec?.type && ( <ListItem> - <ListItemText primary="spec.type" secondary={spec.type} /> + <ListItemText + primary="spec.type" + secondary={spec.type?.toString()} + /> </ListItem> )} {metadata.uid && ( diff --git a/plugins/catalog-react/src/components/UnregisterEntityDialog/useUnregisterEntityDialogState.test.tsx b/plugins/catalog-react/src/components/UnregisterEntityDialog/useUnregisterEntityDialogState.test.tsx index e458e7d157..8591cdad93 100644 --- a/plugins/catalog-react/src/components/UnregisterEntityDialog/useUnregisterEntityDialogState.test.tsx +++ b/plugins/catalog-react/src/components/UnregisterEntityDialog/useUnregisterEntityDialogState.test.tsx @@ -22,7 +22,7 @@ import { renderHook, RenderHookResult, } from '@testing-library/react-hooks'; -import React from 'react'; +import React, { ReactNode } from 'react'; import { UseUnregisterEntityDialogState, useUnregisterEntityDialogState, @@ -85,7 +85,10 @@ describe('useUnregisterEntityDialogState', () => { }); it('goes through the happy unregister path', async () => { - let rendered: RenderHookResult<unknown, UseUnregisterEntityDialogState>; + let rendered: RenderHookResult< + { children?: ReactNode }, + UseUnregisterEntityDialogState + >; act(() => { rendered = renderHook(() => useUnregisterEntityDialogState(entity), { wrapper: Wrapper, @@ -114,7 +117,10 @@ describe('useUnregisterEntityDialogState', () => { entity.metadata.annotations![ANNOTATION_ORIGIN_LOCATION] = 'bootstrap:bootstrap'; - let rendered: RenderHookResult<unknown, UseUnregisterEntityDialogState>; + let rendered: RenderHookResult< + { children?: ReactNode }, + UseUnregisterEntityDialogState + >; act(() => { rendered = renderHook(() => useUnregisterEntityDialogState(entity), { wrapper: Wrapper, @@ -137,7 +143,10 @@ describe('useUnregisterEntityDialogState', () => { it('chooses only-delete when there was no location annotation', async () => { delete entity.metadata.annotations![ANNOTATION_ORIGIN_LOCATION]; - let rendered: RenderHookResult<unknown, UseUnregisterEntityDialogState>; + let rendered: RenderHookResult< + { children?: ReactNode }, + UseUnregisterEntityDialogState + >; act(() => { rendered = renderHook(() => useUnregisterEntityDialogState(entity), { wrapper: Wrapper, @@ -157,7 +166,10 @@ describe('useUnregisterEntityDialogState', () => { }); it('chooses only-delete when the location could not be found', async () => { - let rendered: RenderHookResult<unknown, UseUnregisterEntityDialogState>; + let rendered: RenderHookResult< + { children?: ReactNode }, + UseUnregisterEntityDialogState + >; act(() => { rendered = renderHook(() => useUnregisterEntityDialogState(entity), { wrapper: Wrapper, diff --git a/plugins/catalog-unprocessed-entities/CHANGELOG.md b/plugins/catalog-unprocessed-entities/CHANGELOG.md index 612c02a9a1..f42483fc92 100644 --- a/plugins/catalog-unprocessed-entities/CHANGELOG.md +++ b/plugins/catalog-unprocessed-entities/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-catalog-unprocessed-entities +## 0.1.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.1.4-next.1 ### Patch Changes diff --git a/plugins/catalog-unprocessed-entities/package.json b/plugins/catalog-unprocessed-entities/package.json index 735cb05f8d..822fffa343 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.1.4-next.1", + "version": "0.1.4-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -50,7 +50,7 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/catalog/CHANGELOG.md b/plugins/catalog/CHANGELOG.md index 648fa4d7a4..2286652eb8 100644 --- a/plugins/catalog/CHANGELOG.md +++ b/plugins/catalog/CHANGELOG.md @@ -1,5 +1,26 @@ # @backstage/plugin-catalog +## 1.14.0-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.14.0-next.1 ### Patch Changes diff --git a/plugins/catalog/alpha-api-report.md b/plugins/catalog/alpha-api-report.md index e89807ac34..4582a13a5d 100644 --- a/plugins/catalog/alpha-api-report.md +++ b/plugins/catalog/alpha-api-report.md @@ -3,6 +3,8 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { Extension } from '@backstage/frontend-plugin-api'; @@ -15,7 +17,7 @@ export const CatalogSearchResultListItemExtension: Extension<{ }>; // @alpha (undocumented) -const _default: BackstagePlugin; +const _default: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; export default _default; // @alpha (undocumented) diff --git a/plugins/catalog/package.json b/plugins/catalog/package.json index 59f523d3f1..67106a5d5e 100644 --- a/plugins/catalog/package.json +++ b/plugins/catalog/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-catalog", "description": "The Backstage plugin for browsing the Backstage catalog", - "version": "1.14.0-next.1", + "version": "1.14.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -81,8 +81,8 @@ "@backstage/dev-utils": "workspace:^", "@backstage/plugin-permission-react": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0" }, diff --git a/plugins/catalog/src/components/EntityLayout/EntityLayout.tsx b/plugins/catalog/src/components/EntityLayout/EntityLayout.tsx index a190984ffe..9505dad889 100644 --- a/plugins/catalog/src/components/EntityLayout/EntityLayout.tsx +++ b/plugins/catalog/src/components/EntityLayout/EntityLayout.tsx @@ -128,7 +128,10 @@ function EntityLabels(props: { entity: Entity }) { /> )} {entity.spec?.lifecycle && ( - <HeaderLabel label="Lifecycle" value={entity.spec.lifecycle} /> + <HeaderLabel + label="Lifecycle" + value={entity.spec.lifecycle?.toString()} + /> )} </> ); diff --git a/plugins/cicd-statistics-module-gitlab/CHANGELOG.md b/plugins/cicd-statistics-module-gitlab/CHANGELOG.md index a1952616bb..8821eeab83 100644 --- a/plugins/cicd-statistics-module-gitlab/CHANGELOG.md +++ b/plugins/cicd-statistics-module-gitlab/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-cicd-statistics-module-gitlab +## 0.1.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-cicd-statistics@0.1.27-next.2 + - @backstage/catalog-model@1.4.3-next.0 + ## 0.1.21-next.1 ### Patch Changes diff --git a/plugins/cicd-statistics-module-gitlab/package.json b/plugins/cicd-statistics-module-gitlab/package.json index afdd1cd758..d2997056fc 100644 --- a/plugins/cicd-statistics-module-gitlab/package.json +++ b/plugins/cicd-statistics-module-gitlab/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-cicd-statistics-module-gitlab", "description": "CI/CD Statistics plugin module; Gitlab CICD", - "version": "0.1.21-next.1", + "version": "0.1.21-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/cicd-statistics/CHANGELOG.md b/plugins/cicd-statistics/CHANGELOG.md index 4abb69de10..7d07199028 100644 --- a/plugins/cicd-statistics/CHANGELOG.md +++ b/plugins/cicd-statistics/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-cicd-statistics +## 0.1.27-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + ## 0.1.27-next.1 ### Patch Changes diff --git a/plugins/cicd-statistics/package.json b/plugins/cicd-statistics/package.json index c186ced0df..744963d55c 100644 --- a/plugins/cicd-statistics/package.json +++ b/plugins/cicd-statistics/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-cicd-statistics", "description": "A frontend plugin visualizing CI/CD pipeline statistics (build time)", - "version": "0.1.27-next.1", + "version": "0.1.27-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/circleci/CHANGELOG.md b/plugins/circleci/CHANGELOG.md index 38e797dc35..7a25c01f56 100644 --- a/plugins/circleci/CHANGELOG.md +++ b/plugins/circleci/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-circleci +## 0.3.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.3.25-next.1 ### Patch Changes diff --git a/plugins/circleci/package.json b/plugins/circleci/package.json index c1c4c07004..752e908374 100644 --- a/plugins/circleci/package.json +++ b/plugins/circleci/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-circleci", "description": "A Backstage plugin that integrates towards Circle CI", - "version": "0.3.25-next.1", + "version": "0.3.25-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,8 +59,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/humanize-duration": "^3.25.1", diff --git a/plugins/circleci/src/setupTests.ts b/plugins/circleci/src/setupTests.ts index 83a0078a28..d3232290a7 100644 --- a/plugins/circleci/src/setupTests.ts +++ b/plugins/circleci/src/setupTests.ts @@ -14,4 +14,4 @@ * limitations under the License. */ -import '@testing-library/jest-dom/extend-expect'; +export {}; diff --git a/plugins/cloudbuild/CHANGELOG.md b/plugins/cloudbuild/CHANGELOG.md index 3affd61ba7..c1ac4d0747 100644 --- a/plugins/cloudbuild/CHANGELOG.md +++ b/plugins/cloudbuild/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-cloudbuild +## 0.3.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.3.25-next.1 ### Patch Changes diff --git a/plugins/cloudbuild/package.json b/plugins/cloudbuild/package.json index d09f2372ab..055fb5bb62 100644 --- a/plugins/cloudbuild/package.json +++ b/plugins/cloudbuild/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-cloudbuild", "description": "A Backstage plugin that integrates towards Google Cloud Build", - "version": "0.3.25-next.1", + "version": "0.3.25-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -57,8 +57,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/code-climate/CHANGELOG.md b/plugins/code-climate/CHANGELOG.md index 9e32befc60..5f97316244 100644 --- a/plugins/code-climate/CHANGELOG.md +++ b/plugins/code-climate/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-code-climate +## 0.1.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.1.25-next.1 ### Patch Changes diff --git a/plugins/code-climate/package.json b/plugins/code-climate/package.json index 800c97652f..4b2bfcd9b3 100644 --- a/plugins/code-climate/package.json +++ b/plugins/code-climate/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-code-climate", - "version": "0.1.25-next.1", + "version": "0.1.25-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -51,8 +51,8 @@ "@backstage/cli": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/humanize-duration": "^3.27.1", diff --git a/plugins/code-coverage-backend/CHANGELOG.md b/plugins/code-coverage-backend/CHANGELOG.md index 817fe0d57d..c7fb955e9f 100644 --- a/plugins/code-coverage-backend/CHANGELOG.md +++ b/plugins/code-coverage-backend/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-code-coverage-backend +## 0.2.20-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.2.19-next.1 ### Patch Changes diff --git a/plugins/code-coverage-backend/package.json b/plugins/code-coverage-backend/package.json index 761fccda23..3c07f28eb8 100644 --- a/plugins/code-coverage-backend/package.json +++ b/plugins/code-coverage-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-code-coverage-backend", "description": "A Backstage backend plugin that helps you keep track of your code coverage", - "version": "0.2.19-next.1", + "version": "0.2.20-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/code-coverage/CHANGELOG.md b/plugins/code-coverage/CHANGELOG.md index 3801f63f61..06a29ca4cc 100644 --- a/plugins/code-coverage/CHANGELOG.md +++ b/plugins/code-coverage/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-code-coverage +## 0.2.18-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.2.18-next.1 ### Patch Changes diff --git a/plugins/code-coverage/package.json b/plugins/code-coverage/package.json index f47a44221a..c2c16f69b6 100644 --- a/plugins/code-coverage/package.json +++ b/plugins/code-coverage/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-code-coverage", "description": "A Backstage plugin that helps you keep track of your code coverage", - "version": "0.2.18-next.1", + "version": "0.2.18-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -56,8 +56,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/highlightjs": "^10.1.0", diff --git a/plugins/code-coverage/src/components/FileExplorer/FileExplorer.tsx b/plugins/code-coverage/src/components/FileExplorer/FileExplorer.tsx index 4017ba8264..57bb9a2be0 100644 --- a/plugins/code-coverage/src/components/FileExplorer/FileExplorer.tsx +++ b/plugins/code-coverage/src/components/FileExplorer/FileExplorer.tsx @@ -14,7 +14,7 @@ * limitations under the License. */ -import { useEntity } from '@backstage/plugin-catalog-react'; +import { humanizeEntityRef, useEntity } from '@backstage/plugin-catalog-react'; import { Box, Modal, makeStyles } from '@material-ui/core'; import FolderIcon from '@material-ui/icons/Folder'; import FileOutlinedIcon from '@material-ui/icons/InsertDriveFileOutlined'; @@ -181,7 +181,9 @@ export const FileExplorer = () => { } if (!value) { return ( - <Alert severity="warning">No code coverage found for ${entity}</Alert> + <Alert severity="warning"> + No code coverage found for {humanizeEntityRef(entity)} + </Alert> ); } diff --git a/plugins/codescene/CHANGELOG.md b/plugins/codescene/CHANGELOG.md index 15f34acaf0..aed76f3c8b 100644 --- a/plugins/codescene/CHANGELOG.md +++ b/plugins/codescene/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-codescene +## 0.1.18-next.2 + +### Patch Changes + +- 9c9a9100b0: Internal refactor to avoid using the deprecated `.icon.svg` extension. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.1.18-next.1 ### Patch Changes diff --git a/plugins/codescene/package.json b/plugins/codescene/package.json index c57a9c53af..4d3e5ab597 100644 --- a/plugins/codescene/package.json +++ b/plugins/codescene/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-codescene", - "version": "0.1.18-next.1", + "version": "0.1.18-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -51,8 +51,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/config-schema/CHANGELOG.md b/plugins/config-schema/CHANGELOG.md index 2c2ac53154..0b1a03c5e5 100644 --- a/plugins/config-schema/CHANGELOG.md +++ b/plugins/config-schema/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-config-schema +## 0.1.46-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.1.46-next.1 ### Patch Changes diff --git a/plugins/config-schema/package.json b/plugins/config-schema/package.json index c623a59dfa..6b97abc91d 100644 --- a/plugins/config-schema/package.json +++ b/plugins/config-schema/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-config-schema", "description": "A Backstage plugin that lets you browse the configuration schema of your app", - "version": "0.1.46-next.1", + "version": "0.1.46-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/cost-insights/CHANGELOG.md b/plugins/cost-insights/CHANGELOG.md index a51c19f324..08dc64071e 100644 --- a/plugins/cost-insights/CHANGELOG.md +++ b/plugins/cost-insights/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-cost-insights +## 0.12.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-cost-insights-common@0.1.2 + ## 0.12.14-next.1 ### Patch Changes diff --git a/plugins/cost-insights/package.json b/plugins/cost-insights/package.json index c204616fe4..a66fde70ad 100644 --- a/plugins/cost-insights/package.json +++ b/plugins/cost-insights/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-cost-insights", "description": "A Backstage plugin that helps you keep track of your cloud spend", - "version": "0.12.14-next.1", + "version": "0.12.14-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -66,8 +66,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/pluralize": "^0.0.31", diff --git a/plugins/cost-insights/src/components/BarChart/BarChartTooltip.test.tsx b/plugins/cost-insights/src/components/BarChart/BarChartTooltip.test.tsx index 3a6dca9417..4e255917d8 100644 --- a/plugins/cost-insights/src/components/BarChart/BarChartTooltip.test.tsx +++ b/plugins/cost-insights/src/components/BarChart/BarChartTooltip.test.tsx @@ -33,8 +33,9 @@ const items = [ }, ]; -const tooltipItems = () => - items.map(item => <BarChartTooltipItem key={item.label} item={item} />); +const tooltipItems = items.map(item => ( + <BarChartTooltipItem key={item.label} item={item} /> +)); describe('<BarChartTooltip/>', () => { it('formats label and tooltip item text correctly', async () => { diff --git a/plugins/cost-insights/src/components/ProjectSelect/ProjectSelect.test.tsx b/plugins/cost-insights/src/components/ProjectSelect/ProjectSelect.test.tsx index 7dd5b4253f..3a2f30bbfe 100644 --- a/plugins/cost-insights/src/components/ProjectSelect/ProjectSelect.test.tsx +++ b/plugins/cost-insights/src/components/ProjectSelect/ProjectSelect.test.tsx @@ -14,7 +14,7 @@ * limitations under the License. */ -import React from 'react'; +import React, { ComponentType } from 'react'; import { getByRole, screen, waitFor } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; import { ProjectSelect } from './ProjectSelect'; @@ -28,7 +28,7 @@ const mockProjects = [ ]; describe('<ProjectSelect />', () => { - let Component: React.ReactNode; + let Component: ComponentType; beforeEach(() => { Component = () => ( <MockFilterProvider> diff --git a/plugins/devtools-backend/CHANGELOG.md b/plugins/devtools-backend/CHANGELOG.md index 7fc9c01be5..16de7b7e6f 100644 --- a/plugins/devtools-backend/CHANGELOG.md +++ b/plugins/devtools-backend/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-devtools-backend +## 0.2.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/config-loader@1.5.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/cli-common@0.1.13-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-devtools-common@0.1.5-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.2.2-next.1 ### Patch Changes diff --git a/plugins/devtools-backend/package.json b/plugins/devtools-backend/package.json index f5311f9cf3..865bbae714 100644 --- a/plugins/devtools-backend/package.json +++ b/plugins/devtools-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-devtools-backend", - "version": "0.2.2-next.1", + "version": "0.2.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/devtools-backend/src/service/standaloneServer.ts b/plugins/devtools-backend/src/service/standaloneServer.ts index d2fdce169d..43edb47935 100644 --- a/plugins/devtools-backend/src/service/standaloneServer.ts +++ b/plugins/devtools-backend/src/service/standaloneServer.ts @@ -16,7 +16,7 @@ import { ServerTokenManager, - SingleHostDiscovery, + HostDiscovery, createServiceBuilder, loadBackendConfig, } from '@backstage/backend-common'; @@ -37,7 +37,7 @@ export async function startStandaloneServer( ): Promise<Server> { const logger = options.logger.child({ service: 'devtools-backend-backend' }); const config = await loadBackendConfig({ logger, argv: process.argv }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const tokenManager = ServerTokenManager.fromConfig(config, { logger, }); diff --git a/plugins/devtools-common/CHANGELOG.md b/plugins/devtools-common/CHANGELOG.md index 4e1f15afcf..48688e77de 100644 --- a/plugins/devtools-common/CHANGELOG.md +++ b/plugins/devtools-common/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-devtools-common +## 0.1.5-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.1.4 ### Patch Changes diff --git a/plugins/devtools-common/package.json b/plugins/devtools-common/package.json index bde9934ffa..7f1aa0f93f 100644 --- a/plugins/devtools-common/package.json +++ b/plugins/devtools-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-devtools-common", "description": "Common functionalities for the devtools plugin", - "version": "0.1.4", + "version": "0.1.5-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/devtools/CHANGELOG.md b/plugins/devtools/CHANGELOG.md index b858ff2c61..a585b7bde7 100644 --- a/plugins/devtools/CHANGELOG.md +++ b/plugins/devtools/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-devtools +## 0.1.5-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-devtools-common@0.1.5-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + ## 0.1.5-next.1 ### Patch Changes diff --git a/plugins/devtools/package.json b/plugins/devtools/package.json index 62ba643765..7dffd4fdc4 100644 --- a/plugins/devtools/package.json +++ b/plugins/devtools/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-devtools", - "version": "0.1.5-next.1", + "version": "0.1.5-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -53,7 +53,7 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/dynatrace/CHANGELOG.md b/plugins/dynatrace/CHANGELOG.md index dc1c8cd54d..71b6670ab6 100644 --- a/plugins/dynatrace/CHANGELOG.md +++ b/plugins/dynatrace/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-dynatrace +## 7.0.5-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 7.0.5-next.1 ### Patch Changes diff --git a/plugins/dynatrace/README.md b/plugins/dynatrace/README.md index b03e65473f..9143b0ff9c 100644 --- a/plugins/dynatrace/README.md +++ b/plugins/dynatrace/README.md @@ -109,6 +109,10 @@ The annotation can also contain a comma or space separated list of Synthetic Ids The `SYNTHETIC_ID` can be found in Dynatrace by browsing to the Synthetic monitor. It will be located in the browser address bar in the resource path - `https://example.dynatrace.com/ui/http-monitor/HTTP_CHECK-1234` for an Http check, or `https://example.dynatrace.com/ui/browser-monitor/SYNTHETIC_TEST-1234` for a browser clickpath. +## Contribution + +This plugin was originally built by [TELUS](https://github.com/telus). + ## Disclaimer This plugin is not officially supported by Dynatrace. diff --git a/plugins/dynatrace/catalog-info.yaml b/plugins/dynatrace/catalog-info.yaml index 3dc14c96ff..64d6d5f845 100644 --- a/plugins/dynatrace/catalog-info.yaml +++ b/plugins/dynatrace/catalog-info.yaml @@ -4,6 +4,6 @@ metadata: name: backstage-plugin-dynatrace title: '@backstage/plugin-dynatrace' spec: - lifecycle: experimental + lifecycle: production type: backstage-frontend-plugin owner: maintainers diff --git a/plugins/dynatrace/package.json b/plugins/dynatrace/package.json index 83395cabb8..bfea48cc90 100644 --- a/plugins/dynatrace/package.json +++ b/plugins/dynatrace/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-dynatrace", - "version": "7.0.5-next.1", + "version": "7.0.5-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -50,8 +50,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "express": "^4.18.1", diff --git a/plugins/entity-feedback-backend/CHANGELOG.md b/plugins/entity-feedback-backend/CHANGELOG.md index 8c0b27d2aa..3f7cac2902 100644 --- a/plugins/entity-feedback-backend/CHANGELOG.md +++ b/plugins/entity-feedback-backend/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-entity-feedback-backend +## 0.2.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-entity-feedback-common@0.1.3 + ## 0.2.2-next.1 ### Patch Changes diff --git a/plugins/entity-feedback-backend/package.json b/plugins/entity-feedback-backend/package.json index 320748501f..8fe5048e4b 100644 --- a/plugins/entity-feedback-backend/package.json +++ b/plugins/entity-feedback-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-entity-feedback-backend", - "version": "0.2.2-next.1", + "version": "0.2.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/entity-feedback-backend/src/service/standaloneServer.ts b/plugins/entity-feedback-backend/src/service/standaloneServer.ts index 9395c72141..f230cc1463 100644 --- a/plugins/entity-feedback-backend/src/service/standaloneServer.ts +++ b/plugins/entity-feedback-backend/src/service/standaloneServer.ts @@ -18,7 +18,7 @@ import { createServiceBuilder, DatabaseManager, loadBackendConfig, - SingleHostDiscovery, + HostDiscovery, useHotMemoize, } from '@backstage/backend-common'; import { ConfigReader } from '@backstage/config'; @@ -38,7 +38,7 @@ export async function startStandaloneServer( ): Promise<Server> { const logger = options.logger.child({ service: 'entity-feedback-backend' }); const config = await loadBackendConfig({ logger, argv: process.argv }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const database = useHotMemoize(module, () => { const manager = DatabaseManager.fromConfig( diff --git a/plugins/entity-feedback/CHANGELOG.md b/plugins/entity-feedback/CHANGELOG.md index c5ead7f611..a88d2edb3f 100644 --- a/plugins/entity-feedback/CHANGELOG.md +++ b/plugins/entity-feedback/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-entity-feedback +## 0.2.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-entity-feedback-common@0.1.3 + ## 0.2.8-next.1 ### Patch Changes diff --git a/plugins/entity-feedback/package.json b/plugins/entity-feedback/package.json index b04e438e34..fb2d03d6c4 100644 --- a/plugins/entity-feedback/package.json +++ b/plugins/entity-feedback/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-entity-feedback", - "version": "0.2.8-next.1", + "version": "0.2.8-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -52,8 +52,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.1", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/entity-validation/CHANGELOG.md b/plugins/entity-validation/CHANGELOG.md index 0cb48bd911..1c4d966583 100644 --- a/plugins/entity-validation/CHANGELOG.md +++ b/plugins/entity-validation/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-entity-validation +## 0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + ## 0.1.10-next.1 ### Patch Changes diff --git a/plugins/entity-validation/package.json b/plugins/entity-validation/package.json index 5f8368aeb0..eb102cce17 100644 --- a/plugins/entity-validation/package.json +++ b/plugins/entity-validation/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-entity-validation", - "version": "0.1.10-next.1", + "version": "0.1.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -60,8 +60,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/events-backend-module-aws-sqs/CHANGELOG.md b/plugins/events-backend-module-aws-sqs/CHANGELOG.md index c45de40839..3f162afd2e 100644 --- a/plugins/events-backend-module-aws-sqs/CHANGELOG.md +++ b/plugins/events-backend-module-aws-sqs/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-events-backend-module-aws-sqs +## 0.2.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.2.8-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 c9825edbff..8ca4e27abf 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.2.8-next.1", + "version": "0.2.9-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-backend-module-azure/CHANGELOG.md b/plugins/events-backend-module-azure/CHANGELOG.md index 4883d87b10..bd0ca38f85 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.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-azure/package.json b/plugins/events-backend-module-azure/package.json index 18d712e5c4..87c95c0dbe 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.1.15-next.1", + "version": "0.1.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-backend-module-bitbucket-cloud/CHANGELOG.md b/plugins/events-backend-module-bitbucket-cloud/CHANGELOG.md index 21b4e7e6ca..813824f84b 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.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.1.15-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 5d6563e8b6..b3217dc782 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.1.15-next.1", + "version": "0.1.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-backend-module-gerrit/CHANGELOG.md b/plugins/events-backend-module-gerrit/CHANGELOG.md index aa368e48e4..a5b9334e3a 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.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-gerrit/package.json b/plugins/events-backend-module-gerrit/package.json index 9b05753c42..e23ade8c7b 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.1.15-next.1", + "version": "0.1.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-backend-module-github/CHANGELOG.md b/plugins/events-backend-module-github/CHANGELOG.md index 16979ed40b..cfac727ae8 100644 --- a/plugins/events-backend-module-github/CHANGELOG.md +++ b/plugins/events-backend-module-github/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-events-backend-module-github +## 0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-github/package.json b/plugins/events-backend-module-github/package.json index c6cce93bda..7a7d0f8a29 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.1.15-next.1", + "version": "0.1.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-backend-module-gitlab/CHANGELOG.md b/plugins/events-backend-module-gitlab/CHANGELOG.md index 24f8a1c574..a2dc5c06e0 100644 --- a/plugins/events-backend-module-gitlab/CHANGELOG.md +++ b/plugins/events-backend-module-gitlab/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-events-backend-module-gitlab +## 0.1.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/events-backend-module-gitlab/package.json b/plugins/events-backend-module-gitlab/package.json index 7e7ca5eb31..bc5708a589 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.1.15-next.1", + "version": "0.1.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-backend-test-utils/CHANGELOG.md b/plugins/events-backend-test-utils/CHANGELOG.md index 6df0dc6a05..ced0c8f8ce 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.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.1.15-next.1 ### Patch Changes diff --git a/plugins/events-backend-test-utils/package.json b/plugins/events-backend-test-utils/package.json index 9d09d999f4..79e512f16c 100644 --- a/plugins/events-backend-test-utils/package.json +++ b/plugins/events-backend-test-utils/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-events-backend-test-utils", "description": "The plugin-events-backend-test-utils for @backstage/plugin-events-node", - "version": "0.1.15-next.1", + "version": "0.1.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-backend/CHANGELOG.md b/plugins/events-backend/CHANGELOG.md index 9810584a6b..618bbfaeb1 100644 --- a/plugins/events-backend/CHANGELOG.md +++ b/plugins/events-backend/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-events-backend +## 0.2.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-events-node@0.2.15-next.2 + ## 0.2.14-next.1 ### Patch Changes diff --git a/plugins/events-backend/package.json b/plugins/events-backend/package.json index 03028ae833..d06abe1d69 100644 --- a/plugins/events-backend/package.json +++ b/plugins/events-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-events-backend", - "version": "0.2.14-next.1", + "version": "0.2.15-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/events-node/CHANGELOG.md b/plugins/events-node/CHANGELOG.md index 607651ad73..de950928af 100644 --- a/plugins/events-node/CHANGELOG.md +++ b/plugins/events-node/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-events-node +## 0.2.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-plugin-api@0.6.6-next.2 + ## 0.2.14-next.1 ### Patch Changes diff --git a/plugins/events-node/package.json b/plugins/events-node/package.json index 762b5237b0..1918c7f247 100644 --- a/plugins/events-node/package.json +++ b/plugins/events-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-events-node", "description": "The plugin-events-node module for @backstage/plugin-events-backend", - "version": "0.2.14-next.1", + "version": "0.2.15-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/example-todo-list-backend/CHANGELOG.md b/plugins/example-todo-list-backend/CHANGELOG.md index 8c1c37256d..95d2fead77 100644 --- a/plugins/example-todo-list-backend/CHANGELOG.md +++ b/plugins/example-todo-list-backend/CHANGELOG.md @@ -1,5 +1,16 @@ # @internal/plugin-todo-list-backend +## 1.0.18-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 1.0.18-next.1 ### Patch Changes diff --git a/plugins/example-todo-list-backend/package.json b/plugins/example-todo-list-backend/package.json index 3a3a38a5c4..d8ad84d67a 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.18-next.1", + "version": "1.0.18-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/example-todo-list-backend/src/service/standaloneServer.ts b/plugins/example-todo-list-backend/src/service/standaloneServer.ts index eedf1230ca..77c78365d6 100644 --- a/plugins/example-todo-list-backend/src/service/standaloneServer.ts +++ b/plugins/example-todo-list-backend/src/service/standaloneServer.ts @@ -17,7 +17,7 @@ import { createServiceBuilder, loadBackendConfig, - SingleHostDiscovery, + HostDiscovery, } from '@backstage/backend-common'; import { DefaultIdentityClient } from '@backstage/plugin-auth-node'; import { Server } from 'http'; @@ -36,7 +36,7 @@ export async function startStandaloneServer( const logger = options.logger.child({ service: 'todo-list-backend' }); logger.debug('Starting application server...'); const config = await loadBackendConfig({ logger, argv: process.argv }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const router = await createRouter({ logger, identity: DefaultIdentityClient.create({ diff --git a/plugins/example-todo-list-common/CHANGELOG.md b/plugins/example-todo-list-common/CHANGELOG.md index af2dba54e0..ad0c7d91e9 100644 --- a/plugins/example-todo-list-common/CHANGELOG.md +++ b/plugins/example-todo-list-common/CHANGELOG.md @@ -1,5 +1,12 @@ # @internal/plugin-todo-list-common +## 1.0.14-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 1.0.13 ### Patch Changes diff --git a/plugins/example-todo-list-common/package.json b/plugins/example-todo-list-common/package.json index 257f19e1c7..f2c852921c 100644 --- a/plugins/example-todo-list-common/package.json +++ b/plugins/example-todo-list-common/package.json @@ -1,6 +1,6 @@ { "name": "@internal/plugin-todo-list-common", - "version": "1.0.13", + "version": "1.0.14-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/example-todo-list/CHANGELOG.md b/plugins/example-todo-list/CHANGELOG.md index 04243ee26a..f23c1769d3 100644 --- a/plugins/example-todo-list/CHANGELOG.md +++ b/plugins/example-todo-list/CHANGELOG.md @@ -1,5 +1,14 @@ # @internal/plugin-todo-list +## 1.0.18-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + ## 1.0.18-next.1 ### Patch Changes diff --git a/plugins/example-todo-list/package.json b/plugins/example-todo-list/package.json index 589689a59c..698f4547c7 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.18-next.1", + "version": "1.0.18-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -48,8 +48,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/react": "^16.13.1 || ^17.0.0", diff --git a/plugins/explore-backend/CHANGELOG.md b/plugins/explore-backend/CHANGELOG.md index 4e27d8f124..1e49ebec92 100644 --- a/plugins/explore-backend/CHANGELOG.md +++ b/plugins/explore-backend/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-explore-backend +## 0.0.16-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-search-backend-module-explore@0.1.10-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-explore-common@0.0.2 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.0.15-next.1 ### Patch Changes diff --git a/plugins/explore-backend/package.json b/plugins/explore-backend/package.json index 1e8a4a456b..72c461a539 100644 --- a/plugins/explore-backend/package.json +++ b/plugins/explore-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-explore-backend", - "version": "0.0.15-next.1", + "version": "0.0.16-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/explore-react/CHANGELOG.md b/plugins/explore-react/CHANGELOG.md index 6d45e9a689..499e04120f 100644 --- a/plugins/explore-react/CHANGELOG.md +++ b/plugins/explore-react/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-explore-react +## 0.0.32-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-explore-common@0.0.2 + ## 0.0.32-next.0 ### Patch Changes diff --git a/plugins/explore-react/package.json b/plugins/explore-react/package.json index 9282573a38..cd9cd037e7 100644 --- a/plugins/explore-react/package.json +++ b/plugins/explore-react/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-explore-react", "description": "A frontend library for Backstage plugins that want to interact with the explore plugin", - "version": "0.0.32-next.0", + "version": "0.0.32-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -45,8 +45,8 @@ "@backstage/cli": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/react": "^16.13.1 || ^17.0.0", diff --git a/plugins/explore/CHANGELOG.md b/plugins/explore/CHANGELOG.md index 480d85437d..687cad7d4c 100644 --- a/plugins/explore/CHANGELOG.md +++ b/plugins/explore/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-explore +## 0.4.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-explore-common@0.0.2 + - @backstage/plugin-explore-react@0.0.32-next.1 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.4.11-next.1 ### Patch Changes diff --git a/plugins/explore/alpha-api-report.md b/plugins/explore/alpha-api-report.md index 3d6e527629..308cbac733 100644 --- a/plugins/explore/alpha-api-report.md +++ b/plugins/explore/alpha-api-report.md @@ -3,11 +3,13 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { Extension } from '@backstage/frontend-plugin-api'; // @alpha (undocumented) -const _default: BackstagePlugin; +const _default: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; export default _default; // @alpha (undocumented) diff --git a/plugins/explore/package.json b/plugins/explore/package.json index 0462d60884..e9967fda71 100644 --- a/plugins/explore/package.json +++ b/plugins/explore/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-explore", "description": "A Backstage plugin for building an exploration page of your software ecosystem", - "version": "0.4.11-next.1", + "version": "0.4.11-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -76,8 +76,8 @@ "@backstage/dev-utils": "workspace:^", "@backstage/plugin-catalog": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/firehydrant/CHANGELOG.md b/plugins/firehydrant/CHANGELOG.md index b1694c6717..8bb37cc531 100644 --- a/plugins/firehydrant/CHANGELOG.md +++ b/plugins/firehydrant/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-firehydrant +## 0.2.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.2.9-next.1 ### Patch Changes diff --git a/plugins/firehydrant/package.json b/plugins/firehydrant/package.json index 31848ee464..5ea154d32f 100644 --- a/plugins/firehydrant/package.json +++ b/plugins/firehydrant/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-firehydrant", "description": "A Backstage plugin that integrates towards FireHydrant", - "version": "0.2.9-next.1", + "version": "0.2.9-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -52,8 +52,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/fossa/CHANGELOG.md b/plugins/fossa/CHANGELOG.md index 68a526db00..e22cf6629c 100644 --- a/plugins/fossa/CHANGELOG.md +++ b/plugins/fossa/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-fossa +## 0.2.57-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.2.57-next.1 ### Patch Changes diff --git a/plugins/fossa/package.json b/plugins/fossa/package.json index 7fbe7e5570..cb79e48325 100644 --- a/plugins/fossa/package.json +++ b/plugins/fossa/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-fossa", "description": "A Backstage plugin that integrates towards FOSSA", - "version": "0.2.57-next.1", + "version": "0.2.57-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,8 +59,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/gcalendar/CHANGELOG.md b/plugins/gcalendar/CHANGELOG.md index 3e479c9bc4..0a64fd7019 100644 --- a/plugins/gcalendar/CHANGELOG.md +++ b/plugins/gcalendar/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-gcalendar +## 0.3.19-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.3.19-next.1 ### Patch Changes diff --git a/plugins/gcalendar/package.json b/plugins/gcalendar/package.json index be9b02d4cc..b871d49729 100644 --- a/plugins/gcalendar/package.json +++ b/plugins/gcalendar/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-gcalendar", - "version": "0.3.19-next.1", + "version": "0.3.19-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -57,8 +57,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/dompurify": "^2.3.3", diff --git a/plugins/gcp-projects/CHANGELOG.md b/plugins/gcp-projects/CHANGELOG.md index 69584e9c89..c5c8d88264 100644 --- a/plugins/gcp-projects/CHANGELOG.md +++ b/plugins/gcp-projects/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-gcp-projects +## 0.3.42-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.3.42-next.1 ### Patch Changes diff --git a/plugins/gcp-projects/package.json b/plugins/gcp-projects/package.json index 888f2c7a16..4c365e4a33 100644 --- a/plugins/gcp-projects/package.json +++ b/plugins/gcp-projects/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-gcp-projects", "description": "A Backstage plugin that helps you manage projects in GCP", - "version": "0.3.42-next.1", + "version": "0.3.42-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -53,8 +53,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/git-release-manager/CHANGELOG.md b/plugins/git-release-manager/CHANGELOG.md index 10c0d6770a..7471d15867 100644 --- a/plugins/git-release-manager/CHANGELOG.md +++ b/plugins/git-release-manager/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-git-release-manager +## 0.3.38-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.3.38-next.1 ### Patch Changes diff --git a/plugins/git-release-manager/package.json b/plugins/git-release-manager/package.json index 869d39633d..3a49aee327 100644 --- a/plugins/git-release-manager/package.json +++ b/plugins/git-release-manager/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-git-release-manager", "description": "A Backstage plugin that helps you manage releases in git", - "version": "0.3.38-next.1", + "version": "0.3.38-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/github-actions/CHANGELOG.md b/plugins/github-actions/CHANGELOG.md index e4bea23a68..9c57b8914b 100644 --- a/plugins/github-actions/CHANGELOG.md +++ b/plugins/github-actions/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-github-actions +## 0.6.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.6.6-next.1 ### Patch Changes diff --git a/plugins/github-actions/package.json b/plugins/github-actions/package.json index fa273363c9..446b7434c5 100644 --- a/plugins/github-actions/package.json +++ b/plugins/github-actions/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-github-actions", "description": "A Backstage plugin that integrates towards GitHub Actions", - "version": "0.6.6-next.1", + "version": "0.6.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -61,8 +61,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/github-deployments/CHANGELOG.md b/plugins/github-deployments/CHANGELOG.md index 637bb2ca7f..37f8d61176 100644 --- a/plugins/github-deployments/CHANGELOG.md +++ b/plugins/github-deployments/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-github-deployments +## 0.1.56-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.1.56-next.1 ### Patch Changes diff --git a/plugins/github-deployments/package.json b/plugins/github-deployments/package.json index edd3b6ff0e..0d5f24427f 100644 --- a/plugins/github-deployments/package.json +++ b/plugins/github-deployments/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-github-deployments", "description": "A Backstage plugin that integrates towards GitHub Deployments", - "version": "0.1.56-next.1", + "version": "0.1.56-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -56,8 +56,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/github-issues/CHANGELOG.md b/plugins/github-issues/CHANGELOG.md index e6a848c39d..c79e8c21eb 100644 --- a/plugins/github-issues/CHANGELOG.md +++ b/plugins/github-issues/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-github-issues +## 0.2.14-next.2 + +### Patch Changes + +- 7bd0a8ab3c: Filters out entities that belonged to a different github instance other than the one configured by the plugin +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.2.14-next.1 ### Patch Changes diff --git a/plugins/github-issues/package.json b/plugins/github-issues/package.json index 0a18bb22b9..ec68838caa 100644 --- a/plugins/github-issues/package.json +++ b/plugins/github-issues/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-github-issues", - "version": "0.2.14-next.1", + "version": "0.2.14-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/github-issues/src/api/githubIssuesApi.test.ts b/plugins/github-issues/src/api/githubIssuesApi.test.ts index e960d3123b..f3c1b29675 100644 --- a/plugins/github-issues/src/api/githubIssuesApi.test.ts +++ b/plugins/github-issues/src/api/githubIssuesApi.test.ts @@ -21,9 +21,22 @@ jest.mock('octokit', () => ({ import { ConfigApi, ErrorApi } from '@backstage/core-plugin-api'; import { ForwardedError } from '@backstage/errors'; -import { createFilterByClause, githubIssuesApi } from './githubIssuesApi'; -import type { GithubIssuesFilters } from './githubIssuesApi'; +import { + createFilterByClause, + githubIssuesApi, + Repository, + GithubIssuesFilters, +} from './githubIssuesApi'; +function entityRepository( + name: string, + locationHostname: string = 'github.com', +): Repository { + return { + locationHostname, + name, + }; +} function getFragment( filterBy = '', orderBy = 'field: UPDATED_AT, direction: DESC', @@ -110,7 +123,26 @@ describe('githubIssuesApi', () => { it('should call GitHub API with correct query with fragment for each repo', async () => { await api.fetchIssuesByRepoFromGithub( - ['mrwolny/yo-yo', 'mrwolny/yoyo', 'mrwolny/yo.yo'], + [ + entityRepository('mrwolny/yo-yo'), + entityRepository('mrwolny/yoyo'), + entityRepository('mrwolny/yo.yo'), + ], + 10, + ); + + expect(mockGraphQLQuery).toHaveBeenCalledTimes(1); + expect(mockGraphQLQuery).toHaveBeenCalledWith(getFragment()); + }); + + it("should only fetch data for entities hosted in the same GitHub instance as the plugin's config", async () => { + await api.fetchIssuesByRepoFromGithub( + [ + entityRepository('mrwolny/yo-yo'), + entityRepository('mrwolny/yoyo'), + entityRepository('mrwolny/yo.yo'), + entityRepository('mrwolny/another-repo', 'enterprise.github.com'), // This one should be filtered out + ], 10, ); @@ -120,7 +152,11 @@ describe('githubIssuesApi', () => { it('should call Github API with the correct filterBy and orderBy clauses', async () => { await api.fetchIssuesByRepoFromGithub( - ['mrwolny/yo-yo', 'mrwolny/yoyo', 'mrwolny/yo.yo'], + [ + entityRepository('mrwolny/yo-yo'), + entityRepository('mrwolny/yoyo'), + entityRepository('mrwolny/yo.yo'), + ], 10, { filterBy: { @@ -231,7 +267,7 @@ describe('githubIssuesApi', () => { ); const data = await api.fetchIssuesByRepoFromGithub( - ['mrwolny/yo-yo', 'mrwolny/notfound'], + [entityRepository('mrwolny/yo-yo'), entityRepository('mrwolny/notfound')], 10, ); @@ -301,7 +337,7 @@ describe('githubIssuesApi', () => { ); const data = await api.fetchIssuesByRepoFromGithub( - ['mrwolny/notfound'], + [entityRepository('mrwolny/notfound')], 10, ); @@ -341,7 +377,10 @@ describe('githubIssuesApi', () => { mockErrorApi as unknown as ErrorApi, ); - await api.fetchIssuesByRepoFromGithub(['mrwolny/notfound'], 10); + await api.fetchIssuesByRepoFromGithub( + [entityRepository('mrwolny/notfound')], + 10, + ); expect(mockErrorApi.post).toHaveBeenCalledTimes(1); expect(mockErrorApi.post).toHaveBeenCalledWith( diff --git a/plugins/github-issues/src/api/githubIssuesApi.ts b/plugins/github-issues/src/api/githubIssuesApi.ts index 32331ef6b1..d7b39989d8 100644 --- a/plugins/github-issues/src/api/githubIssuesApi.ts +++ b/plugins/github-issues/src/api/githubIssuesApi.ts @@ -24,6 +24,11 @@ import { import { readGithubIntegrationConfigs } from '@backstage/integration'; import { ForwardedError } from '@backstage/errors'; +/** @internal */ +export type Repository = { + name: string; + locationHostname: string; +}; /** @internal */ export type Assignee = { avatarUrl: string; @@ -116,9 +121,10 @@ export const githubIssuesApi = ( let octokit: Octokit; const getOctokit = async () => { - const baseUrl = readGithubIntegrationConfigs( + const githubConfig = readGithubIntegrationConfigs( configApi.getOptionalConfigArray('integrations.github') ?? [], - )[0].apiBaseUrl; + )[0]; + const baseUrl = githubConfig.apiBaseUrl; const token = await githubAuthApi.getAccessToken(['repo']); @@ -126,11 +132,11 @@ export const githubIssuesApi = ( octokit = new Octokit({ auth: token, ...(baseUrl && { baseUrl }) }); } - return octokit.graphql; + return { graphql: octokit.graphql, hostname: githubConfig.host }; }; const fetchIssuesByRepoFromGithub = async ( - repos: Array<string>, + repos: Array<Repository>, itemsPerRepo: number, { filterBy, @@ -140,30 +146,35 @@ export const githubIssuesApi = ( }, }: GithubIssuesByRepoOptions = {}, ): Promise<IssuesByRepo> => { - const graphql = await getOctokit(); + const { graphql, hostname } = await getOctokit(); const safeNames: Array<string> = []; + const repositories = repos + // only tries to fetch issues from repositories that are hosted on the same GitHub instance as the octokit + .filter(repo => repo.locationHostname === hostname) + .map(repo => { + const [owner, name] = repo.name.split('/'); - const repositories = repos.map(repo => { - const [owner, name] = repo.split('/'); + const safeNameRegex = /-|\./gi; + let safeName = name.replace(safeNameRegex, ''); - const safeNameRegex = /-|\./gi; - let safeName = name.replace(safeNameRegex, ''); + while (safeNames.includes(safeName)) { + safeName += 'x'; + } - while (safeNames.includes(safeName)) { - safeName += 'x'; - } + safeNames.push(safeName); - safeNames.push(safeName); - - return { - safeName, - name, - owner, - }; - }); + return { + safeName, + name, + owner, + }; + }); let issuesByRepo: IssuesByRepo = {}; try { + if (repositories.length === 0) { + throw new Error(`No repositories found for ${hostname}`); + } issuesByRepo = await graphql( createIssueByRepoQuery(repositories, itemsPerRepo, { filterBy, diff --git a/plugins/github-issues/src/components/GithubIssues/GithubIssues.test.tsx b/plugins/github-issues/src/components/GithubIssues/GithubIssues.test.tsx index 3f9e829de9..bf3cac7423 100644 --- a/plugins/github-issues/src/components/GithubIssues/GithubIssues.test.tsx +++ b/plugins/github-issues/src/components/GithubIssues/GithubIssues.test.tsx @@ -68,6 +68,8 @@ const entityComponent = { metadata: { annotations: { 'github.com/project-slug': 'backstage/backstage', + 'backstage.io/source-location': + 'url:https://github.com/backstage/backstage', }, name: 'backstage', }, diff --git a/plugins/github-issues/src/hooks/useEntityGithubRepositories.ts b/plugins/github-issues/src/hooks/useEntityGithubRepositories.ts index f3fab72090..b9763298e6 100644 --- a/plugins/github-issues/src/hooks/useEntityGithubRepositories.ts +++ b/plugins/github-issues/src/hooks/useEntityGithubRepositories.ts @@ -14,10 +14,15 @@ * limitations under the License. */ -import { Entity, stringifyEntityRef } from '@backstage/catalog-model'; +import { + Entity, + stringifyEntityRef, + getEntitySourceLocation, +} from '@backstage/catalog-model'; import { useApi } from '@backstage/core-plugin-api'; import { catalogApiRef, useEntity } from '@backstage/plugin-catalog-react'; import { useCallback, useEffect, useState } from 'react'; +import { Repository } from '../api'; const GITHUB_PROJECT_SLUG_ANNOTATION = 'github.com/project-slug'; @@ -25,18 +30,28 @@ export const getProjectNameFromEntity = (entity: Entity): string => { return entity?.metadata.annotations?.[GITHUB_PROJECT_SLUG_ANNOTATION] ?? ''; }; +export const getHostnameFromEntity = (entity: Entity): string => { + const { target } = getEntitySourceLocation(entity); + return new URL(target).hostname; +}; + export function useEntityGithubRepositories() { const { entity } = useEntity(); const catalogApi = useApi(catalogApiRef); - const [repositories, setRepositories] = useState<string[]>([]); + const [repositories, setRepositories] = useState<Repository[]>([]); const getRepositoriesNames = useCallback(async () => { if (entity.kind === 'Component' || entity.kind === 'API') { const entityName = getProjectNameFromEntity(entity); - + const locationHostname = getHostnameFromEntity(entity); if (entityName) { - setRepositories([entityName]); + setRepositories([ + { + name: entityName, + locationHostname, + }, + ]); } return; @@ -49,11 +64,26 @@ export function useEntityGithubRepositories() { }, }); - const entitiesNames: string[] = entitiesList.items.map(componentEntity => - getProjectNameFromEntity(componentEntity), + const repositoryEntities: Repository[] = entitiesList.items.reduce( + (acc: Repository[], componentEntity: Entity) => { + const entityName = getProjectNameFromEntity(componentEntity); + const entityLocationHostname = getHostnameFromEntity(componentEntity); + if ( + entityName && + !acc.some((it: Repository) => it.name === entityName) && + entityName.length + ) { + acc.push({ + name: entityName, + locationHostname: entityLocationHostname, + }); + } + return acc; + }, + [], ); - setRepositories([...new Set(entitiesNames)].filter(name => name.length)); + setRepositories(repositoryEntities); }, [catalogApi, entity]); useEffect(() => { diff --git a/plugins/github-issues/src/hooks/useGetIssuesByRepoFromGithub.ts b/plugins/github-issues/src/hooks/useGetIssuesByRepoFromGithub.ts index 8ec5f3ec65..0b5bad7f57 100644 --- a/plugins/github-issues/src/hooks/useGetIssuesByRepoFromGithub.ts +++ b/plugins/github-issues/src/hooks/useGetIssuesByRepoFromGithub.ts @@ -16,10 +16,14 @@ import { useApi } from '@backstage/core-plugin-api'; import useAsyncRetry from 'react-use/lib/useAsyncRetry'; -import { githubIssuesApiRef, GithubIssuesByRepoOptions } from '../api'; +import { + Repository, + githubIssuesApiRef, + GithubIssuesByRepoOptions, +} from '../api'; export const useGetIssuesByRepoFromGithub = ( - repos: Array<string>, + repos: Array<Repository>, itemsPerRepo: number, options?: GithubIssuesByRepoOptions, ) => { diff --git a/plugins/github-pull-requests-board/CHANGELOG.md b/plugins/github-pull-requests-board/CHANGELOG.md index cf06af7c0c..3dd30fd68e 100644 --- a/plugins/github-pull-requests-board/CHANGELOG.md +++ b/plugins/github-pull-requests-board/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-github-pull-requests-board +## 0.1.19-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.1.19-next.1 ### Patch Changes diff --git a/plugins/github-pull-requests-board/package.json b/plugins/github-pull-requests-board/package.json index b7d320931b..cfd6434668 100644 --- a/plugins/github-pull-requests-board/package.json +++ b/plugins/github-pull-requests-board/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-github-pull-requests-board", "description": "A Backstage plugin that allows you to see all open Pull Requests for all the repositories owned by your team", - "version": "0.1.19-next.1", + "version": "0.1.19-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,8 +59,8 @@ "@backstage/cli": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/gitops-profiles/CHANGELOG.md b/plugins/gitops-profiles/CHANGELOG.md index 7783bf960b..fbcdded7dd 100644 --- a/plugins/gitops-profiles/CHANGELOG.md +++ b/plugins/gitops-profiles/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-gitops-profiles +## 0.3.41-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.3.41-next.1 ### Patch Changes diff --git a/plugins/gitops-profiles/package.json b/plugins/gitops-profiles/package.json index d254a70390..5969918cb7 100644 --- a/plugins/gitops-profiles/package.json +++ b/plugins/gitops-profiles/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-gitops-profiles", "description": "A Backstage plugin that helps you manage GitOps profiles", - "version": "0.3.41-next.1", + "version": "0.3.41-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/gocd/CHANGELOG.md b/plugins/gocd/CHANGELOG.md index 33c2d9bd14..6b952b9a74 100644 --- a/plugins/gocd/CHANGELOG.md +++ b/plugins/gocd/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-gocd +## 0.1.31-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.1.31-next.1 ### Patch Changes diff --git a/plugins/gocd/package.json b/plugins/gocd/package.json index 9da32e57b1..adbb2936b4 100644 --- a/plugins/gocd/package.json +++ b/plugins/gocd/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-gocd", "description": "A Backstage plugin that integrates towards GoCD", - "version": "0.1.31-next.1", + "version": "0.1.31-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/lodash": "^4.14.173", diff --git a/plugins/graphiql/CHANGELOG.md b/plugins/graphiql/CHANGELOG.md index 0663cb0755..b39dd16f2c 100644 --- a/plugins/graphiql/CHANGELOG.md +++ b/plugins/graphiql/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-graphiql +## 0.2.55-next.2 + +### Patch Changes + +- 9c9a9100b0: Internal refactor to avoid using the deprecated `.icon.svg` extension. +- 06432f900c: Updated `/alpha` exports to use new `attachTo` option. +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.2.55-next.1 ### Patch Changes diff --git a/plugins/graphiql/alpha-api-report.md b/plugins/graphiql/alpha-api-report.md index 28537cfb15..6c0ea02988 100644 --- a/plugins/graphiql/alpha-api-report.md +++ b/plugins/graphiql/alpha-api-report.md @@ -3,6 +3,8 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { Extension } from '@backstage/frontend-plugin-api'; import { GraphQLEndpoint } from '@backstage/plugin-graphiql'; @@ -19,7 +21,7 @@ export function createEndpointExtension<TConfig extends {}>(options: { }): Extension<TConfig>; // @alpha (undocumented) -const _default: BackstagePlugin; +const _default: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; export default _default; // @alpha (undocumented) diff --git a/plugins/graphiql/package.json b/plugins/graphiql/package.json index d0ce3982a6..36e55b8c66 100644 --- a/plugins/graphiql/package.json +++ b/plugins/graphiql/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-graphiql", "description": "Backstage plugin for browsing GraphQL APIs", - "version": "0.2.55-next.1", + "version": "0.2.55-next.2", "publishConfig": { "access": "public" }, @@ -69,8 +69,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/codemirror": "^5.0.0", diff --git a/plugins/graphql-backend/CHANGELOG.md b/plugins/graphql-backend/CHANGELOG.md index c3991bd3a2..182d8840b0 100644 --- a/plugins/graphql-backend/CHANGELOG.md +++ b/plugins/graphql-backend/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-graphql-backend +## 0.1.44-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-graphql@0.3.24-next.0 + ## 0.1.43-next.1 ### Patch Changes diff --git a/plugins/graphql-backend/README.md b/plugins/graphql-backend/README.md index 970222fb1f..7e9f6c772e 100644 --- a/plugins/graphql-backend/README.md +++ b/plugins/graphql-backend/README.md @@ -1,28 +1,3 @@ # GraphQL Backend -## Getting Started - -This is the GraphQL Backend plugin. - -It is responsible for merging different `graphql-plugins` together to provide the end schema. - -To run it within the backend do: - -1. Register the router in `packages/backend/src/index.ts`: - -```ts -const graphqlEnv = useHotMemoize(module, () => createEnv('graphql')); - -const service = createServiceBuilder(module) - .loadConfig(configReader) - /** several different routers */ - .addRouter('/graphql', await graphql(graphqlEnv)); -``` - -2. Start the backend - -```bash -yarn workspace example-backend start -``` - -This will launch the full example backend. +This package has been deprecated, consider using [@frontside/backstage-plugin-graphql-backend](https://www.npmjs.com/package/@frontside/backstage-plugin-graphql-backend) instead. diff --git a/plugins/graphql-backend/package.json b/plugins/graphql-backend/package.json index 7ba1b47881..d07cd29a3d 100644 --- a/plugins/graphql-backend/package.json +++ b/plugins/graphql-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-graphql-backend", - "description": "An experimental Backstage backend plugin for GraphQL", - "version": "0.1.43-next.1", + "description": "Deprecated, consider using @frontside/backstage-plugin-graphql-backend instead", + "version": "0.1.44-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/graphql-voyager/CHANGELOG.md b/plugins/graphql-voyager/CHANGELOG.md index 5331c0a7fc..85b1cf7dae 100644 --- a/plugins/graphql-voyager/CHANGELOG.md +++ b/plugins/graphql-voyager/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-graphql-voyager +## 0.1.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.1.8-next.1 ### Patch Changes diff --git a/plugins/graphql-voyager/package.json b/plugins/graphql-voyager/package.json index bc62c158ac..7d8a07c2ac 100644 --- a/plugins/graphql-voyager/package.json +++ b/plugins/graphql-voyager/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-graphql-voyager", "description": "Backstage plugin for GraphQL Voyager", - "version": "0.1.8-next.1", + "version": "0.1.8-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -50,8 +50,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/home-react/CHANGELOG.md b/plugins/home-react/CHANGELOG.md index 2c2fce8504..63f73232fe 100644 --- a/plugins/home-react/CHANGELOG.md +++ b/plugins/home-react/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-home-react +## 0.1.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + ## 0.1.4-next.1 ### Patch Changes diff --git a/plugins/home-react/package.json b/plugins/home-react/package.json index f6e9655849..9708367ae4 100644 --- a/plugins/home-react/package.json +++ b/plugins/home-react/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-home-react", "description": "A Backstage plugin that contains react components helps you build a home page", - "version": "0.1.4-next.1", + "version": "0.1.4-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -51,8 +51,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/react-grid-layout": "^1.3.2", diff --git a/plugins/home/CHANGELOG.md b/plugins/home/CHANGELOG.md index 2d826ed5d0..1f0a83c1c9 100644 --- a/plugins/home/CHANGELOG.md +++ b/plugins/home/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-home +## 0.5.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-home-react@0.1.4-next.2 + ## 0.5.9-next.1 ### Patch Changes diff --git a/plugins/home/package.json b/plugins/home/package.json index 17c17cffe3..017f78be57 100644 --- a/plugins/home/package.json +++ b/plugins/home/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-home", "description": "A Backstage plugin that helps you build a home page", - "version": "0.5.9-next.1", + "version": "0.5.9-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -67,8 +67,8 @@ "@backstage/cli": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.1", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/ilert/CHANGELOG.md b/plugins/ilert/CHANGELOG.md index 31cace8de8..1960cff7b1 100644 --- a/plugins/ilert/CHANGELOG.md +++ b/plugins/ilert/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-ilert +## 0.2.14-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- 9c9a9100b0: Internal refactor to avoid using the deprecated `.icon.svg` extension. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.2.14-next.1 ### Patch Changes diff --git a/plugins/ilert/package.json b/plugins/ilert/package.json index 7fb0309bdc..da4161cc91 100644 --- a/plugins/ilert/package.json +++ b/plugins/ilert/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-ilert", "description": "A Backstage plugin that integrates towards iLert", - "version": "0.2.14-next.1", + "version": "0.2.14-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -56,8 +56,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/jenkins-backend/CHANGELOG.md b/plugins/jenkins-backend/CHANGELOG.md index b0aeddb339..e93668b500 100644 --- a/plugins/jenkins-backend/CHANGELOG.md +++ b/plugins/jenkins-backend/CHANGELOG.md @@ -1,5 +1,23 @@ # @backstage/plugin-jenkins-backend +## 0.2.9-next.2 + +### Patch Changes + +- 930ac236d8: Added support for the [new backend system](https://backstage.io/docs/backend-system/) +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-jenkins-common@0.1.20-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.2.8-next.1 ### Patch Changes diff --git a/plugins/jenkins-backend/README.md b/plugins/jenkins-backend/README.md index 133b9f42e2..d6f8fa5472 100644 --- a/plugins/jenkins-backend/README.md +++ b/plugins/jenkins-backend/README.md @@ -8,6 +8,20 @@ This is the backend half of the 2 Jenkins plugins and is responsible for: - finding the appropriate job(s) on that instance for an entity - connecting to Jenkins and gathering data to present to the frontend +## New Backend System + +The jenkins backend plugin has support for the [new backend system](https://backstage.io/docs/backend-system/), here's how you can set that up: + +In your `packages/backend/src/index.ts` make the following changes: + +```diff + import { createBackend } from '@backstage/backend-defaults'; + const backend = createBackend(); + // ... other feature additions + backend.add(import('@backstage/plugin-jenkins-backend')); + backend.start(); +``` + ## Integrating into a backstage instance This plugin needs to be added to an existing backstage instance. diff --git a/plugins/jenkins-backend/api-report.md b/plugins/jenkins-backend/api-report.md index fd1365547d..28dafa70bf 100644 --- a/plugins/jenkins-backend/api-report.md +++ b/plugins/jenkins-backend/api-report.md @@ -3,6 +3,7 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { BackendFeature } from '@backstage/backend-plugin-api'; import { CatalogApi } from '@backstage/catalog-client'; import { CompoundEntityRef } from '@backstage/catalog-model'; import { Config } from '@backstage/config'; @@ -79,6 +80,10 @@ export interface JenkinsInstanceConfig { username: string; } +// @public +const jenkinsPlugin: () => BackendFeature; +export default jenkinsPlugin; + // @public (undocumented) export interface RouterOptions { // (undocumented) diff --git a/plugins/jenkins-backend/package.json b/plugins/jenkins-backend/package.json index 12fe2debe1..02c9c8bf21 100644 --- a/plugins/jenkins-backend/package.json +++ b/plugins/jenkins-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-jenkins-backend", "description": "A Backstage backend plugin that integrates towards Jenkins", - "version": "0.2.8-next.1", + "version": "0.2.9-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -31,11 +31,13 @@ }, "dependencies": { "@backstage/backend-common": "workspace:^", + "@backstage/backend-plugin-api": "workspace:^", "@backstage/catalog-client": "workspace:^", "@backstage/catalog-model": "workspace:^", "@backstage/config": "workspace:^", "@backstage/errors": "workspace:^", "@backstage/plugin-auth-node": "workspace:^", + "@backstage/plugin-catalog-node": "workspace:^", "@backstage/plugin-jenkins-common": "workspace:^", "@backstage/plugin-permission-common": "workspace:^", "@backstage/plugin-permission-node": "workspace:^", diff --git a/plugins/jenkins-backend/src/index.ts b/plugins/jenkins-backend/src/index.ts index c55335c52d..4d01566a60 100644 --- a/plugins/jenkins-backend/src/index.ts +++ b/plugins/jenkins-backend/src/index.ts @@ -21,3 +21,4 @@ */ export * from './service'; +export { jenkinsPlugin as default } from './plugin'; diff --git a/plugins/jenkins-backend/src/plugin.test.tsx b/plugins/jenkins-backend/src/plugin.test.tsx new file mode 100644 index 0000000000..22ef6de078 --- /dev/null +++ b/plugins/jenkins-backend/src/plugin.test.tsx @@ -0,0 +1,22 @@ +/* + * Copyright 2021 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 { jenkinsPlugin } from './plugin'; + +describe('jenkins', () => { + it('should export the jenkins plugin', () => { + expect(jenkinsPlugin).toBeDefined(); + }); +}); diff --git a/plugins/jenkins-backend/src/plugin.ts b/plugins/jenkins-backend/src/plugin.ts new file mode 100644 index 0000000000..8da26d62aa --- /dev/null +++ b/plugins/jenkins-backend/src/plugin.ts @@ -0,0 +1,64 @@ +/* + * 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 { loggerToWinstonLogger } from '@backstage/backend-common'; +import { + createBackendPlugin, + coreServices, +} from '@backstage/backend-plugin-api'; +import { DefaultJenkinsInfoProvider } from './service/jenkinsInfoProvider'; +import { createRouter } from './service/router'; +import { catalogServiceRef } from '@backstage/plugin-catalog-node/alpha'; + +/** + * Jenkins backend plugin + * + * @public + */ +export const jenkinsPlugin = createBackendPlugin({ + pluginId: 'jenkins', + register(env) { + env.registerInit({ + deps: { + logger: coreServices.logger, + permissions: coreServices.permissions, + httpRouter: coreServices.httpRouter, + config: coreServices.rootConfig, + catalogClient: catalogServiceRef, + }, + async init({ logger, permissions, httpRouter, config, catalogClient }) { + const winstonLogger = loggerToWinstonLogger(logger); + const jenkinsInfoProvider = DefaultJenkinsInfoProvider.fromConfig({ + config, + catalog: catalogClient, + }); + httpRouter.use( + await createRouter({ + permissions, + /** + * Logger for logging purposes + */ + logger: winstonLogger, + /** + * Info provider to be able to get all necessary information for the APIs + */ + jenkinsInfoProvider, + }), + ); + }, + }); + }, +}); diff --git a/plugins/jenkins-backend/src/service/jenkinsApi.ts b/plugins/jenkins-backend/src/service/jenkinsApi.ts index 85271462eb..2cf432343f 100644 --- a/plugins/jenkins-backend/src/service/jenkinsApi.ts +++ b/plugins/jenkins-backend/src/service/jenkinsApi.ts @@ -54,6 +54,7 @@ export class JenkinsApiImpl { private static readonly jobTreeSpec = `actions[*], ${JenkinsApiImpl.lastBuildTreeSpec} jobs{0,1}, + url, name, fullName, displayName, @@ -64,6 +65,16 @@ export class JenkinsApiImpl { ${JenkinsApiImpl.jobTreeSpec} ]{0,50}`; + private static readonly jobBuildsTreeSpec = ` + name, + description, + url, + fullName, + displayName, + fullDisplayName, + inQueue, + builds[*]`; + constructor(private readonly permissionApi?: PermissionEvaluator) {} /** @@ -329,4 +340,35 @@ export class JenkinsApiImpl { const jobs = jobFullName.split('/'); return `${jenkinsInfo.baseUrl}/job/${jobs.join('/job/')}/${buildId}`; } + + async getJobBuilds(jenkinsInfo: JenkinsInfo, jobFullName: string) { + let jobName = jobFullName; + + if (jobFullName.includes('/')) { + const arr = jobFullName.split('/'); + const multibranchJobName = arr.shift(); + jobName = [ + multibranchJobName, + 'job', + encodeURIComponent(arr.join('/')), + ].join('/'); + } + + const response = await fetch( + `${ + jenkinsInfo.baseUrl + }/job/${jobName}/api/json?tree=${JenkinsApiImpl.jobBuildsTreeSpec.replace( + /\s/g, + '', + )}`, + { + method: 'get', + headers: jenkinsInfo.headers as HeaderInit, + }, + ); + + const jobBuilds = await response.json(); + + return jobBuilds; + } } diff --git a/plugins/jenkins-backend/src/service/router.ts b/plugins/jenkins-backend/src/service/router.ts index eea067fab6..06a04d8266 100644 --- a/plugins/jenkins-backend/src/service/router.ts +++ b/plugins/jenkins-backend/src/service/router.ts @@ -151,6 +151,32 @@ export async function createRouter( }, ); + router.get( + '/v1/entity/:namespace/:kind/:name/job/:jobFullName', + async (request, response) => { + const token = getBearerTokenFromAuthorizationHeader( + request.header('authorization'), + ); + const { namespace, kind, name, jobFullName } = request.params; + + const jenkinsInfo = await jenkinsInfoProvider.getInstance({ + entityRef: { + kind, + namespace, + name, + }, + jobFullName, + backstageToken: token, + }); + + const build = await jenkinsApi.getJobBuilds(jenkinsInfo, jobFullName); + + response.json({ + build: build, + }); + }, + ); + router.post( '/v1/entity/:namespace/:kind/:name/job/:jobFullName/:buildNumber', async (request, response) => { diff --git a/plugins/jenkins-common/CHANGELOG.md b/plugins/jenkins-common/CHANGELOG.md index 4fa915f473..816bc32b02 100644 --- a/plugins/jenkins-common/CHANGELOG.md +++ b/plugins/jenkins-common/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-jenkins-common +## 0.1.20-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.1.19 ### Patch Changes diff --git a/plugins/jenkins-common/package.json b/plugins/jenkins-common/package.json index 4bf522dadd..bf9dd8f344 100644 --- a/plugins/jenkins-common/package.json +++ b/plugins/jenkins-common/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-jenkins-common", - "version": "0.1.19", + "version": "0.1.20-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/jenkins/CHANGELOG.md b/plugins/jenkins/CHANGELOG.md index c7b92cbcdd..9874ab8bfc 100644 --- a/plugins/jenkins/CHANGELOG.md +++ b/plugins/jenkins/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-jenkins +## 0.8.7-next.2 + +### Patch Changes + +- 1a05cf34f6: Extend EntityJenkinsContent to receive columns as prop +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-jenkins-common@0.1.20-next.0 + ## 0.8.7-next.1 ### Patch Changes diff --git a/plugins/jenkins/README.md b/plugins/jenkins/README.md index 2a0ec451c8..b62eaab514 100644 --- a/plugins/jenkins/README.md +++ b/plugins/jenkins/README.md @@ -5,6 +5,8 @@ Website: [https://jenkins.io/](https://jenkins.io/) <img src="./src/assets/last-master-build.png" alt="Last master build"/> <img src="./src/assets/folder-results.png" alt="Folder results"/> <img src="./src/assets/build-details.png" alt="Build details"/> +<img src="./src/assets/jobrun-table.png" alt="Job builds records"/> +<img src="./src/assets/dynamic-columns.png" alt="Modify Table Columns"/> ## Setup @@ -74,7 +76,9 @@ metadata: name: 'your-component' description: 'a description' annotations: - jenkins.io/github-folder: 'folder-name/project-name' + jenkins.io/github-folder: 'folder-name/project-name' # deprecated + jenkins.io/job-full-name: 'folder-name/project-name' # use this instead + spec: type: service lifecycle: experimental @@ -97,3 +101,35 @@ spec: - Only works with organization folder projects backed by GitHub - No pagination support currently, limited to 50 projects - don't run this on a Jenkins instance with lots of builds + +## EntityJobRunsTable + +- View all builds of a particular job +- shows average build time for successful builds + +## Modify Columns of EntityJenkinsContent + +- now you can pass down column props to show the columns/metadata as per your use case. + +```tsx +export const generatedColumns: TableColumn[] = [ + { + title: 'Timestamp', + field: 'lastBuild.timestamp', + render: (row: Partial<Project>) => ( + <> + <Typography paragraph> + {` + ${new Date(row.lastBuild?.timestamp).toLocaleDateString()} + ${new Date(row.lastBuild?.timestamp).toLocaleTimeString()} + `} + </Typography> + </> + ), + }, +] + +// ... +<EntityJenkinsContent columns={generatedColumns}/> +// ... +``` diff --git a/plugins/jenkins/api-report.md b/plugins/jenkins/api-report.md index 611a56cd5f..c1b8ad2b81 100644 --- a/plugins/jenkins/api-report.md +++ b/plugins/jenkins/api-report.md @@ -15,9 +15,15 @@ import { InfoCardVariants } from '@backstage/core-components'; import { JSX as JSX_2 } from 'react'; import { default as React_2 } from 'react'; import { RouteRef } from '@backstage/core-plugin-api'; +import { TableColumn } from '@backstage/core-components'; // @public (undocumented) -export const EntityJenkinsContent: () => JSX_2.Element; +export const EntityJenkinsContent: (props: { + columns?: TableColumn<Project>[] | undefined; +}) => JSX_2.Element; + +// @public (undocumented) +export const EntityJobRunsTable: () => JSX_2.Element; // @public (undocumented) export const EntityLatestJenkinsRunCard: (props: { @@ -45,7 +51,13 @@ export interface JenkinsApi { jobFullName: string; buildNumber: string; }): Promise<Build>; - // Warning: (ae-forgotten-export) The symbol "Project" needs to be exported by the entry point index.d.ts + // Warning: (ae-forgotten-export) The symbol "Job" needs to be exported by the entry point index.d.ts + // + // (undocumented) + getJobBuilds(options: { + entity: CompoundEntityRef; + jobFullName: string; + }): Promise<Job>; getProjects(options: { entity: CompoundEntityRef; filter: { @@ -80,6 +92,11 @@ export class JenkinsClient implements JenkinsApi { buildNumber: string; }): Promise<Build>; // (undocumented) + getJobBuilds(options: { + entity: CompoundEntityRef; + jobFullName: string; + }): Promise<Job>; + // (undocumented) getProjects(options: { entity: CompoundEntityRef; filter: { @@ -117,8 +134,28 @@ export const LatestRunCard: (props: { // @public (undocumented) export const LEGACY_JENKINS_ANNOTATION = 'jenkins.io/github-folder'; +// @public (undocumented) +export interface Project { + // (undocumented) + displayName: string; + // (undocumented) + fullDisplayName: string; + // (undocumented) + fullName: string; + // (undocumented) + inQueue: string; + // (undocumented) + lastBuild: Build; + // (undocumented) + onRestartClick: () => Promise<void>; + // (undocumented) + status: string; +} + // Warning: (ae-missing-release-tag) "Router" is part of the package's API, but it is missing a release tag (@alpha, @beta, @public, or @internal) // // @public (undocumented) -export const Router: () => React_2.JSX.Element; +export const Router: (props: { + columns?: TableColumn<Project>[]; +}) => React_2.JSX.Element; ``` diff --git a/plugins/jenkins/package.json b/plugins/jenkins/package.json index cfbac50ae5..7d4e60f19b 100644 --- a/plugins/jenkins/package.json +++ b/plugins/jenkins/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-jenkins", "description": "A Backstage plugin that integrates towards Jenkins", - "version": "0.8.7-next.1", + "version": "0.8.7-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -58,8 +58,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/testing-library__jest-dom": "^5.9.1", diff --git a/plugins/jenkins/src/api/JenkinsApi.ts b/plugins/jenkins/src/api/JenkinsApi.ts index 04bd313227..1f6e7ec294 100644 --- a/plugins/jenkins/src/api/JenkinsApi.ts +++ b/plugins/jenkins/src/api/JenkinsApi.ts @@ -56,7 +56,32 @@ export interface Build { }; status: string; // == building ? 'running' : result, } +export interface JobBuild { + timestamp: number; + building: boolean; + duration: number; + result?: string; + fullDisplayName: string; + displayName: string; + url: string; + number: number; + inProgress: boolean; + queueId: number; + id: number; +} +export interface Job { + name: string; + displayName: string; + description: string; + fullDisplayName: string; + inQueue: boolean; + fullName: string; + url: string; + builds: JobBuild[]; +} + +/** @public */ export interface Project { // standard Jenkins lastBuild: Build; @@ -98,6 +123,11 @@ export interface JenkinsApi { buildNumber: string; }): Promise<Build>; + getJobBuilds(options: { + entity: CompoundEntityRef; + jobFullName: string; + }): Promise<Job>; + retry(options: { entity: CompoundEntityRef; jobFullName: string; @@ -212,4 +242,28 @@ export class JenkinsClient implements JenkinsApi { const { token } = await this.identityApi.getCredentials(); return token; } + + async getJobBuilds(options: { + entity: CompoundEntityRef; + jobFullName: string; + }): Promise<Job> { + const { entity, jobFullName } = options; + const url = `${await this.discoveryApi.getBaseUrl( + 'jenkins', + )}/v1/entity/${encodeURIComponent(entity.namespace)}/${encodeURIComponent( + entity.kind, + )}/${encodeURIComponent(entity.name)}/job/${encodeURIComponent( + jobFullName, + )}`; + + const idToken = await this.getToken(); + const response = await fetch(url, { + method: 'GET', + headers: { + ...(idToken && { Authorization: `Bearer ${idToken}` }), + }, + }); + + return (await response.json()).build; + } } diff --git a/plugins/jenkins/src/api/index.ts b/plugins/jenkins/src/api/index.ts index af1829c0b4..32c98ae5a6 100644 --- a/plugins/jenkins/src/api/index.ts +++ b/plugins/jenkins/src/api/index.ts @@ -16,4 +16,4 @@ export { JenkinsClient, jenkinsApiRef } from './JenkinsApi'; -export type { JenkinsApi } from './JenkinsApi'; +export type { JenkinsApi, Project } from './JenkinsApi'; diff --git a/plugins/jenkins/src/assets/dynamic-columns.png b/plugins/jenkins/src/assets/dynamic-columns.png new file mode 100644 index 0000000000..1a85257403 Binary files /dev/null and b/plugins/jenkins/src/assets/dynamic-columns.png differ diff --git a/plugins/jenkins/src/assets/jobrun-table.png b/plugins/jenkins/src/assets/jobrun-table.png new file mode 100644 index 0000000000..9fff841c3b Binary files /dev/null and b/plugins/jenkins/src/assets/jobrun-table.png differ diff --git a/plugins/jenkins/src/components/BuildsPage/lib/CITable/CITable.tsx b/plugins/jenkins/src/components/BuildsPage/lib/CITable/CITable.tsx index f82ce2e7ec..1f5d272c61 100644 --- a/plugins/jenkins/src/components/BuildsPage/lib/CITable/CITable.tsx +++ b/plugins/jenkins/src/components/BuildsPage/lib/CITable/CITable.tsx @@ -13,222 +13,15 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -import { Link, Progress, Table, TableColumn } from '@backstage/core-components'; -import { alertApiRef, useApi, useRouteRef } from '@backstage/core-plugin-api'; -import { useEntityPermission } from '@backstage/plugin-catalog-react/alpha'; -import { Box, IconButton, Tooltip, Typography } from '@material-ui/core'; +import { Table, TableColumn } from '@backstage/core-components'; +import { Box, Typography } from '@material-ui/core'; import RetryIcon from '@material-ui/icons/Replay'; -import VisibilityIcon from '@material-ui/icons/Visibility'; -import { default as React, useState } from 'react'; +import { default as React } from 'react'; import { Project } from '../../../../api/JenkinsApi'; import JenkinsLogo from '../../../../assets/JenkinsLogo.svg'; -import { buildRouteRef } from '../../../../plugin'; import { useBuilds } from '../../../useBuilds'; -import { JenkinsRunStatus } from '../Status'; -import { jenkinsExecutePermission } from '@backstage/plugin-jenkins-common'; - -const FailCount = ({ count }: { count: number }): JSX.Element | null => { - if (count !== 0) { - return <>{count} failed</>; - } - return null; -}; - -const SkippedCount = ({ count }: { count: number }): JSX.Element | null => { - if (count !== 0) { - return <>{count} skipped</>; - } - return null; -}; - -const FailSkippedWidget = ({ - skipped, - failed, -}: { - skipped: number; - failed: number; -}): JSX.Element | null => { - if (skipped === 0 && failed === 0) { - return null; - } - - if (skipped !== 0 && failed !== 0) { - return ( - <> - {' '} - (<FailCount count={failed} />, <SkippedCount count={skipped} />) - </> - ); - } - - if (failed !== 0) { - return ( - <> - {' '} - (<FailCount count={failed} />) - </> - ); - } - - if (skipped !== 0) { - return ( - <> - {' '} - (<SkippedCount count={skipped} />) - </> - ); - } - - return null; -}; - -const generatedColumns: TableColumn[] = [ - { - title: 'Timestamp', - defaultSort: 'desc', - hidden: true, - field: 'lastBuild.timestamp', - }, - { - title: 'Build', - field: 'fullName', - highlight: true, - render: (row: Partial<Project>) => { - const LinkWrapper = () => { - const routeLink = useRouteRef(buildRouteRef); - if (!row.fullName || !row.lastBuild?.number) { - return ( - <> - {row.fullName || - row.fullDisplayName || - row.displayName || - 'Unknown'} - </> - ); - } - - return ( - <Link - to={routeLink({ - jobFullName: encodeURIComponent(row.fullName), - buildNumber: String(row.lastBuild?.number), - })} - > - {row.fullDisplayName} - </Link> - ); - }; - - return <LinkWrapper />; - }, - }, - { - title: 'Source', - field: 'lastBuild.source.branchName', - render: (row: Partial<Project>) => ( - <> - <Typography paragraph> - <Link to={row.lastBuild?.source?.url ?? ''}> - {row.lastBuild?.source?.branchName} - </Link> - </Typography> - <Typography paragraph>{row.lastBuild?.source?.commit?.hash}</Typography> - </> - ), - }, - { - title: 'Status', - field: 'status', - render: (row: Partial<Project>) => { - return ( - <Box display="flex" alignItems="center"> - <JenkinsRunStatus status={row.status} /> - </Box> - ); - }, - }, - { - title: 'Tests', - sorting: false, - render: (row: Partial<Project>) => { - return ( - <> - <Typography paragraph> - {row.lastBuild?.tests && ( - <Link to={row.lastBuild?.tests.testUrl ?? ''}> - {row.lastBuild?.tests.passed} / {row.lastBuild?.tests.total}{' '} - passed - <FailSkippedWidget - skipped={row.lastBuild?.tests.skipped} - failed={row.lastBuild?.tests.failed} - /> - </Link> - )} - - {!row.lastBuild?.tests && 'n/a'} - </Typography> - </> - ); - }, - }, - { - title: 'Actions', - sorting: false, - render: (row: Partial<Project>) => { - const ActionWrapper = () => { - const [isLoadingRebuild, setIsLoadingRebuild] = useState(false); - const { allowed, loading } = useEntityPermission( - jenkinsExecutePermission, - ); - - const alertApi = useApi(alertApiRef); - - const onRebuild = async () => { - if (row.onRestartClick) { - setIsLoadingRebuild(true); - try { - await row.onRestartClick(); - alertApi.post({ - message: 'Jenkins re-build has successfully executed', - severity: 'success', - display: 'transient', - }); - } catch (e) { - alertApi.post({ - message: `Jenkins re-build has failed. Error: ${e.message}`, - severity: 'error', - }); - } finally { - setIsLoadingRebuild(false); - } - } - }; - - return ( - <div style={{ width: '98px' }}> - {row.lastBuild?.url && ( - <Tooltip title="View build"> - <IconButton href={row.lastBuild.url} target="_blank"> - <VisibilityIcon /> - </IconButton> - </Tooltip> - )} - {isLoadingRebuild && <Progress />} - {!isLoadingRebuild && ( - <Tooltip title="Rerun build"> - <IconButton onClick={onRebuild} disabled={loading || !allowed}> - <RetryIcon /> - </IconButton> - </Tooltip> - )} - </div> - ); - }; - return <ActionWrapper />; - }, - width: '10%', - }, -]; +import { columnFactories } from './columns'; +import { defaultCITableColumns } from './presets'; type Props = { loading: boolean; @@ -239,6 +32,7 @@ type Props = { total: number; pageSize: number; onChangePageSize: (pageSize: number) => void; + columns: TableColumn<Project>[]; }; export const CITableView = ({ @@ -249,6 +43,7 @@ export const CITableView = ({ projects, onChangePage, onChangePageSize, + columns, total, }: Props) => { const projectsInPage = projects?.slice( @@ -279,20 +74,31 @@ export const CITableView = ({ <Typography variant="h6">Projects</Typography> </Box> } - columns={generatedColumns} + columns={ + columns && columns.length !== 0 ? columns : defaultCITableColumns + } /> ); }; -export const CITable = () => { +type CITableProps = { + columns?: TableColumn<Project>[]; +}; + +export const CITable = ({ columns }: CITableProps) => { const [tableProps, { setPage, retry, setPageSize }] = useBuilds(); return ( <CITableView {...tableProps} + columns={columns || ([] as TableColumn<Project>[])} retry={retry} onChangePageSize={setPageSize} onChangePage={setPage} /> ); }; + +CITable.columns = columnFactories; + +CITable.defaultCITableColumns = defaultCITableColumns; diff --git a/plugins/jenkins/src/components/BuildsPage/lib/CITable/columns.tsx b/plugins/jenkins/src/components/BuildsPage/lib/CITable/columns.tsx new file mode 100644 index 0000000000..f18d3e5b21 --- /dev/null +++ b/plugins/jenkins/src/components/BuildsPage/lib/CITable/columns.tsx @@ -0,0 +1,283 @@ +/* + * 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 { Link, Progress, TableColumn } from '@backstage/core-components'; +import { alertApiRef, useApi, useRouteRef } from '@backstage/core-plugin-api'; +import { useEntityPermission } from '@backstage/plugin-catalog-react/alpha'; +import { Box, IconButton, Tooltip, Typography } from '@material-ui/core'; +import RetryIcon from '@material-ui/icons/Replay'; +import VisibilityIcon from '@material-ui/icons/Visibility'; +import HistoryIcon from '@material-ui/icons/History'; +import { default as React, useState } from 'react'; +import { Project } from '../../../../api/JenkinsApi'; +import { buildRouteRef, jobRunsRouteRef } from '../../../../plugin'; +import { JenkinsRunStatus } from '../Status'; +import { jenkinsExecutePermission } from '@backstage/plugin-jenkins-common'; + +const FailCount = ({ count }: { count: number }): JSX.Element | null => { + if (count !== 0) { + return <>{count} failed</>; + } + return null; +}; + +const SkippedCount = ({ count }: { count: number }): JSX.Element | null => { + if (count !== 0) { + return <>{count} skipped</>; + } + return null; +}; + +const FailSkippedWidget = ({ + skipped, + failed, +}: { + skipped: number; + failed: number; +}): JSX.Element | null => { + if (skipped === 0 && failed === 0) { + return null; + } + + if (skipped !== 0 && failed !== 0) { + return ( + <> + {' '} + (<FailCount count={failed} />, <SkippedCount count={skipped} />) + </> + ); + } + + if (failed !== 0) { + return ( + <> + {' '} + (<FailCount count={failed} />) + </> + ); + } + + if (skipped !== 0) { + return ( + <> + {' '} + (<SkippedCount count={skipped} />) + </> + ); + } + + return null; +}; + +export const columnFactories = Object.freeze({ + createTimestampColumn(): TableColumn<Project> { + return { + title: 'Timestamp', + defaultSort: 'desc', + hidden: true, + field: 'lastBuild.timestamp', + }; + }, + + createBuildColumn(): TableColumn<Project> { + return { + title: 'Build', + field: 'fullName', + highlight: true, + render: (row: Partial<Project>) => { + const LinkWrapper = () => { + const routeLink = useRouteRef(buildRouteRef); + if (!row.fullName || !row.lastBuild?.number) { + return ( + <> + {row.fullName || + row.fullDisplayName || + row.displayName || + 'Unknown'} + </> + ); + } + + return ( + <Link + to={routeLink({ + jobFullName: encodeURIComponent(row.fullName), + buildNumber: String(row.lastBuild?.number), + })} + > + {row.fullDisplayName} + </Link> + ); + }; + + return <LinkWrapper />; + }, + }; + }, + + createSourceColumn(): TableColumn<Project> { + return { + title: 'Source', + field: 'lastBuild.source.branchName', + render: (row: Partial<Project>) => ( + <> + <Typography paragraph> + <Link to={row.lastBuild?.source?.url ?? ''}> + {row.lastBuild?.source?.branchName} + </Link> + </Typography> + <Typography paragraph> + {row.lastBuild?.source?.commit?.hash} + </Typography> + </> + ), + }; + }, + + createStatusColumn(): TableColumn<Project> { + return { + title: 'Status', + field: 'status', + render: (row: Partial<Project>) => { + return ( + <Box display="flex" alignItems="center"> + <JenkinsRunStatus status={row.status} /> + </Box> + ); + }, + }; + }, + + createTestColumn(): TableColumn<Project> { + return { + title: 'Tests', + sorting: false, + render: (row: Partial<Project>) => { + return ( + <> + <Typography paragraph> + {row.lastBuild?.tests && ( + <Link to={row.lastBuild?.tests.testUrl ?? ''}> + {row.lastBuild?.tests.passed} / {row.lastBuild?.tests.total}{' '} + passed + <FailSkippedWidget + skipped={row.lastBuild?.tests.skipped} + failed={row.lastBuild?.tests.failed} + /> + </Link> + )} + + {!row.lastBuild?.tests && 'n/a'} + </Typography> + </> + ); + }, + }; + }, + + createLastRunDuration(): TableColumn<Project> { + return { + title: 'Last Run Duration', + align: 'left', + render: (row: Partial<Project>) => ( + <> + <Typography> + {row?.lastBuild?.duration + ? (row?.lastBuild?.duration / 1000) + .toFixed(1) + .toString() + .concat(' s') + : ''}{' '} + </Typography> + </> + ), + }; + }, + + createActionsColumn(): TableColumn<Project> { + return { + title: 'Actions', + sorting: false, + render: (row: Partial<Project>) => { + const ActionWrapper = () => { + const [isLoadingRebuild, setIsLoadingRebuild] = useState(false); + const { allowed, loading } = useEntityPermission( + jenkinsExecutePermission, + ); + + const alertApi = useApi(alertApiRef); + const jobRunsLink = useRouteRef(jobRunsRouteRef); + + const onRebuild = async () => { + if (row.onRestartClick) { + setIsLoadingRebuild(true); + try { + await row.onRestartClick(); + alertApi.post({ + message: 'Jenkins re-build has successfully executed', + severity: 'success', + display: 'transient', + }); + } catch (e) { + alertApi.post({ + message: `Jenkins re-build has failed. Error: ${e.message}`, + severity: 'error', + }); + } finally { + setIsLoadingRebuild(false); + } + } + }; + + return ( + <div style={{ width: '148px' }}> + {row.lastBuild?.url && ( + <Tooltip title="View build"> + <IconButton href={row.lastBuild.url} target="_blank"> + <VisibilityIcon /> + </IconButton> + </Tooltip> + )} + {isLoadingRebuild && <Progress />} + {!isLoadingRebuild && ( + <Tooltip title="Rerun build"> + <IconButton + onClick={onRebuild} + disabled={loading || !allowed} + > + <RetryIcon /> + </IconButton> + </Tooltip> + )} + <Link + to={jobRunsLink({ + jobFullName: encodeURIComponent(row.fullName || ''), + })} + > + <Tooltip title="View Runs"> + <IconButton> + <HistoryIcon /> + </IconButton> + </Tooltip> + </Link> + </div> + ); + }; + return <ActionWrapper />; + }, + width: '10%', + }; + }, +}); diff --git a/plugins/jenkins/src/components/BuildsPage/lib/CITable/presets.ts b/plugins/jenkins/src/components/BuildsPage/lib/CITable/presets.ts new file mode 100644 index 0000000000..828e035c8e --- /dev/null +++ b/plugins/jenkins/src/components/BuildsPage/lib/CITable/presets.ts @@ -0,0 +1,29 @@ +/* + * Copyright 2021 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 { Project } from '../../../../api'; +import { columnFactories } from './columns'; +import { TableColumn } from '@backstage/core-components'; + +export const defaultCITableColumns: TableColumn<Project>[] = [ + columnFactories.createTimestampColumn(), + columnFactories.createSourceColumn(), + columnFactories.createBuildColumn(), + columnFactories.createTestColumn(), + columnFactories.createStatusColumn(), + columnFactories.createLastRunDuration(), + columnFactories.createActionsColumn(), +]; diff --git a/plugins/jenkins/src/components/JobRunsTable/JobRunsTable.tsx b/plugins/jenkins/src/components/JobRunsTable/JobRunsTable.tsx new file mode 100644 index 0000000000..78b66b98eb --- /dev/null +++ b/plugins/jenkins/src/components/JobRunsTable/JobRunsTable.tsx @@ -0,0 +1,187 @@ +/* + * 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 { Link, Table, TableColumn } from '@backstage/core-components'; +import { Box, IconButton, Tooltip, Typography } from '@material-ui/core'; +import { default as React } from 'react'; +import JenkinsLogo from './../../assets/JenkinsLogo.svg'; +import { useJobRuns } from './../useJobRuns'; +import { Job, JobBuild } from './../../api/JenkinsApi'; +import { JenkinsRunStatus } from './../BuildsPage/lib/Status'; +import VisibilityIcon from '@material-ui/icons/Visibility'; +import { jobRunsRouteRef } from '../../plugin'; +import { useRouteRefParams } from '@backstage/core-plugin-api'; + +const generatedColumns: TableColumn[] = [ + { + title: 'Number', + field: 'number', + render: (row: Partial<JobBuild>) => { + return ( + <Box display="flex" alignItems="center"> + <Typography paragraph> + <Link to={row.url ?? ''}>{row.number}</Link> + </Typography> + </Box> + ); + }, + }, + { + title: 'Timestamp', + field: 'timestamp', + render: (row: Partial<JobBuild>) => { + return ( + <Box display="flex" alignItems="center"> + <Typography> + {row?.timestamp ? new Date(row?.timestamp).toLocaleString() : ' '} + </Typography> + </Box> + ); + }, + }, + { + title: 'Result', + field: 'result', + render: (row: Partial<JobBuild>) => { + return ( + <Box display="flex" alignItems="center"> + {row.inProgress ? ( + <Typography>In Progress</Typography> + ) : ( + <JenkinsRunStatus status={row?.result} /> + )} + </Box> + ); + }, + }, + { + title: 'Duration', + field: 'duration', + render: (row: Partial<JobBuild>) => { + return ( + <Box display="flex" alignItems="center"> + <Typography> + {row?.duration + ? (row.duration / 1000).toFixed(1).toString().concat(' s') + : ''} + </Typography> + </Box> + ); + }, + }, + + { + title: 'Actions', + render: (row: Partial<JobBuild>) => { + const ActionWrapper = () => { + return ( + <div style={{ width: '98px' }}> + {row?.url && ( + <Tooltip title="View build"> + <Link component={IconButton} to={row.url}> + <VisibilityIcon /> + </Link> + </Tooltip> + )} + </div> + ); + }; + return <ActionWrapper />; + }, + width: '10%', + }, +]; + +type Props = { + loading: boolean; + jobRuns?: Job; + page: number; + onChangePage: (page: number) => void; + pageSize: number; + onChangePageSize: (pageSize: number) => void; +}; + +export const JobRunsTableView = ({ + loading, + pageSize, + page, + jobRuns, + onChangePage, + onChangePageSize, +}: Props) => { + const builds = jobRuns?.builds.slice( + page * pageSize, + page * pageSize + pageSize, + ); + let sumOfAllSuccessfulJobDuration = 0; + + const successfulJobCount = + builds?.reduce((count, build) => { + if (!build.inProgress && build.result === 'SUCCESS') { + sumOfAllSuccessfulJobDuration += build.duration; + return count + 1; + } + return count; + }, 0) || 0; + + let avgTime; + + if (successfulJobCount > 0) { + avgTime = (sumOfAllSuccessfulJobDuration / successfulJobCount / 1000) + .toFixed(1) + .toString(); + } + + return ( + <Table + isLoading={loading} + options={{ paging: true, pageSize, padding: 'dense' }} + totalCount={jobRuns?.builds.length || 0} + page={page} + data={builds ?? []} + onPageChange={onChangePage} + onRowsPerPageChange={onChangePageSize} + title={ + <Box> + <Box display="flex" alignItems="center"> + <img src={JenkinsLogo} alt="Jenkins logo" height="50px" /> + <Box mr={2} /> + <Typography variant="h6">{`${jobRuns?.displayName} Runs`}</Typography> + </Box> + <Box display="flex" alignItems="center" mt={2}> + <Typography variant="h6"> + Average Build Time For Last {successfulJobCount} Successful jobs :{' '} + {avgTime || 0} + </Typography> + </Box> + </Box> + } + columns={generatedColumns} + /> + ); +}; + +export const JobRunsTable = () => { + const { jobFullName } = useRouteRefParams(jobRunsRouteRef); + const [tableProps, { setPage, setPageSize }] = useJobRuns(jobFullName); + + return ( + <JobRunsTableView + {...tableProps} + onChangePageSize={setPageSize} + onChangePage={setPage} + /> + ); +}; diff --git a/plugins/jenkins/src/components/JobRunsTable/index.ts b/plugins/jenkins/src/components/JobRunsTable/index.ts new file mode 100644 index 0000000000..b74beeb315 --- /dev/null +++ b/plugins/jenkins/src/components/JobRunsTable/index.ts @@ -0,0 +1,16 @@ +/* + * 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. + */ +export { JobRunsTable } from './JobRunsTable'; diff --git a/plugins/jenkins/src/components/Router.tsx b/plugins/jenkins/src/components/Router.tsx index af13575c62..30ce999f31 100644 --- a/plugins/jenkins/src/components/Router.tsx +++ b/plugins/jenkins/src/components/Router.tsx @@ -15,31 +15,39 @@ */ import { Entity } from '@backstage/catalog-model'; -import { MissingAnnotationEmptyState } from '@backstage/core-components'; +import { + MissingAnnotationEmptyState, + TableColumn, +} from '@backstage/core-components'; import { useEntity } from '@backstage/plugin-catalog-react'; import React from 'react'; import { Route, Routes } from 'react-router-dom'; import { JENKINS_ANNOTATION, LEGACY_JENKINS_ANNOTATION } from '../constants'; -import { buildRouteRef } from '../plugin'; +import { buildRouteRef, jobRunsRouteRef } from '../plugin'; import { CITable } from './BuildsPage/lib/CITable'; import { DetailedViewPage } from './BuildWithStepsPage/'; +import { JobRunsTable } from './JobRunsTable'; +import { Project } from '../api'; /** @public */ export const isJenkinsAvailable = (entity: Entity) => Boolean(entity.metadata.annotations?.[JENKINS_ANNOTATION]) || Boolean(entity.metadata.annotations?.[LEGACY_JENKINS_ANNOTATION]); -export const Router = () => { +export const Router = (props: { columns?: TableColumn<Project>[] }) => { const { entity } = useEntity(); if (!isJenkinsAvailable(entity)) { return <MissingAnnotationEmptyState annotation={JENKINS_ANNOTATION} />; } + const columns = props.columns; + return ( <Routes> - <Route path="/" element={<CITable />} /> + <Route path="/" element={<CITable columns={columns} />} /> <Route path={`/${buildRouteRef.path}`} element={<DetailedViewPage />} /> + <Route path={`/${jobRunsRouteRef.path}`} element={<JobRunsTable />} /> </Routes> ); }; diff --git a/plugins/jenkins/src/components/useJobRuns.ts b/plugins/jenkins/src/components/useJobRuns.ts new file mode 100644 index 0000000000..d80e09b18b --- /dev/null +++ b/plugins/jenkins/src/components/useJobRuns.ts @@ -0,0 +1,70 @@ +/* + * 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 { useState } from 'react'; +import useAsyncRetry from 'react-use/lib/useAsyncRetry'; +import { jenkinsApiRef } from '../api'; +import { errorApiRef, useApi } from '@backstage/core-plugin-api'; +import { useEntity } from '@backstage/plugin-catalog-react'; +import { getCompoundEntityRef } from '@backstage/catalog-model'; + +export enum ErrorType { + CONNECTION_ERROR, + NOT_FOUND, +} + +export function useJobRuns(jobFullName: string) { + const { entity } = useEntity(); + const api = useApi(jenkinsApiRef); + const errorApi = useApi(errorApiRef); + + const [page, setPage] = useState(0); + const [pageSize, setPageSize] = useState(5); + + const [error, setError] = useState<{ + message: string; + errorType: ErrorType; + }>(); + + const { loading, value: jobRuns } = useAsyncRetry(async () => { + try { + const jobBuilds = await api.getJobBuilds({ + entity: getCompoundEntityRef(entity), + jobFullName, + }); + return jobBuilds; + } catch (e) { + const errorType = e.notFound + ? ErrorType.NOT_FOUND + : ErrorType.CONNECTION_ERROR; + setError({ message: e.message, errorType }); + throw e; + } + }, [api, errorApi, entity]); + + return [ + { + page, + pageSize, + loading, + jobRuns, + error, + }, + { + setPage, + setPageSize, + }, + ] as const; +} diff --git a/plugins/jenkins/src/index.ts b/plugins/jenkins/src/index.ts index 7562026bdc..9d092014a0 100644 --- a/plugins/jenkins/src/index.ts +++ b/plugins/jenkins/src/index.ts @@ -25,6 +25,7 @@ export { jenkinsPlugin as plugin, EntityJenkinsContent, EntityLatestJenkinsRunCard, + EntityJobRunsTable, } from './plugin'; export { LatestRunCard } from './components/Cards'; export { diff --git a/plugins/jenkins/src/plugin.ts b/plugins/jenkins/src/plugin.ts index 7dbb6bfde1..1b666da9a9 100644 --- a/plugins/jenkins/src/plugin.ts +++ b/plugins/jenkins/src/plugin.ts @@ -38,6 +38,13 @@ export const buildRouteRef = createSubRouteRef({ parent: rootRouteRef, }); +/** @public */ +export const jobRunsRouteRef = createSubRouteRef({ + id: 'jenkins/job/runs', + path: '/builds/:jobFullName/runs', + parent: rootRouteRef, +}); + /** @public */ export const jenkinsPlugin = createPlugin({ id: 'jenkins', @@ -72,3 +79,13 @@ export const EntityLatestJenkinsRunCard = jenkinsPlugin.provide( }, }), ); + +/** @public */ +export const EntityJobRunsTable = jenkinsPlugin.provide( + createComponentExtension({ + name: 'EntityJobRunsTable', + component: { + lazy: () => import('./components/JobRunsTable').then(m => m.JobRunsTable), + }, + }), +); diff --git a/plugins/kafka-backend/CHANGELOG.md b/plugins/kafka-backend/CHANGELOG.md index bccda7319f..79183bce97 100644 --- a/plugins/kafka-backend/CHANGELOG.md +++ b/plugins/kafka-backend/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-kafka-backend +## 0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.3.2-next.1 ### Patch Changes diff --git a/plugins/kafka-backend/package.json b/plugins/kafka-backend/package.json index d965258859..64aa68be19 100644 --- a/plugins/kafka-backend/package.json +++ b/plugins/kafka-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-kafka-backend", "description": "A Backstage backend plugin that integrates towards Kafka", - "version": "0.3.2-next.1", + "version": "0.3.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/kafka/CHANGELOG.md b/plugins/kafka/CHANGELOG.md index adb941bc3f..d3f967dc0c 100644 --- a/plugins/kafka/CHANGELOG.md +++ b/plugins/kafka/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-kafka +## 0.3.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.3.25-next.1 ### Patch Changes diff --git a/plugins/kafka/package.json b/plugins/kafka/package.json index 5e699b3bcc..7b03465504 100644 --- a/plugins/kafka/package.json +++ b/plugins/kafka/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-kafka", "description": "A Backstage plugin that integrates towards Kafka", - "version": "0.3.25-next.1", + "version": "0.3.25-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -53,8 +53,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/kubernetes-backend/CHANGELOG.md b/plugins/kubernetes-backend/CHANGELOG.md index cef2f97198..1f3532632b 100644 --- a/plugins/kubernetes-backend/CHANGELOG.md +++ b/plugins/kubernetes-backend/CHANGELOG.md @@ -1,5 +1,28 @@ # @backstage/plugin-kubernetes-backend +## 0.12.3-next.2 + +### Patch Changes + +- cbb0e3c3f4: A new plugin has been introduced to house the extension points for Kubernetes backend plugin; at the moment only the `KubernetesObjectsProviderExtensionPoint` is present. The `kubernetes-backend` plugin was modified to use this new extension point. +- 95518765ee: Add Kubernetes cluster plugin. Viewing Kubernetes clusters as an Admin from Backstage +- 5dac12e435: The kubernetes APIs invokes Authentication Strategies when Backstage-Kubernetes-Authorization-X-X headers are provided, this enable the possibility to invoke strategies that executes additional steps to get a kubernetes token like on pinniped or custom strategies +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-node@0.1.0-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.12.2-next.1 ### Patch Changes diff --git a/plugins/kubernetes-backend/api-report.md b/plugins/kubernetes-backend/api-report.md index 158b917a48..a6fa50848d 100644 --- a/plugins/kubernetes-backend/api-report.md +++ b/plugins/kubernetes-backend/api-report.md @@ -6,16 +6,18 @@ import { CatalogApi } from '@backstage/catalog-client'; import { Config } from '@backstage/config'; import type { CustomResourceMatcher } from '@backstage/plugin-kubernetes-common'; +import { CustomResourcesByEntity } from '@backstage/plugin-kubernetes-node'; import { Duration } from 'luxon'; import { Entity } from '@backstage/catalog-model'; import express from 'express'; import type { FetchResponse } from '@backstage/plugin-kubernetes-common'; import type { JsonObject } from '@backstage/types'; import type { KubernetesFetchError } from '@backstage/plugin-kubernetes-common'; +import { KubernetesObjectsByEntity } from '@backstage/plugin-kubernetes-node'; +import { KubernetesObjectsProvider } from '@backstage/plugin-kubernetes-node'; import { KubernetesRequestAuth } from '@backstage/plugin-kubernetes-common'; import type { KubernetesRequestBody } from '@backstage/plugin-kubernetes-common'; import { Logger } from 'winston'; -import type { ObjectsByEntityResponse } from '@backstage/plugin-kubernetes-common'; import { PermissionEvaluator } from '@backstage/plugin-permission-common'; import { PluginEndpointDiscovery } from '@backstage/backend-common'; import { RequestHandler } from 'http-proxy-middleware'; @@ -101,11 +103,7 @@ export interface CustomResource extends ObjectToFetch { objectType: 'customresources'; } -// @public (undocumented) -export interface CustomResourcesByEntity extends KubernetesObjectsByEntity { - // (undocumented) - customResources: CustomResourceMatcher[]; -} +export { CustomResourcesByEntity }; // @public (undocumented) export const DEFAULT_OBJECTS: ObjectToFetch[]; @@ -316,25 +314,9 @@ export interface KubernetesFetcher { ): Promise<FetchResponseWrapper>; } -// @public (undocumented) -export interface KubernetesObjectsByEntity { - // (undocumented) - auth: KubernetesRequestAuth; - // (undocumented) - entity: Entity; -} +export { KubernetesObjectsByEntity }; -// @public (undocumented) -export interface KubernetesObjectsProvider { - // (undocumented) - getCustomResourcesByEntity( - customResourcesByEntity: CustomResourcesByEntity, - ): Promise<ObjectsByEntityResponse>; - // (undocumented) - getKubernetesObjectsByEntity( - kubernetesObjectsByEntity: KubernetesObjectsByEntity, - ): Promise<ObjectsByEntityResponse>; -} +export { KubernetesObjectsProvider }; // @public (undocumented) export interface KubernetesObjectsProviderOptions { @@ -409,7 +391,7 @@ export interface ObjectFetchParams { // (undocumented) customResources: CustomResource[]; // (undocumented) - labelSelector: string; + labelSelector?: string; // (undocumented) namespace?: string; // (undocumented) diff --git a/plugins/kubernetes-backend/package.json b/plugins/kubernetes-backend/package.json index bb39a01c6c..32bc958286 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.12.2-next.1", + "version": "0.12.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -61,12 +61,13 @@ "@backstage/plugin-auth-node": "workspace:^", "@backstage/plugin-catalog-node": "workspace:^", "@backstage/plugin-kubernetes-common": "workspace:^", + "@backstage/plugin-kubernetes-node": "workspace:^", "@backstage/plugin-permission-common": "workspace:^", "@backstage/plugin-permission-node": "workspace:^", "@backstage/types": "workspace:^", "@google-cloud/container": "^4.0.0", "@jest-mock/express": "^2.0.1", - "@kubernetes/client-node": "0.18.1", + "@kubernetes/client-node": "0.19.0", "@types/express": "^4.17.6", "@types/http-proxy-middleware": "^0.19.3", "@types/luxon": "^3.0.0", @@ -86,6 +87,7 @@ "yn": "^4.0.0" }, "devDependencies": { + "@backstage/backend-app-api": "workspace:^", "@backstage/backend-test-utils": "workspace:^", "@backstage/cli": "workspace:^", "@types/aws4": "^1.5.1", diff --git a/plugins/kubernetes-backend/src/plugin.ts b/plugins/kubernetes-backend/src/plugin.ts index e2523b4ecd..83dbae15a0 100644 --- a/plugins/kubernetes-backend/src/plugin.ts +++ b/plugins/kubernetes-backend/src/plugin.ts @@ -22,14 +22,43 @@ import { import { catalogServiceRef } from '@backstage/plugin-catalog-node/alpha'; import { KubernetesBuilder } from '@backstage/plugin-kubernetes-backend'; +import { + KubernetesObjectsProviderExtensionPoint, + kubernetesObjectsProviderExtensionPoint, + KubernetesObjectsProvider, +} from '@backstage/plugin-kubernetes-node'; + +class ObjectsProvider implements KubernetesObjectsProviderExtensionPoint { + private objectsProvider: KubernetesObjectsProvider | undefined; + + getObjectsProvider() { + return this.objectsProvider; + } + + addObjectsProvider(provider: KubernetesObjectsProvider) { + if (this.objectsProvider) { + throw new Error( + 'Multiple Kubernetes objects provider is not supported at this time', + ); + } + this.objectsProvider = provider; + } +} /** * This is the backend plugin that provides the Kubernetes integration. * @alpha */ + export const kubernetesPlugin = createBackendPlugin({ pluginId: 'kubernetes', register(env) { + const extensionPoint = new ObjectsProvider(); + env.registerExtensionPoint( + kubernetesObjectsProviderExtensionPoint, + extensionPoint, + ); + env.registerInit({ deps: { http: coreServices.httpRouter, @@ -46,7 +75,9 @@ export const kubernetesPlugin = createBackendPlugin({ config, catalogApi, permissions, - }).build(); + }) + .setObjectsProvider(extensionPoint.getObjectsProvider()) + .build(); http.use(router); }, }); diff --git a/plugins/kubernetes-backend/src/routes/resourceRoutes.test.ts b/plugins/kubernetes-backend/src/routes/resourceRoutes.test.ts index 753be36fb0..b8254d781c 100644 --- a/plugins/kubernetes-backend/src/routes/resourceRoutes.test.ts +++ b/plugins/kubernetes-backend/src/routes/resourceRoutes.test.ts @@ -14,23 +14,64 @@ * limitations under the License. */ -import { errorHandler } from '@backstage/backend-common'; -import express from 'express'; import request from 'supertest'; -import Router from 'express-promise-router'; -import { addResourceRoutesToRouter } from './resourcesRoutes'; +import { mockServices, startTestBackend } from '@backstage/backend-test-utils'; +import { ExtendedHttpServer } from '@backstage/backend-app-api'; +import { kubernetesObjectsProviderExtensionPoint } from '@backstage/plugin-kubernetes-node'; +import { createBackendModule } from '@backstage/backend-plugin-api'; import { Entity } from '@backstage/catalog-model'; describe('resourcesRoutes', () => { - let app: express.Express; + let app: ExtendedHttpServer; - beforeAll(() => { - app = express(); - app.use(express.json()); - const router = Router(); - addResourceRoutesToRouter( - router, - { + beforeAll(async () => { + const objectsProviderMock = { + getKubernetesObjectsByEntity: jest.fn().mockImplementation(args => { + if (args.entity.metadata.name === 'inject500') { + return Promise.reject(new Error('some internal error')); + } + + return Promise.resolve({ + items: [ + { + clusterOne: { + pods: [ + { + metadata: { + name: 'pod1', + }, + }, + ], + }, + }, + ], + }); + }), + getCustomResourcesByEntity: jest.fn().mockImplementation(args => { + if (args.entity.metadata.name === 'inject500') { + return Promise.reject(new Error('some internal error')); + } + + return Promise.resolve({ + items: [ + { + clusterOne: { + pods: [ + { + metadata: { + name: 'pod1', + }, + }, + ], + }, + }, + ], + }); + }), + }; + + jest.mock('@backstage/catalog-client', () => ({ + CatalogClient: jest.fn().mockImplementation(() => ({ getEntityByRef: jest.fn().mockImplementation(entityRef => { if (entityRef.name === 'noentity') { return Promise.resolve(undefined); @@ -43,61 +84,50 @@ describe('resourcesRoutes', () => { }, } as Entity); }), - } as any, - { - getKubernetesObjectsByEntity: jest.fn().mockImplementation(args => { - if (args.entity.metadata.name === 'inject500') { - return Promise.reject(new Error('some internal error')); - } + })), + })); - return Promise.resolve({ - items: [ - { - clusterOne: { - pods: [ - { - metadata: { - name: 'pod1', - }, - }, - ], - }, + const { server } = await startTestBackend({ + features: [ + mockServices.rootConfig.factory({ + data: { + kubernetes: { + serviceLocatorMethod: { + type: 'multiTenant', }, - ], - }); + clusterLocatorMethods: [ + { + type: 'config', + clusters: [], + }, + ], + }, + }, }), - getCustomResourcesByEntity: jest.fn().mockImplementation(args => { - if (args.entity.metadata.name === 'inject500') { - return Promise.reject(new Error('some internal error')); - } + import('@backstage/plugin-kubernetes-backend/alpha'), + createBackendModule({ + pluginId: 'kubernetes', + moduleId: 'testObjectsProvider', + register(env) { + env.registerInit({ + deps: { extension: kubernetesObjectsProviderExtensionPoint }, + async init({ extension }) { + extension.addObjectsProvider(objectsProviderMock); + }, + }); + }, + }), + ], + }); - return Promise.resolve({ - items: [ - { - clusterOne: { - pods: [ - { - metadata: { - name: 'pod1', - }, - }, - ], - }, - }, - ], - }); - }), - } as any, - ); - app.use('/', router); - app.use(errorHandler()); + app = server; }); describe('POST /resources/workloads/query', () => { // eslint-disable-next-line jest/expect-expect it('200 happy path', async () => { await request(app) - .post('/resources/workloads/query') + .post('/api/kubernetes/resources/workloads/query') .send({ entityRef: 'kind:namespacec/someComponent', auth: { @@ -125,7 +155,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when missing entity ref', async () => { await request(app) - .post('/resources/workloads/query') + .post('/api/kubernetes/resources/workloads/query') .send({ auth: { google: 'something', @@ -137,7 +167,7 @@ describe('resourcesRoutes', () => { error: { name: 'InputError', message: 'entity is a required field' }, request: { method: 'POST', - url: '/resources/workloads/query', + url: '/api/kubernetes/resources/workloads/query', }, response: { statusCode: 400 }, }); @@ -145,7 +175,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when bad entity ref', async () => { await request(app) - .post('/resources/workloads/query') + .post('/api/kubernetes/resources/workloads/query') .send({ entityRef: 'ffff', auth: { @@ -162,7 +192,7 @@ describe('resourcesRoutes', () => { }, request: { method: 'POST', - url: '/resources/workloads/query', + url: '/api/kubernetes/resources/workloads/query', }, response: { statusCode: 400 }, }); @@ -170,7 +200,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when no entity in catalog', async () => { await request(app) - .post('/resources/workloads/query') + .post('/api/kubernetes/resources/workloads/query') .send({ entityRef: 'noentity:noentity', auth: { @@ -186,7 +216,7 @@ describe('resourcesRoutes', () => { }, request: { method: 'POST', - url: '/resources/workloads/query', + url: '/api/kubernetes/resources/workloads/query', }, response: { statusCode: 400 }, }); @@ -194,7 +224,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('401 when no Auth header', async () => { await request(app) - .post('/resources/workloads/query') + .post('/api/kubernetes/resources/workloads/query') .send({ entityRef: 'component:someComponent', auth: { @@ -206,7 +236,7 @@ describe('resourcesRoutes', () => { error: { name: 'AuthenticationError', message: 'No Backstage token' }, request: { method: 'POST', - url: '/resources/workloads/query', + url: '/api/kubernetes/resources/workloads/query', }, response: { statusCode: 401 }, }); @@ -214,7 +244,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('401 when invalid Auth header', async () => { await request(app) - .post('/resources/workloads/query') + .post('/api/kubernetes/resources/workloads/query') .send({ entityRef: 'component:someComponent', auth: { @@ -227,7 +257,7 @@ describe('resourcesRoutes', () => { error: { name: 'AuthenticationError', message: 'No Backstage token' }, request: { method: 'POST', - url: '/resources/workloads/query', + url: '/api/kubernetes/resources/workloads/query', }, response: { statusCode: 401 }, }); @@ -235,7 +265,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('500 handle gracefully', async () => { await request(app) - .post('/resources/workloads/query') + .post('/api/kubernetes/resources/workloads/query') .send({ entityRef: 'inject500:inject500/inject500', auth: { @@ -249,7 +279,10 @@ describe('resourcesRoutes', () => { name: 'Error', message: 'some internal error', }, - request: { method: 'POST', url: '/resources/workloads/query' }, + request: { + method: 'POST', + url: '/api/kubernetes/resources/workloads/query', + }, response: { statusCode: 500 }, }); }); @@ -258,7 +291,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('200 happy path', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'component:someComponent', auth: { @@ -293,7 +326,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when missing custom resources', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'component:someComponent', auth: { @@ -309,7 +342,7 @@ describe('resourcesRoutes', () => { }, request: { method: 'POST', - url: '/resources/custom/query', + url: '/api/kubernetes/resources/custom/query', }, response: { statusCode: 400 }, }); @@ -317,7 +350,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when custom resources not array', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'component:someComponent', auth: { @@ -334,7 +367,7 @@ describe('resourcesRoutes', () => { }, request: { method: 'POST', - url: '/resources/custom/query', + url: '/api/kubernetes/resources/custom/query', }, response: { statusCode: 400 }, }); @@ -342,7 +375,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when custom resources empty', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'component:someComponent', auth: { @@ -359,7 +392,7 @@ describe('resourcesRoutes', () => { }, request: { method: 'POST', - url: '/resources/custom/query', + url: '/api/kubernetes/resources/custom/query', }, response: { statusCode: 400 }, }); @@ -367,7 +400,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when missing entity ref', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ auth: { google: 'something', @@ -386,7 +419,7 @@ describe('resourcesRoutes', () => { error: { name: 'InputError', message: 'entity is a required field' }, request: { method: 'POST', - url: '/resources/custom/query', + url: '/api/kubernetes/resources/custom/query', }, response: { statusCode: 400 }, }); @@ -394,7 +427,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when bad entity ref', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'ffff', auth: { @@ -418,7 +451,7 @@ describe('resourcesRoutes', () => { }, request: { method: 'POST', - url: '/resources/custom/query', + url: '/api/kubernetes/resources/custom/query', }, response: { statusCode: 400 }, }); @@ -426,7 +459,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('400 when no entity in catalog', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'noentity:noentity', auth: { @@ -449,7 +482,7 @@ describe('resourcesRoutes', () => { }, request: { method: 'POST', - url: '/resources/custom/query', + url: '/api/kubernetes/resources/custom/query', }, response: { statusCode: 400 }, }); @@ -457,7 +490,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('401 when no Auth header', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'component:someComponent', auth: { @@ -476,7 +509,7 @@ describe('resourcesRoutes', () => { error: { name: 'AuthenticationError', message: 'No Backstage token' }, request: { method: 'POST', - url: '/resources/custom/query', + url: '/api/kubernetes/resources/custom/query', }, response: { statusCode: 401 }, }); @@ -484,7 +517,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('401 when invalid Auth header', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'component:someComponent', auth: { @@ -504,7 +537,7 @@ describe('resourcesRoutes', () => { error: { name: 'AuthenticationError', message: 'No Backstage token' }, request: { method: 'POST', - url: '/resources/custom/query', + url: '/api/kubernetes/resources/custom/query', }, response: { statusCode: 401 }, }); @@ -512,7 +545,7 @@ describe('resourcesRoutes', () => { // eslint-disable-next-line jest/expect-expect it('500 handle gracefully', async () => { await request(app) - .post('/resources/custom/query') + .post('/api/kubernetes/resources/custom/query') .send({ entityRef: 'inject500:inject500/inject500', auth: { @@ -533,7 +566,10 @@ describe('resourcesRoutes', () => { name: 'Error', message: 'some internal error', }, - request: { method: 'POST', url: '/resources/custom/query' }, + request: { + method: 'POST', + url: '/api/kubernetes/resources/custom/query', + }, response: { statusCode: 500 }, }); }); diff --git a/plugins/kubernetes-backend/src/routes/resourcesRoutes.ts b/plugins/kubernetes-backend/src/routes/resourcesRoutes.ts index 2b2a48f707..0468799908 100644 --- a/plugins/kubernetes-backend/src/routes/resourcesRoutes.ts +++ b/plugins/kubernetes-backend/src/routes/resourcesRoutes.ts @@ -21,7 +21,7 @@ import { import { CatalogApi } from '@backstage/catalog-client'; import { InputError, AuthenticationError } from '@backstage/errors'; import express, { Request } from 'express'; -import { KubernetesObjectsProvider } from '../types/types'; +import { KubernetesObjectsProvider } from '@backstage/plugin-kubernetes-node'; import { getBearerTokenFromAuthorizationHeader } from '@backstage/plugin-auth-node'; export const addResourceRoutesToRouter = ( diff --git a/plugins/kubernetes-backend/src/service/KubernetesBuilder.ts b/plugins/kubernetes-backend/src/service/KubernetesBuilder.ts index 9ac1bf6e5d..b05db36398 100644 --- a/plugins/kubernetes-backend/src/service/KubernetesBuilder.ts +++ b/plugins/kubernetes-backend/src/service/KubernetesBuilder.ts @@ -47,13 +47,13 @@ import { CustomResource, KubernetesClustersSupplier, KubernetesFetcher, - KubernetesObjectsProvider, KubernetesObjectsProviderOptions, KubernetesObjectTypes, KubernetesServiceLocator, ObjectsByEntityRequest, ServiceLocatorMethod, } from '../types/types'; +import { KubernetesObjectsProvider } from '@backstage/plugin-kubernetes-node'; import { DEFAULT_OBJECTS, KubernetesFanOutHandler, diff --git a/plugins/kubernetes-backend/src/service/KubernetesFanOutHandler.ts b/plugins/kubernetes-backend/src/service/KubernetesFanOutHandler.ts index f2f1c6d38f..02f7ab86df 100644 --- a/plugins/kubernetes-backend/src/service/KubernetesFanOutHandler.ts +++ b/plugins/kubernetes-backend/src/service/KubernetesFanOutHandler.ts @@ -25,8 +25,6 @@ import { FetchResponseWrapper, ObjectToFetch, CustomResource, - CustomResourcesByEntity, - KubernetesObjectsByEntity, } from '../types/types'; import { AuthenticationStrategy, KubernetesCredential } from '../auth/types'; import { @@ -46,6 +44,10 @@ import { CurrentResourceUsage, PodStatus, } from '@kubernetes/client-node'; +import { + CustomResourcesByEntity, + KubernetesObjectsByEntity, +} from '@backstage/plugin-kubernetes-node'; /** * diff --git a/plugins/kubernetes-backend/src/service/KubernetesFetcher.test.ts b/plugins/kubernetes-backend/src/service/KubernetesFetcher.test.ts index 574a1475fd..e388589e74 100644 --- a/plugins/kubernetes-backend/src/service/KubernetesFetcher.test.ts +++ b/plugins/kubernetes-backend/src/service/KubernetesFetcher.test.ts @@ -165,7 +165,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'pod-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -226,7 +226,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'pod-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -237,7 +237,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'service-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -289,7 +289,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'service-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -339,7 +339,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'pod-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -350,7 +350,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'service-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -420,7 +420,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'pod-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -431,7 +431,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'service-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -443,7 +443,7 @@ describe('KubernetesFetcher', () => { kind: 'Thing', metadata: { name: 'something-else', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -511,7 +511,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'pod-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -861,7 +861,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'pod-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -872,7 +872,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'service-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], @@ -956,7 +956,7 @@ describe('KubernetesFetcher', () => { { metadata: { name: 'pod-name', - labels: { 'backstage.io/kubernetes-id': 'some-service' }, + labels: {}, }, }, ], diff --git a/plugins/kubernetes-backend/src/service/KubernetesFetcher.ts b/plugins/kubernetes-backend/src/service/KubernetesFetcher.ts index e514f5fe0b..d5c945a864 100644 --- a/plugins/kubernetes-backend/src/service/KubernetesFetcher.ts +++ b/plugins/kubernetes-backend/src/service/KubernetesFetcher.ts @@ -101,8 +101,7 @@ export class KubernetesClientBasedFetcher implements KubernetesFetcher { apiVersion, plural, params.namespace, - params.labelSelector || - `backstage.io/kubernetes-id=${params.serviceId}`, + params.labelSelector, ).then( (r: Response): Promise<FetchResult> => r.ok diff --git a/plugins/kubernetes-backend/src/types/index.ts b/plugins/kubernetes-backend/src/types/index.ts index db229eae34..c8413c1aa9 100644 --- a/plugins/kubernetes-backend/src/types/index.ts +++ b/plugins/kubernetes-backend/src/types/index.ts @@ -15,3 +15,9 @@ */ export * from './types'; + +export type { + CustomResourcesByEntity, + KubernetesObjectsByEntity, + KubernetesObjectsProvider, +} from '@backstage/plugin-kubernetes-node'; diff --git a/plugins/kubernetes-backend/src/types/types.ts b/plugins/kubernetes-backend/src/types/types.ts index 3767791589..fa7d4f9e60 100644 --- a/plugins/kubernetes-backend/src/types/types.ts +++ b/plugins/kubernetes-backend/src/types/types.ts @@ -21,9 +21,7 @@ import type { CustomResourceMatcher, FetchResponse, KubernetesFetchError, - KubernetesRequestAuth, KubernetesRequestBody, - ObjectsByEntityResponse, } from '@backstage/plugin-kubernetes-common'; import { Config } from '@backstage/config'; import { KubernetesCredential } from '../auth/types'; @@ -37,7 +35,7 @@ export interface ObjectFetchParams { clusterDetails: ClusterDetails; credential: KubernetesCredential; objectTypesToFetch: Set<ObjectToFetch>; - labelSelector: string; + labelSelector?: string; customResources: CustomResource[]; namespace?: string; } @@ -229,33 +227,3 @@ export interface KubernetesObjectsProviderOptions { * @public */ export type ObjectsByEntityRequest = KubernetesRequestBody; - -/** - * - * @public - */ -export interface KubernetesObjectsByEntity { - entity: Entity; - auth: KubernetesRequestAuth; -} - -/** - * - * @public - */ -export interface CustomResourcesByEntity extends KubernetesObjectsByEntity { - customResources: CustomResourceMatcher[]; -} - -/** - * - * @public - */ -export interface KubernetesObjectsProvider { - getKubernetesObjectsByEntity( - kubernetesObjectsByEntity: KubernetesObjectsByEntity, - ): Promise<ObjectsByEntityResponse>; - getCustomResourcesByEntity( - customResourcesByEntity: CustomResourcesByEntity, - ): Promise<ObjectsByEntityResponse>; -} diff --git a/plugins/kubernetes-cluster/CHANGELOG.md b/plugins/kubernetes-cluster/CHANGELOG.md new file mode 100644 index 0000000000..9e0961f3f7 --- /dev/null +++ b/plugins/kubernetes-cluster/CHANGELOG.md @@ -0,0 +1,17 @@ +# @backstage/plugin-kubernetes-cluster + +## 0.0.1-next.0 + +### Patch Changes + +- 95518765ee: Add Kubernetes cluster plugin. Viewing Kubernetes clusters as an Admin from Backstage +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-react@0.1.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/config@1.1.1-next.0 diff --git a/plugins/kubernetes-cluster/package.json b/plugins/kubernetes-cluster/package.json index 2e1c8d8309..8d0509b448 100644 --- a/plugins/kubernetes-cluster/package.json +++ b/plugins/kubernetes-cluster/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-kubernetes-cluster", "description": "A Backstage plugin that shows details of Kubernetes clusters", - "version": "0.0.0", + "version": "0.0.1-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -66,8 +66,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/kubernetes-common/CHANGELOG.md b/plugins/kubernetes-common/CHANGELOG.md index 4bd84d3ca7..c95c8afa61 100644 --- a/plugins/kubernetes-common/CHANGELOG.md +++ b/plugins/kubernetes-common/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-kubernetes-common +## 0.7.0-next.1 + +### Patch Changes + +- 5dac12e435: The kubernetes APIs invokes Authentication Strategies when Backstage-Kubernetes-Authorization-X-X headers are provided, this enable the possibility to invoke strategies that executes additional steps to get a kubernetes token like on pinniped or custom strategies +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.7.0-next.0 ### Minor Changes diff --git a/plugins/kubernetes-common/package.json b/plugins/kubernetes-common/package.json index baf24cea5d..3a68e07495 100644 --- a/plugins/kubernetes-common/package.json +++ b/plugins/kubernetes-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-kubernetes-common", "description": "Common functionalities for kubernetes, to be shared between kubernetes and kubernetes-backend plugin", - "version": "0.7.0-next.0", + "version": "0.7.0-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -44,7 +44,7 @@ "@backstage/errors": "workspace:^", "@backstage/plugin-permission-common": "workspace:^", "@backstage/types": "workspace:^", - "@kubernetes/client-node": "0.18.1", + "@kubernetes/client-node": "0.19.0", "kubernetes-models": "^4.3.1", "lodash": "^4.17.21", "luxon": "^3.0.0" diff --git a/plugins/kubernetes-node/.eslintrc.js b/plugins/kubernetes-node/.eslintrc.js new file mode 100644 index 0000000000..e2a53a6ad2 --- /dev/null +++ b/plugins/kubernetes-node/.eslintrc.js @@ -0,0 +1 @@ +module.exports = require('@backstage/cli/config/eslint-factory')(__dirname); diff --git a/plugins/kubernetes-node/CHANGELOG.md b/plugins/kubernetes-node/CHANGELOG.md new file mode 100644 index 0000000000..6aa0b7be7f --- /dev/null +++ b/plugins/kubernetes-node/CHANGELOG.md @@ -0,0 +1,14 @@ +# @backstage/plugin-kubernetes-node + +## 0.1.0-next.0 + +### Minor Changes + +- cbb0e3c3f4: A new plugin has been introduced to house the extension points for Kubernetes backend plugin; at the moment only the `KubernetesObjectsProviderExtensionPoint` is present. The `kubernetes-backend` plugin was modified to use this new extension point. + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/backend-plugin-api@0.6.6-next.2 diff --git a/plugins/kubernetes-node/README.md b/plugins/kubernetes-node/README.md new file mode 100644 index 0000000000..afdc299bce --- /dev/null +++ b/plugins/kubernetes-node/README.md @@ -0,0 +1,5 @@ +# @backstage/plugin-kubernetes-node + +Welcome to the Node.js library package for the kubernetes plugin! + +_This plugin was created through the Backstage CLI_ diff --git a/plugins/kubernetes-node/api-report.md b/plugins/kubernetes-node/api-report.md new file mode 100644 index 0000000000..d2981b32d1 --- /dev/null +++ b/plugins/kubernetes-node/api-report.md @@ -0,0 +1,47 @@ +## API Report File for "@backstage/plugin-kubernetes-node" + +> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). + +```ts +import { CustomResourceMatcher } from '@backstage/plugin-kubernetes-common'; +import { Entity } from '@backstage/catalog-model'; +import { ExtensionPoint } from '@backstage/backend-plugin-api'; +import { KubernetesObjectsProvider as KubernetesObjectsProvider_2 } from '@backstage/plugin-kubernetes-node'; +import { KubernetesRequestAuth } from '@backstage/plugin-kubernetes-common'; +import { ObjectsByEntityResponse } from '@backstage/plugin-kubernetes-common'; + +// @public (undocumented) +export interface CustomResourcesByEntity extends KubernetesObjectsByEntity { + // (undocumented) + customResources: CustomResourceMatcher[]; +} + +// @public (undocumented) +export interface KubernetesObjectsByEntity { + // (undocumented) + auth: KubernetesRequestAuth; + // (undocumented) + entity: Entity; +} + +// @public (undocumented) +export interface KubernetesObjectsProvider { + // (undocumented) + getCustomResourcesByEntity( + customResourcesByEntity: CustomResourcesByEntity, + ): Promise<ObjectsByEntityResponse>; + // (undocumented) + getKubernetesObjectsByEntity( + kubernetesObjectsByEntity: KubernetesObjectsByEntity, + ): Promise<ObjectsByEntityResponse>; +} + +// @public +export interface KubernetesObjectsProviderExtensionPoint { + // (undocumented) + addObjectsProvider(provider: KubernetesObjectsProvider_2): void; +} + +// @public +export const kubernetesObjectsProviderExtensionPoint: ExtensionPoint<KubernetesObjectsProviderExtensionPoint>; +``` diff --git a/plugins/kubernetes-node/catalog-info.yaml b/plugins/kubernetes-node/catalog-info.yaml new file mode 100644 index 0000000000..ad04818e49 --- /dev/null +++ b/plugins/kubernetes-node/catalog-info.yaml @@ -0,0 +1,10 @@ +apiVersion: backstage.io/v1alpha1 +kind: Component +metadata: + name: backstage-plugin-kubernetes-node + title: '@backstage/plugin-kubernetes-node' + description: Node.js library for the kubernetes plugin +spec: + lifecycle: experimental + type: backstage-node-library + owner: kubernetes-maintainers diff --git a/plugins/kubernetes-node/package.json b/plugins/kubernetes-node/package.json new file mode 100644 index 0000000000..433fadf2f2 --- /dev/null +++ b/plugins/kubernetes-node/package.json @@ -0,0 +1,35 @@ +{ + "name": "@backstage/plugin-kubernetes-node", + "description": "Node.js library for the kubernetes plugin", + "version": "0.1.0-next.0", + "main": "src/index.ts", + "types": "src/index.ts", + "license": "Apache-2.0", + "publishConfig": { + "access": "public", + "main": "dist/index.cjs.js", + "types": "dist/index.d.ts" + }, + "backstage": { + "role": "node-library" + }, + "scripts": { + "build": "backstage-cli package build", + "lint": "backstage-cli package lint", + "test": "backstage-cli package test", + "clean": "backstage-cli package clean", + "prepack": "backstage-cli package prepack", + "postpack": "backstage-cli package postpack" + }, + "devDependencies": { + "@backstage/cli": "workspace:^" + }, + "files": [ + "dist" + ], + "dependencies": { + "@backstage/backend-plugin-api": "workspace:^", + "@backstage/catalog-model": "workspace:^", + "@backstage/plugin-kubernetes-common": "workspace:^" + } +} diff --git a/plugins/kubernetes-node/src/extensions.ts b/plugins/kubernetes-node/src/extensions.ts new file mode 100644 index 0000000000..152622cf96 --- /dev/null +++ b/plugins/kubernetes-node/src/extensions.ts @@ -0,0 +1,36 @@ +/* + * 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 { createExtensionPoint } from '@backstage/backend-plugin-api'; +import { KubernetesObjectsProvider } from '@backstage/plugin-kubernetes-node'; + +/** + * The interface for {@link kubernetesObjectsProviderExtensionPoint}. + * + * @public + */ +export interface KubernetesObjectsProviderExtensionPoint { + addObjectsProvider(provider: KubernetesObjectsProvider): void; +} + +/** + * An extension point the exposes the ability to configure a objects provider. + * + * @public + */ +export const kubernetesObjectsProviderExtensionPoint = + createExtensionPoint<KubernetesObjectsProviderExtensionPoint>({ + id: 'kubernetes.objects-provider', + }); diff --git a/plugins/kubernetes-node/src/index.ts b/plugins/kubernetes-node/src/index.ts new file mode 100644 index 0000000000..09ea4123ce --- /dev/null +++ b/plugins/kubernetes-node/src/index.ts @@ -0,0 +1,37 @@ +/* + * 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. + */ + +/** + * Node.js library for the kubernetes plugin. + * + * @packageDocumentation + */ + +// In this package you might for example export functions that +// help other plugins or modules interact with your plugin. + +/** + * Node.js library for the kubernetes plugin. + * + * @packageDocumentation + */ + +export { + kubernetesObjectsProviderExtensionPoint, + type KubernetesObjectsProviderExtensionPoint, +} from './extensions'; + +export * from './types'; diff --git a/plugins/user-settings/src/alpha.ts b/plugins/kubernetes-node/src/setupTests.ts similarity index 95% rename from plugins/user-settings/src/alpha.ts rename to plugins/kubernetes-node/src/setupTests.ts index e1f7678bae..4b9026cde5 100644 --- a/plugins/user-settings/src/alpha.ts +++ b/plugins/kubernetes-node/src/setupTests.ts @@ -13,4 +13,4 @@ * See the License for the specific language governing permissions and * limitations under the License. */ -export * from './translation'; +export {}; diff --git a/plugins/kubernetes-node/src/types/index.ts b/plugins/kubernetes-node/src/types/index.ts new file mode 100644 index 0000000000..34ed8a9604 --- /dev/null +++ b/plugins/kubernetes-node/src/types/index.ts @@ -0,0 +1,17 @@ +/* + * 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. + */ + +export * from './types'; diff --git a/plugins/kubernetes-node/src/types/types.ts b/plugins/kubernetes-node/src/types/types.ts new file mode 100644 index 0000000000..182f3ecfeb --- /dev/null +++ b/plugins/kubernetes-node/src/types/types.ts @@ -0,0 +1,53 @@ +/* + * 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 { Entity } from '@backstage/catalog-model'; +import { + CustomResourceMatcher, + KubernetesRequestAuth, + ObjectsByEntityResponse, +} from '@backstage/plugin-kubernetes-common'; + +/** + * + * @public + */ + +export interface KubernetesObjectsProvider { + getKubernetesObjectsByEntity( + kubernetesObjectsByEntity: KubernetesObjectsByEntity, + ): Promise<ObjectsByEntityResponse>; + getCustomResourcesByEntity( + customResourcesByEntity: CustomResourcesByEntity, + ): Promise<ObjectsByEntityResponse>; +} + +/** + * + * @public + */ + +export interface KubernetesObjectsByEntity { + entity: Entity; + auth: KubernetesRequestAuth; +} +/** + * + * @public + */ + +export interface CustomResourcesByEntity extends KubernetesObjectsByEntity { + customResources: CustomResourceMatcher[]; +} diff --git a/plugins/kubernetes-react/CHANGELOG.md b/plugins/kubernetes-react/CHANGELOG.md index f7ed7bb39d..bd2c4759de 100644 --- a/plugins/kubernetes-react/CHANGELOG.md +++ b/plugins/kubernetes-react/CHANGELOG.md @@ -1,5 +1,19 @@ # @backstage/plugin-kubernetes-react +## 0.1.0-next.1 + +### Patch Changes + +- 95518765ee: Add Kubernetes cluster plugin. Viewing Kubernetes clusters as an Admin from Backstage +- 5dac12e435: The kubernetes APIs invokes Authentication Strategies when Backstage-Kubernetes-Authorization-X-X headers are provided, this enable the possibility to invoke strategies that executes additional steps to get a kubernetes token like on pinniped or custom strategies +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/types@1.1.1 + ## 0.1.0-next.0 ### Minor Changes diff --git a/plugins/kubernetes-react/package.json b/plugins/kubernetes-react/package.json index e708e9e455..2463f0bb62 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.1.0-next.0", + "version": "0.1.0-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,7 +54,7 @@ "@backstage/cli": "workspace:^", "@backstage/core-app-api": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.1", "jest-websocket-mock": "^2.5.0", diff --git a/plugins/kubernetes-react/src/utils/pod.test.tsx b/plugins/kubernetes-react/src/utils/pod.test.tsx index 06d4e22371..c48e40cd42 100644 --- a/plugins/kubernetes-react/src/utils/pod.test.tsx +++ b/plugins/kubernetes-react/src/utils/pod.test.tsx @@ -24,18 +24,18 @@ import { SubvalueCell } from '@backstage/core-components'; describe('pod', () => { describe('currentToDeclaredResourceToPerc', () => { - it('10%', () => { - const tests: (number | string)[][] = [ - [10, 100], - [10, '100'], - ['10', 100], - ['10', '100'], - ]; - tests.forEach(([a, b]) => { - const result = currentToDeclaredResourceToPerc(a, b); - expect(result).toBe('10%'); - }); - }); + it.each([ + [10, 100], + [10, '100'], + ['10', 100], + ['10', '100'], + ['10', 100.0], + [10.0, '100'], + [10.1, '100'], + ['10', 100.1], + ])('%p out of %p gives 10%%', (current, resource) => + expect(currentToDeclaredResourceToPerc(current, resource)).toBe('10%'), + ); }); describe('podStatusToCpuUtil', () => { it('does use correct units', () => { diff --git a/plugins/kubernetes-react/src/utils/pod.tsx b/plugins/kubernetes-react/src/utils/pod.tsx index 9c0ce898a3..1123f11427 100644 --- a/plugins/kubernetes-react/src/utils/pod.tsx +++ b/plugins/kubernetes-react/src/utils/pod.tsx @@ -126,8 +126,12 @@ export const currentToDeclaredResourceToPerc = ( return `${Math.round((current / resource) * 100)}%`; } - const numerator: bigint = BigInt(current); - const denominator: bigint = BigInt(resource); + const numerator: bigint = BigInt( + typeof current === 'number' ? Math.round(current) : current, + ); + const denominator: bigint = BigInt( + typeof resource === 'number' ? Math.round(resource) : resource, + ); return `${(numerator * BigInt(100)) / denominator}%`; }; diff --git a/plugins/kubernetes/CHANGELOG.md b/plugins/kubernetes/CHANGELOG.md index 55fda1b465..58016d750a 100644 --- a/plugins/kubernetes/CHANGELOG.md +++ b/plugins/kubernetes/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-kubernetes +## 0.11.0-next.2 + +### Patch Changes + +- 95518765ee: Add Kubernetes cluster plugin. Viewing Kubernetes clusters as an Admin from Backstage +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-kubernetes-react@0.1.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-kubernetes-common@0.7.0-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.11.0-next.1 ### Minor Changes diff --git a/plugins/kubernetes/package.json b/plugins/kubernetes/package.json index 8ed59595c2..6075687478 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.0-next.1", + "version": "0.11.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -46,7 +46,7 @@ "@backstage/types": "workspace:^", "@kubernetes-models/apimachinery": "^1.1.0", "@kubernetes-models/base": "^4.0.1", - "@kubernetes/client-node": "0.18.1", + "@kubernetes/client-node": "0.19.0", "@material-ui/core": "^4.12.2", "@material-ui/icons": "^4.9.1", "@material-ui/lab": "4.0.0-alpha.61", @@ -58,8 +58,8 @@ "luxon": "^3.0.0", "react-use": "^17.2.4", "xterm": "^5.2.1", - "xterm-addon-attach": "^0.8.0", - "xterm-addon-fit": "^0.7.0" + "xterm-addon-attach": "^0.9.0", + "xterm-addon-fit": "^0.8.0" }, "peerDependencies": { "react": "^16.13.1 || ^17.0.0", @@ -71,8 +71,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/lighthouse-backend/CHANGELOG.md b/plugins/lighthouse-backend/CHANGELOG.md index 32c2b599dd..ae3bc3ec7b 100644 --- a/plugins/lighthouse-backend/CHANGELOG.md +++ b/plugins/lighthouse-backend/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-lighthouse-backend +## 0.3.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-lighthouse-common@0.1.4-next.0 + ## 0.3.2-next.1 ### Patch Changes diff --git a/plugins/lighthouse-backend/package.json b/plugins/lighthouse-backend/package.json index bd337e185a..9f7c582060 100644 --- a/plugins/lighthouse-backend/package.json +++ b/plugins/lighthouse-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-lighthouse-backend", "description": "Backend functionalities for lighthouse", - "version": "0.3.2-next.1", + "version": "0.3.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/lighthouse-common/CHANGELOG.md b/plugins/lighthouse-common/CHANGELOG.md index ddeffb94b3..16133e9d52 100644 --- a/plugins/lighthouse-common/CHANGELOG.md +++ b/plugins/lighthouse-common/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-lighthouse-common +## 0.1.4-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/config@1.1.1-next.0 + ## 0.1.3 ### Patch Changes diff --git a/plugins/lighthouse-common/package.json b/plugins/lighthouse-common/package.json index 086ee6cccd..e3cab60d5e 100644 --- a/plugins/lighthouse-common/package.json +++ b/plugins/lighthouse-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-lighthouse-common", "description": "Common functionalities for lighthouse, to be shared between lighthouse and lighthouse-backend plugin", - "version": "0.1.3", + "version": "0.1.4-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/lighthouse/CHANGELOG.md b/plugins/lighthouse/CHANGELOG.md index 4ae227281a..a462393423 100644 --- a/plugins/lighthouse/CHANGELOG.md +++ b/plugins/lighthouse/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-lighthouse +## 0.4.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-lighthouse-common@0.1.4-next.0 + ## 0.4.10-next.1 ### Patch Changes diff --git a/plugins/lighthouse/package.json b/plugins/lighthouse/package.json index 1b81e64511..25735b9a31 100644 --- a/plugins/lighthouse/package.json +++ b/plugins/lighthouse/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-lighthouse", "description": "A Backstage plugin that integrates towards Lighthouse", - "version": "0.4.10-next.1", + "version": "0.4.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -57,8 +57,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/lighthouse/src/components/AuditList/index.tsx b/plugins/lighthouse/src/components/AuditList/index.tsx index c433bb1900..f030ec4708 100644 --- a/plugins/lighthouse/src/components/AuditList/index.tsx +++ b/plugins/lighthouse/src/components/AuditList/index.tsx @@ -44,7 +44,9 @@ import { useApi } from '@backstage/core-plugin-api'; export const LIMIT = 10; const AuditList = () => { - const [dismissedStored] = useLocalStorage(LIGHTHOUSE_INTRO_LOCAL_STORAGE); + const [dismissedStored] = useLocalStorage<boolean>( + LIGHTHOUSE_INTRO_LOCAL_STORAGE, + ); const [dismissed, setDismissed] = useState(dismissedStored); const query = useQuery(); diff --git a/plugins/linguist-backend/CHANGELOG.md b/plugins/linguist-backend/CHANGELOG.md index 5bc5640704..ccdcf24842 100644 --- a/plugins/linguist-backend/CHANGELOG.md +++ b/plugins/linguist-backend/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-linguist-backend +## 0.5.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-linguist-common@0.1.2 + ## 0.5.2-next.1 ### Patch Changes diff --git a/plugins/linguist-backend/package.json b/plugins/linguist-backend/package.json index 99ce86abd8..954eb5c634 100644 --- a/plugins/linguist-backend/package.json +++ b/plugins/linguist-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-linguist-backend", - "version": "0.5.2-next.1", + "version": "0.5.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/linguist-backend/src/service/standaloneServer.ts b/plugins/linguist-backend/src/service/standaloneServer.ts index 11604cddfb..61f75d4827 100644 --- a/plugins/linguist-backend/src/service/standaloneServer.ts +++ b/plugins/linguist-backend/src/service/standaloneServer.ts @@ -17,7 +17,7 @@ import { createServiceBuilder, loadBackendConfig, - SingleHostDiscovery, + HostDiscovery, UrlReaders, useHotMemoize, ServerTokenManager, @@ -64,7 +64,7 @@ export async function startStandaloneServer( { schedule: schedule, age: { days: 30 }, useSourceLocation: false }, { database: { getClient: async () => db }, - discovery: SingleHostDiscovery.fromConfig(config), + discovery: HostDiscovery.fromConfig(config), reader: UrlReaders.default({ logger, config }), logger, tokenManager: ServerTokenManager.noop(), diff --git a/plugins/linguist/CHANGELOG.md b/plugins/linguist/CHANGELOG.md index b5f72d53ba..003e1b6d80 100644 --- a/plugins/linguist/CHANGELOG.md +++ b/plugins/linguist/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-linguist +## 0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-linguist-common@0.1.2 + ## 0.1.10-next.1 ### Patch Changes diff --git a/plugins/linguist/package.json b/plugins/linguist/package.json index 4bdc89ce29..b3f3fedafe 100644 --- a/plugins/linguist/package.json +++ b/plugins/linguist/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-linguist", - "version": "0.1.10-next.1", + "version": "0.1.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/microsoft-calendar/CHANGELOG.md b/plugins/microsoft-calendar/CHANGELOG.md index 1b1942ce6f..fc3a2c86b1 100644 --- a/plugins/microsoft-calendar/CHANGELOG.md +++ b/plugins/microsoft-calendar/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-microsoft-calendar +## 0.1.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.1.8-next.1 ### Patch Changes diff --git a/plugins/microsoft-calendar/package.json b/plugins/microsoft-calendar/package.json index 63ce1d7dfa..610940977c 100644 --- a/plugins/microsoft-calendar/package.json +++ b/plugins/microsoft-calendar/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-microsoft-calendar", - "version": "0.1.8-next.1", + "version": "0.1.8-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -74,8 +74,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/newrelic-dashboard/CHANGELOG.md b/plugins/newrelic-dashboard/CHANGELOG.md index c667e3594c..8b9e3b4555 100644 --- a/plugins/newrelic-dashboard/CHANGELOG.md +++ b/plugins/newrelic-dashboard/CHANGELOG.md @@ -1,5 +1,25 @@ # @backstage/plugin-newrelic-dashboard +## 0.3.0-next.2 + +### Minor Changes + +- d7eba6cab4: Changes in `newrelic-dashboard` plugin: + + - Make DashboardSnapshotList component public + - Settle discrepancies in the exported API + - Deprecate DashboardSnapshotComponent + +### Patch Changes + +- 5194a51a1c: Fixed React Warning: "Each child in a list should have a unique 'key' prop" during the rendering of `EntityNewRelicDashboardCard` +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + ## 0.2.18-next.1 ### Patch Changes diff --git a/plugins/newrelic-dashboard/package.json b/plugins/newrelic-dashboard/package.json index af5003dc1a..d4d40c8e26 100644 --- a/plugins/newrelic-dashboard/package.json +++ b/plugins/newrelic-dashboard/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-newrelic-dashboard", - "version": "0.2.18-next.1", + "version": "0.3.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -48,7 +48,8 @@ "devDependencies": { "@backstage/cli": "workspace:^", "@backstage/dev-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1" + "@backstage/test-utils": "workspace:^", + "@testing-library/jest-dom": "^6.0.0" }, "files": [ "dist" diff --git a/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardEntityList.tsx b/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardEntityList.tsx index 6c89f3eb80..8d87a54ca0 100644 --- a/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardEntityList.tsx +++ b/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardEntityList.tsx @@ -69,9 +69,9 @@ export const DashboardEntityList = () => { <>No Dashboard Pages found with the specified Dashboard GUID</> )} {value?.getDashboardEntity?.data.actor.entitySearch.results.entities?.map( - (entityResult: ResultEntity) => { + (entityResult: ResultEntity, index: number) => { return ( - <Box style={{ margin: '10px' }} display="flex"> + <Box style={{ margin: '10px' }} display="flex" key={index}> <Box mr={1} className={classes.svgIcon}> <Typography component="div"> <DesktopMac /> diff --git a/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshot.tsx b/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshot.tsx index cdac4196d4..c19697a4f0 100644 --- a/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshot.tsx +++ b/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshot.tsx @@ -15,8 +15,7 @@ */ import React from 'react'; -import { Box, Grid, MenuItem, Select } from '@material-ui/core'; -import { useTheme } from '@material-ui/core/styles'; +import { Box, makeStyles, MenuItem, Select } from '@material-ui/core'; import { useApi, storageApiRef } from '@backstage/core-plugin-api'; import useAsync from 'react-use/lib/useAsync'; import { @@ -29,6 +28,20 @@ import { newRelicDashboardApiRef } from '../../../api'; import { DashboardSnapshotSummary } from '../../../api/NewRelicDashboardApi'; import useObservable from 'react-use/lib/useObservable'; +const useStyles = makeStyles( + theme => ({ + cardSelect: { + margin: theme.spacing(2, 1, 0, 0), + }, + img: { + width: '100%', + height: 'auto', + border: `solid 1px ${theme.palette.common.black}`, + }, + }), + { name: 'BackstageNewRelicDashboardSnapshot' }, +); + /** * @public */ @@ -37,11 +50,7 @@ export const DashboardSnapshot = (props: { name: string; permalink: string; }) => { - const { - palette: { - common: { black }, - }, - } = useTheme(); + const classes = useStyles(); const { guid, name, permalink } = props; const newRelicDashboardAPI = useApi(newRelicDashboardApiRef); const storageApi = useApi(storageApiRef).forBucket('newrelic-dashboard'); @@ -76,14 +85,15 @@ export const DashboardSnapshot = (props: { /\pdf$/i, 'png', ); + return ( - <Grid container> - <InfoCard - variant="gridItem" - title={name} - action={ + <InfoCard + variant="gridItem" + title={name} + action={ + <div> <Select - style={{ margin: '15px 10px 0 0' }} + className={classes.cardSelect} defaultValue={2592000000} value={storageSnapshot.value} onChange={event => { @@ -97,24 +107,24 @@ export const DashboardSnapshot = (props: { <MenuItem value={604800000}>1 Week</MenuItem> <MenuItem value={2592000000}>1 Month</MenuItem> </Select> - } - > - <Box display="flex"> - <Box flexGrow="1"> - <Link to={permalink}> - {url ? ( - <img - alt={`${name} Dashbord`} - style={{ border: `solid 1px ${black}` }} - src={url} - /> - ) : ( - 'Dashboard loading... , click here to open if it did not render correctly' - )} - </Link> - </Box> + </div> + } + > + <Box display="flex"> + <Box flexGrow="1"> + <Link to={permalink}> + {url ? ( + <img + alt={`${name} Dashboard`} + className={classes.img} + src={url} + /> + ) : ( + 'Dashboard loading... , click here to open if it did not render correctly' + )} + </Link> </Box> - </InfoCard> - </Grid> + </Box> + </InfoCard> ); }; diff --git a/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshotList.tsx b/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshotList.tsx index 594a5fd53d..81686d10c9 100644 --- a/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshotList.tsx +++ b/plugins/newrelic-dashboard/src/components/NewRelicDashboard/DashboardSnapshotList/DashboardSnapshotList.tsx @@ -14,7 +14,7 @@ * limitations under the License. */ import React, { useState } from 'react'; -import { Grid, Tab, Tabs, makeStyles } from '@material-ui/core'; +import { Tab, Tabs, makeStyles, Box } from '@material-ui/core'; import { newRelicDashboardApiRef } from '../../../api'; import { useApi } from '@backstage/core-plugin-api'; import useAsync from 'react-use/lib/useAsync'; @@ -29,11 +29,22 @@ interface TabPanelProps { value1: number; } +const tabPanelStyles = makeStyles( + theme => ({ + tabPanel: { + marginTop: theme.spacing(0.5), + }, + }), + { name: 'BackstageNewRelicDashboardTabPanel' }, +); + function TabPanel(props: TabPanelProps) { const { children, value1, index, ...other } = props; + const classes = tabPanelStyles(tabPanelStyles); return ( <div + className={classes.tabPanel} role="tabpanel" hidden={value1 !== index} id={`simple-tabpanel-${index}`} @@ -102,7 +113,7 @@ export const DashboardSnapshotList = (props: { guid: string }) => { return <ErrorPanel title={error.name} defaultExpanded error={error} />; } return ( - <Grid container direction="column"> + <Box> <Tabs selectionFollowsFocus indicatorColor="primary" @@ -112,7 +123,6 @@ export const DashboardSnapshotList = (props: { guid: string }) => { aria-label="scrollable auto tabs example" onChange={handleChange} value={value1} - style={{ width: '100%' }} > {value?.getDashboardEntity?.data?.actor.entitySearch.results.entities?.map( (Entity: ResultEntity, index: number) => { @@ -143,6 +153,6 @@ export const DashboardSnapshotList = (props: { guid: string }) => { ); }, )} - </Grid> + </Box> ); }; diff --git a/plugins/newrelic-dashboard/src/components/NewRelicDashboard/NewRelicDashboard.stories.tsx b/plugins/newrelic-dashboard/src/components/NewRelicDashboard/NewRelicDashboard.stories.tsx new file mode 100644 index 0000000000..a15a4c573c --- /dev/null +++ b/plugins/newrelic-dashboard/src/components/NewRelicDashboard/NewRelicDashboard.stories.tsx @@ -0,0 +1,131 @@ +/* + * Copyright 2021 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 React from 'react'; +import { NewRelicDashboard } from './NewRelicDashboard'; +import { MockStorageApi, TestApiProvider } from '@backstage/test-utils'; +import { EntityProvider } from '@backstage/plugin-catalog-react'; +import { newRelicDashboardApiRef } from '../../api'; +import { NEWRELIC_GUID_ANNOTATION } from '../../constants'; +import { storageApiRef } from '@backstage/core-plugin-api'; +import { Entity } from '@backstage/catalog-model'; + +function createImage( + width: number, + height: number, + bgColor: string, + text: string, +): HTMLCanvasElement { + const canvas = document.createElement('canvas'); + canvas.width = width; + canvas.height = height; + const ctx = canvas.getContext('2d'); + if (ctx !== null) { + ctx.fillStyle = bgColor; + ctx.fillRect(0, 0, canvas.width, canvas.height); + ctx.fillStyle = '#000'; // text color + ctx.textAlign = 'center'; + ctx.textBaseline = 'middle'; + ctx.font = '20px sans-serif'; + ctx.fillText(text, canvas.width / 2, canvas.height / 2); + } + return canvas; +} + +const entity: Entity = { + apiVersion: '1', + kind: 'Component', + metadata: { + name: 'mocked entity with newrelic service', + title: 'app with newrelic', + annotations: { + [NEWRELIC_GUID_ANNOTATION]: 'some-cool-guid', + }, + }, +}; + +const newRelicApiMockEmpty = { + getDashboardEntity: () => Promise.resolve(undefined), +}; + +export const EmptyNewRelicDashboard = () => ( + <TestApiProvider apis={[[newRelicDashboardApiRef, newRelicApiMockEmpty]]}> + <EntityProvider entity={entity}> + <NewRelicDashboard /> + </EntityProvider> + </TestApiProvider> +); + +const resultEntities = [ + { + dashboardParentGuid: 'parent guid', + guid: 'guid', + permalink: 'http://example.com', + name: 'Production metrics', + }, +]; + +const dashboardEntity = { + data: { + actor: { + entitySearch: { + results: { + entities: resultEntities, + }, + }, + }, + }, +}; + +const entitySummary = { + getDashboardEntity: dashboardEntity, +}; + +const dashboardSnapshot = { + getDashboardSnapshot: { + data: { + dashboardCreateSnapshotUrl: createImage( + 1000, + 600, + '#ddd', + 'Example snapshot, imagine NewRelic panels here', + ).toDataURL(), + }, + }, +}; + +const newRelicApiMockFull = { + getDashboardEntity: () => Promise.resolve(entitySummary), + getDashboardSnapshot: () => Promise.resolve(dashboardSnapshot), +}; + +export const NewRelicDashboardWithSnapshots = () => ( + <TestApiProvider + apis={[ + [newRelicDashboardApiRef, newRelicApiMockFull], + [storageApiRef, MockStorageApi.create()], + ]} + > + <EntityProvider entity={entity}> + <NewRelicDashboard /> + </EntityProvider> + </TestApiProvider> +); + +export default { + title: 'NewRelic Dashboard', + component: EmptyNewRelicDashboard, +}; diff --git a/plugins/newrelic/CHANGELOG.md b/plugins/newrelic/CHANGELOG.md index a0d122a18c..5274857950 100644 --- a/plugins/newrelic/CHANGELOG.md +++ b/plugins/newrelic/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-newrelic +## 0.3.41-next.2 + +### Patch Changes + +- ce50a15506: Fixed sorting and searching in the NewRelic table. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.3.41-next.1 ### Patch Changes diff --git a/plugins/newrelic/package.json b/plugins/newrelic/package.json index da63717dda..1499839493 100644 --- a/plugins/newrelic/package.json +++ b/plugins/newrelic/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-newrelic", "description": "A Backstage plugin that integrates towards New Relic", - "version": "0.3.41-next.1", + "version": "0.3.41-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -55,8 +55,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/parse-link-header": "^2.0.1", diff --git a/plugins/nomad-backend/CHANGELOG.md b/plugins/nomad-backend/CHANGELOG.md index a5186f75f8..f5ceaf5b9e 100644 --- a/plugins/nomad-backend/CHANGELOG.md +++ b/plugins/nomad-backend/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-nomad-backend +## 0.1.8-next.2 + +### Patch Changes + +- 6822918c50: Added support for the [new backend system](https://backstage.io/docs/backend-system/) +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.1.7-next.1 ### Patch Changes diff --git a/plugins/nomad-backend/package.json b/plugins/nomad-backend/package.json index 7873f846ba..caff96aa11 100644 --- a/plugins/nomad-backend/package.json +++ b/plugins/nomad-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-nomad-backend", - "version": "0.1.7-next.1", + "version": "0.1.8-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/nomad/CHANGELOG.md b/plugins/nomad/CHANGELOG.md index 15f8fca004..e16f5ea02c 100644 --- a/plugins/nomad/CHANGELOG.md +++ b/plugins/nomad/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-nomad +## 0.1.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.1.6-next.1 ### Patch Changes diff --git a/plugins/nomad/package.json b/plugins/nomad/package.json index 5a3964cdc1..a500250507 100644 --- a/plugins/nomad/package.json +++ b/plugins/nomad/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-nomad", - "version": "0.1.6-next.1", + "version": "0.1.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -52,7 +52,7 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/octopus-deploy/CHANGELOG.md b/plugins/octopus-deploy/CHANGELOG.md index b9d7dc084f..9ac914a653 100644 --- a/plugins/octopus-deploy/CHANGELOG.md +++ b/plugins/octopus-deploy/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-octopus-deploy +## 0.2.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.2.7-next.1 ### Patch Changes diff --git a/plugins/octopus-deploy/package.json b/plugins/octopus-deploy/package.json index 5e0bf27520..fd375d59f5 100644 --- a/plugins/octopus-deploy/package.json +++ b/plugins/octopus-deploy/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-octopus-deploy", - "version": "0.2.7-next.1", + "version": "0.2.7-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -50,8 +50,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/opencost/CHANGELOG.md b/plugins/opencost/CHANGELOG.md index 60edb74ed8..24625e7f2d 100644 --- a/plugins/opencost/CHANGELOG.md +++ b/plugins/opencost/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-opencost +## 0.2.1-next.2 + +### Patch Changes + +- 777b9a16a4: Fix for broken image reference. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.2.1-next.1 ### Patch Changes diff --git a/plugins/opencost/README.md b/plugins/opencost/README.md index 39c5e7ee2e..05c63206a2 100644 --- a/plugins/opencost/README.md +++ b/plugins/opencost/README.md @@ -28,7 +28,7 @@ and </FlatRoutes> ``` -3. Add link to OpenCost to your sidebar +3. Import the `MoneyIcon` and add link to OpenCost to your sidebar ```typescript // packages/app/src/components/Root/Root.tsx diff --git a/plugins/opencost/package.json b/plugins/opencost/package.json index d733276152..a2f8aa2ed7 100644 --- a/plugins/opencost/package.json +++ b/plugins/opencost/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-opencost", - "version": "0.2.1-next.1", + "version": "0.2.1-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -48,7 +48,7 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/opencost/src/components/OpenCostPage/OpenCostPage.tsx b/plugins/opencost/src/components/OpenCostPage/OpenCostPage.tsx index bd60fa0c35..4062eca155 100644 --- a/plugins/opencost/src/components/OpenCostPage/OpenCostPage.tsx +++ b/plugins/opencost/src/components/OpenCostPage/OpenCostPage.tsx @@ -17,6 +17,7 @@ import React from 'react'; import { Grid } from '@material-ui/core'; import { Header, Page, Content } from '@backstage/core-components'; import { OpenCostReport } from '../OpenCostReport'; +import logo from '../../images/pig.png'; export const OpenCostPage = () => ( <Page themeId="tool"> @@ -25,12 +26,7 @@ export const OpenCostPage = () => ( subtitle="Open source Kubernetes cloud cost monitoring" > <a href="https://opencost.io"> - <img - width={68} - height={64} - src={require('../../images/pig.png')} - alt="OpenCost" - /> + <img width={68} height={64} src={logo} alt="OpenCost" /> </a> </Header> <Content> diff --git a/plugins/org-react/CHANGELOG.md b/plugins/org-react/CHANGELOG.md index 2d5f4fbd7e..8f1a3bcaf0 100644 --- a/plugins/org-react/CHANGELOG.md +++ b/plugins/org-react/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-org-react +## 0.1.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + ## 0.1.14-next.1 ### Patch Changes diff --git a/plugins/org-react/package.json b/plugins/org-react/package.json index 28876a6700..1877d025fe 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.14-next.1", + "version": "0.1.14-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/org-react/src/components/GroupListPicker/GroupListPicker.tsx b/plugins/org-react/src/components/GroupListPicker/GroupListPicker.tsx index a47c346390..57a93ce0fe 100644 --- a/plugins/org-react/src/components/GroupListPicker/GroupListPicker.tsx +++ b/plugins/org-react/src/components/GroupListPicker/GroupListPicker.tsx @@ -74,7 +74,7 @@ export const GroupListPicker = (props: GroupListPickerProps) => { }, [catalogApi, groupTypes]); const handleChange = useCallback( - (_, v: GroupEntity | null) => { + (_: unknown, v: GroupEntity | null) => { onChange(v ?? undefined); setAnchorEl(null); }, diff --git a/plugins/org/CHANGELOG.md b/plugins/org/CHANGELOG.md index 6ede70db1b..ff34eae200 100644 --- a/plugins/org/CHANGELOG.md +++ b/plugins/org/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-org +## 0.6.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.6.15-next.1 ### Patch Changes diff --git a/plugins/org/package.json b/plugins/org/package.json index 4f01b5fa09..8289db0805 100644 --- a/plugins/org/package.json +++ b/plugins/org/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-org", "description": "A Backstage plugin that helps you create entity pages for your organization", - "version": "0.6.15-next.1", + "version": "0.6.15-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,8 +59,8 @@ "@backstage/plugin-permission-react": "workspace:^", "@backstage/test-utils": "workspace:^", "@backstage/types": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.1", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/pagerduty/CHANGELOG.md b/plugins/pagerduty/CHANGELOG.md index d37d6b4033..92721d7cc8 100644 --- a/plugins/pagerduty/CHANGELOG.md +++ b/plugins/pagerduty/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-pagerduty +## 0.6.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-home-react@0.1.4-next.2 + ## 0.6.6-next.1 ### Patch Changes diff --git a/plugins/pagerduty/package.json b/plugins/pagerduty/package.json index 4ade1d9224..92337a3ae5 100644 --- a/plugins/pagerduty/package.json +++ b/plugins/pagerduty/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-pagerduty", "description": "A Backstage plugin that integrates towards PagerDuty", - "version": "0.6.6-next.1", + "version": "0.6.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,8 +59,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/periskop-backend/CHANGELOG.md b/plugins/periskop-backend/CHANGELOG.md index c4b41389b6..d0653d6836 100644 --- a/plugins/periskop-backend/CHANGELOG.md +++ b/plugins/periskop-backend/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-periskop-backend +## 0.2.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.2.2-next.1 ### Patch Changes diff --git a/plugins/periskop-backend/package.json b/plugins/periskop-backend/package.json index ff276b7a55..91a7ee4ebd 100644 --- a/plugins/periskop-backend/package.json +++ b/plugins/periskop-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-periskop-backend", - "version": "0.2.2-next.1", + "version": "0.2.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/periskop/CHANGELOG.md b/plugins/periskop/CHANGELOG.md index 7030b94dfc..32cccbb745 100644 --- a/plugins/periskop/CHANGELOG.md +++ b/plugins/periskop/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-periskop +## 0.1.23-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.1.23-next.1 ### Patch Changes diff --git a/plugins/periskop/package.json b/plugins/periskop/package.json index 9d47082842..2bf9bab4b8 100644 --- a/plugins/periskop/package.json +++ b/plugins/periskop/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-periskop", - "version": "0.1.23-next.1", + "version": "0.1.23-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -52,8 +52,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/luxon": "^3.0.0", diff --git a/plugins/permission-backend-module-policy-allow-all/CHANGELOG.md b/plugins/permission-backend-module-policy-allow-all/CHANGELOG.md index 127e39e251..ad8d765829 100644 --- a/plugins/permission-backend-module-policy-allow-all/CHANGELOG.md +++ b/plugins/permission-backend-module-policy-allow-all/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-permission-backend-module-allow-all-policy +## 0.1.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.1.2-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 2b309e852c..0dc2e20689 100644 --- a/plugins/permission-backend-module-policy-allow-all/package.json +++ b/plugins/permission-backend-module-policy-allow-all/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-permission-backend-module-allow-all-policy", "description": "Allow all policy backend module for the permission plugin.", - "version": "0.1.2-next.1", + "version": "0.1.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/permission-backend/CHANGELOG.md b/plugins/permission-backend/CHANGELOG.md index d3419ba508..679e235598 100644 --- a/plugins/permission-backend/CHANGELOG.md +++ b/plugins/permission-backend/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-permission-backend +## 0.5.29-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.5.28-next.1 ### Patch Changes diff --git a/plugins/permission-backend/package.json b/plugins/permission-backend/package.json index 2709204635..a3bd75e6db 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.28-next.1", + "version": "0.5.29-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/permission-common/CHANGELOG.md b/plugins/permission-common/CHANGELOG.md index f39e4455ec..56af3e310e 100644 --- a/plugins/permission-common/CHANGELOG.md +++ b/plugins/permission-common/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-permission-common +## 0.7.9-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.7.8 ### Patch Changes diff --git a/plugins/permission-common/package.json b/plugins/permission-common/package.json index 050b696aef..c08d962e4a 100644 --- a/plugins/permission-common/package.json +++ b/plugins/permission-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-permission-common", "description": "Isomorphic types and client for Backstage permissions and authorization", - "version": "0.7.8", + "version": "0.7.9-next.0", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/plugins/permission-node/CHANGELOG.md b/plugins/permission-node/CHANGELOG.md index e387547156..05af5694ca 100644 --- a/plugins/permission-node/CHANGELOG.md +++ b/plugins/permission-node/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-permission-node +## 0.7.17-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.7.16-next.1 ### Patch Changes diff --git a/plugins/permission-node/package.json b/plugins/permission-node/package.json index 9f57f44886..6aee34ad50 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.16-next.1", + "version": "0.7.17-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/permission-react/CHANGELOG.md b/plugins/permission-react/CHANGELOG.md index 0df727d454..6db19085fb 100644 --- a/plugins/permission-react/CHANGELOG.md +++ b/plugins/permission-react/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-permission-react +## 0.4.16-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.4.16-next.0 ### Patch Changes diff --git a/plugins/permission-react/package.json b/plugins/permission-react/package.json index 7e79128739..b21d3fc6fb 100644 --- a/plugins/permission-react/package.json +++ b/plugins/permission-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-permission-react", - "version": "0.4.16-next.0", + "version": "0.4.16-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -48,7 +48,7 @@ "devDependencies": { "@backstage/cli": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3" }, "files": [ diff --git a/plugins/playlist-backend/CHANGELOG.md b/plugins/playlist-backend/CHANGELOG.md index c7f001ae4b..503f4a1796 100644 --- a/plugins/playlist-backend/CHANGELOG.md +++ b/plugins/playlist-backend/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-playlist-backend +## 0.3.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-playlist-common@0.1.11-next.0 + ## 0.3.9-next.1 ### Patch Changes diff --git a/plugins/playlist-backend/package.json b/plugins/playlist-backend/package.json index 319206e6c6..193ecd3fe0 100644 --- a/plugins/playlist-backend/package.json +++ b/plugins/playlist-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-playlist-backend", - "version": "0.3.9-next.1", + "version": "0.3.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/playlist-backend/src/service/standaloneServer.ts b/plugins/playlist-backend/src/service/standaloneServer.ts index 3b6acfd09b..02a375229c 100644 --- a/plugins/playlist-backend/src/service/standaloneServer.ts +++ b/plugins/playlist-backend/src/service/standaloneServer.ts @@ -19,7 +19,7 @@ import { DatabaseManager, loadBackendConfig, ServerTokenManager, - SingleHostDiscovery, + HostDiscovery, useHotMemoize, } from '@backstage/backend-common'; import { ConfigReader } from '@backstage/config'; @@ -40,7 +40,7 @@ export async function startStandaloneServer( ): Promise<Server> { const logger = options.logger.child({ service: 'playlist-backend' }); const config = await loadBackendConfig({ logger, argv: process.argv }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const database = useHotMemoize(module, () => { const manager = DatabaseManager.fromConfig( diff --git a/plugins/playlist-common/CHANGELOG.md b/plugins/playlist-common/CHANGELOG.md index b6d6eb8990..cc3cd85cb8 100644 --- a/plugins/playlist-common/CHANGELOG.md +++ b/plugins/playlist-common/CHANGELOG.md @@ -1,5 +1,12 @@ # @backstage/plugin-playlist-common +## 0.1.11-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 0.1.10 ### Patch Changes diff --git a/plugins/playlist-common/package.json b/plugins/playlist-common/package.json index f31094c5a6..08b0b8bb32 100644 --- a/plugins/playlist-common/package.json +++ b/plugins/playlist-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-playlist-common", "description": "Common functionalities for the playlist plugin", - "version": "0.1.10", + "version": "0.1.11-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/playlist/CHANGELOG.md b/plugins/playlist/CHANGELOG.md index 301f289b8c..9682635f51 100644 --- a/plugins/playlist/CHANGELOG.md +++ b/plugins/playlist/CHANGELOG.md @@ -1,5 +1,23 @@ # @backstage/plugin-playlist +## 0.1.17-next.2 + +### Patch Changes + +- 65498193e8: Updated Playlist read me with additional screenshots +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + - @backstage/plugin-playlist-common@0.1.11-next.0 + ## 0.1.17-next.1 ### Patch Changes diff --git a/plugins/playlist/package.json b/plugins/playlist/package.json index 10a3c651ed..a479c2946d 100644 --- a/plugins/playlist/package.json +++ b/plugins/playlist/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-playlist", - "version": "0.1.17-next.1", + "version": "0.1.17-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,9 +59,10 @@ "@backstage/cli": "workspace:^", "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", + "@backstage/plugin-search-common": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/playlist/src/components/PlaylistPage/AddEntitiesDrawer.tsx b/plugins/playlist/src/components/PlaylistPage/AddEntitiesDrawer.tsx index d5a52dc83c..529327776e 100644 --- a/plugins/playlist/src/components/PlaylistPage/AddEntitiesDrawer.tsx +++ b/plugins/playlist/src/components/PlaylistPage/AddEntitiesDrawer.tsx @@ -15,6 +15,7 @@ */ import { + CompoundEntityRef, Entity, getCompoundEntityRef, stringifyEntityRef, @@ -22,6 +23,7 @@ import { import { useApi, useRouteRef } from '@backstage/core-plugin-api'; import { CatalogEntityDocument } from '@backstage/plugin-catalog-common'; import { catalogApiRef, entityRouteRef } from '@backstage/plugin-catalog-react'; +import type { SearchDocument } from '@backstage/plugin-search-common'; import { SearchBar, SearchContextProvider, @@ -131,13 +133,13 @@ export const AddEntitiesDrawer = ({ }; const addEntity = useCallback( - entityResult => { + (entityResult: SearchDocument) => { // TODO(kuangp): this parsing of the location is not great. Ideally `CatalogEntityDocument` // contains the `metadata.name` field so we can derive the full ref and we only fall back to // parsing location if it's missing (ie. for older versions) const match = entityResult.location.match(entityLocationRegex); if (match?.groups) { - onAdd(stringifyEntityRef(match?.groups)); + onAdd(stringifyEntityRef(match?.groups as CompoundEntityRef)); } else { // eslint-disable-next-line no-console console.error( diff --git a/plugins/playlist/src/components/PlaylistPage/PlaylistEntitiesTable.tsx b/plugins/playlist/src/components/PlaylistPage/PlaylistEntitiesTable.tsx index c74859ce20..72d50506b0 100644 --- a/plugins/playlist/src/components/PlaylistPage/PlaylistEntitiesTable.tsx +++ b/plugins/playlist/src/components/PlaylistPage/PlaylistEntitiesTable.tsx @@ -72,7 +72,7 @@ export const PlaylistEntitiesTable = ({ ); const removeEntity = useCallback( - async (_, entity: Entity | Entity[]) => { + async (_: unknown, entity: Entity | Entity[]) => { try { const entityArray = [entity].flat(); const entityNames = entityArray.map( diff --git a/plugins/proxy-backend/CHANGELOG.md b/plugins/proxy-backend/CHANGELOG.md index 22dae797a3..a4059a1828 100644 --- a/plugins/proxy-backend/CHANGELOG.md +++ b/plugins/proxy-backend/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-proxy-backend +## 0.4.3-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.4.2-next.1 ### Patch Changes diff --git a/plugins/proxy-backend/package.json b/plugins/proxy-backend/package.json index 9b21073dc7..28f8d3ea5f 100644 --- a/plugins/proxy-backend/package.json +++ b/plugins/proxy-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-proxy-backend", "description": "A Backstage backend plugin that helps you set up proxy endpoints in the backend", - "version": "0.4.2-next.1", + "version": "0.4.3-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/proxy-backend/src/service/router.config.test.ts b/plugins/proxy-backend/src/service/router.config.test.ts index fffdcb5142..8643ee67c0 100644 --- a/plugins/proxy-backend/src/service/router.config.test.ts +++ b/plugins/proxy-backend/src/service/router.config.test.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import { getVoidLogger, SingleHostDiscovery } from '@backstage/backend-common'; +import { getVoidLogger, HostDiscovery } from '@backstage/backend-common'; import { ConfigSources, MutableConfigSource, @@ -87,7 +87,7 @@ describe('createRouter reloadable configuration', () => { ]), ); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const router = await createRouter({ config, logger, diff --git a/plugins/proxy-backend/src/service/router.test.ts b/plugins/proxy-backend/src/service/router.test.ts index 23b6e17ecc..9149f36015 100644 --- a/plugins/proxy-backend/src/service/router.test.ts +++ b/plugins/proxy-backend/src/service/router.test.ts @@ -14,7 +14,7 @@ * limitations under the License. */ -import { getVoidLogger, SingleHostDiscovery } from '@backstage/backend-common'; +import { getVoidLogger, HostDiscovery } from '@backstage/backend-common'; import { mockServices } from '@backstage/backend-test-utils'; import { ConfigReader } from '@backstage/config'; import { Request, Response } from 'express'; @@ -56,7 +56,7 @@ describe('createRouter', () => { }, }, }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); beforeEach(() => { mockCreateProxyMiddleware.mockClear(); @@ -150,7 +150,7 @@ describe('createRouter', () => { }, }, }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); await expect( createRouter({ config, @@ -185,7 +185,7 @@ describe('createRouter', () => { }, }, }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const router = await createRouter({ config, logger, diff --git a/plugins/proxy-backend/src/service/standaloneServer.ts b/plugins/proxy-backend/src/service/standaloneServer.ts index 3a8401986c..44a1e34090 100644 --- a/plugins/proxy-backend/src/service/standaloneServer.ts +++ b/plugins/proxy-backend/src/service/standaloneServer.ts @@ -17,7 +17,7 @@ import { createServiceBuilder, loadBackendConfig, - SingleHostDiscovery, + HostDiscovery, } from '@backstage/backend-common'; import { Server } from 'http'; import { Logger } from 'winston'; @@ -37,7 +37,7 @@ export async function startStandaloneServer( logger.debug('Creating application...'); const config = await loadBackendConfig({ logger, argv: process.argv }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const router = await createRouter({ config, logger, diff --git a/plugins/puppetdb/CHANGELOG.md b/plugins/puppetdb/CHANGELOG.md index 5d9dc0be04..98680eed03 100644 --- a/plugins/puppetdb/CHANGELOG.md +++ b/plugins/puppetdb/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-puppetdb +## 0.1.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.1.8-next.1 ### Patch Changes diff --git a/plugins/puppetdb/package.json b/plugins/puppetdb/package.json index ad23b77a8f..b493b78d71 100644 --- a/plugins/puppetdb/package.json +++ b/plugins/puppetdb/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-puppetdb", "description": "Backstage plugin to visualize resource information and Puppet facts from PuppetDB.", - "version": "0.1.8-next.1", + "version": "0.1.8-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -57,7 +57,7 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.1" diff --git a/plugins/rollbar-backend/CHANGELOG.md b/plugins/rollbar-backend/CHANGELOG.md index 6d4b6b309e..b6a0bb6a79 100644 --- a/plugins/rollbar-backend/CHANGELOG.md +++ b/plugins/rollbar-backend/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-rollbar-backend +## 0.1.51-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.1.50-next.1 ### Patch Changes diff --git a/plugins/rollbar-backend/package.json b/plugins/rollbar-backend/package.json index 019f851d04..b58241b5e2 100644 --- a/plugins/rollbar-backend/package.json +++ b/plugins/rollbar-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-rollbar-backend", "description": "A Backstage backend plugin that integrates towards Rollbar", - "version": "0.1.50-next.1", + "version": "0.1.51-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/rollbar/CHANGELOG.md b/plugins/rollbar/CHANGELOG.md index 69c38eead1..cc3f2e564d 100644 --- a/plugins/rollbar/CHANGELOG.md +++ b/plugins/rollbar/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-rollbar +## 0.4.25-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.4.25-next.1 ### Patch Changes diff --git a/plugins/rollbar/package.json b/plugins/rollbar/package.json index 5a5159ceb6..2444240a78 100644 --- a/plugins/rollbar/package.json +++ b/plugins/rollbar/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-rollbar", "description": "A Backstage plugin that integrates towards Rollbar", - "version": "0.4.25-next.1", + "version": "0.4.25-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -57,8 +57,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/scaffolder-backend-module-confluence-to-markdown/CHANGELOG.md b/plugins/scaffolder-backend-module-confluence-to-markdown/CHANGELOG.md index 366698d2e6..7344084491 100644 --- a/plugins/scaffolder-backend-module-confluence-to-markdown/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-confluence-to-markdown/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-scaffolder-backend-module-confluence-to-markdown +## 0.2.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.2.6-next.1 ### 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 bb996d7da8..dcdfc51f93 100644 --- a/plugins/scaffolder-backend-module-confluence-to-markdown/package.json +++ b/plugins/scaffolder-backend-module-confluence-to-markdown/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-scaffolder-backend-module-confluence-to-markdown", "description": "The confluence-to-markdown module for @backstage/plugin-scaffolder-backend", - "version": "0.2.6-next.1", + "version": "0.2.7-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-backend-module-cookiecutter/CHANGELOG.md b/plugins/scaffolder-backend-module-cookiecutter/CHANGELOG.md index 8a4dc42f44..4373cf9a1a 100644 --- a/plugins/scaffolder-backend-module-cookiecutter/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-cookiecutter/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-scaffolder-backend-module-cookiecutter +## 0.2.30-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.2.29-next.1 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-cookiecutter/package.json b/plugins/scaffolder-backend-module-cookiecutter/package.json index 908f907f13..68bbd40294 100644 --- a/plugins/scaffolder-backend-module-cookiecutter/package.json +++ b/plugins/scaffolder-backend-module-cookiecutter/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-scaffolder-backend-module-cookiecutter", "description": "A module for the scaffolder backend that lets you template projects using cookiecutter", - "version": "0.2.29-next.1", + "version": "0.2.30-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-backend-module-gitlab/CHANGELOG.md b/plugins/scaffolder-backend-module-gitlab/CHANGELOG.md index 3cd1812ca7..950fd2edb5 100644 --- a/plugins/scaffolder-backend-module-gitlab/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-gitlab/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-scaffolder-backend-module-gitlab +## 0.2.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.2.8-next.1 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-gitlab/package.json b/plugins/scaffolder-backend-module-gitlab/package.json index 89d755f1dd..aa57094af4 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.2.8-next.1", + "version": "0.2.9-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-backend-module-rails/CHANGELOG.md b/plugins/scaffolder-backend-module-rails/CHANGELOG.md index c51d36eb64..e8ee3e7d35 100644 --- a/plugins/scaffolder-backend-module-rails/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-rails/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-scaffolder-backend-module-rails +## 0.4.23-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.4.22-next.1 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-rails/package.json b/plugins/scaffolder-backend-module-rails/package.json index c58fb6a035..fad98d5216 100644 --- a/plugins/scaffolder-backend-module-rails/package.json +++ b/plugins/scaffolder-backend-module-rails/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-scaffolder-backend-module-rails", "description": "A module for the scaffolder backend that lets you template projects using Rails", - "version": "0.4.22-next.1", + "version": "0.4.23-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-backend-module-sentry/CHANGELOG.md b/plugins/scaffolder-backend-module-sentry/CHANGELOG.md index e07feaa885..55de9576e5 100644 --- a/plugins/scaffolder-backend-module-sentry/CHANGELOG.md +++ b/plugins/scaffolder-backend-module-sentry/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-scaffolder-backend-module-sentry +## 0.1.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.1.13-next.1 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-sentry/package.json b/plugins/scaffolder-backend-module-sentry/package.json index 366f7a9126..53613c14b6 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.13-next.1", + "version": "0.1.14-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-backend-module-yeoman/CHANGELOG.md b/plugins/scaffolder-backend-module-yeoman/CHANGELOG.md index a24ec57bb3..41522939e6 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.2.27-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + ## 0.2.26-next.1 ### Patch Changes diff --git a/plugins/scaffolder-backend-module-yeoman/package.json b/plugins/scaffolder-backend-module-yeoman/package.json index cd4350f681..8f17f30e7c 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.2.26-next.1", + "version": "0.2.27-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-backend/CHANGELOG.md b/plugins/scaffolder-backend/CHANGELOG.md index 50fda07ce7..f468e42f72 100644 --- a/plugins/scaffolder-backend/CHANGELOG.md +++ b/plugins/scaffolder-backend/CHANGELOG.md @@ -1,5 +1,41 @@ # @backstage/plugin-scaffolder-backend +## 1.18.0-next.2 + +### Minor Changes + +- dea0aafda7: Updated `publish:gitlab` action properties to support additional Gitlab project settings: + + - general project settings provided by gitlab project create API (new `settings` property) + - branch level settings to create additional branches and make them protected (new `branches` property) + - project level environment variables settings (new `projectVariables` property) + + Marked existed properties `repoVisibility` and `topics` as deprecated, as they are covered by `settings` property. + +### Patch Changes + +- 7dd82cc07e: Add examples for `github:issues:label` scaffolder action & improve related tests +- 733ddf7130: Add examples for `publish:Azure` scaffolder action. +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/plugin-catalog-backend@1.14.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-backend-module-scaffolder-entity-model@0.1.3-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-scaffolder-node@0.2.6-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + ## 1.18.0-next.1 ### Minor Changes diff --git a/plugins/scaffolder-backend/api-report.md b/plugins/scaffolder-backend/api-report.md index 17e13131cf..1b0930eaee 100644 --- a/plugins/scaffolder-backend/api-report.md +++ b/plugins/scaffolder-backend/api-report.md @@ -679,6 +679,36 @@ export function createPublishGitlabAction(options: { gitAuthorEmail?: string | undefined; setUserAsOwner?: boolean | undefined; topics?: string[] | undefined; + settings?: + | { + path?: string | undefined; + auto_devops_enabled?: boolean | undefined; + ci_config_path?: string | undefined; + description?: string | undefined; + topics?: string[] | undefined; + visibility?: 'internal' | 'private' | 'public' | undefined; + } + | undefined; + branches?: + | { + name: string; + protect?: boolean | undefined; + create?: boolean | undefined; + ref?: string | undefined; + }[] + | undefined; + projectVariables?: + | { + key: string; + value: string; + description?: string | undefined; + variable_type?: string | undefined; + protected?: boolean | undefined; + masked?: boolean | undefined; + raw?: boolean | undefined; + environment_scope?: string | undefined; + }[] + | undefined; }, JsonObject >; @@ -711,8 +741,8 @@ export function createRouter(options: RouterOptions): Promise<express.Router>; export const createTemplateAction: < TInputParams extends JsonObject = JsonObject, TOutputParams extends JsonObject = JsonObject, - TInputSchema extends ZodType<any, ZodTypeDef, any> | Schema = {}, - TOutputSchema extends ZodType<any, ZodTypeDef, any> | Schema = {}, + TInputSchema extends Schema | ZodType<any, ZodTypeDef, any> = {}, + TOutputSchema extends Schema | ZodType<any, ZodTypeDef, any> = {}, TActionInput extends JsonObject = TInputSchema extends ZodType< any, any, diff --git a/plugins/scaffolder-backend/package.json b/plugins/scaffolder-backend/package.json index 4ff894cd61..1c87b1f289 100644 --- a/plugins/scaffolder-backend/package.json +++ b/plugins/scaffolder-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-scaffolder-backend", "description": "The Backstage backend plugin that helps you create new things", - "version": "1.18.0-next.1", + "version": "1.18.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/debug/wait.examples.test.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/debug/wait.examples.test.ts index 11cc83c696..9b755d86dd 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/debug/wait.examples.test.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/debug/wait.examples.test.ts @@ -53,6 +53,7 @@ describe('debug:wait examples', () => { const start = new Date().getTime(); await action.handler(context); const end = new Date().getTime(); - expect(end - start).toBeGreaterThanOrEqual(50); + expect(end - start).toBeGreaterThanOrEqual(45); // should rarely by markedly less + expect(end - start).toBeLessThanOrEqual(500); // can get delayed a bit in CI }); }); diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.examples.test.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.examples.test.ts new file mode 100644 index 0000000000..9d74d53c6d --- /dev/null +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.examples.test.ts @@ -0,0 +1,120 @@ +/* + * 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 { TemplateAction } from '@backstage/plugin-scaffolder-node'; +import { getVoidLogger } from '@backstage/backend-common'; +import { ConfigReader } from '@backstage/config'; +import { + DefaultGithubCredentialsProvider, + GithubCredentialsProvider, + ScmIntegrations, +} from '@backstage/integration'; +import { PassThrough } from 'stream'; +import { createGithubIssuesLabelAction } from './githubIssuesLabel'; +import yaml from 'yaml'; +import { examples } from './githubIssuesLabel.examples'; +import { getOctokitOptions } from './helpers'; + +jest.mock('./helpers', () => { + return { + getOctokitOptions: jest.fn(), + }; +}); + +const mockOctokit = { + rest: { + issues: { + addLabels: jest.fn(), + }, + }, +}; +jest.mock('octokit', () => ({ + Octokit: class { + constructor() { + return mockOctokit; + } + }, +})); + +describe('github:issues:label examples', () => { + const config = new ConfigReader({ + integrations: { + github: [ + { host: 'github.com', token: 'tokenlols' }, + { host: 'ghe.github.com' }, + ], + }, + }); + + const getOctokitOptionsMock = getOctokitOptions as jest.Mock; + const integrations = ScmIntegrations.fromConfig(config); + let githubCredentialsProvider: GithubCredentialsProvider; + let action: TemplateAction<any>; + + const mockContext = { + workspacePath: 'lol', + logger: getVoidLogger(), + logStream: new PassThrough(), + output: jest.fn(), + createTemporaryDirectory: jest.fn(), + }; + + beforeEach(() => { + jest.resetAllMocks(); + githubCredentialsProvider = + DefaultGithubCredentialsProvider.fromIntegrations(integrations); + action = createGithubIssuesLabelAction({ + integrations, + githubCredentialsProvider, + }); + }); + + afterEach(jest.resetAllMocks); + + it('should call the githubApi for adding labels without token', async () => { + await action.handler({ + ...mockContext, + input: yaml.parse(examples[0].example).steps[0].input, + }); + + expect(mockOctokit.rest.issues.addLabels).toHaveBeenCalledWith({ + owner: 'owner', + repo: 'repo', + issue_number: '1', + labels: ['bug'], + }); + + expect(getOctokitOptionsMock.mock.calls[0][0].token).toBeUndefined(); + }); + + it('should call the githubApi for adding labels with token', async () => { + await action.handler({ + ...mockContext, + input: yaml.parse(examples[1].example).steps[0].input, + }); + + expect(mockOctokit.rest.issues.addLabels).toHaveBeenCalledWith({ + owner: 'owner', + repo: 'repo', + issue_number: '1', + labels: ['bug', 'documentation'], + }); + + expect(getOctokitOptionsMock.mock.calls[0][0].token).toEqual( + 'gph_YourGitHubToken', + ); + }); +}); diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.examples.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.examples.ts new file mode 100644 index 0000000000..e0f631df7b --- /dev/null +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.examples.ts @@ -0,0 +1,54 @@ +/* + * 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 { TemplateExample } from '@backstage/plugin-scaffolder-node'; +import yaml from 'yaml'; + +export const examples: TemplateExample[] = [ + { + description: 'Add labels to pull request or issue', + example: yaml.stringify({ + steps: [ + { + action: 'github:issues:label', + name: 'Add labels to pull request or issue', + input: { + repoUrl: 'github.com?repo=repo&owner=owner', + number: '1', + labels: ['bug'], + }, + }, + ], + }), + }, + { + description: 'Add labels to pull request or issue with specific token', + example: yaml.stringify({ + steps: [ + { + action: 'github:issues:label', + name: 'Add labels to pull request or issue with token', + input: { + repoUrl: 'github.com?repo=repo&owner=owner', + number: '1', + labels: ['bug', 'documentation'], + token: 'gph_YourGitHubToken', + }, + }, + ], + }), + }, +]; diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.test.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.test.ts index a1a0274304..3da16e677a 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.test.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.test.ts @@ -24,6 +24,13 @@ import { ConfigReader } from '@backstage/config'; import { getVoidLogger } from '@backstage/backend-common'; import { TemplateAction } from '@backstage/plugin-scaffolder-node'; import { PassThrough } from 'stream'; +import { getOctokitOptions } from './helpers'; + +jest.mock('./helpers', () => { + return { + getOctokitOptions: jest.fn(), + }; +}); const mockOctokit = { rest: { @@ -50,6 +57,7 @@ describe('github:issues:label', () => { }, }); + const getOctokitOptionsMock = getOctokitOptions as jest.Mock; const integrations = ScmIntegrations.fromConfig(config); let githubCredentialsProvider: GithubCredentialsProvider; let action: TemplateAction<any>; @@ -85,5 +93,22 @@ describe('github:issues:label', () => { issue_number: '1', labels: ['label1', 'label2'], }); + expect(getOctokitOptionsMock.mock.calls[0][0].token).toBeUndefined(); + }); + + it('should call the githubApi for adding labels with token', async () => { + await action.handler({ + ...mockContext, + input: { ...mockContext.input, token: 'gph_YourGitHubToken' }, + }); + expect(mockOctokit.rest.issues.addLabels).toHaveBeenCalledWith({ + owner: 'owner', + repo: 'repo', + issue_number: '1', + labels: ['label1', 'label2'], + }); + expect(getOctokitOptionsMock.mock.calls[0][0].token).toEqual( + 'gph_YourGitHubToken', + ); }); }); diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.ts index 2dad0aa33a..73a65ffb14 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/github/githubIssuesLabel.ts @@ -23,6 +23,7 @@ import { assertError, InputError } from '@backstage/errors'; import { Octokit } from 'octokit'; import { getOctokitOptions } from './helpers'; import { parseRepoUrl } from '../publish/util'; +import { examples } from './githubIssuesLabel.examples'; /** * Adds labels to a pull request or issue on GitHub @@ -42,6 +43,7 @@ export function createGithubIssuesLabelAction(options: { }>({ id: 'github:issues:label', description: 'Adds labels to a pull request or issue on GitHub.', + examples, schema: { input: { type: 'object', diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.examples.test.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.examples.test.ts new file mode 100644 index 0000000000..e4fd18ef59 --- /dev/null +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.examples.test.ts @@ -0,0 +1,121 @@ +/* + * Copyright 2021 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 yaml from 'yaml'; +import { ConfigReader } from '@backstage/config'; +import { createPublishAzureAction } from './azure'; +import { ScmIntegrations } from '@backstage/integration'; +import { getVoidLogger } from '@backstage/backend-common'; +import { WebApi } from 'azure-devops-node-api'; +import { PassThrough } from 'stream'; +import { initRepoAndPush } from '../helpers'; +import { examples } from './azure.examples'; + +jest.mock('azure-devops-node-api', () => ({ + WebApi: jest.fn(), + getPersonalAccessTokenHandler: jest.fn().mockReturnValue(() => {}), +})); + +jest.mock('../helpers', () => { + return { + initRepoAndPush: jest.fn().mockResolvedValue({ + commitHash: '220f19cc36b551763d157f1b5e4a4b446165dbd6', + }), + commitAndPushRepo: jest.fn().mockResolvedValue({ + commitHash: '220f19cc36b551763d157f1b5e4a4b446165dbd6', + }), + }; +}); + +describe('publish:azure examples', () => { + const config = new ConfigReader({ + integrations: { + azure: [ + { + host: 'dev.azure.com', + credentials: [{ personalAccessToken: 'tokenlols' }], + }, + ], + }, + }); + + const integrations = ScmIntegrations.fromConfig(config); + const action = createPublishAzureAction({ integrations, config }); + const mockContext = { + workspacePath: 'lol', + logger: getVoidLogger(), + logStream: new PassThrough(), + output: jest.fn(), + createTemporaryDirectory: jest.fn(), + }; + + const mockGitClient = { + createRepository: jest.fn(), + }; + const mockGitApi = { + getGitApi: jest.fn().mockReturnValue(mockGitClient), + }; + + (WebApi as unknown as jest.Mock).mockImplementation(() => mockGitApi); + + beforeEach(() => { + jest.clearAllMocks(); + }); + + it('should call initRepoAndPush with the correct values', async () => { + mockGitClient.createRepository.mockResolvedValue({ + remoteUrl: 'https://dev.azure.com/organization/project/_git/repo', + id: '709e891c-dee7-4f91-b963-534713c0737f', + }); + + await action.handler({ + ...mockContext, + input: yaml.parse(examples[0].example).steps[0].input, + }); + + expect(initRepoAndPush).toHaveBeenCalledWith({ + dir: mockContext.workspacePath, + remoteUrl: 'https://dev.azure.com/organization/project/_git/repo', + defaultBranch: 'master', + auth: { username: 'notempty', password: 'tokenlols' }, + logger: mockContext.logger, + commitMessage: 'initial commit', + gitAuthorInfo: {}, + }); + }); + + it('should call initRepoAndPush with a changed default branch', async () => { + mockGitClient.createRepository.mockResolvedValue({ + remoteUrl: 'https://dev.azure.com/organization/project/_git/repo', + id: '709e891c-dee7-4f91-b963-534713c0737f', + }); + + await action.handler({ + ...mockContext, + input: yaml.parse(examples[2].example).steps[0].input, + }); + + expect(initRepoAndPush).toHaveBeenCalledWith({ + dir: mockContext.workspacePath, + remoteUrl: 'https://dev.azure.com/organization/project/_git/repo', + defaultBranch: 'main', + auth: { username: 'notempty', password: 'tokenlols' }, + logger: mockContext.logger, + commitMessage: 'initial commit', + gitAuthorInfo: {}, + }); + }); +}); diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.examples.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.examples.ts new file mode 100644 index 0000000000..48b57c410d --- /dev/null +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.examples.ts @@ -0,0 +1,73 @@ +/* + * 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 { TemplateExample } from '@backstage/plugin-scaffolder-node'; +import yaml from 'yaml'; + +export const examples: TemplateExample[] = [ + { + description: + 'Initializes a git repository of the content in the workspace, and publishes it to Azure.', + example: yaml.stringify({ + steps: [ + { + id: 'publish', + action: 'publish:azure', + name: 'Publish to Azure', + input: { + repoUrl: + 'dev.azure.com?organization=organization&owner=project&repo=repo', + }, + }, + ], + }), + }, + { + description: 'Add a description.', + example: yaml.stringify({ + steps: [ + { + id: 'publish', + action: 'publish:azure', + name: 'Publish to Azure', + input: { + repoUrl: + 'dev.azure.com?organization=organization&owner=project&repo=repo', + description: 'Initialize a git repository', + }, + }, + ], + }), + }, + { + description: 'Change the default branch.', + example: yaml.stringify({ + steps: [ + { + id: 'publish', + action: 'publish:azure', + name: 'Publish to Azure', + input: { + repoUrl: + 'dev.azure.com?organization=organization&owner=project&repo=repo', + description: 'Initialize a git repository', + defaultBranch: 'main', + }, + }, + ], + }), + }, +]; diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.ts index b6c0226163..a7df154687 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/azure.ts @@ -29,6 +29,7 @@ import { import { getRepoSourceDirectory, parseRepoUrl } from './util'; import { createTemplateAction } from '@backstage/plugin-scaffolder-node'; import { Config } from '@backstage/config'; +import { examples } from './azure.examples'; /** * Creates a new action that initializes a git repository of the content in the workspace @@ -52,6 +53,7 @@ export function createPublishAzureAction(options: { gitAuthorEmail?: string; }>({ id: 'publish:azure', + examples, description: 'Initializes a git repository of the content in the workspace, and publishes it to Azure.', schema: { diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.examples.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.examples.ts index ac259866e3..b20fcf52e9 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.examples.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.examples.ts @@ -68,4 +68,79 @@ export const examples: TemplateExample[] = [ ], }), }, + { + description: 'Initializes a git repository with additional settings.', + example: yaml.stringify({ + steps: [ + { + id: 'publish', + action: 'publish:gitlab', + name: 'Publish to GitLab', + input: { + repoUrl: 'gitlab.com?repo=project_name&owner=group_name', + settings: { + ci_config_path: '.gitlab-ci.yml', + visibility: 'public', + }, + }, + }, + ], + }), + }, + { + description: 'Initializes a git repository with branches settings', + example: yaml.stringify({ + steps: [ + { + id: 'publish', + action: 'publish:gitlab', + name: 'Publish to GitLab', + input: { + repoUrl: 'gitlab.com?repo=project_name&owner=group_name', + branches: [ + { + name: 'dev', + create: true, + protected: true, + ref: 'master', + }, + { + name: 'master', + protected: true, + }, + ], + }, + }, + ], + }), + }, + { + description: 'Initializes a git repository with environment variables', + example: yaml.stringify({ + steps: [ + { + id: 'publish', + action: 'publish:gitlab', + name: 'Publish to GitLab', + input: { + repoUrl: 'gitlab.com?repo=project_name&owner=group_name', + projectVariables: [ + { + key: 'key1', + value: 'value1', + protected: true, + masked: false, + }, + { + key: 'key2', + value: 'value2', + protected: true, + masked: false, + }, + ], + }, + }, + ], + }), + }, ]; diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.test.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.test.ts index dc8e3eb0ee..b2f3dc6480 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.test.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.test.ts @@ -45,6 +45,15 @@ const mockGitlabClient = { ProjectMembers: { add: jest.fn(), }, + Branches: { + create: jest.fn(), + }, + ProtectedBranches: { + protect: jest.fn(), + }, + ProjectVariables: { + create: jest.fn(), + }, }; jest.mock('@gitbeaker/node', () => ({ Gitlab: class { @@ -77,6 +86,73 @@ describe('publish:gitlab', () => { input: { repoUrl: 'gitlab.com?repo=repo&owner=owner', repoVisibility: 'private' as const, + settings: { + ci_config_path: '.gitlab-ci.yml', + }, + }, + workspacePath: 'lol', + logger: getVoidLogger(), + logStream: new PassThrough(), + output: jest.fn(), + createTemporaryDirectory: jest.fn(), + }; + const mockContextWithSettings = { + input: { + repoUrl: 'gitlab.com?repo=repo&owner=owner', + repoVisibility: 'private' as const, + topics: ['topic'], + settings: { + ci_config_path: '.gitlab-ci.yml', + visibility: 'internal' as const, + topics: ['topic1', 'topic2'], + }, + }, + workspacePath: 'lol', + logger: getVoidLogger(), + logStream: new PassThrough(), + output: jest.fn(), + createTemporaryDirectory: jest.fn(), + }; + const mockContextWithBranches = { + input: { + repoUrl: 'gitlab.com?repo=repo&owner=owner', + repoVisibility: 'private' as const, + branches: [ + { + name: 'dev', + create: true, + ref: 'master', + protect: true, + }, + { + name: 'stage', + create: true, + }, + { + name: 'perf', + protect: true, + }, + ], + }, + workspacePath: 'lol', + logger: getVoidLogger(), + logStream: new PassThrough(), + output: jest.fn(), + createTemporaryDirectory: jest.fn(), + }; + const mockContextWithVariables = { + input: { + repoUrl: 'gitlab.com?repo=repo&owner=owner', + repoVisibility: 'private' as const, + projectVariables: [ + { + key: 'key', + value: 'value', + description: 'description', + protected: true, + masked: true, + }, + ], }, workspacePath: 'lol', logger: getVoidLogger(), @@ -146,6 +222,8 @@ describe('publish:gitlab', () => { name: 'bob', visibility: 'private', }); + expect(mockGitlabClient.Branches.create).not.toHaveBeenCalled(); + expect(mockGitlabClient.ProtectedBranches.protect).not.toHaveBeenCalled(); }); it('should call the correct Gitlab APIs when the owner is an organization', async () => { @@ -162,7 +240,10 @@ describe('publish:gitlab', () => { namespace_id: 1234, name: 'repo', visibility: 'private', + ci_config_path: '.gitlab-ci.yml', }); + expect(mockGitlabClient.Branches.create).not.toHaveBeenCalled(); + expect(mockGitlabClient.ProtectedBranches.protect).not.toHaveBeenCalled(); }); it('should call the correct Gitlab APIs when the owner is not an organization', async () => { @@ -179,7 +260,103 @@ describe('publish:gitlab', () => { namespace_id: 12345, name: 'repo', visibility: 'private', + ci_config_path: '.gitlab-ci.yml', }); + expect(mockGitlabClient.Branches.create).not.toHaveBeenCalled(); + expect(mockGitlabClient.ProtectedBranches.protect).not.toHaveBeenCalled(); + }); + + it('should call the correct Gitlab APIs when using project settings with override of visibility and topics', async () => { + mockGitlabClient.Users.current.mockResolvedValue({ id: 12345 }); + mockGitlabClient.Namespaces.show.mockResolvedValue({ id: 1234 }); + mockGitlabClient.Projects.create.mockResolvedValue({ + http_url_to_repo: 'http://mockurl.git', + }); + + await action.handler(mockContextWithSettings); + + expect(mockGitlabClient.Namespaces.show).toHaveBeenCalledWith('owner'); + expect(mockGitlabClient.Projects.create).toHaveBeenCalledWith({ + namespace_id: 1234, + name: 'repo', + visibility: 'internal', + topics: ['topic1', 'topic2'], + ci_config_path: '.gitlab-ci.yml', + }); + expect(mockGitlabClient.Branches.create).not.toHaveBeenCalled(); + expect(mockGitlabClient.ProtectedBranches.protect).not.toHaveBeenCalled(); + }); + + it('should call the correct Gitlab APIs for branches and protectd branches when branch settings provided', async () => { + mockGitlabClient.Users.current.mockResolvedValue({ id: 12345 }); + mockGitlabClient.Namespaces.show.mockResolvedValue({ id: 1234 }); + mockGitlabClient.Projects.create.mockResolvedValue({ + id: 123456, + http_url_to_repo: 'http://mockurl.git', + }); + + await action.handler(mockContextWithBranches); + + expect(mockGitlabClient.Namespaces.show).toHaveBeenCalledWith('owner'); + expect(mockGitlabClient.Projects.create).toHaveBeenCalledWith({ + namespace_id: 1234, + name: 'repo', + visibility: 'private', + }); + expect(mockGitlabClient.Branches.create).toHaveBeenCalledTimes(2); + expect(mockGitlabClient.ProtectedBranches.protect).toHaveBeenCalledTimes(2); + + expect(mockGitlabClient.Branches.create).toHaveBeenCalledWith( + 123456, + 'dev', + 'master', + ); + expect(mockGitlabClient.Branches.create).toHaveBeenCalledWith( + 123456, + 'stage', + 'master', + ); + + expect(mockGitlabClient.ProtectedBranches.protect).toHaveBeenCalledWith( + 123456, + 'dev', + ); + expect(mockGitlabClient.ProtectedBranches.protect).toHaveBeenCalledWith( + 123456, + 'perf', + ); + }); + + it('should call the correct Gitlab APIs for variables when their configuration is provided', async () => { + mockGitlabClient.Users.current.mockResolvedValue({ id: 12345 }); + mockGitlabClient.Namespaces.show.mockResolvedValue({ id: 1234 }); + mockGitlabClient.Projects.create.mockResolvedValue({ + id: 123456, + http_url_to_repo: 'http://mockurl.git', + }); + + await action.handler(mockContextWithVariables); + + expect(mockGitlabClient.Namespaces.show).toHaveBeenCalledWith('owner'); + expect(mockGitlabClient.Projects.create).toHaveBeenCalledWith({ + namespace_id: 1234, + name: 'repo', + visibility: 'private', + }); + + expect(mockGitlabClient.ProjectVariables.create).toHaveBeenCalledWith( + 123456, + { + key: 'key', + value: 'value', + description: 'description', + variable_type: 'env_var', + protected: true, + masked: true, + raw: false, + environment_scope: '*', + }, + ); }); it('should call initRepoAndPush with the correct values', async () => { diff --git a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.ts b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.ts index 25f78452a4..6d86841a20 100644 --- a/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.ts +++ b/plugins/scaffolder-backend/src/scaffolder/actions/builtin/publish/gitlab.ts @@ -38,6 +38,7 @@ export function createPublishGitlabAction(options: { return createTemplateAction<{ repoUrl: string; defaultBranch?: string; + /** @deprecated in favour of settings.visibility field */ repoVisibility?: 'private' | 'internal' | 'public'; sourcePath?: string; token?: string; @@ -45,7 +46,32 @@ export function createPublishGitlabAction(options: { gitAuthorName?: string; gitAuthorEmail?: string; setUserAsOwner?: boolean; + /** @deprecated in favour of settings.topics field */ topics?: string[]; + settings?: { + path?: string; + auto_devops_enabled?: boolean; + ci_config_path?: string; + description?: string; + topics?: string[]; + visibility?: 'private' | 'internal' | 'public'; + }; + branches?: Array<{ + name: string; + protect?: boolean; + create?: boolean; + ref?: string; + }>; + projectVariables?: Array<{ + key: string; + value: string; + description?: string; + variable_type?: string; + protected?: boolean; + masked?: boolean; + raw?: boolean; + environment_scope?: string; + }>; }>({ id: 'publish:gitlab', description: @@ -63,6 +89,7 @@ export function createPublishGitlabAction(options: { }, repoVisibility: { title: 'Repository Visibility', + description: `Sets the visibility of the repository. The default value is 'private'. (deprecated, use settings.visibility instead)`, type: 'string', enum: ['private', 'public', 'internal'], }, @@ -105,12 +132,135 @@ export function createPublishGitlabAction(options: { }, topics: { title: 'Topic labels', - description: 'Topic labels to apply on the repository.', + description: + 'Topic labels to apply on the repository. (deprecated, use settings.topics instead)', type: 'array', items: { type: 'string', }, }, + settings: { + title: 'Project settings', + description: + 'Additional project settings, based on https://docs.gitlab.com/ee/api/projects.html#create-project attributes', + type: 'object', + properties: { + path: { + title: 'Project path', + description: + 'Repository name for new project. Generated based on name if not provided (generated as lowercase with dashes).', + type: 'string', + }, + auto_devops_enabled: { + title: 'Auto DevOps enabled', + description: 'Enable Auto DevOps for this project', + type: 'boolean', + }, + ci_config_path: { + title: 'CI config path', + description: 'Custom CI config path for this project', + type: 'string', + }, + description: { + title: 'Project description', + description: 'Short project description', + type: 'string', + }, + topics: { + title: 'Topic labels', + description: 'Topic labels to apply on the repository', + type: 'array', + items: { + type: 'string', + }, + }, + visibility: { + title: 'Project visibility', + description: + 'The visibility of the project. Can be private, internal, or public. The default value is private.', + type: 'string', + enum: ['private', 'public', 'internal'], + }, + }, + }, + branches: { + title: 'Project branches settings', + type: 'array', + items: { + type: 'object', + required: ['name'], + properties: { + name: { + title: 'Branch name', + type: 'string', + }, + protect: { + title: 'Should branch be protected', + description: `Will mark branch as protected. The default value is 'false'`, + type: 'boolean', + }, + create: { + title: 'Should branch be created', + description: `If branch does not exist, it will be created from provided ref. The default value is 'false'`, + type: 'boolean', + }, + ref: { + title: 'Branch reference', + description: `Branch reference to create branch from. The default value is 'master'`, + type: 'string', + }, + }, + }, + }, + projectVariables: { + title: 'Project variables', + description: + 'Project variables settings based on Gitlab Project Environments API - https://docs.gitlab.com/ee/api/project_level_variables.html#create-a-variable', + type: 'array', + items: { + type: 'object', + required: ['key', 'value'], + properties: { + key: { + title: 'Variable key', + description: + 'The key of a variable; must have no more than 255 characters; only A-Z, a-z, 0-9, and _ are allowed', + type: 'string', + }, + value: { + title: 'Variable value', + description: 'The value of a variable', + type: 'string', + }, + description: { + title: 'Variable description', + description: `The description of the variable. The default value is 'null'`, + type: 'string', + }, + variable_type: { + title: 'Variable type', + description: `The type of a variable. The default value is 'env_var'`, + type: 'string', + enum: ['env_var', 'file'], + }, + protected: { + title: 'Variable protection', + description: `Whether the variable is protected. The default value is 'false'`, + type: 'boolean', + }, + raw: { + title: 'Variable raw', + description: `Whether the variable is in raw format. The default value is 'false'`, + type: 'boolean', + }, + environment_scope: { + title: 'Variable environment scope', + description: `The environment_scope of the variable. The default value is '*'`, + type: 'string', + }, + }, + }, + }, }, }, output: { @@ -145,6 +295,9 @@ export function createPublishGitlabAction(options: { gitAuthorEmail, setUserAsOwner = false, topics = [], + settings = {}, + branches = [], + projectVariables = [], } = ctx.input; const { owner, repo, host } = parseRepoUrl(repoUrl, integrations); @@ -204,6 +357,7 @@ export function createPublishGitlabAction(options: { name: repo, visibility: repoVisibility, ...(topics.length ? { topics } : {}), + ...(Object.keys(settings).length ? { ...settings } : {}), }); // When setUserAsOwner is true the input token is expected to come from an unprivileged user GitLab @@ -247,6 +401,66 @@ export function createPublishGitlabAction(options: { gitAuthorInfo, }); + if (branches) { + for (const branch of branches) { + const { + name, + protect = false, + create = false, + ref = 'master', + } = branch; + + if (create) { + try { + await client.Branches.create(projectId, name, ref); + } catch (e) { + throw new InputError( + `Branch creation failed for ${name}. ${printGitlabError(e)}`, + ); + } + ctx.logger.info( + `Branch ${name} created for ${projectId} with ref ${ref}`, + ); + } + + if (protect) { + try { + await client.ProtectedBranches.protect(projectId, name); + } catch (e) { + throw new InputError( + `Branch protection failed for ${name}. ${printGitlabError(e)}`, + ); + } + ctx.logger.info(`Branch ${name} protected for ${projectId}`); + } + } + } + + if (projectVariables) { + for (const variable of projectVariables) { + const variableWithDefaults = Object.assign(variable, { + variable_type: variable.variable_type ?? 'env_var', + protected: variable.protected ?? false, + masked: variable.masked ?? false, + raw: variable.raw ?? false, + environment_scope: variable.environment_scope ?? '*', + }); + + try { + await client.ProjectVariables.create( + projectId, + variableWithDefaults, + ); + } catch (e) { + throw new InputError( + `Environment variable creation failed for ${ + variableWithDefaults.key + }. ${printGitlabError(e)}`, + ); + } + } + } + ctx.output('commitHash', commitResult?.commitHash); ctx.output('remoteUrl', remoteUrl); ctx.output('repoContentsUrl', repoContentsUrl); @@ -254,3 +468,7 @@ export function createPublishGitlabAction(options: { }, }); } + +function printGitlabError(error: any): string { + return JSON.stringify({ code: error.code, message: error.description }); +} diff --git a/plugins/scaffolder-common/CHANGELOG.md b/plugins/scaffolder-common/CHANGELOG.md index bf11adfc0e..523ce514d6 100644 --- a/plugins/scaffolder-common/CHANGELOG.md +++ b/plugins/scaffolder-common/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-scaffolder-common +## 1.4.2-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 1.4.1 ### Patch Changes diff --git a/plugins/scaffolder-common/package.json b/plugins/scaffolder-common/package.json index f1a2a45fe0..5fe72348c1 100644 --- a/plugins/scaffolder-common/package.json +++ b/plugins/scaffolder-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-scaffolder-common", "description": "Common functionalities for the scaffolder, to be shared between scaffolder and scaffolder-backend plugin", - "version": "1.4.1", + "version": "1.4.2-next.0", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-node/CHANGELOG.md b/plugins/scaffolder-node/CHANGELOG.md index c3a17eaf61..0d95cd77cc 100644 --- a/plugins/scaffolder-node/CHANGELOG.md +++ b/plugins/scaffolder-node/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-scaffolder-node +## 0.2.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/types@1.1.1 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + ## 0.2.5-next.1 ### Patch Changes diff --git a/plugins/scaffolder-node/api-report.md b/plugins/scaffolder-node/api-report.md index 52ce3c8d13..0c97fb2e40 100644 --- a/plugins/scaffolder-node/api-report.md +++ b/plugins/scaffolder-node/api-report.md @@ -53,8 +53,8 @@ export type ActionContext< export const createTemplateAction: < TInputParams extends JsonObject = JsonObject, TOutputParams extends JsonObject = JsonObject, - TInputSchema extends z.ZodType<any, z.ZodTypeDef, any> | Schema = {}, - TOutputSchema extends z.ZodType<any, z.ZodTypeDef, any> | Schema = {}, + TInputSchema extends Schema | z.ZodType<any, z.ZodTypeDef, any> = {}, + TOutputSchema extends Schema | z.ZodType<any, z.ZodTypeDef, any> = {}, TActionInput extends JsonObject = TInputSchema extends z.ZodType< any, any, diff --git a/plugins/scaffolder-node/package.json b/plugins/scaffolder-node/package.json index b46d4207c5..fd49db0371 100644 --- a/plugins/scaffolder-node/package.json +++ b/plugins/scaffolder-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-scaffolder-node", "description": "The plugin-scaffolder-node module for @backstage/plugin-scaffolder-backend", - "version": "0.2.5-next.1", + "version": "0.2.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/scaffolder-react/CHANGELOG.md b/plugins/scaffolder-react/CHANGELOG.md index 77ef8b2d45..eb20d79d2a 100644 --- a/plugins/scaffolder-react/CHANGELOG.md +++ b/plugins/scaffolder-react/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-scaffolder-react +## 1.5.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + ## 1.5.6-next.1 ### Patch Changes diff --git a/plugins/scaffolder-react/package.json b/plugins/scaffolder-react/package.json index 9722c366c4..7a5aa49a01 100644 --- a/plugins/scaffolder-react/package.json +++ b/plugins/scaffolder-react/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-scaffolder-react", "description": "A frontend library that helps other Backstage plugins interact with the Scaffolder", - "version": "1.5.6-next.1", + "version": "1.5.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -93,8 +93,8 @@ "@backstage/plugin-catalog": "workspace:^", "@backstage/plugin-catalog-common": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/scaffolder/CHANGELOG.md b/plugins/scaffolder/CHANGELOG.md index 75417547a2..f32e05eed7 100644 --- a/plugins/scaffolder/CHANGELOG.md +++ b/plugins/scaffolder/CHANGELOG.md @@ -1,5 +1,29 @@ # @backstage/plugin-scaffolder +## 1.15.1-next.2 + +### Patch Changes + +- ff2ab02690: Make entity picker more reliable with only one available entity +- 83e4a42ccd: Display log visibility button on the template panel +- 4c70fe497d: `RepoUrlPickerRepoName` now correctly handles value changes in allowed repos. +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-react@0.4.16-next.1 + - @backstage/plugin-scaffolder-common@1.4.2-next.0 + - @backstage/plugin-scaffolder-react@1.5.6-next.2 + ## 1.15.1-next.1 ### Patch Changes diff --git a/plugins/scaffolder/package.json b/plugins/scaffolder/package.json index 841e6d61d6..7766669411 100644 --- a/plugins/scaffolder/package.json +++ b/plugins/scaffolder/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-scaffolder", "description": "The Backstage plugin that helps you create new things", - "version": "1.15.1-next.1", + "version": "1.15.1-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -58,6 +58,7 @@ "@backstage/plugin-catalog-react": "workspace:^", "@backstage/plugin-permission-react": "workspace:^", "@backstage/plugin-scaffolder-common": "workspace:^", + "@backstage/plugin-scaffolder-node": "workspace:^", "@backstage/plugin-scaffolder-react": "workspace:^", "@backstage/theme": "workspace:^", "@backstage/types": "workspace:^", @@ -102,8 +103,8 @@ "@backstage/dev-utils": "workspace:^", "@backstage/plugin-catalog": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/scaffolder/src/api.test.ts b/plugins/scaffolder/src/api.test.ts index b9b1881066..e10363b61f 100644 --- a/plugins/scaffolder/src/api.test.ts +++ b/plugins/scaffolder/src/api.test.ts @@ -21,6 +21,11 @@ import { rest } from 'msw'; import { setupServer } from 'msw/node'; import { ScaffolderClient } from './api'; import { EventSourcePolyfill } from 'event-source-polyfill'; +import { + SerializedTask, + SerializedTaskEvent, +} from '@backstage/plugin-scaffolder-node'; +import { ScaffolderStep } from '@backstage/plugin-scaffolder-react'; const MockedEventSource = EventSourcePolyfill as jest.MockedClass< typeof EventSourcePolyfill @@ -327,6 +332,98 @@ describe('api', () => { }); }); + describe('getTask', () => { + it('should return the task enriched with timestamps', async () => { + const taskId = 'e4e4cb25-e743-4b79-8572-87e9d35aa998'; + server.use( + rest.get(`${mockBaseUrl}/v2/tasks/:taskId`, (_req, res, ctx) => { + return res( + ctx.json({ + createdAt: '2023-10-16T08:21:32.038Z', + id: taskId, + lastHeartbeatAt: '2023-10-16T08:21:54.304Z', + spec: { + apiVersion: 'scaffolder.backstage.io/v1beta3', + steps: [ + { + action: 'fetch:template', + id: 'fetch', + }, + { + action: 'debug:wait', + id: 'mock-step-1', + }, + { + action: 'debug:wait', + id: 'mock-step-2', + }, + ], + templateInfo: { + entityRef: 'template:default/docs-long-running-template', + }, + }, + } as SerializedTask), + ); + }), + rest.get(`${mockBaseUrl}/v2/tasks/:taskId/events`, (_req, res, ctx) => { + return res( + ctx.json([ + { + createdAt: '2023-10-16T08:21:32.062Z', + body: {}, + id: 109, + taskId, + type: 'log', + }, + { + body: { stepId: 'fetch' }, + createdAt: '2023-10-16T08:21:32.062Z', + id: 110, + taskId, + type: 'log', + }, + { + body: { stepId: 'fetch' }, + createdAt: '2023-10-16T08:21:33.062Z', + id: 111, + taskId, + type: 'log', + }, + { + body: { stepId: 'fetch' }, + createdAt: '2023-10-16T08:21:34.062Z', + id: 112, + taskId, + type: 'log', + }, + { + body: { stepId: 'mock-step-1' }, + createdAt: '2023-10-16T08:21:37.062Z', + id: 120, + taskId, + type: 'log', + }, + ] as SerializedTaskEvent[]), + ); + }), + ); + + const task = await apiClient.getTask(taskId); + + const getStep = (stepId: string) => + task.spec.steps.find( + step => step.id === stepId, + ) as unknown as ScaffolderStep; + + expect(getStep('fetch').startedAt).toBe('2023-10-16T08:21:32.062Z'); + expect(getStep('fetch').endedAt).toBe('2023-10-16T08:21:34.062Z'); + expect(getStep('mock-step-1').startedAt).toBe('2023-10-16T08:21:37.062Z'); + expect(getStep('mock-step-1').endedAt).toBe('2023-10-16T08:21:37.062Z'); + expect(getStep('mock-step-2').startedAt).toBeUndefined(); + expect(getStep('mock-step-2').endedAt).toBeUndefined(); + }); + }); + describe('listTasks', () => { it('should list all tasks', async () => { server.use( diff --git a/plugins/scaffolder/src/api.ts b/plugins/scaffolder/src/api.ts index c67a5c944e..6aa7fac780 100644 --- a/plugins/scaffolder/src/api.ts +++ b/plugins/scaffolder/src/api.ts @@ -38,10 +38,13 @@ import { ScaffolderDryRunOptions, ScaffolderDryRunResponse, TemplateParameterSchema, + ScaffolderStep, } from '@backstage/plugin-scaffolder-react'; +import { TaskStep } from '@backstage/plugin-scaffolder-common'; import queryString from 'qs'; import { EventSourcePolyfill } from 'event-source-polyfill'; +import { SerializedTaskEvent } from '@backstage/plugin-scaffolder-node'; /** * An API to interact with the scaffolder backend. @@ -170,14 +173,62 @@ export class ScaffolderClient implements ScaffolderApi { async getTask(taskId: string): Promise<ScaffolderTask> { const baseUrl = await this.discoveryApi.getBaseUrl('scaffolder'); - const url = `${baseUrl}/v2/tasks/${encodeURIComponent(taskId)}`; + const taskUrl = `${baseUrl}/v2/tasks/${encodeURIComponent(taskId)}`; - const response = await this.fetchApi.fetch(url); - if (!response.ok) { - throw await ResponseError.fromResponse(response); + const taskEventsUrl = `${baseUrl}/v2/tasks/${encodeURIComponent( + taskId, + )}/events`; + + const taskResponse = await this.fetchApi.fetch(taskUrl); + if (!taskResponse.ok) { + throw await ResponseError.fromResponse(taskResponse); } - return await response.json(); + const taskEventsResponse = await this.fetchApi.fetch(taskEventsUrl); + if (!taskEventsResponse.ok) { + throw await ResponseError.fromResponse(taskEventsResponse); + } + + const task = (await taskResponse.json()) as ScaffolderTask; + const taskEvents = + (await taskEventsResponse.json()) as SerializedTaskEvent[]; + + const stepIdToTimestamps = taskEvents + .filter(event => event.type === 'log') + .reduce((acc, event) => { + const stepId = event.body.stepId as string; + if (stepId) { + acc.set(stepId, [...(acc.get(stepId) ?? []), event.createdAt]); + } + return acc; + }, new Map<string, string[]>()); + + const toStartedAt = (stepId: string) => { + const timestamps = stepIdToTimestamps.get(stepId); + return timestamps ? timestamps[0] : undefined; + }; + + const toEndedAt = (stepId: string) => { + const timestamps = stepIdToTimestamps.get(stepId); + return timestamps ? timestamps[timestamps.length - 1] : undefined; + }; + + const enrichedTask = { + ...task, + spec: { + ...task.spec, + steps: task.spec.steps.map( + step => + ({ + ...step, + startedAt: toStartedAt(step.id), + endedAt: toEndedAt(step.id), + } as TaskStep & ScaffolderStep), + ), + }, + }; + + return enrichedTask as ScaffolderTask; } streamLogs(options: ScaffolderStreamLogsOptions): Observable<LogEvent> { diff --git a/plugins/scaffolder/src/components/MultistepJsonForm/MultistepJsonForm.tsx b/plugins/scaffolder/src/components/MultistepJsonForm/MultistepJsonForm.tsx index ec95bad0e5..d8299a9b5f 100644 --- a/plugins/scaffolder/src/components/MultistepJsonForm/MultistepJsonForm.tsx +++ b/plugins/scaffolder/src/components/MultistepJsonForm/MultistepJsonForm.tsx @@ -29,7 +29,7 @@ import { useRouteRefParams, useApi, } from '@backstage/core-plugin-api'; -import { FormProps, IChangeEvent, withTheme } from '@rjsf/core'; +import { FormProps, IChangeEvent, ISubmitEvent, withTheme } from '@rjsf/core'; import { Theme as MuiTheme } from '@rjsf/material-ui'; import React, { ComponentType, useState } from 'react'; import { transformSchemaToProps } from './schema'; @@ -185,7 +185,7 @@ export const MultistepJsonForm = (props: MultistepJsonFormProps) => { formData={formData} formContext={{ formData }} onChange={onChange} - onSubmit={e => { + onSubmit={(e: ISubmitEvent<any>) => { if (e.errors.length === 0) handleNext(); }} {...formProps} diff --git a/plugins/scaffolder/src/components/TemplateEditorPage/CustomFieldExplorer.tsx b/plugins/scaffolder/src/components/TemplateEditorPage/CustomFieldExplorer.tsx index 43b3b49bcf..e470267b23 100644 --- a/plugins/scaffolder/src/components/TemplateEditorPage/CustomFieldExplorer.tsx +++ b/plugins/scaffolder/src/components/TemplateEditorPage/CustomFieldExplorer.tsx @@ -28,7 +28,7 @@ import { Select, } from '@material-ui/core'; import CloseIcon from '@material-ui/icons/Close'; -import { withTheme } from '@rjsf/core'; +import { ISubmitEvent, withTheme } from '@rjsf/core'; import { Theme as MuiTheme } from '@rjsf/material-ui'; import CodeMirror from '@uiw/react-codemirror'; import React, { useCallback, useMemo, useState } from 'react'; @@ -104,7 +104,7 @@ export const CustomFieldExplorer = ({ }, [customFieldExtensions]); const handleSelectionChange = useCallback( - selection => { + (selection: FieldExtensionOptions) => { setSelectedField(selection); setFieldFormState({}); setFormState({}); @@ -113,7 +113,7 @@ export const CustomFieldExplorer = ({ ); const handleFieldConfigChange = useCallback( - state => { + (state: {}) => { setFieldFormState(state); setFormState({}); // Force TemplateEditorForm to re-render since some fields @@ -134,7 +134,9 @@ export const CustomFieldExplorer = ({ value={selectedField} label="Choose Custom Field Extension" labelId="select-field-label" - onChange={e => handleSelectionChange(e.target.value)} + onChange={e => + handleSelectionChange(e.target.value as FieldExtensionOptions) + } > {fieldOptions.map((option, idx) => ( <MenuItem key={idx} value={option as any}> @@ -158,7 +160,9 @@ export const CustomFieldExplorer = ({ noHtml5Validate formData={fieldFormState} formContext={{ fieldFormState }} - onSubmit={e => handleFieldConfigChange(e.formData)} + onSubmit={(e: ISubmitEvent<any>) => + handleFieldConfigChange(e.formData) + } schema={selectedField.schema?.uiOptions || {}} > <Button diff --git a/plugins/scaffolder/src/components/TemplateEditorPage/TemplateFormPreviewer.tsx b/plugins/scaffolder/src/components/TemplateEditorPage/TemplateFormPreviewer.tsx index 69433d5f51..9442394177 100644 --- a/plugins/scaffolder/src/components/TemplateEditorPage/TemplateFormPreviewer.tsx +++ b/plugins/scaffolder/src/components/TemplateEditorPage/TemplateFormPreviewer.tsx @@ -164,7 +164,8 @@ export const TemplateFormPreviewer = ({ ); const handleSelectChange = useCallback( - selected => { + // TODO(Rugvip): Afaik this should be Entity, but didn't want to make runtime changes while fixing types + (selected: any) => { setSelectedTemplate(selected); setTemplateYaml(yaml.stringify(selected.spec)); }, diff --git a/plugins/scaffolder/src/components/fields/EntityPicker/EntityPicker.tsx b/plugins/scaffolder/src/components/fields/EntityPicker/EntityPicker.tsx index 0f698919d5..0d45fe771c 100644 --- a/plugins/scaffolder/src/components/fields/EntityPicker/EntityPicker.tsx +++ b/plugins/scaffolder/src/components/fields/EntityPicker/EntityPicker.tsx @@ -123,11 +123,17 @@ export const EntityPicker = (props: EntityPickerProps) => { [onChange, formData, defaultKind, defaultNamespace, allowArbitraryValues], ); + // Since free solo can be enabled, attempt to parse as a full entity ref first, then fall + // back to the given value. + const selectedEntity = + entities?.find(e => stringifyEntityRef(e) === formData) ?? + (allowArbitraryValues && formData ? getLabel(formData) : ''); + useEffect(() => { - if (entities?.length === 1) { + if (entities?.length === 1 && selectedEntity === '') { onChange(stringifyEntityRef(entities[0])); } - }, [entities, onChange]); + }, [entities, onChange, selectedEntity]); return ( <FormControl @@ -138,12 +144,7 @@ export const EntityPicker = (props: EntityPickerProps) => { <Autocomplete disabled={entities?.length === 1} id={idSchema?.$id} - value={ - // Since free solo can be enabled, attempt to parse as a full entity ref first, then fall - // back to the given value. - entities?.find(e => stringifyEntityRef(e) === formData) ?? - (allowArbitraryValues && formData ? getLabel(formData) : '') - } + value={selectedEntity} loading={loading} onChange={onSelect} options={entities || []} diff --git a/plugins/scaffolder/src/next/TemplateEditorPage/CustomFieldExplorer.tsx b/plugins/scaffolder/src/next/TemplateEditorPage/CustomFieldExplorer.tsx index bf5ffe97ea..15298dff8a 100644 --- a/plugins/scaffolder/src/next/TemplateEditorPage/CustomFieldExplorer.tsx +++ b/plugins/scaffolder/src/next/TemplateEditorPage/CustomFieldExplorer.tsx @@ -102,7 +102,7 @@ export const CustomFieldExplorer = ({ }, [customFieldExtensions]); const handleSelectionChange = useCallback( - selection => { + (selection: NextFieldExtensionOptions) => { setSelectedField(selection); setFieldFormState({}); }, @@ -110,7 +110,7 @@ export const CustomFieldExplorer = ({ ); const handleFieldConfigChange = useCallback( - state => { + (state: {}) => { setFieldFormState(state); // Force TemplateEditorForm to re-render since some fields // may not be responsive to ui:option changes @@ -130,7 +130,9 @@ export const CustomFieldExplorer = ({ value={selectedField} label="Choose Custom Field Extension" labelId="select-field-label" - onChange={e => handleSelectionChange(e.target.value)} + onChange={e => + handleSelectionChange(e.target.value as NextFieldExtensionOptions) + } > {fieldOptions.map((option, idx) => ( <MenuItem key={idx} value={option as any}> diff --git a/plugins/scaffolder/src/next/TemplateEditorPage/TemplateFormPreviewer.tsx b/plugins/scaffolder/src/next/TemplateEditorPage/TemplateFormPreviewer.tsx index 2aa1cc764d..75d8c511b1 100644 --- a/plugins/scaffolder/src/next/TemplateEditorPage/TemplateFormPreviewer.tsx +++ b/plugins/scaffolder/src/next/TemplateEditorPage/TemplateFormPreviewer.tsx @@ -161,7 +161,8 @@ export const TemplateFormPreviewer = ({ ); const handleSelectChange = useCallback( - selected => { + // TODO(Rugvip): Afaik this should be Entity, but didn't want to make runtime changes while fixing types + (selected: any) => { setSelectedTemplate(selected); setTemplateYaml(yaml.stringify(selected.spec)); }, diff --git a/plugins/search-backend-module-catalog/CHANGELOG.md b/plugins/search-backend-module-catalog/CHANGELOG.md index 402b501695..80f8e6b2b9 100644 --- a/plugins/search-backend-module-catalog/CHANGELOG.md +++ b/plugins/search-backend-module-catalog/CHANGELOG.md @@ -1,5 +1,23 @@ # @backstage/plugin-search-backend-module-catalog +## 0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.1.9-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-catalog/package.json b/plugins/search-backend-module-catalog/package.json index 4963708861..dc69657e74 100644 --- a/plugins/search-backend-module-catalog/package.json +++ b/plugins/search-backend-module-catalog/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search-backend-module-catalog", "description": "A module for the search backend that exports catalog modules", - "version": "0.1.9-next.1", + "version": "0.1.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/search-backend-module-elasticsearch/CHANGELOG.md b/plugins/search-backend-module-elasticsearch/CHANGELOG.md index 0e92e7c3db..e08124fc5a 100644 --- a/plugins/search-backend-module-elasticsearch/CHANGELOG.md +++ b/plugins/search-backend-module-elasticsearch/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-search-backend-module-elasticsearch +## 1.3.9-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.3.8-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-elasticsearch/package.json b/plugins/search-backend-module-elasticsearch/package.json index 36d66e827b..505af44be1 100644 --- a/plugins/search-backend-module-elasticsearch/package.json +++ b/plugins/search-backend-module-elasticsearch/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search-backend-module-elasticsearch", "description": "A module for the search backend that implements search using ElasticSearch", - "version": "1.3.8-next.1", + "version": "1.3.9-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/search-backend-module-explore/CHANGELOG.md b/plugins/search-backend-module-explore/CHANGELOG.md index c26bf84328..9acc5a8616 100644 --- a/plugins/search-backend-module-explore/CHANGELOG.md +++ b/plugins/search-backend-module-explore/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-search-backend-module-explore +## 0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-explore-common@0.0.2 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.1.9-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-explore/package.json b/plugins/search-backend-module-explore/package.json index f70d70dd73..e050734050 100644 --- a/plugins/search-backend-module-explore/package.json +++ b/plugins/search-backend-module-explore/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search-backend-module-explore", "description": "A module for the search backend that exports explore modules", - "version": "0.1.9-next.1", + "version": "0.1.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/search-backend-module-pg/CHANGELOG.md b/plugins/search-backend-module-pg/CHANGELOG.md index 10453b9500..0e2b137bbc 100644 --- a/plugins/search-backend-module-pg/CHANGELOG.md +++ b/plugins/search-backend-module-pg/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-search-backend-module-pg +## 0.5.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.5.14-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-pg/package.json b/plugins/search-backend-module-pg/package.json index ad9f9e0a3b..1a34413dcc 100644 --- a/plugins/search-backend-module-pg/package.json +++ b/plugins/search-backend-module-pg/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search-backend-module-pg", "description": "A module for the search backend that implements search using PostgreSQL", - "version": "0.5.14-next.1", + "version": "0.5.15-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/search-backend-module-techdocs/CHANGELOG.md b/plugins/search-backend-module-techdocs/CHANGELOG.md index 5364e493c6..557b7edd13 100644 --- a/plugins/search-backend-module-techdocs/CHANGELOG.md +++ b/plugins/search-backend-module-techdocs/CHANGELOG.md @@ -1,5 +1,23 @@ # @backstage/plugin-search-backend-module-techdocs +## 0.1.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-techdocs-node@1.9.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.1.9-next.1 ### Patch Changes diff --git a/plugins/search-backend-module-techdocs/package.json b/plugins/search-backend-module-techdocs/package.json index 54e9b86afa..ec57b3f624 100644 --- a/plugins/search-backend-module-techdocs/package.json +++ b/plugins/search-backend-module-techdocs/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search-backend-module-techdocs", "description": "A module for the search backend that exports techdocs modules", - "version": "0.1.9-next.1", + "version": "0.1.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/search-backend-node/CHANGELOG.md b/plugins/search-backend-node/CHANGELOG.md index 880615383a..58f334fb30 100644 --- a/plugins/search-backend-node/CHANGELOG.md +++ b/plugins/search-backend-node/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-search-backend-node +## 1.2.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.2.9-next.1 ### Patch Changes diff --git a/plugins/search-backend-node/package.json b/plugins/search-backend-node/package.json index 587b98cd61..a040f3a8f7 100644 --- a/plugins/search-backend-node/package.json +++ b/plugins/search-backend-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search-backend-node", "description": "A library for Backstage backend plugins that want to interact with the search backend plugin", - "version": "1.2.9-next.1", + "version": "1.2.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/search-backend/CHANGELOG.md b/plugins/search-backend/CHANGELOG.md index a1cae58b98..ea0a17908c 100644 --- a/plugins/search-backend/CHANGELOG.md +++ b/plugins/search-backend/CHANGELOG.md @@ -1,5 +1,22 @@ # @backstage/plugin-search-backend +## 1.4.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-openapi-utils@0.0.5-next.0 + - @backstage/plugin-permission-node@0.7.17-next.2 + - @backstage/plugin-search-backend-node@1.2.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.4.5-next.1 ### Patch Changes diff --git a/plugins/search-backend/config.d.ts b/plugins/search-backend/config.d.ts index 3dbdf78dfe..25ae59d273 100644 --- a/plugins/search-backend/config.d.ts +++ b/plugins/search-backend/config.d.ts @@ -22,6 +22,11 @@ export interface Config { */ maxPageLimit?: number; + /** + * Sets the maximum term length for the search string. Defaults to 100. + */ + maxTermLength?: number; + /** * Options related to the search integration with the Backstage permissions system */ diff --git a/plugins/search-backend/package.json b/plugins/search-backend/package.json index 10c09a0178..ead9e7f6b6 100644 --- a/plugins/search-backend/package.json +++ b/plugins/search-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search-backend", "description": "The Backstage backend plugin that provides your backstage app with search", - "version": "1.4.5-next.1", + "version": "1.4.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/search-backend/src/service/router.test.ts b/plugins/search-backend/src/service/router.test.ts index 7ec8603307..73523f2b62 100644 --- a/plugins/search-backend/src/service/router.test.ts +++ b/plugins/search-backend/src/service/router.test.ts @@ -60,7 +60,7 @@ describe('createRouter', () => { }, config: new ConfigReader({ permissions: { enabled: false }, - search: { maxPageLimit: 200 }, + search: { maxPageLimit: 200, maxTermLength: 20 }, }), permissions: mockPermissionEvaluator, logger, @@ -162,6 +162,19 @@ describe('createRouter', () => { }); }); + it('should reject term length over configured max', async () => { + const response = await request(app).get( + `/query?term=HelloWorld1234567890!`, + ); + + expect(response.status).toEqual(400); + expect(response.body).toMatchObject({ + error: { + message: /The term length "21" is greater than "20"/i, + }, + }); + }); + it('removes backend-only properties from search documents', async () => { mockSearchEngine.query.mockResolvedValue({ results: [ diff --git a/plugins/search-backend/src/service/router.ts b/plugins/search-backend/src/service/router.ts index dca632dfaf..876cb5d103 100644 --- a/plugins/search-backend/src/service/router.ts +++ b/plugins/search-backend/src/service/router.ts @@ -63,6 +63,7 @@ export type RouterOptions = { }; const defaultMaxPageLimit = 100; +const defaultMaxTermLength = 100; const allowedLocationProtocols = ['http:', 'https:']; /** @@ -77,8 +78,19 @@ export async function createRouter( const maxPageLimit = config.getOptionalNumber('search.maxPageLimit') ?? defaultMaxPageLimit; + const maxTermLength = + config.getOptionalNumber('search.maxTermLength') ?? defaultMaxTermLength; + const requestSchema = z.object({ - term: z.string().default(''), + term: z + .string() + .refine( + term => term.length <= maxTermLength, + term => ({ + message: `The term length "${term.length}" is greater than "${maxTermLength}"`, + }), + ) + .default(''), filters: jsonObjectSchema.optional(), types: z .array(z.string().refine(type => Object.keys(types).includes(type))) diff --git a/plugins/search-backend/src/service/standaloneServer.ts b/plugins/search-backend/src/service/standaloneServer.ts index 3f1fdcb34e..9e4294d39f 100644 --- a/plugins/search-backend/src/service/standaloneServer.ts +++ b/plugins/search-backend/src/service/standaloneServer.ts @@ -18,7 +18,7 @@ import { createServiceBuilder, loadBackendConfig, ServerTokenManager, - SingleHostDiscovery, + HostDiscovery, } from '@backstage/backend-common'; import { Server } from 'http'; import { Logger } from 'winston'; @@ -42,7 +42,7 @@ export async function startStandaloneServer( const config = await loadBackendConfig({ logger, argv: process.argv }); const searchEngine = new LunrSearchEngine({ logger }); const indexBuilder = new IndexBuilder({ logger, searchEngine }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const tokenManager = ServerTokenManager.fromConfig(config, { logger, }); diff --git a/plugins/search-common/CHANGELOG.md b/plugins/search-common/CHANGELOG.md index 0e7f901614..f1ca109111 100644 --- a/plugins/search-common/CHANGELOG.md +++ b/plugins/search-common/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-search-common +## 1.2.7-next.0 + +### Patch Changes + +- Updated dependencies + - @backstage/types@1.1.1 + - @backstage/plugin-permission-common@0.7.9-next.0 + ## 1.2.6 ### Patch Changes diff --git a/plugins/search-common/package.json b/plugins/search-common/package.json index b59df94990..427d6b8498 100644 --- a/plugins/search-common/package.json +++ b/plugins/search-common/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search-common", "description": "Common functionalities for Search, to be shared between various search-enabled plugins", - "version": "1.2.6", + "version": "1.2.7-next.0", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/plugins/search-react/CHANGELOG.md b/plugins/search-react/CHANGELOG.md index 1cb3a0e329..0a5cc65d96 100644 --- a/plugins/search-react/CHANGELOG.md +++ b/plugins/search-react/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-search-react +## 1.7.1-next.2 + +### Patch Changes + +- 06432f900c: Updated `/alpha` exports to use new `attachTo` option. +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/frontend-app-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.7.1-next.1 ### Patch Changes diff --git a/plugins/search-react/package.json b/plugins/search-react/package.json index 3591e75e94..fa01c9cb5a 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.1-next.1", + "version": "1.7.1-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -70,8 +70,8 @@ "@backstage/cli": "workspace:^", "@backstage/core-app-api": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0" diff --git a/plugins/search-react/src/alpha.test.tsx b/plugins/search-react/src/alpha.test.tsx index 8a88c9cc5d..5222e4dad5 100644 --- a/plugins/search-react/src/alpha.test.tsx +++ b/plugins/search-react/src/alpha.test.tsx @@ -168,7 +168,7 @@ describe('createSearchResultListItemExtension', () => { }); const app = createApp({ - plugins: [SearchPlugin], + features: [SearchPlugin], configLoader: async () => new MockConfigApi({ app: { diff --git a/plugins/search-react/src/components/SearchFilter/SearchFilter.Autocomplete.test.tsx b/plugins/search-react/src/components/SearchFilter/SearchFilter.Autocomplete.test.tsx index 765d2a26d1..e95f7fa856 100644 --- a/plugins/search-react/src/components/SearchFilter/SearchFilter.Autocomplete.test.tsx +++ b/plugins/search-react/src/components/SearchFilter/SearchFilter.Autocomplete.test.tsx @@ -29,7 +29,7 @@ const SearchContextFilterSpy = ({ name }: { name: string }) => { const value = filters[name]; return ( <span data-testid={`${name}-filter-spy`}> - {Array.isArray(value) ? value.join(',') : value} + {Array.isArray(value) ? value.join(',') : value?.toString()} </span> ); }; diff --git a/plugins/search-react/src/components/SearchResultGroup/SearchResultGroup.tsx b/plugins/search-react/src/components/SearchResultGroup/SearchResultGroup.tsx index 2a3ae1e24c..ea1817193c 100644 --- a/plugins/search-react/src/components/SearchResultGroup/SearchResultGroup.tsx +++ b/plugins/search-react/src/components/SearchResultGroup/SearchResultGroup.tsx @@ -193,7 +193,7 @@ export const SearchResultGroupTextFilterField = ( contentEditable suppressContentEditableWarning > - {value} + {value?.toString()} </Typography> </SearchResultGroupFilterFieldLayout> ); @@ -377,7 +377,7 @@ export function SearchResultGroupLayout<FilterOption>( filterOptions, renderFilterOption = filterOption => ( <MenuItem key={String(filterOption)} value={String(filterOption)}> - {filterOption} + {String(filterOption)} </MenuItem> ), filterFields, diff --git a/plugins/search/CHANGELOG.md b/plugins/search/CHANGELOG.md index 714e4ef1de..067c7dfc41 100644 --- a/plugins/search/CHANGELOG.md +++ b/plugins/search/CHANGELOG.md @@ -1,5 +1,23 @@ # @backstage/plugin-search +## 1.4.1-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/version-bridge@1.0.5 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.4.1-next.1 ### Patch Changes diff --git a/plugins/search/alpha-api-report.md b/plugins/search/alpha-api-report.md index 5799ff5cd6..58c963b1d6 100644 --- a/plugins/search/alpha-api-report.md +++ b/plugins/search/alpha-api-report.md @@ -3,11 +3,13 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { Extension } from '@backstage/frontend-plugin-api'; // @alpha (undocumented) -const _default: BackstagePlugin; +const _default: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; export default _default; // @alpha (undocumented) diff --git a/plugins/search/package.json b/plugins/search/package.json index 6067d0004c..e4e5ee5aa0 100644 --- a/plugins/search/package.json +++ b/plugins/search/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-search", "description": "The Backstage plugin that provides your backstage app with search", - "version": "1.4.1-next.1", + "version": "1.4.1-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -75,8 +75,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/search/src/alpha.tsx b/plugins/search/src/alpha.tsx index 6d74c85d49..f1c4f68d02 100644 --- a/plugins/search/src/alpha.tsx +++ b/plugins/search/src/alpha.tsx @@ -198,22 +198,24 @@ export const SearchPage = createPageExtension({ <Grid item xs> <SearchPagination /> <SearchResults> - {({ results }) => - results.map((result, index) => { - const { noTrack } = config; - const { document, ...rest } = result; - const SearchResultListItem = - getResultItemComponent(result); - return ( - <SearchResultListItem - {...rest} - key={index} - result={document} - noTrack={noTrack} - /> - ); - }) - } + {({ results }) => ( + <> + {results.map((result, index) => { + const { noTrack } = config; + const { document, ...rest } = result; + const SearchResultListItem = + getResultItemComponent(result); + return ( + <SearchResultListItem + {...rest} + key={index} + result={document} + noTrack={noTrack} + /> + ); + })} + </> + )} </SearchResults> <SearchResultPager /> </Grid> diff --git a/plugins/search/src/components/HomePageComponent/HomePageSearchBar.tsx b/plugins/search/src/components/HomePageComponent/HomePageSearchBar.tsx index 47ee15c7f3..19dfd8190d 100644 --- a/plugins/search/src/components/HomePageComponent/HomePageSearchBar.tsx +++ b/plugins/search/src/components/HomePageComponent/HomePageSearchBar.tsx @@ -57,18 +57,11 @@ export const HomePageSearchBar = (props: HomePageSearchBarProps) => { handleSearch({ query: ref.current?.value ?? '' }); }, [handleSearch]); - const handleChange = useCallback( - value => { - setQuery(value); - }, - [setQuery], - ); - return ( <SearchBarBase value={query} onSubmit={handleSubmit} - onChange={handleChange} + onChange={setQuery} inputProps={{ ref }} InputProps={{ ...props.InputProps, diff --git a/plugins/sentry/CHANGELOG.md b/plugins/sentry/CHANGELOG.md index 0e2a3d446c..7794d30a34 100644 --- a/plugins/sentry/CHANGELOG.md +++ b/plugins/sentry/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-sentry +## 0.5.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.5.10-next.1 ### Patch Changes diff --git a/plugins/sentry/package.json b/plugins/sentry/package.json index b6f502baee..cc9c553bf1 100644 --- a/plugins/sentry/package.json +++ b/plugins/sentry/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-sentry", "description": "A Backstage plugin that integrates towards Sentry", - "version": "0.5.10-next.1", + "version": "0.5.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,8 +59,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/luxon": "^3.0.0", diff --git a/plugins/sentry/src/components/SentryIssuesTable/SentryIssuesTable.tsx b/plugins/sentry/src/components/SentryIssuesTable/SentryIssuesTable.tsx index 60ee6b7dbf..8f336c629b 100644 --- a/plugins/sentry/src/components/SentryIssuesTable/SentryIssuesTable.tsx +++ b/plugins/sentry/src/components/SentryIssuesTable/SentryIssuesTable.tsx @@ -74,12 +74,15 @@ const SentryIssuesTable = (props: SentryIssuesTableProps) => { const { sentryIssues, statsFor, tableOptions } = props; const [selected, setSelected] = useState(ONE_DAY_IN_MILLIS); - const filterByDate = useCallback((issue, selectedFilter) => { - return ( - DateTime.fromISO(issue.lastSeen) > - DateTime.now().minus(Duration.fromMillis(selectedFilter)) - ); - }, []); + const filterByDate = useCallback( + (issue: SentryIssue, selectedFilter: number) => { + return ( + DateTime.fromISO(issue.lastSeen) > + DateTime.now().minus(Duration.fromMillis(selectedFilter)) + ); + }, + [], + ); const [filteredIssues, setFilteredIssues] = useState( sentryIssues.filter(i => filterByDate(i, selected)), ); diff --git a/plugins/shortcuts/CHANGELOG.md b/plugins/shortcuts/CHANGELOG.md index 29eb3eefc5..49298f1942 100644 --- a/plugins/shortcuts/CHANGELOG.md +++ b/plugins/shortcuts/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-shortcuts +## 0.3.15-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + ## 0.3.15-next.1 ### Patch Changes diff --git a/plugins/shortcuts/package.json b/plugins/shortcuts/package.json index b3f3d53858..db2a5ab6fb 100644 --- a/plugins/shortcuts/package.json +++ b/plugins/shortcuts/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-shortcuts", "description": "A Backstage plugin that provides a shortcuts feature to the sidebar", - "version": "0.3.15-next.1", + "version": "0.3.15-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -53,8 +53,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/zen-observable": "^0.8.2", diff --git a/plugins/sonarqube-backend/CHANGELOG.md b/plugins/sonarqube-backend/CHANGELOG.md index d5f8999191..72533260d3 100644 --- a/plugins/sonarqube-backend/CHANGELOG.md +++ b/plugins/sonarqube-backend/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-sonarqube-backend +## 0.2.8-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.2.7-next.1 ### Patch Changes diff --git a/plugins/sonarqube-backend/package.json b/plugins/sonarqube-backend/package.json index 1ff45c2ac9..2b9baba2de 100644 --- a/plugins/sonarqube-backend/package.json +++ b/plugins/sonarqube-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-sonarqube-backend", - "version": "0.2.7-next.1", + "version": "0.2.8-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/sonarqube-react/CHANGELOG.md b/plugins/sonarqube-react/CHANGELOG.md index 5fea1d2e9e..9bf9e3177f 100644 --- a/plugins/sonarqube-react/CHANGELOG.md +++ b/plugins/sonarqube-react/CHANGELOG.md @@ -1,5 +1,13 @@ # @backstage/plugin-sonarqube-react +## 0.1.9-next.1 + +### Patch Changes + +- Updated dependencies + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + ## 0.1.9-next.0 ### Patch Changes diff --git a/plugins/sonarqube-react/package.json b/plugins/sonarqube-react/package.json index 6e1adb42f9..958c41dde9 100644 --- a/plugins/sonarqube-react/package.json +++ b/plugins/sonarqube-react/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-sonarqube-react", - "version": "0.1.9-next.0", + "version": "0.1.9-next.1", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/sonarqube/CHANGELOG.md b/plugins/sonarqube/CHANGELOG.md index d951104286..f8e8b1dde1 100644 --- a/plugins/sonarqube/CHANGELOG.md +++ b/plugins/sonarqube/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-sonarqube +## 0.7.6-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-sonarqube-react@0.1.9-next.1 + ## 0.7.6-next.1 ### Patch Changes diff --git a/plugins/sonarqube/package.json b/plugins/sonarqube/package.json index b68c28b76b..b99233d945 100644 --- a/plugins/sonarqube/package.json +++ b/plugins/sonarqube/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-sonarqube", "description": "", - "version": "0.7.6-next.1", + "version": "0.7.6-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -62,8 +62,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/splunk-on-call/CHANGELOG.md b/plugins/splunk-on-call/CHANGELOG.md index 1117cfee3e..086deabcb7 100644 --- a/plugins/splunk-on-call/CHANGELOG.md +++ b/plugins/splunk-on-call/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-splunk-on-call +## 0.4.14-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/theme@0.4.3-next.0 + ## 0.4.14-next.1 ### Patch Changes diff --git a/plugins/splunk-on-call/package.json b/plugins/splunk-on-call/package.json index b677f6f425..5066b28a52 100644 --- a/plugins/splunk-on-call/package.json +++ b/plugins/splunk-on-call/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-splunk-on-call", "description": "A Backstage plugin that integrates towards Splunk On-Call", - "version": "0.4.14-next.1", + "version": "0.4.14-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -57,8 +57,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/luxon": "^3.0.0", diff --git a/plugins/stack-overflow-backend/CHANGELOG.md b/plugins/stack-overflow-backend/CHANGELOG.md index 149dd6913f..588eb3e4c0 100644 --- a/plugins/stack-overflow-backend/CHANGELOG.md +++ b/plugins/stack-overflow-backend/CHANGELOG.md @@ -1,5 +1,14 @@ # @backstage/plugin-stack-overflow-backend +## 0.2.10-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.2.9-next.1 ### Patch Changes diff --git a/plugins/stack-overflow-backend/package.json b/plugins/stack-overflow-backend/package.json index 57c8d6bcfc..17f5edd9ad 100644 --- a/plugins/stack-overflow-backend/package.json +++ b/plugins/stack-overflow-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-stack-overflow-backend", - "version": "0.2.9-next.1", + "version": "0.2.10-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/stack-overflow/CHANGELOG.md b/plugins/stack-overflow/CHANGELOG.md index d0866a9211..cb9d27d7e1 100644 --- a/plugins/stack-overflow/CHANGELOG.md +++ b/plugins/stack-overflow/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-stack-overflow +## 0.1.21-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-home-react@0.1.4-next.2 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 0.1.21-next.1 ### Patch Changes diff --git a/plugins/stack-overflow/package.json b/plugins/stack-overflow/package.json index eef133b305..857b6f22cf 100644 --- a/plugins/stack-overflow/package.json +++ b/plugins/stack-overflow/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-stack-overflow", - "version": "0.1.21-next.1", + "version": "0.1.21-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -38,7 +38,7 @@ "@backstage/theme": "workspace:^", "@material-ui/core": "^4.12.2", "@material-ui/icons": "^4.9.1", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@types/react": "^16.13.1 || ^17.0.0", "cross-fetch": "^3.1.5", "lodash": "^4.17.21", @@ -55,7 +55,7 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", + "@testing-library/dom": "^9.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/stackstorm/CHANGELOG.md b/plugins/stackstorm/CHANGELOG.md index 6734c7dd27..199e2e320e 100644 --- a/plugins/stackstorm/CHANGELOG.md +++ b/plugins/stackstorm/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-stackstorm +## 0.1.7-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.1.7-next.1 ### Patch Changes diff --git a/plugins/stackstorm/package.json b/plugins/stackstorm/package.json index bd945feb36..a0c2a0ecdf 100644 --- a/plugins/stackstorm/package.json +++ b/plugins/stackstorm/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-stackstorm", "description": "A Backstage plugin that integrates towards StackStorm", - "version": "0.1.7-next.1", + "version": "0.1.7-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/tech-insights-backend-module-jsonfc/CHANGELOG.md b/plugins/tech-insights-backend-module-jsonfc/CHANGELOG.md index f8f70f1c0c..531e00b079 100644 --- a/plugins/tech-insights-backend-module-jsonfc/CHANGELOG.md +++ b/plugins/tech-insights-backend-module-jsonfc/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-tech-insights-backend-module-jsonfc +## 0.1.38-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-tech-insights-node@0.4.12-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-tech-insights-common@0.2.12 + ## 0.1.37-next.1 ### Patch Changes diff --git a/plugins/tech-insights-backend-module-jsonfc/package.json b/plugins/tech-insights-backend-module-jsonfc/package.json index bd7b2c2226..496b61cf7b 100644 --- a/plugins/tech-insights-backend-module-jsonfc/package.json +++ b/plugins/tech-insights-backend-module-jsonfc/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-tech-insights-backend-module-jsonfc", - "version": "0.1.37-next.1", + "version": "0.1.38-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/tech-insights-backend/CHANGELOG.md b/plugins/tech-insights-backend/CHANGELOG.md index cbafe8f3b5..9a41dd8389 100644 --- a/plugins/tech-insights-backend/CHANGELOG.md +++ b/plugins/tech-insights-backend/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-tech-insights-backend +## 0.5.20-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/plugin-tech-insights-node@0.4.12-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-tech-insights-common@0.2.12 + ## 0.5.19-next.1 ### Patch Changes diff --git a/plugins/tech-insights-backend/package.json b/plugins/tech-insights-backend/package.json index a89907fd62..048ea64364 100644 --- a/plugins/tech-insights-backend/package.json +++ b/plugins/tech-insights-backend/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-tech-insights-backend", - "version": "0.5.19-next.1", + "version": "0.5.20-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/tech-insights-backend/src/service/fact/FactRetrieverEngine.test.ts b/plugins/tech-insights-backend/src/service/fact/FactRetrieverEngine.test.ts index fe3c050e69..5473b28c62 100644 --- a/plugins/tech-insights-backend/src/service/fact/FactRetrieverEngine.test.ts +++ b/plugins/tech-insights-backend/src/service/fact/FactRetrieverEngine.test.ts @@ -64,15 +64,15 @@ const testFactRetriever: FactRetriever = { ]; }), }; + const defaultCadence = '1 * * * *'; + describe('FactRetrieverEngine', () => { let engine: FactRetrieverEngine; type FactSchemaAssertionCallback = ( factSchemaDefinition: FactSchemaDefinition, ) => void; - jest.setTimeout(15000); - type FactInsertionAssertionCallback = ({ facts, id, diff --git a/plugins/tech-insights-node/CHANGELOG.md b/plugins/tech-insights-node/CHANGELOG.md index 549c427075..fa99e50423 100644 --- a/plugins/tech-insights-node/CHANGELOG.md +++ b/plugins/tech-insights-node/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-tech-insights-node +## 0.4.12-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/config@1.1.1-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-tech-insights-common@0.2.12 + ## 0.4.11-next.1 ### Patch Changes diff --git a/plugins/tech-insights-node/package.json b/plugins/tech-insights-node/package.json index 980acd1a4b..1d72568bc9 100644 --- a/plugins/tech-insights-node/package.json +++ b/plugins/tech-insights-node/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-tech-insights-node", - "version": "0.4.11-next.1", + "version": "0.4.12-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/tech-insights/CHANGELOG.md b/plugins/tech-insights/CHANGELOG.md index 053f9d97ed..ee64de0b64 100644 --- a/plugins/tech-insights/CHANGELOG.md +++ b/plugins/tech-insights/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-tech-insights +## 0.3.17-next.2 + +### Patch Changes + +- 21f409d776: Export `ScorecardInfo` and `ScorecardsList` components to be able to use manually queried check results directly. +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + - @backstage/plugin-tech-insights-common@0.2.12 + ## 0.3.17-next.1 ### Patch Changes diff --git a/plugins/tech-insights/package.json b/plugins/tech-insights/package.json index 142a24cb9b..e8d9d7a12c 100644 --- a/plugins/tech-insights/package.json +++ b/plugins/tech-insights/package.json @@ -1,6 +1,6 @@ { "name": "@backstage/plugin-tech-insights", - "version": "0.3.17-next.1", + "version": "0.3.17-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -54,8 +54,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/tech-radar/CHANGELOG.md b/plugins/tech-radar/CHANGELOG.md index a7684ba5c8..b182aa25a9 100644 --- a/plugins/tech-radar/CHANGELOG.md +++ b/plugins/tech-radar/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-tech-radar +## 0.6.9-next.2 + +### Patch Changes + +- 0b55f773a7: Removed some unused dependencies +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/theme@0.4.3-next.0 + ## 0.6.9-next.1 ### Patch Changes diff --git a/plugins/tech-radar/alpha-api-report.md b/plugins/tech-radar/alpha-api-report.md index c54f692982..9245acfaf2 100644 --- a/plugins/tech-radar/alpha-api-report.md +++ b/plugins/tech-radar/alpha-api-report.md @@ -3,11 +3,13 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { Extension } from '@backstage/frontend-plugin-api'; // @alpha (undocumented) -const _default: BackstagePlugin; +const _default: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; export default _default; // @alpha (undocumented) diff --git a/plugins/tech-radar/package.json b/plugins/tech-radar/package.json index 7b1f18c072..d954c71a0c 100644 --- a/plugins/tech-radar/package.json +++ b/plugins/tech-radar/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-tech-radar", "description": "A Backstage plugin that lets you display a Tech Radar for your organization", - "version": "0.6.9-next.1", + "version": "0.6.9-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -68,8 +68,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/color": "^3.0.1", diff --git a/plugins/techdocs-addons-test-utils/CHANGELOG.md b/plugins/techdocs-addons-test-utils/CHANGELOG.md index ea84b35661..321bf0737e 100644 --- a/plugins/techdocs-addons-test-utils/CHANGELOG.md +++ b/plugins/techdocs-addons-test-utils/CHANGELOG.md @@ -1,5 +1,21 @@ # @backstage/plugin-techdocs-addons-test-utils +## 1.0.22-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/plugin-techdocs@1.7.1-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-catalog@1.14.0-next.2 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/test-utils@1.4.4-next.2 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + ## 1.0.22-next.1 ### Patch Changes diff --git a/plugins/techdocs-addons-test-utils/package.json b/plugins/techdocs-addons-test-utils/package.json index 3a0f83ad6f..90fac69b95 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.22-next.1", + "version": "1.0.22-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,8 +59,8 @@ "devDependencies": { "@backstage/cli": "workspace:^", "@backstage/dev-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/techdocs-backend/CHANGELOG.md b/plugins/techdocs-backend/CHANGELOG.md index 2723867071..caa2e42dcf 100644 --- a/plugins/techdocs-backend/CHANGELOG.md +++ b/plugins/techdocs-backend/CHANGELOG.md @@ -1,5 +1,32 @@ # @backstage/plugin-techdocs-backend +## 1.8.0-next.2 + +### Minor Changes + +- 344cfbcfbc: Allow prepared directory clean up for custom preparers + + When using custom preparer for TechDocs, the `preparedDir` might + end up taking disk space. This requires all custom preparers to + implement a new method `shouldCleanPreparedDirectory` which indicates + whether the prepared directory should be cleaned after generation. + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-techdocs-node@1.9.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-backend-module-techdocs@0.1.10-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-catalog-common@1.0.17-next.0 + - @backstage/plugin-permission-common@0.7.9-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.7.2-next.1 ### Patch Changes diff --git a/plugins/techdocs-backend/package.json b/plugins/techdocs-backend/package.json index 821457e518..3c247508ef 100644 --- a/plugins/techdocs-backend/package.json +++ b/plugins/techdocs-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-techdocs-backend", "description": "The Backstage backend plugin that renders technical documentation for your components", - "version": "1.7.2-next.1", + "version": "1.8.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/techdocs-backend/src/service/standaloneServer.ts b/plugins/techdocs-backend/src/service/standaloneServer.ts index 7e7e8b24f8..ce981633ca 100644 --- a/plugins/techdocs-backend/src/service/standaloneServer.ts +++ b/plugins/techdocs-backend/src/service/standaloneServer.ts @@ -18,7 +18,7 @@ import { CacheManager, createServiceBuilder, DockerContainerRunner, - SingleHostDiscovery, + HostDiscovery, UrlReader, } from '@backstage/backend-common'; import { ConfigReader } from '@backstage/config'; @@ -51,7 +51,7 @@ export async function startStandaloneServer( }, }, }); - const discovery = SingleHostDiscovery.fromConfig(config); + const discovery = HostDiscovery.fromConfig(config); const mockUrlReader: jest.Mocked<UrlReader> = { readUrl: jest.fn(), readTree: jest.fn(), diff --git a/plugins/techdocs-module-addons-contrib/CHANGELOG.md b/plugins/techdocs-module-addons-contrib/CHANGELOG.md index 3b4c893faa..fe8fd1834c 100644 --- a/plugins/techdocs-module-addons-contrib/CHANGELOG.md +++ b/plugins/techdocs-module-addons-contrib/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-techdocs-module-addons-contrib +## 1.1.1-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/integration@1.7.1-next.1 + - @backstage/theme@0.4.3-next.0 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + ## 1.1.1-next.1 ### Patch Changes diff --git a/plugins/techdocs-module-addons-contrib/package.json b/plugins/techdocs-module-addons-contrib/package.json index 53ccd6c244..c4ff929540 100644 --- a/plugins/techdocs-module-addons-contrib/package.json +++ b/plugins/techdocs-module-addons-contrib/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-techdocs-module-addons-contrib", "description": "Plugin module for contributed TechDocs Addons", - "version": "1.1.1-next.1", + "version": "1.1.1-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -59,8 +59,8 @@ "@backstage/dev-utils": "workspace:^", "@backstage/plugin-techdocs-addons-test-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/react": "^16.13.1 || ^17.0.0", diff --git a/plugins/techdocs-node/CHANGELOG.md b/plugins/techdocs-node/CHANGELOG.md index a385a83136..91290cc550 100644 --- a/plugins/techdocs-node/CHANGELOG.md +++ b/plugins/techdocs-node/CHANGELOG.md @@ -1,5 +1,29 @@ # @backstage/plugin-techdocs-node +## 1.9.0-next.2 + +### Minor Changes + +- 344cfbcfbc: Allow prepared directory clean up for custom preparers + + When using custom preparer for TechDocs, the `preparedDir` might + end up taking disk space. This requires all custom preparers to + implement a new method `shouldCleanPreparedDirectory` which indicates + whether the prepared directory should be cleaned after generation. + +- d06b30b050: Add possibility to use a mkdocs config file with a different name than `mkdocs.<yaml|yml> with the serve command using the `--mkdocs-config-file-name` argument + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/integration-aws-node@0.1.7-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + ## 1.8.2-next.1 ### Patch Changes diff --git a/plugins/techdocs-node/package.json b/plugins/techdocs-node/package.json index 56bb4f86a4..4ec11fde71 100644 --- a/plugins/techdocs-node/package.json +++ b/plugins/techdocs-node/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-techdocs-node", "description": "Common node.js functionalities for TechDocs, to be shared between techdocs-backend plugin and techdocs-cli", - "version": "1.8.2-next.1", + "version": "1.9.0-next.2", "main": "src/index.ts", "types": "src/index.ts", "publishConfig": { diff --git a/plugins/techdocs-react/CHANGELOG.md b/plugins/techdocs-react/CHANGELOG.md index 3e502df15d..0d5aafecbc 100644 --- a/plugins/techdocs-react/CHANGELOG.md +++ b/plugins/techdocs-react/CHANGELOG.md @@ -1,5 +1,16 @@ # @backstage/plugin-techdocs-react +## 1.1.12-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/version-bridge@1.0.5 + ## 1.1.12-next.1 ### Patch Changes diff --git a/plugins/techdocs-react/package.json b/plugins/techdocs-react/package.json index 64df90080d..f324f3be76 100644 --- a/plugins/techdocs-react/package.json +++ b/plugins/techdocs-react/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-techdocs-react", "description": "Shared frontend utilities for TechDocs and Addons", - "version": "1.1.12-next.1", + "version": "1.1.12-next.2", "publishConfig": { "access": "public", "main": "dist/index.esm.js", @@ -57,7 +57,7 @@ "@backstage/cli": "workspace:^", "@backstage/test-utils": "workspace:^", "@backstage/theme": "workspace:^", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0" }, diff --git a/plugins/techdocs/CHANGELOG.md b/plugins/techdocs/CHANGELOG.md index c407d11028..8797b30bd2 100644 --- a/plugins/techdocs/CHANGELOG.md +++ b/plugins/techdocs/CHANGELOG.md @@ -1,5 +1,25 @@ # @backstage/plugin-techdocs +## 1.7.1-next.2 + +### Patch Changes + +- 3605370af6: Improved `DocsTable` to display pagination controls dynamically, appearing only when needed. +- Updated dependencies + - @backstage/frontend-plugin-api@0.2.0-next.2 + - @backstage/integration-react@1.1.20-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/plugin-search-react@1.7.1-next.2 + - @backstage/theme@0.4.3-next.0 + - @backstage/config@1.1.1-next.0 + - @backstage/plugin-search-common@1.2.7-next.0 + - @backstage/plugin-techdocs-react@1.1.12-next.2 + ## 1.7.1-next.1 ### Patch Changes diff --git a/plugins/techdocs/alpha-api-report.md b/plugins/techdocs/alpha-api-report.md index 30d208865c..0bf8c25b33 100644 --- a/plugins/techdocs/alpha-api-report.md +++ b/plugins/techdocs/alpha-api-report.md @@ -3,11 +3,13 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; import { BackstagePlugin } from '@backstage/frontend-plugin-api'; import { Extension } from '@backstage/frontend-plugin-api'; // @alpha (undocumented) -const _default: BackstagePlugin; +const _default: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; export default _default; // @alpha (undocumented) diff --git a/plugins/techdocs/package.json b/plugins/techdocs/package.json index e7251a4eb2..578535c351 100644 --- a/plugins/techdocs/package.json +++ b/plugins/techdocs/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-techdocs", "description": "The Backstage plugin that renders technical documentation for your components", - "version": "1.7.1-next.1", + "version": "1.7.1-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -74,8 +74,8 @@ "react-use": "^17.2.4" }, "peerDependencies": { - "react": "^16.13.1 || ^17.0.0", - "react-dom": "^16.13.1 || ^17.0.0", + "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": { @@ -84,8 +84,8 @@ "@backstage/dev-utils": "workspace:^", "@backstage/plugin-techdocs-module-addons-contrib": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/react-hooks": "^8.0.0", "@testing-library/user-event": "^14.0.0", diff --git a/plugins/techdocs/src/alpha.tsx b/plugins/techdocs/src/alpha.tsx index bea4b7ab34..2f991f2fcc 100644 --- a/plugins/techdocs/src/alpha.tsx +++ b/plugins/techdocs/src/alpha.tsx @@ -18,8 +18,32 @@ import React from 'react'; import { createPlugin, createSchemaFromZod, + createApiExtension, + createPageExtension, } from '@backstage/frontend-plugin-api'; import { createSearchResultListItemExtension } from '@backstage/plugin-search-react/alpha'; +import { + configApiRef, + createApiFactory, + createRouteRef, + discoveryApiRef, + fetchApiRef, + identityApiRef, +} from '@backstage/core-plugin-api'; +import { + techdocsApiRef, + techdocsStorageApiRef, +} from '@backstage/plugin-techdocs-react'; +import { TechDocsClient, TechDocsStorageClient } from './client'; + +const rootRouteRef = createRouteRef({ + id: 'plugin.techdocs.indexPage', +}); + +const rootDocsRouteRef = createRouteRef({ + id: 'plugin.techdocs.readerPage', + params: ['namespace', 'kind', 'name'], +}); /** @alpha */ export const TechDocsSearchResultListItemExtension = @@ -44,8 +68,89 @@ export const TechDocsSearchResultListItemExtension = }, }); +/** + * Responsible for rendering the provided router element + * + * @alpha + */ +const TechDocsIndexPage = createPageExtension({ + id: 'plugin.techdocs.indexPage', + defaultPath: '/docs', + routeRef: rootRouteRef, + loader: () => + import('./home/components/TechDocsIndexPage').then(m => ( + <m.TechDocsIndexPage /> + )), +}); + +/** + * Component responsible for composing a TechDocs reader page experience + * + * @alpha + */ +const TechDocsReaderPage = createPageExtension({ + id: 'plugin.techdocs.readerPage', + loader: () => + import('./reader/components/TechDocsReaderPage').then(m => ( + <m.TechDocsReaderPage /> + )), + routeRef: rootDocsRouteRef, + defaultPath: '/docs/:namespace/:kind/:name/*', +}); + +/** @alpha */ +const techDocsStorage = createApiExtension({ + api: techdocsStorageApiRef, + + factory() { + return createApiFactory({ + api: techdocsStorageApiRef, + deps: { + configApi: configApiRef, + discoveryApi: discoveryApiRef, + identityApi: identityApiRef, + fetchApi: fetchApiRef, + }, + factory: ({ configApi, discoveryApi, identityApi, fetchApi }) => + new TechDocsStorageClient({ + configApi, + discoveryApi, + identityApi, + fetchApi, + }), + }); + }, +}); + +/** @alpha */ +const techDocsClient = createApiExtension({ + api: techdocsApiRef, + factory() { + return createApiFactory({ + api: techdocsApiRef, + deps: { + configApi: configApiRef, + discoveryApi: discoveryApiRef, + fetchApi: fetchApiRef, + }, + factory: ({ configApi, discoveryApi, fetchApi }) => + new TechDocsClient({ + configApi, + discoveryApi, + fetchApi, + }), + }); + }, +}); + /** @alpha */ export default createPlugin({ id: 'techdocs', - extensions: [TechDocsSearchResultListItemExtension], + extensions: [ + TechDocsIndexPage, + TechDocsReaderPage, + techDocsClient, + techDocsStorage, + TechDocsSearchResultListItemExtension, + ], }); diff --git a/plugins/techdocs/src/reader/components/TechDocsReaderPageHeader/TechDocsReaderPageHeader.tsx b/plugins/techdocs/src/reader/components/TechDocsReaderPageHeader/TechDocsReaderPageHeader.tsx index f7b4f2eff2..d84c5c5347 100644 --- a/plugins/techdocs/src/reader/components/TechDocsReaderPageHeader/TechDocsReaderPageHeader.tsx +++ b/plugins/techdocs/src/reader/components/TechDocsReaderPageHeader/TechDocsReaderPageHeader.tsx @@ -133,7 +133,9 @@ export const TechDocsReaderPageHeader = ( } /> )} - {lifecycle ? <HeaderLabel label="Lifecycle" value={lifecycle} /> : null} + {lifecycle ? ( + <HeaderLabel label="Lifecycle" value={String(lifecycle)} /> + ) : null} {locationMetadata && locationMetadata.type !== 'dir' && locationMetadata.type !== 'file' ? ( diff --git a/plugins/techdocs/src/reader/transformers/addGitFeedbackLink.ts b/plugins/techdocs/src/reader/transformers/addGitFeedbackLink.ts index 9239573bd1..58876cd806 100644 --- a/plugins/techdocs/src/reader/transformers/addGitFeedbackLink.ts +++ b/plugins/techdocs/src/reader/transformers/addGitFeedbackLink.ts @@ -21,8 +21,8 @@ import { } from '@backstage/integration'; import FeedbackOutlinedIcon from '@material-ui/icons/FeedbackOutlined'; import React from 'react'; -import ReactDOM from 'react-dom'; import parseGitUrl from 'git-url-parse'; +import { renderReactElement } from './renderReactElement'; // requires repo export const addGitFeedbackLink = ( @@ -75,7 +75,7 @@ export const addGitFeedbackLink = ( default: return dom; } - ReactDOM.render(React.createElement(FeedbackOutlinedIcon), feedbackLink); + renderReactElement(React.createElement(FeedbackOutlinedIcon), feedbackLink); feedbackLink.style.paddingLeft = '5px'; feedbackLink.title = 'Leave feedback for this page'; feedbackLink.id = 'git-feedback-link'; diff --git a/plugins/techdocs/src/reader/transformers/addSidebarToggle.ts b/plugins/techdocs/src/reader/transformers/addSidebarToggle.ts index 789c9179d5..352e396abf 100644 --- a/plugins/techdocs/src/reader/transformers/addSidebarToggle.ts +++ b/plugins/techdocs/src/reader/transformers/addSidebarToggle.ts @@ -17,7 +17,7 @@ import type { Transformer } from './transformer'; import MenuIcon from '@material-ui/icons/Menu'; import React from 'react'; -import ReactDOM from 'react-dom'; +import { renderReactElement } from './renderReactElement'; export const addSidebarToggle = (): Transformer => { return dom => { @@ -33,7 +33,7 @@ export const addSidebarToggle = (): Transformer => { } const toggleSidebar = mkdocsToggleSidebar.cloneNode() as HTMLLabelElement; - ReactDOM.render(React.createElement(MenuIcon), toggleSidebar); + renderReactElement(React.createElement(MenuIcon), toggleSidebar); toggleSidebar.id = 'toggle-sidebar'; toggleSidebar.title = 'Toggle Sidebar'; toggleSidebar.classList.add('md-content__button'); diff --git a/plugins/techdocs/src/reader/transformers/copyToClipboard.test.ts b/plugins/techdocs/src/reader/transformers/copyToClipboard.test.ts index cac7f76a0e..604957d5cd 100644 --- a/plugins/techdocs/src/reader/transformers/copyToClipboard.test.ts +++ b/plugins/techdocs/src/reader/transformers/copyToClipboard.test.ts @@ -17,7 +17,7 @@ import { createTestShadowDom } from '../../test-utils'; import { copyToClipboard } from './copyToClipboard'; import { lightTheme } from '@backstage/theme'; -import { waitFor } from '@testing-library/react'; +import { act, waitFor } from '@testing-library/react'; import useCopyToClipboard from 'react-use/lib/useCopyToClipboard'; const clipboardSpy = jest.fn(); @@ -43,8 +43,11 @@ describe('copyToClipboard', () => { spy.mockReturnValue([{}, copy]); const expectedClipboard = 'function foo() {return "bar";}'; - const shadowDom = await createTestShadowDom( - ` + + let shadowDom: ShadowRoot; + await act(async () => { + shadowDom = await createTestShadowDom( + ` <!DOCTYPE html> <html> <body> @@ -52,13 +55,20 @@ describe('copyToClipboard', () => { </body> </html> `, - { - preTransformers: [], - postTransformers: [copyToClipboard(lightTheme)], - }, - ); + { + preTransformers: [], + postTransformers: [copyToClipboard(lightTheme)], + }, + ); + }); - shadowDom.querySelector('button')?.click(); + await waitFor(() => { + expect(shadowDom.querySelector('button')).not.toBe(null); + }); + + await act(async () => { + shadowDom.querySelector('button')!.click(); + }); await waitFor(() => { const tooltip = document.querySelector('[role="tooltip"]'); diff --git a/plugins/techdocs/src/reader/transformers/copyToClipboard.tsx b/plugins/techdocs/src/reader/transformers/copyToClipboard.tsx index 28a6c789b6..1fd9d179a3 100644 --- a/plugins/techdocs/src/reader/transformers/copyToClipboard.tsx +++ b/plugins/techdocs/src/reader/transformers/copyToClipboard.tsx @@ -15,7 +15,7 @@ */ import React, { useState, useCallback } from 'react'; -import ReactDom from 'react-dom'; +import { renderReactElement } from './renderReactElement'; import { withStyles, Theme, @@ -91,7 +91,7 @@ export const copyToClipboard = (theme: Theme): Transformer => { const text = code.textContent || ''; const container = document.createElement('div'); code?.parentElement?.prepend(container); - ReactDom.render( + renderReactElement( <ThemeProvider theme={theme}> <CopyToClipboardButton text={text} /> </ThemeProvider>, diff --git a/plugins/techdocs/src/reader/transformers/renderReactElement.ts b/plugins/techdocs/src/reader/transformers/renderReactElement.ts new file mode 100644 index 0000000000..86d44532c5 --- /dev/null +++ b/plugins/techdocs/src/reader/transformers/renderReactElement.ts @@ -0,0 +1,34 @@ +/* + * 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. + */ + +let ReactDOM: + | typeof import('react-dom') + // TODO: replace with import('react-dom/client') when repo is migrated to 18 + | { createRoot(el: HTMLElement): { render(el: JSX.Element): void } }; +if (process.env.HAS_REACT_DOM_CLIENT) { + ReactDOM = require('react-dom/client'); +} else { + ReactDOM = require('react-dom'); +} + +/** @internal */ +export function renderReactElement(element: JSX.Element, root: HTMLElement) { + if ('createRoot' in ReactDOM) { + ReactDOM.createRoot(root).render(element); + } else { + ReactDOM.render(element, root); + } +} diff --git a/plugins/todo-backend/CHANGELOG.md b/plugins/todo-backend/CHANGELOG.md index 4cbf70e538..cb782356f8 100644 --- a/plugins/todo-backend/CHANGELOG.md +++ b/plugins/todo-backend/CHANGELOG.md @@ -1,5 +1,20 @@ # @backstage/plugin-todo-backend +## 0.3.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/integration@1.7.1-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-openapi-utils@0.0.5-next.0 + - @backstage/plugin-catalog-node@1.4.7-next.2 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/catalog-client@1.4.5-next.0 + - @backstage/config@1.1.1-next.0 + ## 0.3.3-next.1 ### Patch Changes diff --git a/plugins/todo-backend/package.json b/plugins/todo-backend/package.json index c741984f2d..1df098c517 100644 --- a/plugins/todo-backend/package.json +++ b/plugins/todo-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-todo-backend", "description": "A Backstage backend plugin that lets you browse TODO comments in your source code", - "version": "0.3.3-next.1", + "version": "0.3.4-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/todo/CHANGELOG.md b/plugins/todo/CHANGELOG.md index 68efd13892..b091767889 100644 --- a/plugins/todo/CHANGELOG.md +++ b/plugins/todo/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-todo +## 0.2.28-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.2.28-next.1 ### Patch Changes diff --git a/plugins/todo/package.json b/plugins/todo/package.json index b255744e12..20fde05ff2 100644 --- a/plugins/todo/package.json +++ b/plugins/todo/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-todo", "description": "A Backstage plugin that lets you browse TODO comments in your source code", - "version": "0.2.28-next.1", + "version": "0.2.28-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -53,8 +53,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/user-settings-backend/CHANGELOG.md b/plugins/user-settings-backend/CHANGELOG.md index 0dedc9dbce..9554c73992 100644 --- a/plugins/user-settings-backend/CHANGELOG.md +++ b/plugins/user-settings-backend/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-user-settings-backend +## 0.2.4-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/plugin-auth-node@0.4.0-next.2 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-plugin-api@0.6.6-next.2 + - @backstage/types@1.1.1 + ## 0.2.3-next.1 ### Patch Changes diff --git a/plugins/user-settings-backend/package.json b/plugins/user-settings-backend/package.json index a8e8a711ae..eb1d08bbe2 100644 --- a/plugins/user-settings-backend/package.json +++ b/plugins/user-settings-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-user-settings-backend", "description": "The Backstage backend plugin to manage user settings", - "version": "0.2.3-next.1", + "version": "0.2.4-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/user-settings/CHANGELOG.md b/plugins/user-settings/CHANGELOG.md index dcd46282a1..3ba16ac03d 100644 --- a/plugins/user-settings/CHANGELOG.md +++ b/plugins/user-settings/CHANGELOG.md @@ -1,5 +1,18 @@ # @backstage/plugin-user-settings +## 0.7.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-app-api@1.11.0-next.2 + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + - @backstage/types@1.1.1 + ## 0.7.11-next.1 ### Patch Changes diff --git a/plugins/user-settings/alpha-api-report.md b/plugins/user-settings/alpha-api-report.md index 203cfac601..8a3e109e5b 100644 --- a/plugins/user-settings/alpha-api-report.md +++ b/plugins/user-settings/alpha-api-report.md @@ -3,8 +3,19 @@ > Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/). ```ts +import { AnyExternalRoutes } from '@backstage/core-plugin-api'; +import { AnyRoutes } from '@backstage/core-plugin-api'; +import { BackstagePlugin } from '@backstage/frontend-plugin-api'; +import { RouteRef } from '@backstage/core-plugin-api'; import { TranslationRef } from '@backstage/core-plugin-api/alpha'; +// @alpha (undocumented) +const _default: BackstagePlugin<AnyRoutes, AnyExternalRoutes>; +export default _default; + +// @alpha (undocumented) +export const userSettingsRouteRef: RouteRef<undefined>; + // @alpha (undocumented) export const userSettingsTranslationRef: TranslationRef< 'user-settings', diff --git a/plugins/user-settings/package.json b/plugins/user-settings/package.json index 251436e85a..8937cb7dc1 100644 --- a/plugins/user-settings/package.json +++ b/plugins/user-settings/package.json @@ -1,19 +1,19 @@ { "name": "@backstage/plugin-user-settings", "description": "A Backstage plugin that provides a settings page", - "version": "0.7.11-next.1", + "version": "0.7.11-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", "exports": { ".": "./src/index.ts", - "./alpha": "./src/alpha.ts", + "./alpha": "./src/alpha.tsx", "./package.json": "./package.json" }, "typesVersions": { "*": { "alpha": [ - "src/alpha.ts" + "src/alpha.tsx" ], "package.json": [ "package.json" @@ -50,6 +50,7 @@ "@backstage/core-components": "workspace:^", "@backstage/core-plugin-api": "workspace:^", "@backstage/errors": "workspace:^", + "@backstage/frontend-plugin-api": "workspace:^", "@backstage/plugin-catalog-react": "workspace:^", "@backstage/theme": "workspace:^", "@backstage/types": "workspace:^", @@ -70,8 +71,8 @@ "@backstage/dev-utils": "workspace:^", "@backstage/plugin-catalog": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "cross-fetch": "^3.1.5", diff --git a/plugins/user-settings/src/alpha.tsx b/plugins/user-settings/src/alpha.tsx new file mode 100644 index 0000000000..8d68ccf259 --- /dev/null +++ b/plugins/user-settings/src/alpha.tsx @@ -0,0 +1,59 @@ +/* + * 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 { createRouteRef } from '@backstage/core-plugin-api'; +import { + coreExtensionData, + createExtensionInput, + createPageExtension, + createPlugin, +} from '@backstage/frontend-plugin-api'; + +import React from 'react'; + +export * from './translation'; + +/** + * @alpha + */ +export const userSettingsRouteRef = createRouteRef({ + id: 'plugin.user-settings.page', +}); + +const UserSettingsPage = createPageExtension({ + id: 'plugin.user-settings.page', + defaultPath: '/settings', + routeRef: userSettingsRouteRef, + inputs: { + providerSettings: createExtensionInput( + { + element: coreExtensionData.reactElement, + }, + { singleton: true, optional: true }, + ), + }, + loader: ({ inputs }) => + import('./components/SettingsPage').then(m => ( + <m.SettingsPage providerSettings={inputs.providerSettings?.element} /> + )), +}); + +/** + * @alpha + */ +export default createPlugin({ + id: 'user-settings', + extensions: [UserSettingsPage], +}); diff --git a/plugins/vault-backend/CHANGELOG.md b/plugins/vault-backend/CHANGELOG.md index 3253d8b99c..2664187ac0 100644 --- a/plugins/vault-backend/CHANGELOG.md +++ b/plugins/vault-backend/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-vault-backend +## 0.3.11-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/backend-common@0.19.8-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/backend-tasks@0.5.11-next.2 + - @backstage/config@1.1.1-next.0 + ## 0.3.10-next.1 ### Patch Changes diff --git a/plugins/vault-backend/package.json b/plugins/vault-backend/package.json index 6906b8124d..e27a8d0524 100644 --- a/plugins/vault-backend/package.json +++ b/plugins/vault-backend/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-vault-backend", "description": "A Backstage backend plugin that integrates towards Vault", - "version": "0.3.10-next.1", + "version": "0.3.11-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", diff --git a/plugins/vault/CHANGELOG.md b/plugins/vault/CHANGELOG.md index 38121353c0..c2037ad665 100644 --- a/plugins/vault/CHANGELOG.md +++ b/plugins/vault/CHANGELOG.md @@ -1,5 +1,17 @@ # @backstage/plugin-vault +## 0.1.20-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/catalog-model@1.4.3-next.0 + - @backstage/plugin-catalog-react@1.8.5-next.2 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.1.20-next.1 ### Patch Changes diff --git a/plugins/vault/package.json b/plugins/vault/package.json index 014e9b0d50..5eef7bca88 100644 --- a/plugins/vault/package.json +++ b/plugins/vault/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-vault", "description": "A Backstage plugin that integrates towards Vault", - "version": "0.1.20-next.1", + "version": "0.1.20-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -56,8 +56,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "msw": "^1.0.0" diff --git a/plugins/xcmetrics/CHANGELOG.md b/plugins/xcmetrics/CHANGELOG.md index f3bebcb916..19f23149bd 100644 --- a/plugins/xcmetrics/CHANGELOG.md +++ b/plugins/xcmetrics/CHANGELOG.md @@ -1,5 +1,15 @@ # @backstage/plugin-xcmetrics +## 0.2.44-next.2 + +### Patch Changes + +- Updated dependencies + - @backstage/core-components@0.13.6-next.2 + - @backstage/core-plugin-api@1.7.0-next.1 + - @backstage/errors@1.2.3-next.0 + - @backstage/theme@0.4.3-next.0 + ## 0.2.44-next.1 ### Patch Changes diff --git a/plugins/xcmetrics/package.json b/plugins/xcmetrics/package.json index c39c0e4963..7a67fd4d5e 100644 --- a/plugins/xcmetrics/package.json +++ b/plugins/xcmetrics/package.json @@ -1,7 +1,7 @@ { "name": "@backstage/plugin-xcmetrics", "description": "A Backstage plugin that shows XCode build metrics for your components", - "version": "0.2.44-next.1", + "version": "0.2.44-next.2", "main": "src/index.ts", "types": "src/index.ts", "license": "Apache-2.0", @@ -53,8 +53,8 @@ "@backstage/core-app-api": "workspace:^", "@backstage/dev-utils": "workspace:^", "@backstage/test-utils": "workspace:^", - "@testing-library/dom": "^8.0.0", - "@testing-library/jest-dom": "^5.10.1", + "@testing-library/dom": "^9.0.0", + "@testing-library/jest-dom": "^6.0.0", "@testing-library/react": "^12.1.3", "@testing-library/user-event": "^14.0.0", "@types/luxon": "^3.0.0", diff --git a/scripts/build-plugins-report.js b/scripts/build-plugins-report.js new file mode 100755 index 0000000000..2caaba4530 --- /dev/null +++ b/scripts/build-plugins-report.js @@ -0,0 +1,183 @@ +#!/usr/bin/env node +/* + * 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. + */ + +const fs = require('fs-extra'); +const path = require('path'); +const { execFile: execFileCb } = require('child_process'); +const { promisify } = require('util'); + +const execFile = promisify(execFileCb); + +const rootDirectory = path.resolve(__dirname, '..'); +const pluginsDirectory = path.resolve(rootDirectory, 'plugins'); + +async function run(command, ...args) { + const { stdout, stderr } = await execFile(command, args, { + cwd: rootDirectory, + }); + + if (stderr) { + console.error(stderr); + } + + return stdout.trim(); +} + +function findLatestValidCommit(commits, directoryPath) { + return commits.find(commit => { + const { author, message, files } = commit; + + // exclude merge commits + if (message.startsWith('Merge pull request #')) { + return false; + } + + // exclude commits authored by a bot + if (author.includes('[bot]')) { + return false; + } + + // exclude core maintainers' commits + if ( + [ + 'ben@blam.sh', + 'freben@gmail.com', + 'poldsberg@gmail.com', + 'johan.haals@gmail.com', + ].some(email => author.includes(email)) + ) { + return false; + } + + // ignore multiple plugins changes + if ( + files.some(file => { + const fileFullPath = path.resolve(rootDirectory, file); + if (!fileFullPath.startsWith(pluginsDirectory)) { + return false; + } + const pluginBasePath = directoryPath.replace( + /-(backend|common|react|node).*$/, + '', + ); + return !fileFullPath.startsWith(pluginBasePath); + }) + ) { + return false; + } + + return true; + }); +} + +async function getPluginDirectory(directoryName) { + const directoryPath = path.resolve(pluginsDirectory, directoryName); + const packageJson = await fs.readJson( + path.resolve(directoryPath, 'package.json'), + ); + return { directoryName, directoryPath, packageJson }; +} + +function parseCommitsLog(log) { + const lines = log.split('\n'); + return lines.reduce((commits, line) => { + if (!line) return commits; + if (line.includes(';')) { + const [author, message, date] = line.split(';'); + return [...commits, { author, message, date, files: [] }]; + } + const { files, ...commit } = commits.pop(); + return [...commits, { ...commit, files: [...files, line] }]; + }, []); +} + +async function readDirectoryCommits(directoryName) { + const maxCount = 100; + const directoryPath = path.resolve(pluginsDirectory, directoryName); + + const logOutput = await run( + 'git', + 'log', + 'origin/master', + '--name-only', + `--max-count=${maxCount}`, + '--pretty=format:%an <%ae>;%s;%as', + '--', + // ignore changes on README and package.json files + path.posix.resolve(directoryPath, 'src'), + `:(exclude)${path.posix.resolve(directoryPath, 'src', '**', '*.test.*')}`, + ); + + return parseCommitsLog(logOutput); +} + +async function getLatestDirectoryCommit({ directoryName, directoryPath }) { + console.log(`🔎 Reading data for ${directoryName}`); + + const commits = await readDirectoryCommits(directoryName); + + const commit = findLatestValidCommit(commits, directoryPath) ?? { + author: '-', + message: '-', + date: '-', + }; + + return { plugin: directoryName, ...commit }; +} + +function isValidDirectory({ packageJson }) { + const roles = [ + 'frontend-plugin', + 'frontend-plugin-module', + 'backend-plugin', + 'backend-plugin-module', + ]; + return roles.includes(packageJson?.backstage?.role ?? ''); +} + +async function main() { + const directoryNames = fs + .readdirSync(pluginsDirectory, { withFileTypes: true }) + .filter(dirent => dirent.isDirectory()) + .map(dirent => dirent.name); + + const directories = await Promise.all(directoryNames.map(getPluginDirectory)); + + const commits = await Promise.all( + directories.filter(isValidDirectory).map(getLatestDirectoryCommit), + ); + + const fileName = 'plugins-report.csv'; + + const fileContent = [ + 'Plugin;Author;Message;Date', + ...commits.map(c => `${c.plugin};${c.author};${c.message};${c.date}`), + ]; + + console.log(`📊 Generating plugins report...`); + + fs.writeFile(fileName, fileContent.join('\n'), err => { + if (err) throw err; + }); + + console.log(`📄 Report generated at ${fileName}`); +} + +main(process.argv.slice(2)).catch(error => { + console.error(error.stack || error); + process.exit(1); +}); diff --git a/yarn.lock b/yarn.lock index 0679040ed1..e7cd435d9b 100644 --- a/yarn.lock +++ b/yarn.lock @@ -12,7 +12,7 @@ __metadata: languageName: node linkType: hard -"@adobe/css-tools@npm:^4.0.1": +"@adobe/css-tools@npm:^4.3.1": version: 4.3.1 resolution: "@adobe/css-tools@npm:4.3.1" checksum: ad43456379ff391132aff687ece190cb23ea69395e23c9b96690eeabe2468da89a4aaf266e4f8b6eaab53db3d1064107ce0f63c3a974e864f4a04affc768da3f @@ -1689,8 +1689,8 @@ __metadata: linkType: hard "@azure/identity@npm:^3.2.1": - version: 3.3.0 - resolution: "@azure/identity@npm:3.3.0" + version: 3.3.1 + resolution: "@azure/identity@npm:3.3.1" dependencies: "@azure/abort-controller": ^1.0.0 "@azure/core-auth": ^1.5.0 @@ -1708,7 +1708,7 @@ __metadata: stoppable: ^1.1.0 tslib: ^2.2.0 uuid: ^8.3.0 - checksum: 95c6f8761ad6bbfd3fbf8a88d1a4af17199fb6b61134a761d51a2df096cb175a5841f02ca5ae3285378c64676e72ce6cddc58143306eef5086a63459c2cef914 + checksum: ba58ce8d6178566757c0554b9b5d6ca3d4e934eb6831c9a7d57ada185ec57bd9a9de1ce9500a547e35f4d11cfb362c312afaad019d1ed6bf7b6ebf908bfea362 languageName: node linkType: hard @@ -3367,7 +3367,7 @@ __metadata: "@backstage/theme": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@types/react": ^16.13.1 || ^17.0.0 peerDependencies: @@ -3449,7 +3449,7 @@ __metadata: "@google-cloud/storage": ^6.0.0 "@keyv/memcache": ^1.3.5 "@keyv/redis": ^2.5.3 - "@kubernetes/client-node": 0.18.1 + "@kubernetes/client-node": 0.19.0 "@manypkg/get-packages": ^1.1.3 "@octokit/rest": ^19.0.3 "@types/archiver": ^5.1.0 @@ -3650,7 +3650,18 @@ __metadata: languageName: unknown linkType: soft -"@backstage/catalog-client@^1.4.4, @backstage/catalog-client@workspace:^, @backstage/catalog-client@workspace:packages/catalog-client": +"@backstage/catalog-client@npm:^1.4.4": + version: 1.4.4 + resolution: "@backstage/catalog-client@npm:1.4.4" + dependencies: + "@backstage/catalog-model": ^1.4.2 + "@backstage/errors": ^1.2.2 + cross-fetch: ^3.1.5 + checksum: 3f821ee7450b192bf750a0275d095a96f7ce137283cecd0353cef817a43fd7f55141d828268cf839b3cfbfc41cea0d6519c4c4411b297b7423728dc7018f68ed + 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" dependencies: @@ -3662,7 +3673,22 @@ __metadata: languageName: unknown linkType: soft -"@backstage/catalog-model@^1.1.5, @backstage/catalog-model@^1.4.2, @backstage/catalog-model@workspace:^, @backstage/catalog-model@workspace:packages/catalog-model": +"@backstage/catalog-model@npm:^1.1.5, @backstage/catalog-model@npm:^1.4.2": + version: 1.4.2 + resolution: "@backstage/catalog-model@npm:1.4.2" + dependencies: + "@backstage/config": ^1.1.0 + "@backstage/errors": ^1.2.2 + "@backstage/types": ^1.1.1 + ajv: ^8.10.0 + json-schema: ^0.4.0 + lodash: ^4.17.21 + uuid: ^8.0.0 + checksum: 7e0d8cfb7fc6bab02803201552a24b73a3d7b502f7ba22e3408e86400e2a4f8937e0e91dea9a063d1f8bc128064400e93d05301611772502811feea10e8ad4e9 + languageName: node + linkType: hard + +"@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: @@ -3758,7 +3784,6 @@ __metadata: "@types/inquirer": ^8.1.3 "@types/jest": ^29.0.0 "@types/minimatch": ^5.0.0 - "@types/mock-fs": ^4.13.0 "@types/node": ^18.17.8 "@types/npm-packlist": ^3.0.0 "@types/recursive-readdir": ^2.2.0 @@ -3769,7 +3794,7 @@ __metadata: "@types/terser-webpack-plugin": ^5.0.4 "@types/webpack-env": ^1.15.2 "@types/yarnpkg__lockfile": ^1.1.4 - "@typescript-eslint/eslint-plugin": 6.7.2 + "@typescript-eslint/eslint-plugin": 6.7.5 "@typescript-eslint/parser": ^6.7.2 "@yarnpkg/lockfile": ^1.1.0 "@yarnpkg/parsers": ^3.0.0-rc.4 @@ -3813,7 +3838,6 @@ __metadata: lodash: ^4.17.21 mini-css-extract-plugin: ^2.4.2 minimatch: ^5.1.1 - mock-fs: ^5.2.0 msw: ^1.0.0 node-fetch: ^2.6.7 node-libs-browser: ^2.2.1 @@ -3899,13 +3923,24 @@ __metadata: minimist: ^1.2.5 msw: ^1.0.0 node-fetch: ^2.6.7 - typescript-json-schema: ^0.55.0 + typescript-json-schema: ^0.61.0 yaml: ^2.0.0 zen-observable: ^0.10.0 languageName: unknown linkType: soft -"@backstage/config@^1.0.6, @backstage/config@^1.0.7, @backstage/config@^1.1.0, @backstage/config@workspace:^, @backstage/config@workspace:packages/config": +"@backstage/config@npm:^1.0.6, @backstage/config@npm:^1.0.7, @backstage/config@npm:^1.1.0": + version: 1.1.0 + resolution: "@backstage/config@npm:1.1.0" + dependencies: + "@backstage/errors": ^1.2.2 + "@backstage/types": ^1.1.1 + lodash: ^4.17.21 + checksum: 9c17ab41b3e4bd6a0ad75caaf46ed3fad198aa8d190cb9a85415140bc9d6506022a4d5450ea5810004fc2d7a3f7a0a00583b468af4a0fa1655ce444606283010 + languageName: node + linkType: hard + +"@backstage/config@workspace:^, @backstage/config@workspace:packages/config": version: 0.0.0-use.local resolution: "@backstage/config@workspace:packages/config" dependencies: @@ -3927,8 +3962,8 @@ __metadata: "@backstage/test-utils": "workspace:^" "@backstage/types": "workspace:^" "@backstage/version-bridge": "workspace:^" - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -4078,8 +4113,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@react-hookz/web": ^20.0.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -4164,8 +4199,8 @@ __metadata: "@backstage/test-utils": "workspace:^" "@backstage/types": "workspace:^" "@backstage/version-bridge": "workspace:^" - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -4222,16 +4257,16 @@ __metadata: "@backstage/theme": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 react-use: ^17.2.4 zen-observable: ^0.10.0 peerDependencies: - react: ^16.13.1 || ^17.0.0 - react-dom: ^16.13.1 || ^17.0.0 + 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 @@ -4253,7 +4288,18 @@ __metadata: languageName: unknown linkType: soft -"@backstage/errors@^1.1.5, @backstage/errors@^1.2.2, @backstage/errors@workspace:^, @backstage/errors@workspace:packages/errors": +"@backstage/errors@npm:^1.1.5, @backstage/errors@npm:^1.2.2": + version: 1.2.2 + resolution: "@backstage/errors@npm:1.2.2" + dependencies: + "@backstage/types": ^1.1.1 + cross-fetch: ^3.1.5 + serialize-error: ^8.0.1 + checksum: 2fd323d528023654ac0910a5bd8ea703fa97a4bd62ee34b6c75e1c992d1a78cae661f0929c1ffd72df5465a1bda69c1bcad2682f017e5e52daa73154e6284234 + languageName: node + linkType: hard + +"@backstage/errors@workspace:^, @backstage/errors@workspace:packages/errors": version: 0.0.0-use.local resolution: "@backstage/errors@workspace:packages/errors" dependencies: @@ -4291,7 +4337,7 @@ __metadata: "@backstage/version-bridge": "workspace:^" "@material-ui/core": ^4.12.4 "@material-ui/icons": ^4.11.3 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@types/react": ^16.13.1 || ^17.0.0 lodash: ^4.17.21 @@ -4310,7 +4356,7 @@ __metadata: "@backstage/frontend-app-api": "workspace:^" "@backstage/test-utils": "workspace:^" "@backstage/types": "workspace:^" - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@types/react": ^16.13.1 || ^17.0.0 lodash: ^4.17.21 @@ -4376,8 +4422,8 @@ __metadata: "@backstage/test-utils": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@types/react": ^16.13.1 || ^17.0.0 msw: ^1.0.0 peerDependencies: @@ -4486,8 +4532,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/git-url-parse": ^9.0.0 @@ -4542,8 +4588,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -4572,8 +4618,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -4598,8 +4644,8 @@ __metadata: "@backstage/dev-utils": "workspace:^" "@backstage/test-utils": "workspace:^" "@backstage/theme": "workspace:^" - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/jest": ^28.1.3 @@ -4629,8 +4675,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -4656,7 +4702,7 @@ __metadata: "@backstage/dev-utils": "workspace:^" "@backstage/test-utils": "workspace:^" "@newrelic/browser-agent": ^1.236.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 msw: ^1.0.0 @@ -4679,8 +4725,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -4700,7 +4746,7 @@ __metadata: resolution: "@backstage/plugin-api-docs-module-protoc-gen-doc@workspace:plugins/api-docs-module-protoc-gen-doc" dependencies: "@backstage/cli": "workspace:^" - "@testing-library/jest-dom": ^5.16.4 + "@testing-library/jest-dom": ^6.0.0 "@types/react": ^16.13.1 || ^17.0.0 grpc-docs: ^1.1.2 peerDependencies: @@ -4728,8 +4774,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -4763,8 +4809,8 @@ __metadata: "@backstage/theme": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -4888,6 +4934,24 @@ __metadata: languageName: unknown linkType: soft +"@backstage/plugin-auth-backend-module-microsoft-provider@workspace:^, @backstage/plugin-auth-backend-module-microsoft-provider@workspace:plugins/auth-backend-module-microsoft-provider": + version: 0.0.0-use.local + resolution: "@backstage/plugin-auth-backend-module-microsoft-provider@workspace:plugins/auth-backend-module-microsoft-provider" + dependencies: + "@backstage/backend-common": "workspace:^" + "@backstage/backend-defaults": "workspace:^" + "@backstage/backend-plugin-api": "workspace:^" + "@backstage/backend-test-utils": "workspace:^" + "@backstage/cli": "workspace:^" + "@backstage/plugin-auth-backend": "workspace:^" + "@backstage/plugin-auth-node": "workspace:^" + express: ^4.18.2 + passport: ^0.6.0 + passport-microsoft: ^1.0.0 + supertest: ^6.3.3 + languageName: unknown + linkType: soft + "@backstage/plugin-auth-backend-module-oauth2-provider@workspace:^, @backstage/plugin-auth-backend-module-oauth2-provider@workspace:plugins/auth-backend-module-oauth2-provider": version: 0.0.0-use.local resolution: "@backstage/plugin-auth-backend-module-oauth2-provider@workspace:plugins/auth-backend-module-oauth2-provider" @@ -4906,6 +4970,30 @@ __metadata: languageName: unknown linkType: soft +"@backstage/plugin-auth-backend-module-pinniped-provider@workspace:plugins/auth-backend-module-pinniped-provider": + version: 0.0.0-use.local + resolution: "@backstage/plugin-auth-backend-module-pinniped-provider@workspace:plugins/auth-backend-module-pinniped-provider" + dependencies: + "@backstage/backend-common": "workspace:^" + "@backstage/backend-defaults": "workspace:^" + "@backstage/backend-plugin-api": "workspace:^" + "@backstage/backend-test-utils": "workspace:^" + "@backstage/cli": "workspace:^" + "@backstage/config": "workspace:^" + "@backstage/plugin-auth-backend": "workspace:^" + "@backstage/plugin-auth-node": "workspace:^" + cookie-parser: ^1.4.6 + express: ^4.18.2 + express-promise-router: ^4.1.1 + express-session: ^1.17.3 + jose: ^4.14.6 + msw: ^1.3.0 + openid-client: ^5.4.3 + passport: ^0.6.0 + supertest: ^6.3.3 + languageName: unknown + linkType: soft + "@backstage/plugin-auth-backend@workspace:^, @backstage/plugin-auth-backend@workspace:plugins/auth-backend": version: 0.0.0-use.local resolution: "@backstage/plugin-auth-backend@workspace:plugins/auth-backend" @@ -4923,6 +5011,7 @@ __metadata: "@backstage/plugin-auth-backend-module-github-provider": "workspace:^" "@backstage/plugin-auth-backend-module-gitlab-provider": "workspace:^" "@backstage/plugin-auth-backend-module-google-provider": "workspace:^" + "@backstage/plugin-auth-backend-module-microsoft-provider": "workspace:^" "@backstage/plugin-auth-backend-module-oauth2-provider": "workspace:^" "@backstage/plugin-auth-node": "workspace:^" "@backstage/plugin-catalog-node": "workspace:^" @@ -5059,8 +5148,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -5122,8 +5211,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -5182,7 +5271,7 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/jest-dom": ^5.16.5 + "@testing-library/jest-dom": ^6.0.0 "@types/react": ^16.13.1 || ^17.0.0 react-use: ^17.2.4 peerDependencies: @@ -5231,7 +5320,7 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@material-ui/pickers": ^3.3.10 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@types/react": ^16.13.1 || ^17.0.0 luxon: ^3.0.0 material-ui-search-bar: ^1.0.0 @@ -5273,8 +5362,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -5465,7 +5554,23 @@ __metadata: languageName: unknown linkType: soft -"@backstage/plugin-catalog-backend-module-github@workspace:plugins/catalog-backend-module-github": +"@backstage/plugin-catalog-backend-module-github-org@workspace:plugins/catalog-backend-module-github-org": + version: 0.0.0-use.local + resolution: "@backstage/plugin-catalog-backend-module-github-org@workspace:plugins/catalog-backend-module-github-org" + dependencies: + "@backstage/backend-common": "workspace:^" + "@backstage/backend-plugin-api": "workspace:^" + "@backstage/backend-tasks": "workspace:^" + "@backstage/backend-test-utils": "workspace:^" + "@backstage/cli": "workspace:^" + "@backstage/config": "workspace:^" + "@backstage/plugin-catalog-backend-module-github": "workspace:^" + "@backstage/plugin-catalog-node": "workspace:^" + luxon: ^3.0.0 + languageName: unknown + linkType: soft + +"@backstage/plugin-catalog-backend-module-github@workspace:^, @backstage/plugin-catalog-backend-module-github@workspace:plugins/catalog-backend-module-github": version: 0.0.0-use.local resolution: "@backstage/plugin-catalog-backend-module-github@workspace:plugins/catalog-backend-module-github" dependencies: @@ -5726,7 +5831,18 @@ __metadata: languageName: unknown linkType: soft -"@backstage/plugin-catalog-common@^1.0.10, @backstage/plugin-catalog-common@^1.0.16, @backstage/plugin-catalog-common@workspace:^, @backstage/plugin-catalog-common@workspace:plugins/catalog-common": +"@backstage/plugin-catalog-common@npm:^1.0.10, @backstage/plugin-catalog-common@npm:^1.0.16": + version: 1.0.16 + resolution: "@backstage/plugin-catalog-common@npm:1.0.16" + dependencies: + "@backstage/catalog-model": ^1.4.2 + "@backstage/plugin-permission-common": ^0.7.8 + "@backstage/plugin-search-common": ^1.2.6 + checksum: 0dd21c3b704abff78fb091c4c35b0217e557d9a7298fe4227c3a58aa7b2a906ba2d7b7aefce9534ad03d152502dec465d30c07873409f8f803929d62acef9594 + languageName: node + linkType: hard + +"@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: @@ -5756,8 +5872,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -5827,8 +5943,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@octokit/rest": ^19.0.3 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -5924,8 +6040,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@react-hookz/web": ^23.0.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -5962,7 +6078,7 @@ __metadata: "@material-ui/core": ^4.9.13 "@material-ui/icons": ^4.9.1 "@material-ui/lab": ^4.0.0-alpha.60 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6001,8 +6117,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6082,8 +6198,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/humanize-duration": ^3.25.1 @@ -6118,8 +6234,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6150,8 +6266,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/humanize-duration": ^3.27.1 @@ -6216,8 +6332,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@material-ui/styles": ^4.11.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/highlightjs": ^10.1.0 @@ -6251,8 +6367,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6283,8 +6399,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6326,8 +6442,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@material-ui/styles": ^4.9.6 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/pluralize": ^0.0.31 @@ -6420,7 +6536,7 @@ __metadata: "@material-ui/core": ^4.9.13 "@material-ui/icons": ^4.9.1 "@material-ui/lab": ^4.0.0-alpha.57 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 cross-fetch: ^3.1.5 @@ -6450,8 +6566,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6518,8 +6634,8 @@ __metadata: "@material-ui/core": ^4.9.13 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.1 "@testing-library/user-event": ^14.0.0 @@ -6556,8 +6672,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@react-hookz/web": ^20.0.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6745,8 +6861,8 @@ __metadata: "@backstage/dev-utils": "workspace:^" "@backstage/plugin-explore-common": "workspace:^" "@backstage/test-utils": "workspace:^" - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6782,8 +6898,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6815,8 +6931,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6847,8 +6963,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6881,8 +6997,8 @@ __metadata: "@material-ui/lab": 4.0.0-alpha.61 "@maxim_mazurok/gapi.client.calendar": ^3.0.20220408 "@tanstack/react-query": ^4.1.3 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/dompurify": ^2.3.3 @@ -6918,8 +7034,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@react-hookz/web": ^20.0.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -6948,8 +7064,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@octokit/rest": ^19.0.3 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -6986,8 +7102,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@octokit/rest": ^19.0.3 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7023,8 +7139,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@octokit/graphql": ^5.0.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7056,8 +7172,8 @@ __metadata: "@material-ui/core": ^4.12.4 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7089,8 +7205,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@octokit/rest": ^19.0.3 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7120,8 +7236,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7152,8 +7268,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/lodash": ^4.14.173 @@ -7186,8 +7302,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/codemirror": ^5.0.0 @@ -7244,8 +7360,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7290,8 +7406,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@rjsf/utils": 5.13.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7328,8 +7444,8 @@ __metadata: "@rjsf/material-ui-v5": "npm:@rjsf/material-ui@5.13.0" "@rjsf/utils": 5.13.0 "@rjsf/validator-ajv8": 5.13.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.1 "@testing-library/user-event": ^14.0.0 @@ -7368,8 +7484,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@material-ui/pickers": ^3.3.10 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7389,12 +7505,14 @@ __metadata: resolution: "@backstage/plugin-jenkins-backend@workspace:plugins/jenkins-backend" dependencies: "@backstage/backend-common": "workspace:^" + "@backstage/backend-plugin-api": "workspace:^" "@backstage/catalog-client": "workspace:^" "@backstage/catalog-model": "workspace:^" "@backstage/cli": "workspace:^" "@backstage/config": "workspace:^" "@backstage/errors": "workspace:^" "@backstage/plugin-auth-node": "workspace:^" + "@backstage/plugin-catalog-node": "workspace:^" "@backstage/plugin-jenkins-common": "workspace:^" "@backstage/plugin-permission-common": "workspace:^" "@backstage/plugin-permission-node": "workspace:^" @@ -7440,8 +7558,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7497,8 +7615,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -7521,6 +7639,7 @@ __metadata: "@aws-sdk/credential-providers": ^3.350.0 "@aws-sdk/signature-v4": ^3.347.0 "@azure/identity": ^3.2.1 + "@backstage/backend-app-api": "workspace:^" "@backstage/backend-common": "workspace:^" "@backstage/backend-plugin-api": "workspace:^" "@backstage/backend-test-utils": "workspace:^" @@ -7533,12 +7652,13 @@ __metadata: "@backstage/plugin-auth-node": "workspace:^" "@backstage/plugin-catalog-node": "workspace:^" "@backstage/plugin-kubernetes-common": "workspace:^" + "@backstage/plugin-kubernetes-node": "workspace:^" "@backstage/plugin-permission-common": "workspace:^" "@backstage/plugin-permission-node": "workspace:^" "@backstage/types": "workspace:^" "@google-cloud/container": ^4.0.0 "@jest-mock/express": ^2.0.1 - "@kubernetes/client-node": 0.18.1 + "@kubernetes/client-node": 0.19.0 "@types/aws4": ^1.5.1 "@types/express": ^4.17.6 "@types/http-proxy-middleware": ^0.19.3 @@ -7585,8 +7705,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -7618,7 +7738,7 @@ __metadata: "@backstage/plugin-permission-common": "workspace:^" "@backstage/test-utils": "workspace:^" "@backstage/types": "workspace:^" - "@kubernetes/client-node": 0.18.1 + "@kubernetes/client-node": 0.19.0 kubernetes-models: ^4.3.1 lodash: ^4.17.21 luxon: ^3.0.0 @@ -7626,6 +7746,17 @@ __metadata: languageName: unknown linkType: soft +"@backstage/plugin-kubernetes-node@workspace:^, @backstage/plugin-kubernetes-node@workspace:plugins/kubernetes-node": + version: 0.0.0-use.local + resolution: "@backstage/plugin-kubernetes-node@workspace:plugins/kubernetes-node" + dependencies: + "@backstage/backend-plugin-api": "workspace:^" + "@backstage/catalog-model": "workspace:^" + "@backstage/cli": "workspace:^" + "@backstage/plugin-kubernetes-common": "workspace:^" + languageName: unknown + linkType: soft + "@backstage/plugin-kubernetes-react@workspace:^, @backstage/plugin-kubernetes-react@workspace:plugins/kubernetes-react": version: 0.0.0-use.local resolution: "@backstage/plugin-kubernetes-react@workspace:plugins/kubernetes-react" @@ -7645,7 +7776,7 @@ __metadata: "@material-ui/core": ^4.9.13 "@material-ui/icons": ^4.11.3 "@material-ui/lab": ^4.0.0-alpha.61 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.1 "@types/react": ^16.13.1 || ^17.0.0 @@ -7685,12 +7816,12 @@ __metadata: "@backstage/types": "workspace:^" "@kubernetes-models/apimachinery": ^1.1.0 "@kubernetes-models/base": ^4.0.1 - "@kubernetes/client-node": 0.18.1 + "@kubernetes/client-node": 0.19.0 "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -7704,8 +7835,8 @@ __metadata: msw: ^1.0.0 react-use: ^17.2.4 xterm: ^5.2.1 - xterm-addon-attach: ^0.8.0 - xterm-addon-fit: ^0.7.0 + xterm-addon-attach: ^0.9.0 + xterm-addon-fit: ^0.8.0 peerDependencies: react: ^16.13.1 || ^17.0.0 react-dom: ^16.13.1 || ^17.0.0 @@ -7758,8 +7889,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -7834,8 +7965,8 @@ __metadata: "@material-ui/core": ^4.9.13 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7866,8 +7997,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@microsoft/microsoft-graph-types": ^2.25.0 "@tanstack/react-query": ^4.1.3 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -7896,10 +8027,11 @@ __metadata: "@backstage/dev-utils": "workspace:^" "@backstage/errors": "workspace:^" "@backstage/plugin-catalog-react": "workspace:^" + "@backstage/test-utils": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@types/react": ^16.13.1 || ^17.0.0 react-use: ^17.2.4 peerDependencies: @@ -7924,8 +8056,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/parse-link-header": ^2.0.1 @@ -7979,7 +8111,7 @@ __metadata: "@material-ui/core": ^4.9.13 "@material-ui/icons": ^4.9.1 "@material-ui/lab": ^4.0.0-alpha.60 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -8010,8 +8142,8 @@ __metadata: "@material-ui/core": ^4.9.13 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -8041,7 +8173,7 @@ __metadata: "@material-ui/lab": ^4.0.0-alpha.60 "@material-ui/pickers": ^3.3.10 "@material-ui/styles": ^4.11.5 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -8075,8 +8207,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -8109,8 +8241,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.1 "@testing-library/user-event": ^14.0.0 @@ -8146,8 +8278,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -8199,8 +8331,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/luxon": ^3.0.0 @@ -8257,7 +8389,21 @@ __metadata: languageName: unknown linkType: soft -"@backstage/plugin-permission-common@^0.7.8, @backstage/plugin-permission-common@workspace:^, @backstage/plugin-permission-common@workspace:plugins/permission-common": +"@backstage/plugin-permission-common@npm:^0.7.8": + version: 0.7.8 + resolution: "@backstage/plugin-permission-common@npm:0.7.8" + dependencies: + "@backstage/config": ^1.1.0 + "@backstage/errors": ^1.2.2 + "@backstage/types": ^1.1.1 + cross-fetch: ^3.1.5 + uuid: ^8.0.0 + zod: ^3.21.4 + checksum: 495f92d0360ab36bb707b0de527e31f42d699b177875c2ed4e8519c9721745ec1b67be547cd5862162e5d48e240ed07d9ab179c022adaf8367f03ef7ded6459e + languageName: node + linkType: hard + +"@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: @@ -8323,7 +8469,7 @@ __metadata: "@backstage/core-plugin-api": "workspace:^" "@backstage/plugin-permission-common": "workspace:^" "@backstage/test-utils": "workspace:^" - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@types/react": ^16.13.1 || ^17.0.0 cross-fetch: ^3.1.5 @@ -8392,14 +8538,15 @@ __metadata: "@backstage/plugin-permission-common": "workspace:^" "@backstage/plugin-permission-react": "workspace:^" "@backstage/plugin-playlist-common": "workspace:^" + "@backstage/plugin-search-common": "workspace:^" "@backstage/plugin-search-react": "workspace:^" "@backstage/test-utils": "workspace:^" "@backstage/theme": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -8464,7 +8611,7 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": ^4.0.0-alpha.57 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -8518,8 +8665,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -8779,8 +8926,8 @@ __metadata: "@rjsf/material-ui-v5": "npm:@rjsf/material-ui@5.13.0" "@rjsf/utils": 5.13.0 "@rjsf/validator-ajv8": 5.13.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -8828,6 +8975,7 @@ __metadata: "@backstage/plugin-catalog-react": "workspace:^" "@backstage/plugin-permission-react": "workspace:^" "@backstage/plugin-scaffolder-common": "workspace:^" + "@backstage/plugin-scaffolder-node": "workspace:^" "@backstage/plugin-scaffolder-react": "workspace:^" "@backstage/test-utils": "workspace:^" "@backstage/theme": "workspace:^" @@ -8843,8 +8991,8 @@ __metadata: "@rjsf/material-ui": ^3.2.1 "@rjsf/utils": 5.13.0 "@rjsf/validator-ajv8": 5.13.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -9037,6 +9185,16 @@ __metadata: languageName: unknown linkType: soft +"@backstage/plugin-search-common@npm:^1.2.6": + version: 1.2.6 + resolution: "@backstage/plugin-search-common@npm:1.2.6" + dependencies: + "@backstage/plugin-permission-common": ^0.7.8 + "@backstage/types": ^1.1.1 + checksum: 19ee6ef72ce75fce6c0e3da5e978419fd01f795db3e701460da652e8581e3eb53fba800c56d518147d03bd4e1e3889fa18e1d11a82a38c26a304fdc3bc5438bc + languageName: node + linkType: hard + "@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" @@ -9065,8 +9223,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -9104,8 +9262,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -9139,8 +9297,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/luxon": ^3.0.0 @@ -9172,8 +9330,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9245,8 +9403,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@material-ui/styles": ^4.10.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9278,8 +9436,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/luxon": ^3.0.0 @@ -9329,8 +9487,8 @@ __metadata: "@backstage/theme": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9360,8 +9518,8 @@ __metadata: "@backstage/theme": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9471,8 +9629,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9501,8 +9659,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/color": ^3.0.1 @@ -9539,8 +9697,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9608,8 +9766,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@react-hookz/web": ^20.0.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9682,7 +9840,7 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/lab": 4.0.0-alpha.61 "@material-ui/styles": ^4.11.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9723,8 +9881,8 @@ __metadata: "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 "@material-ui/styles": ^4.10.0 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@testing-library/user-event": ^14.0.0 @@ -9742,8 +9900,8 @@ __metadata: react-helmet: 6.1.0 react-use: ^17.2.4 peerDependencies: - react: ^16.13.1 || ^17.0.0 - react-dom: ^16.13.1 || ^17.0.0 + 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 @@ -9791,8 +9949,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9838,6 +9996,7 @@ __metadata: "@backstage/core-plugin-api": "workspace:^" "@backstage/dev-utils": "workspace:^" "@backstage/errors": "workspace:^" + "@backstage/frontend-plugin-api": "workspace:^" "@backstage/plugin-catalog": "workspace:^" "@backstage/plugin-catalog-react": "workspace:^" "@backstage/test-utils": "workspace:^" @@ -9846,8 +10005,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9906,8 +10065,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -9935,8 +10094,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/luxon": ^3.0.0 @@ -10030,7 +10189,7 @@ __metadata: "@backstage/types": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@types/react": ^16.13.1 || ^17.0.0 cross-fetch: ^3.1.5 i18next: ^22.4.15 @@ -10044,7 +10203,35 @@ __metadata: languageName: unknown linkType: soft -"@backstage/theme@^0.4.2, @backstage/theme@workspace:^, @backstage/theme@workspace:packages/theme": +"@backstage/theme@npm:^0.2.16, @backstage/theme@npm:^0.2.18": + version: 0.2.19 + resolution: "@backstage/theme@npm:0.2.19" + dependencies: + "@material-ui/core": ^4.12.2 + peerDependencies: + react: ^16.13.1 || ^17.0.0 + react-dom: ^16.13.1 || ^17.0.0 + checksum: 93ca110a3f953d6d98b4a5f2163beaa1bd1f95adb66a593e85eb523a7012acf654b6148db54008a6434805a4bd9016d67e5c6a317bc56940ee6800aecbb97d6f + languageName: node + linkType: hard + +"@backstage/theme@npm:^0.4.2": + version: 0.4.2 + resolution: "@backstage/theme@npm:0.4.2" + 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 + react: ^16.13.1 || ^17.0.0 + react-dom: ^16.13.1 || ^17.0.0 + checksum: 22371c3159ed4d2f6d53925d48318d5f8f66ac9d6df6ff32f34b4b52e070e88ada25031b2a8fc3264cb352a24f4128fa1295b1302d1d3f12df3bcb76c785f605 + languageName: node + linkType: hard + +"@backstage/theme@workspace:^, @backstage/theme@workspace:packages/theme": version: 0.0.0-use.local resolution: "@backstage/theme@workspace:packages/theme" dependencies: @@ -10061,18 +10248,6 @@ __metadata: languageName: unknown linkType: soft -"@backstage/theme@npm:^0.2.16, @backstage/theme@npm:^0.2.18": - version: 0.2.19 - resolution: "@backstage/theme@npm:0.2.19" - dependencies: - "@material-ui/core": ^4.12.2 - peerDependencies: - react: ^16.13.1 || ^17.0.0 - react-dom: ^16.13.1 || ^17.0.0 - checksum: 93ca110a3f953d6d98b4a5f2163beaa1bd1f95adb66a593e85eb523a7012acf654b6148db54008a6434805a4bd9016d67e5c6a317bc56940ee6800aecbb97d6f - languageName: node - linkType: hard - "@backstage/types@^1.0.2, @backstage/types@^1.1.1, @backstage/types@workspace:^, @backstage/types@workspace:packages/types": version: 0.0.0-use.local resolution: "@backstage/types@workspace:packages/types" @@ -10089,7 +10264,7 @@ __metadata: resolution: "@backstage/version-bridge@workspace:packages/version-bridge" dependencies: "@backstage/cli": "workspace:^" - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/react-hooks": ^8.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -12412,8 +12587,8 @@ __metadata: "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 "@material-ui/lab": 4.0.0-alpha.61 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": ^16.13.1 || ^17.0.0 @@ -12929,35 +13104,7 @@ __metadata: languageName: node linkType: hard -"@kubernetes/client-node@npm:0.18.1": - version: 0.18.1 - resolution: "@kubernetes/client-node@npm:0.18.1" - dependencies: - "@types/js-yaml": ^4.0.1 - "@types/node": ^18.11.17 - "@types/request": ^2.47.1 - "@types/ws": ^8.5.3 - byline: ^5.0.0 - isomorphic-ws: ^5.0.0 - js-yaml: ^4.1.0 - jsonpath-plus: ^7.2.0 - openid-client: ^5.3.0 - request: ^2.88.0 - rfc4648: ^1.3.0 - stream-buffers: ^3.0.2 - tar: ^6.1.11 - tmp-promise: ^3.0.2 - tslib: ^2.4.1 - underscore: ^1.13.6 - ws: ^8.11.0 - dependenciesMeta: - openid-client: - optional: true - checksum: 7205f10256f182a0292d483195fab7f4d9b500b3a47e6861dcf2fa8851c0bfd554e4f9a9f832ff76500efefb0422df2ecf2e378c5c3a4290e86abd8bc69ef11d - languageName: node - linkType: hard - -"@kubernetes/client-node@npm:^0.19.0": +"@kubernetes/client-node@npm:0.19.0, @kubernetes/client-node@npm:^0.19.0": version: 0.19.0 resolution: "@kubernetes/client-node@npm:0.19.0" dependencies: @@ -13484,14 +13631,14 @@ __metadata: languageName: node linkType: hard -"@mui/base@npm:5.0.0-beta.18": - version: 5.0.0-beta.18 - resolution: "@mui/base@npm:5.0.0-beta.18" +"@mui/base@npm:5.0.0-beta.19": + version: 5.0.0-beta.19 + resolution: "@mui/base@npm:5.0.0-beta.19" dependencies: "@babel/runtime": ^7.23.1 "@floating-ui/react-dom": ^2.0.2 - "@mui/types": ^7.2.5 - "@mui/utils": ^5.14.12 + "@mui/types": ^7.2.6 + "@mui/utils": ^5.14.13 "@popperjs/core": ^2.11.8 clsx: ^2.0.0 prop-types: ^15.8.1 @@ -13502,28 +13649,28 @@ __metadata: peerDependenciesMeta: "@types/react": optional: true - checksum: 7d4ca1e9d537b7b5850567f1adecd1caa47b8613b43a587cf2f399cfda0a8c17dfda06b030c0bea554b76abe7ac25bb9b1af3c996574def5f860cda0c6ea4a3c + checksum: 7503d5609ba242e270cbcaea69f6c7d4935763a34a8ce8de2695078eae12ffcc1d7a57b5d735200de08f2314b2482aa7279631ffd92af240af24f6c31b633d8f languageName: node linkType: hard -"@mui/core-downloads-tracker@npm:^5.14.12": - version: 5.14.12 - resolution: "@mui/core-downloads-tracker@npm:5.14.12" - checksum: 1c1576ceecf7cade9e0d7a531632f5f9db24853d9ebbd47bb9ed943a3af7de734ad4f3374bab79880e9591db3ea55ea84cc10df72177f9ca5e32cc7662e04405 +"@mui/core-downloads-tracker@npm:^5.14.13": + version: 5.14.13 + resolution: "@mui/core-downloads-tracker@npm:5.14.13" + checksum: 3094f8c289d53eb2189ce3f9e4c71e735f91cfefeadda4cf37b0f3c3de47d9261fdbd49485f74267e2fe93d8c0cb289d38e9c802a404489017e9f1cee9e56488 languageName: node linkType: hard "@mui/material@npm:^5.12.2": - version: 5.14.12 - resolution: "@mui/material@npm:5.14.12" + version: 5.14.13 + resolution: "@mui/material@npm:5.14.13" dependencies: "@babel/runtime": ^7.23.1 - "@mui/base": 5.0.0-beta.18 - "@mui/core-downloads-tracker": ^5.14.12 - "@mui/system": ^5.14.12 - "@mui/types": ^7.2.5 - "@mui/utils": ^5.14.12 - "@types/react-transition-group": ^4.4.6 + "@mui/base": 5.0.0-beta.19 + "@mui/core-downloads-tracker": ^5.14.13 + "@mui/system": ^5.14.13 + "@mui/types": ^7.2.6 + "@mui/utils": ^5.14.13 + "@types/react-transition-group": ^4.4.7 clsx: ^2.0.0 csstype: ^3.1.2 prop-types: ^15.8.1 @@ -13542,16 +13689,16 @@ __metadata: optional: true "@types/react": optional: true - checksum: a0d3b52ce3cc282da04036db0805f95f27b35a9c899f132f962fe96f05d3eb112e99ccbf6bd9d05cae617b24beda95470aedaff129d6e39d1b52e1ddf80a9e12 + checksum: 07d73cb5f770743e080494684fd087770893232415c681a25bff2e791414b702d76d02100996a850e89ced81f986c1dc378cc6fb35fcd0724d19b3b0a4a34bed languageName: node linkType: hard -"@mui/private-theming@npm:^5.14.12": - version: 5.14.12 - resolution: "@mui/private-theming@npm:5.14.12" +"@mui/private-theming@npm:^5.14.13": + version: 5.14.13 + resolution: "@mui/private-theming@npm:5.14.13" dependencies: "@babel/runtime": ^7.23.1 - "@mui/utils": ^5.14.12 + "@mui/utils": ^5.14.13 prop-types: ^15.8.1 peerDependencies: "@types/react": ^17.0.0 || ^18.0.0 @@ -13559,13 +13706,13 @@ __metadata: peerDependenciesMeta: "@types/react": optional: true - checksum: f8127347dc29126fece3b530cb156f6ababf747b64bb1c712874375e6efae6c738c014304d9553001d67a59b24ca6a665f2d03bb5ae137f03bdba90815f0ecc1 + checksum: fb2f3644c332a454897f83b98b6fda7344ce30f9382715194442b7d954fdff4e0b96ef017a631259b2f0e44706737eecda7c5306d4833bf5bd834d59b059a6f9 languageName: node linkType: hard -"@mui/styled-engine@npm:^5.14.12": - version: 5.14.12 - resolution: "@mui/styled-engine@npm:5.14.12" +"@mui/styled-engine@npm:^5.14.13": + version: 5.14.13 + resolution: "@mui/styled-engine@npm:5.14.13" dependencies: "@babel/runtime": ^7.23.1 "@emotion/cache": ^11.11.0 @@ -13580,19 +13727,19 @@ __metadata: optional: true "@emotion/styled": optional: true - checksum: c689ccad59e7fd54cd8367838612daa4f132c64d8c6b99ccb7c8f9697b5c940a6bf7edcccd686ce437b565dbcf3bfc12bb0dea47cbd5fbd750ea1553017f9c0d + checksum: b927fffbfb3a2c8d09f10b3770da610c94826312c2aa3e17791bd0355ef64056a842ede32f9d22225b952e3055aa2364c06f17620ae5203a0d4bb782ec90388f languageName: node linkType: hard -"@mui/system@npm:^5.14.12": - version: 5.14.12 - resolution: "@mui/system@npm:5.14.12" +"@mui/system@npm:^5.14.13": + version: 5.14.13 + resolution: "@mui/system@npm:5.14.13" dependencies: "@babel/runtime": ^7.23.1 - "@mui/private-theming": ^5.14.12 - "@mui/styled-engine": ^5.14.12 - "@mui/types": ^7.2.5 - "@mui/utils": ^5.14.12 + "@mui/private-theming": ^5.14.13 + "@mui/styled-engine": ^5.14.13 + "@mui/types": ^7.2.6 + "@mui/utils": ^5.14.13 clsx: ^2.0.0 csstype: ^3.1.2 prop-types: ^15.8.1 @@ -13608,25 +13755,25 @@ __metadata: optional: true "@types/react": optional: true - checksum: 70c3920eadc593395a2d258ddea0f3b28689c7f02fdaf97fc205e16efaeebe462b2ab01c69a20a3bcb011e0d07ea47fa66a433e70d0a1ce15d7b694fb3c52135 + checksum: 1dfcd19737792d36e87b83623f1bf836f1e1282faf44646f9788cec9e5fb6502e6082872ab839dcebd0ae3d72c5771aa12bad9d3ee4b7e039582970acda13a8d languageName: node linkType: hard -"@mui/types@npm:^7.2.5": - version: 7.2.5 - resolution: "@mui/types@npm:7.2.5" +"@mui/types@npm:^7.2.6": + version: 7.2.6 + resolution: "@mui/types@npm:7.2.6" peerDependencies: "@types/react": ^17.0.0 || ^18.0.0 peerDependenciesMeta: "@types/react": optional: true - checksum: 2807e9a8eb251294eee6384a4d68b2159f7660466625f1781e9efea282aa7c6ff35b42bc7039c2d43e7a5ac80291dcb85c4110022b0b6de4e12b6406b62f3dc1 + checksum: eb92f9c2fa5df048bcf182a611131bee2799ce1de64acfca12855f349d0b69f5f92c953b7e6c4e341e1df48f0e86f1329ed0251be4835ed194f53342827bd576 languageName: node linkType: hard -"@mui/utils@npm:^5.14.12": - version: 5.14.12 - resolution: "@mui/utils@npm:5.14.12" +"@mui/utils@npm:^5.14.13": + version: 5.14.13 + resolution: "@mui/utils@npm:5.14.13" dependencies: "@babel/runtime": ^7.23.1 "@types/prop-types": ^15.7.7 @@ -13638,7 +13785,7 @@ __metadata: peerDependenciesMeta: "@types/react": optional: true - checksum: 41470b6292b7a46c71fb0a0acc6a5f05a5e080648106b8805555de920e8f748669c7e8d39cbbcf0f52be9053927bb8439a748e24bd02bc1a220c9bded4435f42 + checksum: 5f04382d7761d35c5f53bcc0ce91c29aba0b3c0afb731f01d2ff078b05afe8098dee412538d846ab3a4b00eec934d46d730f9ef2ef493c3db885e2672480b6f0 languageName: node linkType: hard @@ -14429,65 +14576,65 @@ __metadata: linkType: hard "@opentelemetry/api@npm:^1.0.1, @opentelemetry/api@npm:^1.3.0, @opentelemetry/api@npm:^1.4.1": - version: 1.4.1 - resolution: "@opentelemetry/api@npm:1.4.1" - checksum: e783c40d1a518abf9c4c5d65223237c1392cd9a6c53ac6e2c3ef0c05ff7266e3dfc4fd9874316dae0dcb7a97950878deb513bcbadfaad653d48f0215f2a0911b + version: 1.6.0 + resolution: "@opentelemetry/api@npm:1.6.0" + checksum: 3283b78b62a39f6568eaa050ac7045fcca747679e255874f6d2107cb8e1a3b2e10bfbf553c3e82a72500fb5fdca49dc07a5fe27fd6980debac24506cca638859 languageName: node linkType: hard -"@opentelemetry/core@npm:1.13.0": - version: 1.13.0 - resolution: "@opentelemetry/core@npm:1.13.0" +"@opentelemetry/core@npm:1.17.1": + version: 1.17.1 + resolution: "@opentelemetry/core@npm:1.17.1" dependencies: - "@opentelemetry/semantic-conventions": 1.13.0 + "@opentelemetry/semantic-conventions": 1.17.1 peerDependencies: - "@opentelemetry/api": ">=1.0.0 <1.5.0" - checksum: a69916bcb710f1241e98a58ac5f5dfbc3372fdcd6cb2a4b2d33cdeb941765ecbdeea029f60f650a5743a56f583b0f06b672566467b89db84a24f1304bf2e5205 + "@opentelemetry/api": ">=1.0.0 <1.7.0" + checksum: 06157f4a51dd1b3c98487c0d29a927a5a0fbbc997a81b04ccc4923968424582f517969b91c4f4f19dc1718f27a97f43b0b07af1310a5c240a96c5ff14c4b5cec languageName: node linkType: hard -"@opentelemetry/exporter-prometheus@npm:^0.39.1": - version: 0.39.1 - resolution: "@opentelemetry/exporter-prometheus@npm:0.39.1" +"@opentelemetry/exporter-prometheus@npm:^0.44.0": + version: 0.44.0 + resolution: "@opentelemetry/exporter-prometheus@npm:0.44.0" dependencies: - "@opentelemetry/core": 1.13.0 - "@opentelemetry/resources": 1.13.0 - "@opentelemetry/sdk-metrics": 1.13.0 + "@opentelemetry/core": 1.17.1 + "@opentelemetry/resources": 1.17.1 + "@opentelemetry/sdk-metrics": 1.17.1 peerDependencies: "@opentelemetry/api": ^1.3.0 - checksum: 97697926ef26e3dca9654b6ea8d2ab8e7fc7fc33ce617d25a6eb70c0ef2e2fe47192fcede15cbe45179d0ade67e55769bbed11c691d34f9e59ebd50aab22add7 + checksum: f0c093ba8b70c23f16fb08e7f2ca59986dff853ae006fd42864b952e4dc9ceac97fcb423586288828f1a35271589a6676eed46f2017369d59e8ed3315e6ac79d languageName: node linkType: hard -"@opentelemetry/resources@npm:1.13.0": - version: 1.13.0 - resolution: "@opentelemetry/resources@npm:1.13.0" +"@opentelemetry/resources@npm:1.17.1": + version: 1.17.1 + resolution: "@opentelemetry/resources@npm:1.17.1" dependencies: - "@opentelemetry/core": 1.13.0 - "@opentelemetry/semantic-conventions": 1.13.0 + "@opentelemetry/core": 1.17.1 + "@opentelemetry/semantic-conventions": 1.17.1 peerDependencies: - "@opentelemetry/api": ">=1.0.0 <1.5.0" - checksum: ef0a11596f27b5e1c13b74357da06c5c2725a1056df0a583562dbcc739927ad85bb8bdec4e01f4b43f348b448c0146c033b135840a7d388b75cc751a33a6364e + "@opentelemetry/api": ">=1.0.0 <1.7.0" + checksum: ea4ec5568f5b67626be6eb2b975614d140dab4f6eb7ca73ee30d0f1957ef9779953956d1d44c35bb124c75e311b34a05e2036b32fcf31cf50ae983154df9ee3d languageName: node linkType: hard -"@opentelemetry/sdk-metrics@npm:1.13.0, @opentelemetry/sdk-metrics@npm:^1.13.0": - version: 1.13.0 - resolution: "@opentelemetry/sdk-metrics@npm:1.13.0" +"@opentelemetry/sdk-metrics@npm:1.17.1, @opentelemetry/sdk-metrics@npm:^1.13.0": + version: 1.17.1 + resolution: "@opentelemetry/sdk-metrics@npm:1.17.1" dependencies: - "@opentelemetry/core": 1.13.0 - "@opentelemetry/resources": 1.13.0 - lodash.merge: 4.6.2 + "@opentelemetry/core": 1.17.1 + "@opentelemetry/resources": 1.17.1 + lodash.merge: ^4.6.2 peerDependencies: - "@opentelemetry/api": ">=1.3.0 <1.5.0" - checksum: 2f87444b6c789acdde3465383b4255b072e201cf9bed642e82970540bfe913d76d4c4ebf8cc1ff3da383d3235dd8399cd6407fac86085a9ac9ff5b5b3afc9f38 + "@opentelemetry/api": ">=1.3.0 <1.7.0" + checksum: 6f6a59c5f594ebfc75da7ba203cb35a9271f4536ed4c2499c83f5953b3a2486d306d7aa17f0d7c2fde0efb8cbe9ac4346988adab0e039d082ec95d8d32703509 languageName: node linkType: hard -"@opentelemetry/semantic-conventions@npm:1.13.0": - version: 1.13.0 - resolution: "@opentelemetry/semantic-conventions@npm:1.13.0" - checksum: 9cccf1d73315fed3920bb2201c0e82f66e58dddfa475314b6613780c2804570d6f657be3894eb8b84a2a543c9b8cd520587f5d6cd4b62bc6731d7299b4c5ee69 +"@opentelemetry/semantic-conventions@npm:1.17.1": + version: 1.17.1 + resolution: "@opentelemetry/semantic-conventions@npm:1.17.1" + checksum: 16161f70526d2abcd37a39771229ffe01a25d569f76c86e97200dc20399e7fa87b231c557a9654629b4789e945350e4fc55f88df979a502911f1dde4643ad416 languageName: node linkType: hard @@ -16872,20 +17019,49 @@ __metadata: languageName: node linkType: hard -"@testing-library/jest-dom@npm:^5.10.1, @testing-library/jest-dom@npm:^5.16.4, @testing-library/jest-dom@npm:^5.16.5": - version: 5.17.0 - resolution: "@testing-library/jest-dom@npm:5.17.0" +"@testing-library/dom@npm:^9.0.0": + version: 9.3.3 + resolution: "@testing-library/dom@npm:9.3.3" dependencies: - "@adobe/css-tools": ^4.0.1 + "@babel/code-frame": ^7.10.4 + "@babel/runtime": ^7.12.5 + "@types/aria-query": ^5.0.1 + aria-query: 5.1.3 + chalk: ^4.1.0 + dom-accessibility-api: ^0.5.9 + lz-string: ^1.5.0 + pretty-format: ^27.0.2 + checksum: 34e0a564da7beb92aa9cc44a9080221e2412b1a132eb37be3d513fe6c58027674868deb9f86195756d98d15ba969a30fe00632a4e26e25df2a5a4f6ac0686e37 + languageName: node + linkType: hard + +"@testing-library/jest-dom@npm:^6.0.0": + version: 6.1.4 + resolution: "@testing-library/jest-dom@npm:6.1.4" + dependencies: + "@adobe/css-tools": ^4.3.1 "@babel/runtime": ^7.9.2 - "@types/testing-library__jest-dom": ^5.9.1 aria-query: ^5.0.0 chalk: ^3.0.0 css.escape: ^1.5.1 dom-accessibility-api: ^0.5.6 lodash: ^4.17.15 redent: ^3.0.0 - checksum: 9f28dbca8b50d7c306aae40c3aa8e06f0e115f740360004bd87d57f95acf7ab4b4f4122a7399a76dbf2bdaaafb15c99cc137fdcb0ae457a92e2de0f3fbf9b03b + peerDependencies: + "@jest/globals": ">= 28" + "@types/jest": ">= 28" + jest: ">= 28" + vitest: ">= 0.32" + peerDependenciesMeta: + "@jest/globals": + optional: true + "@types/jest": + optional: true + jest: + optional: true + vitest: + optional: true + checksum: c6bd9469554136a25d94b55ea16736d56b8c5d200526023774dbf35ca35551a721257e6734f1b404bbd07ae0a1950f1912b5be60e113db2ff2ff50af14f7085c languageName: node linkType: hard @@ -17571,14 +17747,14 @@ __metadata: linkType: hard "@types/express@npm:*, @types/express@npm:^4.17.13, @types/express@npm:^4.17.17, @types/express@npm:^4.17.6": - version: 4.17.18 - resolution: "@types/express@npm:4.17.18" + version: 4.17.19 + resolution: "@types/express@npm:4.17.19" dependencies: "@types/body-parser": "*" "@types/express-serve-static-core": ^4.17.33 "@types/qs": "*" "@types/serve-static": "*" - checksum: 8c178da4f0edff1f006d871fbdc3f849620986ff10bad252f3dfd45b57554e26aaa28c602285df028930d5216e257a06fbaf795070f8bb42f7d87e3b689cba50 + checksum: 3d39d0655eb0825d96fec100985a38737767ddd6da2dbda1e330a3adf36c98a9b7cd8d9539db32876d1fbb47a09343cad7b38c30c8dd7c291271fcb9b85cb21b languageName: node linkType: hard @@ -17820,9 +17996,9 @@ __metadata: linkType: hard "@types/js-yaml@npm:^4.0.0, @types/js-yaml@npm:^4.0.1": - version: 4.0.6 - resolution: "@types/js-yaml@npm:4.0.6" - checksum: d4439ec2cc830d355c2a1d7508f49888931b2cfe59d786d27621edd530bf06314b1dceeaa759e21f9b035a0ff623a0ca306752ebb73df9485c02abe045bd962c + version: 4.0.7 + resolution: "@types/js-yaml@npm:4.0.7" + checksum: e02eca876f3f19dbba62a26a18e59ec5df4e29300b99808fb0b4ca980cbfbb60e4a2c7d75d521728f5b2a3b92a0da5b9343497b2acf621b8ea019d48b40bbd78 languageName: node linkType: hard @@ -18097,11 +18273,11 @@ __metadata: linkType: hard "@types/node-forge@npm:^1.3.0": - version: 1.3.6 - resolution: "@types/node-forge@npm:1.3.6" + version: 1.3.7 + resolution: "@types/node-forge@npm:1.3.7" dependencies: "@types/node": "*" - checksum: 5fe97ce83937c51215a52eb8c9d5c4458abbca2b3cfd91a65142f20fd4a2830ed10ab1a8c860efc55ff36553f939a75c4a6d5c243ed6e24e55a005c9bddeaf43 + checksum: e604e0e09e0ffdcf7babdf2415f7d2de14a7718ddc9c5916a693f81597dc80865d525dfb7fc876a787c25bf1164518cd8ecf1667598bee00c9ba1349f93ba4eb languageName: node linkType: hard @@ -18133,7 +18309,7 @@ __metadata: languageName: node linkType: hard -"@types/node@npm:^18.11.17, @types/node@npm:^18.17.8": +"@types/node@npm:^18.17.8": version: 18.18.4 resolution: "@types/node@npm:18.18.4" checksum: 4901e91c4cc479bb58acbcd79236a97a0ad6db4a53cb1f4ba4cf32af15324c61b16faa6e31c1b09bf538a20feb5f5274239157ce5237f5741db0b9ab71e69c52 @@ -18266,13 +18442,13 @@ __metadata: linkType: hard "@types/pg@npm:^8.6.6": - version: 8.10.3 - resolution: "@types/pg@npm:8.10.3" + version: 8.10.5 + resolution: "@types/pg@npm:8.10.5" dependencies: "@types/node": "*" pg-protocol: "*" pg-types: ^4.0.1 - checksum: 05a12be3f18cc67728e3aee5a7426f065351ca991e351d2e7a0562c5d9063425d67fe88fd35108834e0fa1f5624032fefbf371cf8f3cc47230a666aa953425b9 + checksum: 532a3104ed7898e3c7806e00cbde486dcfc803d2e99e236066f1b675ff0546a1cb232fe6f2ffc60dac81d3df209b69dbe62a597b565bff0965dd622fef957afe languageName: node linkType: hard @@ -18411,12 +18587,12 @@ __metadata: languageName: node linkType: hard -"@types/react-transition-group@npm:^4.2.0, @types/react-transition-group@npm:^4.4.6": - version: 4.4.6 - resolution: "@types/react-transition-group@npm:4.4.6" +"@types/react-transition-group@npm:^4.2.0, @types/react-transition-group@npm:^4.4.7": + version: 4.4.7 + resolution: "@types/react-transition-group@npm:4.4.7" dependencies: "@types/react": "*" - checksum: 0872143821d7ee20a1d81e965f8b1e837837f11cd2206973f1f98655751992d9390304d58bac192c9cd923eca95bff107d8c9e3364a180240d5c2a6fd70fd7c3 + checksum: 3b91486e7aa777a3787e773efce79a0fa9be4ec9e02d51ccda8c7532c5c5d84fbcefe248dacb4007293d85bf0794ac51603bb9cec360db81cf3657d2b7123fb9 languageName: node linkType: hard @@ -18439,13 +18615,13 @@ __metadata: linkType: hard "@types/react@npm:^17": - version: 17.0.67 - resolution: "@types/react@npm:17.0.67" + version: 17.0.68 + resolution: "@types/react@npm:17.0.68" dependencies: "@types/prop-types": "*" "@types/scheduler": "*" csstype: ^3.0.2 - checksum: eb4915fc7d24e19fe6e98dfe98ade377423b1263e7dc001beda41b0298152fb5a410a55dde5def5ec0838156239a48e778d522da03d319ae5ecea80d455da604 + checksum: c6ca4415b53b1abe91162b29af541a1797a56a6f462ef796e8ebda3eaa4d0609205f4f17b3fce8d9a12235d4ffd8a67c47b5e018ed85c2f3bee0fba8f54638c1 languageName: node linkType: hard @@ -18551,11 +18727,11 @@ __metadata: linkType: hard "@types/sanitize-html@npm:^2.6.2": - version: 2.9.1 - resolution: "@types/sanitize-html@npm:2.9.1" + version: 2.9.2 + resolution: "@types/sanitize-html@npm:2.9.2" dependencies: htmlparser2: ^8.0.0 - checksum: 381db8e3f22876e8f6aa8f0997af73c71220c8398545d809ebd4e25d33480e73642b8c143a87d87bba504a43ab58d70a724c60eb3fd8fde31a813b682730c98f + checksum: bdd0db4a39125b8836573ede5ec5cc2f7b0dff5ecfbeae68aefb40163c916429cfb500d581ad3a18613e8d6a53f707abb279350e0811122e84e21b0223b8d560 languageName: node linkType: hard @@ -18952,15 +19128,15 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/eslint-plugin@npm:6.7.2": - version: 6.7.2 - resolution: "@typescript-eslint/eslint-plugin@npm:6.7.2" +"@typescript-eslint/eslint-plugin@npm:6.7.5": + version: 6.7.5 + resolution: "@typescript-eslint/eslint-plugin@npm:6.7.5" dependencies: "@eslint-community/regexpp": ^4.5.1 - "@typescript-eslint/scope-manager": 6.7.2 - "@typescript-eslint/type-utils": 6.7.2 - "@typescript-eslint/utils": 6.7.2 - "@typescript-eslint/visitor-keys": 6.7.2 + "@typescript-eslint/scope-manager": 6.7.5 + "@typescript-eslint/type-utils": 6.7.5 + "@typescript-eslint/utils": 6.7.5 + "@typescript-eslint/visitor-keys": 6.7.5 debug: ^4.3.4 graphemer: ^1.4.0 ignore: ^5.2.4 @@ -18973,25 +19149,25 @@ __metadata: peerDependenciesMeta: typescript: optional: true - checksum: 4d6f612619282a20518cd6581bce16cd7c50ac4e49f5eeca2ab916a923049379aa382817568c929216381fb2c1bfbc1c4e6fde16ac8bfdd63862a9126f0ab797 + checksum: c37edf5a703db4ff9227d67c2d2cf817e65c9afc94cc0e650fa3d2b05ac55201ef887ce9dadb9ca13779f4025bf4367e132b013e3559e777006a2332079bb180 languageName: node linkType: hard "@typescript-eslint/parser@npm:^6.7.2": - version: 6.7.2 - resolution: "@typescript-eslint/parser@npm:6.7.2" + version: 6.7.5 + resolution: "@typescript-eslint/parser@npm:6.7.5" dependencies: - "@typescript-eslint/scope-manager": 6.7.2 - "@typescript-eslint/types": 6.7.2 - "@typescript-eslint/typescript-estree": 6.7.2 - "@typescript-eslint/visitor-keys": 6.7.2 + "@typescript-eslint/scope-manager": 6.7.5 + "@typescript-eslint/types": 6.7.5 + "@typescript-eslint/typescript-estree": 6.7.5 + "@typescript-eslint/visitor-keys": 6.7.5 debug: ^4.3.4 peerDependencies: eslint: ^7.0.0 || ^8.0.0 peerDependenciesMeta: typescript: optional: true - checksum: 9e93d3eb432ed5457a852e25a31782d07518f728966cd477620175ae64db9be04f5d8e605f3561dbfe9a365f209a83b2a3788efb9b3cf33669c8bca17f1bcf6f + checksum: 63f988c1c87697bd20487933be952b97f7a5f2a9977f505af671c7d49367fc01ca508817576646caa937c15cc0a0ef1e86adff9111eb19df8b489e7436d10620 languageName: node linkType: hard @@ -19005,22 +19181,22 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/scope-manager@npm:6.7.2": - version: 6.7.2 - resolution: "@typescript-eslint/scope-manager@npm:6.7.2" +"@typescript-eslint/scope-manager@npm:6.7.5": + version: 6.7.5 + resolution: "@typescript-eslint/scope-manager@npm:6.7.5" dependencies: - "@typescript-eslint/types": 6.7.2 - "@typescript-eslint/visitor-keys": 6.7.2 - checksum: e35fa23ecb16252c3ad00b5f1ec05d9b8d33ee30d4c57543892f900443ed77926be9bd2836f06463c31b483f5f0f79070273bc51c4a606f55ac3cd1d9c9cd542 + "@typescript-eslint/types": 6.7.5 + "@typescript-eslint/visitor-keys": 6.7.5 + checksum: f21858ed78f81ab2d9879139f69657fda2a7b901078f79df64d1262d80f84ef66c56525ed0bb5e393fa5ca5474ad97f2225b7f713977c2d0f79cda31b2744af9 languageName: node linkType: hard -"@typescript-eslint/type-utils@npm:6.7.2": - version: 6.7.2 - resolution: "@typescript-eslint/type-utils@npm:6.7.2" +"@typescript-eslint/type-utils@npm:6.7.5": + version: 6.7.5 + resolution: "@typescript-eslint/type-utils@npm:6.7.5" dependencies: - "@typescript-eslint/typescript-estree": 6.7.2 - "@typescript-eslint/utils": 6.7.2 + "@typescript-eslint/typescript-estree": 6.7.5 + "@typescript-eslint/utils": 6.7.5 debug: ^4.3.4 ts-api-utils: ^1.0.1 peerDependencies: @@ -19028,7 +19204,7 @@ __metadata: peerDependenciesMeta: typescript: optional: true - checksum: 67743f8e4b77d0ab3d82907eda0411ffd221357b60ac9cbd29683d5b8c77127369ebfafcf0bfc30a1f1828927ccd5635fab5b2eaf2b2f1d12a9361549cab3e62 + checksum: 8023d8ddcfbf4a0411b192016711068e9e6787c5811aee3a25ac40025ade0d063a1a3d7b38469e1a534bb31fa9dbeec08ab53b7a6d7b3128358294ac5b219d9a languageName: node linkType: hard @@ -19039,10 +19215,10 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/types@npm:6.7.2": - version: 6.7.2 - resolution: "@typescript-eslint/types@npm:6.7.2" - checksum: 5a7c4cd456f721649757d2edb4cae71d1405c1c2c35672031f012b27007b9d49b7118297eec746dc3351370e6aa414e5d2c493fb658c7b910154b7998c0278e1 +"@typescript-eslint/types@npm:6.7.5": + version: 6.7.5 + resolution: "@typescript-eslint/types@npm:6.7.5" + checksum: f21e5726b60f13feb3a920c92515fbc1205ba0e9bba9959b2e42c02c282a0ab4fb0e5ae84f3807b9b1cf95036027e9033d92a911fa88e6c243a87621d8dd7a01 languageName: node linkType: hard @@ -19064,12 +19240,12 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/typescript-estree@npm:6.7.2": - version: 6.7.2 - resolution: "@typescript-eslint/typescript-estree@npm:6.7.2" +"@typescript-eslint/typescript-estree@npm:6.7.5": + version: 6.7.5 + resolution: "@typescript-eslint/typescript-estree@npm:6.7.5" dependencies: - "@typescript-eslint/types": 6.7.2 - "@typescript-eslint/visitor-keys": 6.7.2 + "@typescript-eslint/types": 6.7.5 + "@typescript-eslint/visitor-keys": 6.7.5 debug: ^4.3.4 globby: ^11.1.0 is-glob: ^4.0.3 @@ -19078,24 +19254,24 @@ __metadata: peerDependenciesMeta: typescript: optional: true - checksum: c30b9803567c37527e2806badd98f3083ae125db9a430d8a28647b153e446e6a4b830833f229cca27d5aa0ff5497c149aaa524aa3a6dbf932b557c60d0bfd4f9 + checksum: 17685e8321edce1d1ec4278d84e63c0f41ccb19e9308f21c37450943ad0c33328755ac52b966e7855af17e01d22bc83d1fcda79c279fabe7d3460c8f315a7265 languageName: node linkType: hard -"@typescript-eslint/utils@npm:6.7.2": - version: 6.7.2 - resolution: "@typescript-eslint/utils@npm:6.7.2" +"@typescript-eslint/utils@npm:6.7.5": + version: 6.7.5 + resolution: "@typescript-eslint/utils@npm:6.7.5" dependencies: "@eslint-community/eslint-utils": ^4.4.0 "@types/json-schema": ^7.0.12 "@types/semver": ^7.5.0 - "@typescript-eslint/scope-manager": 6.7.2 - "@typescript-eslint/types": 6.7.2 - "@typescript-eslint/typescript-estree": 6.7.2 + "@typescript-eslint/scope-manager": 6.7.5 + "@typescript-eslint/types": 6.7.5 + "@typescript-eslint/typescript-estree": 6.7.5 semver: ^7.5.4 peerDependencies: eslint: ^7.0.0 || ^8.0.0 - checksum: 97f950562dba2bda63ffe64672f643ef940123cf74007bc878afcf31c75f905c99934a3ad77da3d5a4fe7807d5d69c791b20c429712ad5a5525e331ebc313756 + checksum: f365c654241f927e7784640079627d60a296aa3d575552b07594a69cfc419832eb5fa4adc87acb1988bea9741ae9cc4a5277dab168990310caef5de125255752 languageName: node linkType: hard @@ -19127,13 +19303,13 @@ __metadata: languageName: node linkType: hard -"@typescript-eslint/visitor-keys@npm:6.7.2": - version: 6.7.2 - resolution: "@typescript-eslint/visitor-keys@npm:6.7.2" +"@typescript-eslint/visitor-keys@npm:6.7.5": + version: 6.7.5 + resolution: "@typescript-eslint/visitor-keys@npm:6.7.5" dependencies: - "@typescript-eslint/types": 6.7.2 + "@typescript-eslint/types": 6.7.5 eslint-visitor-keys: ^3.4.1 - checksum: b4915fbc0f3d44c81b92b7151830b698e8b6ed2dee8587bb65540c888c7a84300d3fd6b0c159e2131c7c6df1bebe49fb0d21c347ecdbf7f3e4aec05acebbb0bc + checksum: 2df996742f63d89fa339b0e8ff3a3a289d36b3f584f7538a7626bed3869e9ae27f8f56ab31748519d25a63de2ae22a43dd8413610b00436ff342b0a17eb85289 languageName: node linkType: hard @@ -25471,8 +25647,8 @@ __metadata: "@roadiehq/backstage-plugin-github-insights": ^2.0.5 "@roadiehq/backstage-plugin-github-pull-requests": ^2.2.7 "@roadiehq/backstage-plugin-travis-ci": ^2.0.5 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/jquery": ^3.3.34 @@ -25584,8 +25760,8 @@ __metadata: "@roadiehq/backstage-plugin-github-insights": ^2.0.5 "@roadiehq/backstage-plugin-github-pull-requests": ^2.2.7 "@roadiehq/backstage-plugin-travis-ci": ^2.0.5 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/jquery": ^3.3.34 @@ -25621,6 +25797,7 @@ __metadata: "@backstage/plugin-catalog-backend-module-unprocessed": "workspace:^" "@backstage/plugin-devtools-backend": "workspace:^" "@backstage/plugin-entity-feedback-backend": "workspace:^" + "@backstage/plugin-jenkins-backend": "workspace:^" "@backstage/plugin-kubernetes-backend": "workspace:^" "@backstage/plugin-lighthouse-backend": "workspace:^" "@backstage/plugin-linguist-backend": "workspace:^" @@ -25703,7 +25880,7 @@ __metadata: "@gitbeaker/node": ^35.1.0 "@octokit/rest": ^19.0.3 "@opentelemetry/api": ^1.4.1 - "@opentelemetry/exporter-prometheus": ^0.39.1 + "@opentelemetry/exporter-prometheus": ^0.44.0 "@opentelemetry/sdk-metrics": ^1.13.0 "@types/dockerode": ^3.3.0 "@types/express": ^4.17.6 @@ -25865,7 +26042,7 @@ __metadata: languageName: node linkType: hard -"express-session@npm:^1.17.1": +"express-session@npm:^1.17.1, express-session@npm:^1.17.3": version: 1.17.3 resolution: "express-session@npm:1.17.3" dependencies: @@ -30069,10 +30246,10 @@ __metadata: languageName: node linkType: hard -"jose@npm:^4.15.1, jose@npm:^4.6.0": - version: 4.15.2 - resolution: "jose@npm:4.15.2" - checksum: 8f0cab1eef31243abe14a935b2b330cd95f10f9b69808fd642088ae5000e50e566664934537d2c6413ab2f6b54acd8265a5033da05157aa1260c5f1d7e57fab0 +"jose@npm:^4.14.6, jose@npm:^4.15.1, jose@npm:^4.6.0": + version: 4.15.3 + resolution: "jose@npm:4.15.3" + checksum: b76eeccc1d40d0eaf26dfaadc0f88fc15802c9105ab66a24ee223bd84369f7cb217f4a2cb852f5080ff6996170b3a73db2b2d26878b8905d99c36ca432628134 languageName: node linkType: hard @@ -31560,7 +31737,7 @@ __metadata: languageName: node linkType: hard -"lodash.merge@npm:4.6.2, lodash.merge@npm:^4.6.2": +"lodash.merge@npm:^4.6.2": version: 4.6.2 resolution: "lodash.merge@npm:4.6.2" checksum: ad580b4bdbb7ca1f7abf7e1bce63a9a0b98e370cf40194b03380a46b4ed799c9573029599caebc1b14e3f24b111aef72b96674a56cfa105e0f5ac70546cdc005 @@ -33196,7 +33373,7 @@ __metadata: languageName: node linkType: hard -"msw@npm:^1.0.0, msw@npm:^1.0.1, msw@npm:^1.2.1, msw@npm:^1.2.3, msw@npm:^1.3.1": +"msw@npm:^1.0.0, msw@npm:^1.0.1, msw@npm:^1.2.1, msw@npm:^1.2.3, msw@npm:^1.3.0, msw@npm:^1.3.1": version: 1.3.2 resolution: "msw@npm:1.3.2" dependencies: @@ -34243,15 +34420,15 @@ __metadata: languageName: node linkType: hard -"openid-client@npm:^5.2.1, openid-client@npm:^5.3.0": - version: 5.6.0 - resolution: "openid-client@npm:5.6.0" +"openid-client@npm:^5.2.1, openid-client@npm:^5.3.0, openid-client@npm:^5.4.3": + version: 5.6.1 + resolution: "openid-client@npm:5.6.1" dependencies: jose: ^4.15.1 lru-cache: ^6.0.0 object-hash: ^2.2.0 oidc-token-hash: ^5.0.3 - checksum: 414fe43c5aac07d8b8f5ea52ef1812374ff28140910977a1360781284b09d4a03c916d910017bf15003d602d859b3dcf9857d1dfe6f61508c8f5c52de334e6ea + checksum: 9d939cec57540e6dd3f67e9a248ec5ecec3b439b7ab5bd2e9fb4481bd03e8d030deedd87a447348194be7f3e93e84085841b0414033caf86479870f526cdbc2f languageName: node linkType: hard @@ -34906,10 +35083,10 @@ __metadata: languageName: node linkType: hard -"path-equal@npm:^1.1.2": - version: 1.2.2 - resolution: "path-equal@npm:1.2.2" - checksum: 948930eb6bbb5ddcc724f7a4339e2a98fe35269b5f46d88f85c588ed4713e7ec1c71da1629608606c6687216ba3afae710a77cfb5146b735a84d6199f06f247d +"path-equal@npm:^1.2.5": + version: 1.2.5 + resolution: "path-equal@npm:1.2.5" + checksum: 2bef7bcb98c7ae371c52c1562b2fc515bfd03bc1a5571df9a8591038db8d742ba2d1ff39aa5130853e6afb69e773ccba5095f54d2e6d17422ca03ef9047992d7 languageName: node linkType: hard @@ -40385,8 +40562,8 @@ __metadata: "@backstage/theme": "workspace:^" "@material-ui/core": ^4.12.2 "@material-ui/icons": ^4.9.1 - "@testing-library/dom": ^8.0.0 - "@testing-library/jest-dom": ^5.10.1 + "@testing-library/dom": ^9.0.0 + "@testing-library/jest-dom": ^6.0.0 "@testing-library/react": ^12.1.3 "@testing-library/user-event": ^14.0.0 "@types/react": "*" @@ -40632,15 +40809,6 @@ __metadata: languageName: node linkType: hard -"tmp-promise@npm:^3.0.2": - version: 3.0.2 - resolution: "tmp-promise@npm:3.0.2" - dependencies: - tmp: ^0.2.0 - checksum: 2d8457c9512e896633f64fab33e5e3fd273c4d8fca33cfc74a04a104a0b921d15ed3e832c4f2a50108635ac88264afef85abddbe5ad8480e15f55fc7f8e76969 - languageName: node - linkType: hard - "tmp@npm:^0.0.33": version: 0.0.33 resolution: "tmp@npm:0.0.33" @@ -40650,7 +40818,7 @@ __metadata: languageName: node linkType: hard -"tmp@npm:^0.2.0, tmp@npm:^0.2.1": +"tmp@npm:^0.2.1": version: 0.2.1 resolution: "tmp@npm:0.2.1" dependencies: @@ -41224,31 +41392,21 @@ __metadata: languageName: node linkType: hard -"typescript-json-schema@npm:^0.55.0": - version: 0.55.0 - resolution: "typescript-json-schema@npm:0.55.0" +"typescript-json-schema@npm:^0.61.0": + version: 0.61.0 + resolution: "typescript-json-schema@npm:0.61.0" dependencies: "@types/json-schema": ^7.0.9 "@types/node": ^16.9.2 glob: ^7.1.7 - path-equal: ^1.1.2 + path-equal: ^1.2.5 safe-stable-stringify: ^2.2.0 ts-node: ^10.9.1 - typescript: ~4.8.2 + typescript: ~5.1.0 yargs: ^17.1.1 bin: typescript-json-schema: bin/typescript-json-schema - checksum: 4188e9d4cc1f1fc3201e2aa06b8d87d35695b0eaf049ff9d2cd3027d87406efc6978c4f90c2bf06f4fcd8d6dd40ceb65e744dc3cf9b412e1f74b8eb5bae96a05 - languageName: node - linkType: hard - -"typescript@npm:~4.8.2": - version: 4.8.4 - resolution: "typescript@npm:4.8.4" - bin: - tsc: bin/tsc - tsserver: bin/tsserver - checksum: 3e4f061658e0c8f36c820802fa809e0fd812b85687a9a2f5430bc3d0368e37d1c9605c3ce9b39df9a05af2ece67b1d844f9f6ea8ff42819f13bcb80f85629af0 + checksum: 8359d5ca8ebcb96dca9cd968b46ea21da40a92ee872a44a7b5c6c8f8f4cd1ffbd0ea457752f3be7d44379ea286ccfaee1d40ab1810321ee45d0ecece80ed45ed languageName: node linkType: hard @@ -41262,13 +41420,13 @@ __metadata: languageName: node linkType: hard -"typescript@patch:typescript@~4.8.2#~builtin<compat/typescript>": - version: 4.8.4 - resolution: "typescript@patch:typescript@npm%3A4.8.4#~builtin<compat/typescript>::version=4.8.4&hash=a1c5e5" +"typescript@npm:~5.1.0": + version: 5.1.6 + resolution: "typescript@npm:5.1.6" bin: tsc: bin/tsc tsserver: bin/tsserver - checksum: 563a0ef47abae6df27a9a3ab38f75fc681f633ccf1a3502b1108e252e187787893de689220f4544aaf95a371a4eb3141e4a337deb9895de5ac3c1ca76430e5f0 + checksum: b2f2c35096035fe1f5facd1e38922ccb8558996331405eb00a5111cc948b2e733163cc22fab5db46992aba7dd520fff637f2c1df4996ff0e134e77d3249a7350 languageName: node linkType: hard @@ -41282,6 +41440,16 @@ __metadata: languageName: node linkType: hard +"typescript@patch:typescript@~5.1.0#~builtin<compat/typescript>": + version: 5.1.6 + resolution: "typescript@patch:typescript@npm%3A5.1.6#~builtin<compat/typescript>::version=5.1.6&hash=a1c5e5" + bin: + tsc: bin/tsc + tsserver: bin/tsserver + checksum: 21e88b0a0c0226f9cb9fd25b9626fb05b4c0f3fddac521844a13e1f30beb8f14e90bd409a9ac43c812c5946d714d6e0dee12d5d02dfc1c562c5aacfa1f49b606 + languageName: node + linkType: hard + "ua-parser-js@npm:^0.7.30": version: 0.7.33 resolution: "ua-parser-js@npm:0.7.33" @@ -41370,7 +41538,7 @@ __metadata: languageName: node linkType: hard -"underscore@npm:^1.12.1, underscore@npm:^1.13.6, underscore@npm:~1.13.2": +"underscore@npm:^1.12.1, underscore@npm:~1.13.2": version: 1.13.6 resolution: "underscore@npm:1.13.6" checksum: d5cedd14a9d0d91dd38c1ce6169e4455bb931f0aaf354108e47bd46d3f2da7464d49b2171a5cf786d61963204a42d01ea1332a903b7342ad428deaafaf70ec36 @@ -42894,15 +43062,6 @@ __metadata: languageName: node linkType: hard -"xterm-addon-attach@npm:^0.8.0": - version: 0.8.0 - resolution: "xterm-addon-attach@npm:0.8.0" - peerDependencies: - xterm: ^5.0.0 - checksum: 2ac70bdd1c97eb05b83b4573132ed9d3686c07ed14212e273800a5693bb0f3ea41c570b49ac90cb95a1e593d5a2764a28c13b649c596054bf5aa87c8489069eb - languageName: node - linkType: hard - "xterm-addon-attach@npm:^0.9.0": version: 0.9.0 resolution: "xterm-addon-attach@npm:0.9.0" @@ -42912,15 +43071,6 @@ __metadata: languageName: node linkType: hard -"xterm-addon-fit@npm:^0.7.0": - version: 0.7.0 - resolution: "xterm-addon-fit@npm:0.7.0" - peerDependencies: - xterm: ^5.0.0 - checksum: 512d41f80d6f9427ba02dab4e6fd642e94775a9cf7ef72ae4b55eab2a36856b5c67069bfc66b4af412fdce29a0842f9c6382af3672f0b514c4352dfd47defe8f - languageName: node - linkType: hard - "xterm-addon-fit@npm:^0.8.0": version: 0.8.0 resolution: "xterm-addon-fit@npm:0.8.0"