From 069cda35f43c1a775e98d07bf548eccb1d075821 Mon Sep 17 00:00:00 2001 From: Oliver Sand Date: Wed, 25 Nov 2020 16:21:08 +0100 Subject: [PATCH] Deprecate implementsApis --- .changeset/short-singers-serve.md | 15 +++++++++++++++ .../software-catalog/descriptor-format.md | 8 ++++++-- .../src/kinds/ComponentEntityV1alpha1.ts | 5 +++++ 3 files changed, 26 insertions(+), 2 deletions(-) create mode 100644 .changeset/short-singers-serve.md diff --git a/.changeset/short-singers-serve.md b/.changeset/short-singers-serve.md new file mode 100644 index 0000000000..ae8e8d171c --- /dev/null +++ b/.changeset/short-singers-serve.md @@ -0,0 +1,15 @@ +--- +'@backstage/catalog-model': patch +--- + +Marked the field `spec.implementsApis` on `Component` entities for deprecation on Dec 14th, 2020. + +Code that consumes these fields should remove those usages as soon as possible as migrate to using +relations instead. Producers should fill the field `spec.providesApis` instead, which has the same +semantic. + +After Dec 14th, the fields will be removed from types and classes of the Backstage repository. At +the first release after that, they will not be present in released packages either. + +If your catalog-info.yaml files still contain this fields after the deletion, they will still be +valid and your ingestion will not break, but they won't be visible in the types for consuming code. diff --git a/docs/features/software-catalog/descriptor-format.md b/docs/features/software-catalog/descriptor-format.md index c86be1be83..438f874990 100644 --- a/docs/features/software-catalog/descriptor-format.md +++ b/docs/features/software-catalog/descriptor-format.md @@ -445,14 +445,18 @@ group of people in an organizational structure. ### `spec.implementsApis` [optional] +**NOTE**: This field was marked for deprecation on Nov 25nd, 2020. It will be +removed entirely from the model on Dec 14th, 2020 in the repository and will not +be present in released packages following the next release after that. Please +update your code to not consume this field before the removal date. + Links APIs that are implemented by the component, e.g. `artist-api`. This field is optional. The software catalog expects a list of one or more strings that references the names of other entities of the `kind` `API`. -This field has the same behavior as `spec.providesApis` and will be deprecated -in the future. +This field has the same behavior as `spec.providesApis`. ### `spec.providesApis` [optional] diff --git a/packages/catalog-model/src/kinds/ComponentEntityV1alpha1.ts b/packages/catalog-model/src/kinds/ComponentEntityV1alpha1.ts index 97c9140e61..5fd4f88537 100644 --- a/packages/catalog-model/src/kinds/ComponentEntityV1alpha1.ts +++ b/packages/catalog-model/src/kinds/ComponentEntityV1alpha1.ts @@ -52,6 +52,11 @@ export interface ComponentEntityV1alpha1 extends Entity { type: string; lifecycle: string; owner: string; + /** + * @deprecated This field will disappear on Dec 14th, 2020. Please remove + * any consuming code. The new field providesApis provides the + * same functionality like before. + */ implementsApis?: string[]; providesApis?: string[]; consumesApis?: string[];