docs/releases/v1.42.0-next.3-changelog.md
Upgrade Helper: https://backstage.github.io/upgrade-helper/?to=1.42.0-next.3
923ceb2: BREAKING: The new app build based on Rspack is now the default, and the EXPERIMENTAL_RSPACK flag has been removed. To revert to the old behavior, set the LEGACY_WEBPACK_BUILD environment flag and install the following optional dependencies:
{
"dependencies": {
"@module-federation/enhanced": "^0.9.0",
"@pmmmwh/react-refresh-webpack-plugin": "^0.5.7",
"esbuild-loader": "^4.0.0",
"eslint-webpack-plugin": "^4.2.0",
"fork-ts-checker-webpack-plugin": "^9.0.0",
"mini-css-extract-plugin": "^2.4.2",
"terser-webpack-plugin": "^5.1.3",
"webpack": "^5.96.0",
"webpack-dev-server": "^5.0.0"
}
}
If you do encounter a blocking issue that forces you to use the old WebPack build, please open an issue explaining the problem. The WebPack build will be removed in a future release.
eda80c7: BREAKING: Removed support for .icon.svg imports, which have been deprecated since the 1.19 release.
app.experimental.packages to just app.packages. The old config will continue working for the time being, but may be removed in a future release.@backstage/cli/config/nodeTransformHooks.mjs now supports the built-in type stripping in Node.js, which is enabled by default from v22.18.0.8e21c4d: Use an app plugin for built-in extension app node specs.
8e21c4d: The AppNodeSpec.plugin property is now required.
5e12252: BREAKING: Restructured some of option fields of createApp and createSpecializedApp.
createApp, all option fields except features and bindRoutes have been moved into a new advanced object field.createSpecializedApp, all option fields except features, config, and bindRoutes have been moved into a new advanced object field.This helps highlight that some options are meant to rarely be needed or used, and simplifies the usage of those options that are almost always required.
As an example, if you used to supply a custom config loader, you would update your code as follows:
createApp({
features: [...],
- configLoader: new MyCustomLoader(),
+ advanced: {
+ configLoader: new MyCustomLoader(),
+ },
})
getNodesByRoutePath parameter from sourcePath to routePathapp.experimental.packages to just app.packages. The old config will continue working for the time being, but may be removed in a future release.SwappableComponentsApi and removing the legacy ComponentsApi implementation5e12252: BREAKING: Restructured some of option fields of createApp and createSpecializedApp.
createApp, all option fields except features and bindRoutes have been moved into a new advanced object field.createSpecializedApp, all option fields except features, config, and bindRoutes have been moved into a new advanced object field.This helps highlight that some options are meant to rarely be needed or used, and simplifies the usage of those options that are almost always required.
As an example, if you used to supply a custom config loader, you would update your code as follows:
createApp({
features: [...],
- configLoader: new MyCustomLoader(),
+ advanced: {
+ configLoader: new MyCustomLoader(),
+ },
})
app.experimental.packages to just app.packages. The old config will continue working for the time being, but may be removed in a future release.loadingComponent option has been renamed to loadingElement, which is now found under advanced.loadingElement. The default loading element has also been switched to <Progress /> from @backstage/core-components. This is of course an improvement over the previous "Loading..." text, but also helps prevent flicker when the app loading is fast.fda1bbc: BREAKING: The component system has been overhauled to use SwappableComponent instead of ComponentRef. Several APIs have been removed and replaced:
createComponentRef, createComponentExtension, ComponentRef, ComponentsApi, componentsApiRef, useComponentRef, coreComponentRefscreateSwappableComponent, SwappableComponentBlueprint, SwappableComponentRef, SwappableComponentsApi, swappableComponentsApiRefBREAKING: The default componentRefs and exported Core*Props have been removed and have replacement SwappableComponents and revised type names instead.
errorBoundaryFallback component and CoreErrorBoundaryFallbackProps type have been replaced with ErrorDisplay swappable component and CoreErrorDisplayProps respectively.progress component and CoreProgressProps type have been replaced with Progress swappable component and ProgressProps respectively.notFoundErrorPage component and CoreNotFoundErrorPageProps type have been replaced with NotFoundErrorPage swappable component and NotFoundErrorPageProps respectively.Migration for creating swappable components:
// OLD: Using createComponentRef and createComponentExtension
import {
createComponentRef,
createComponentExtension,
} from '@backstage/frontend-plugin-api';
const myComponentRef = createComponentRef<{ title: string }>({
id: 'my-plugin.my-component',
});
const myComponentExtension = createComponentExtension({
ref: myComponentRef,
loader: {
lazy: () => import('./MyComponent').then(m => m.MyComponent),
},
});
// NEW: Using createSwappableComponent and SwappableComponentBlueprint
import {
createSwappableComponent,
SwappableComponentBlueprint,
} from '@backstage/frontend-plugin-api';
const MySwappableComponent = createSwappableComponent({
id: 'my-plugin.my-component',
loader: () => import('./MyComponent').then(m => m.MyComponent),
});
const myComponentExtension = SwappableComponentBlueprint.make({
name: 'my-component',
params: {
component: MySwappableComponent,
loader: () => import('./MyComponent').then(m => m.MyComponent),
},
});
Migration for using components:
// OLD: Using ComponentsApi and useComponentRef
import {
useComponentRef,
componentsApiRef,
useApi,
coreComponentRefs,
} from '@backstage/frontend-plugin-api';
const MyComponent = useComponentRef(myComponentRef);
const ProgressComponent = useComponentRef(coreComponentRefs.progress);
// NEW: Direct component usage import { Progress } from '@backstage/frontend-plugin-api';
// Use directly as React Component <Progress /> <MySwappableComponent title="Hello World" />
**Migration for core component references:**
```tsx
// OLD: Core component refs
import { coreComponentRefs } from '@backstage/frontend-plugin-api';
coreComponentRefs.progress
coreComponentRefs.notFoundErrorPage
coreComponentRefs.errorBoundaryFallback
// NEW: Direct swappable component imports
import { Progress, NotFoundErrorPage, ErrorDisplay } from '@backstage/frontend-plugin-api';
// Use directly as React components
<Progress />
<NotFoundErrorPage />
<ErrorDisplay plugin={plugin} error={error} resetError={resetError} />
createFrontendPlugin variant where the plugin ID is passed via an id option. To update existing code, switch to using the pluginId option instead.ResolveInputValueOverrides type is no longer exported.createExtension, createExtensionBlueprint, createFrontendPlugin, and createFrontendModule.HeaderPage instead of the Header in Backstage UI.startCollapsed prop on the SearchField component in BUI.fda1bbc: BREAKING: The componentsApi implementation has been removed from the plugin and replaced with the new SwappableComponentsApi instead.
If you were overriding the componentsApi implementation, you can now use the new SwappableComponentsApi instead.
// old
appPlugin.getExtension('api:app/components').override(...)
// new
appPlugin.getExtension('api:app/swappable-components').override(...)
91cbdf4: Log a warning when SwappableComponent extensions are installed outside of using the app plugin
fda1bbc: Default implementations of core components are now provided by this package.
A backwards compatible componentsApi implementation is also provided from this package which uses the SwappableComponentsApi as the implementation. This backwards compatible wrapper will be removed in the future.
9831f4e: Adjusted the dialog API types to have more sensible defaults
Updated dependencies
759568d: BREAKING CHANGE: Removed support for the legacy backend system. This means that the deprecated createRouter and KubernetesBuilder and related types have been removed. Please refer to the relevant documentation to configure the Kubernetes plugin.
BREAKING CHANGE: The deprecated types AuthenticationStrategy, AuthMetadata, ClusterDetails, CustomResource, CustomResourcesByEntity, FetchResponseWrapper, KubernetesBuilder, KubernetesBuilderReturn, KubernetesClustersSupplier, KubernetesCredential, KubernetesEnvironment, KubernetesFetcher, KubernetesObjectsProvider, KubernetesObjectTypes, KubernetesServiceLocator,ObjectFetchParams, ObjectToFetch,RouterOptions and ServiceLocatorRequestContext should all now be imported from @backstage/plugin-kubernetes-node.
express-openapi-validator to 5.5.8 to fix security vulnerability in transitive dependency multercompatWrapper has been switched to use the new SwappableComponentsApi instead of the old ComponentsApi in its bridging to the old frontend system.linkifyjs to 4.3.2.app.packages config setting now that it no longer is experimentalpackages/canon package for knip reports.@davidzemon/passport-okta-oauth to ^0.0.7.1752be6: Attempt to circumvent event listener memory leak in compression middleware
9dd213c: Make the processing hash calculation not care about the order of the processors.
This change does not affect the behavior of the catalog, but it will make the processing hash calculation more robust against changes in the order of processors. This should lead to more stable processing hashes, which in turn should lead to fewer unnecessary reprocessing of entities.
After deploying this fix, you may see a period of increased processing and stitching, but this should stabilize over time as the processing hashes become more consistent.
fa6fa60: Fixed getLocationByEntity to use original_value instead of value when querying search table
Updated dependencies
customProperties type which was preventing it being used to set a list of values against a key (e.g. for multi-select fields)