Merge pull request #10199 from backstage/rugvip/present

catalog-client,catalog-backend: removed deprecated presence field
This commit is contained in:
Patrik Oldsberg
2022-03-15 11:45:16 +01:00
committed by GitHub
7 changed files with 13 additions and 13 deletions
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/catalog-client': minor
---
**BREAKING**: Removed the deprecated `presence` field in the `Location` and `AddLocationRequest` types. This field was already being ignored by the catalog backend and can be safely removed.
+5
View File
@@ -0,0 +1,5 @@
---
'@backstage/plugin-catalog-backend': minor
---
**BREAKING**: Removed the deprecated `presence` field from `LocationInput`.
+1 -3
View File
@@ -11,7 +11,6 @@ export type AddLocationRequest = {
type?: string;
target: string;
dryRun?: boolean;
presence?: 'optional' | 'required';
};
// @public
@@ -79,7 +78,7 @@ export class CatalogClient implements CatalogApi {
};
});
addLocation(
{ type, target, dryRun, presence }: AddLocationRequest,
{ type, target, dryRun }: AddLocationRequest,
options?: CatalogRequestOptions,
): Promise<AddLocationResponse>;
getEntities(
@@ -195,7 +194,6 @@ type Location_2 = {
id: string;
type: string;
target: string;
presence?: 'optional' | 'required';
};
export { Location_2 as Location };
```
+2 -2
View File
@@ -272,7 +272,7 @@ export class CatalogClient implements CatalogApi {
* {@inheritdoc CatalogApi.addLocation}
*/
async addLocation(
{ type = 'url', target, dryRun, presence }: AddLocationRequest,
{ type = 'url', target, dryRun }: AddLocationRequest,
options?: CatalogRequestOptions,
): Promise<AddLocationResponse> {
const response = await this.fetchApi.fetch(
@@ -285,7 +285,7 @@ export class CatalogClient implements CatalogApi {
...(options?.token && { Authorization: `Bearer ${options?.token}` }),
},
method: 'POST',
body: JSON.stringify({ type, target, presence }),
body: JSON.stringify({ type, target }),
},
);
-4
View File
@@ -244,8 +244,6 @@ export type Location = {
id: string;
type: string;
target: string;
/** @deprecated This field is is ignored */
presence?: 'optional' | 'required';
};
/**
@@ -257,8 +255,6 @@ export type AddLocationRequest = {
type?: string;
target: string;
dryRun?: boolean;
/** @deprecated This field is is ignored */
presence?: 'optional' | 'required';
};
/**
-2
View File
@@ -595,8 +595,6 @@ export type LocationEntityProcessorOptions = {
// @public
export interface LocationInput {
// @deprecated (undocumented)
presence?: 'optional' | 'required';
// (undocumented)
target: string;
// (undocumented)
@@ -25,8 +25,6 @@ import { Location } from '@backstage/catalog-client';
export interface LocationInput {
type: string;
target: string;
/** @deprecated This field is ignored and will be removed */
presence?: 'optional' | 'required';
}
/**