catalog-backend: switch default orphanProviderStrategy to 'delete'

Signed-off-by: Patrik Oldsberg <poldsberg@gmail.com>
This commit is contained in:
Patrik Oldsberg
2025-07-15 15:46:53 +02:00
parent 687bfc826e
commit 5de7a9d119
3 changed files with 7 additions and 4 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-catalog-backend': major
---
**BREAKING**: The default `catalog.orphanProviderStrategy` has been switched to `'delete'`.
+1 -1
View File
@@ -167,7 +167,7 @@ export interface Config {
/**
* The strategy to use for entities that are referenced by providers that are orphaned,
* i.e. entities with no providers currently configured in the catalog. The default value is
* "keep".
* "delete".
*/
orphanProviderStrategy?: 'keep' | 'delete';
@@ -622,9 +622,7 @@ export class CatalogBuilder {
enableRelationsCompatibility,
});
if (
config.getOptionalString('catalog.orphanProviderStrategy') === 'delete'
) {
if (config.getOptionalString('catalog.orphanProviderStrategy') !== 'keep') {
await evictEntitiesFromOrphanedProviders({
db: providerDatabase,
providers: entityProviders,