Skip to content

Commit b965a25

Browse files
Google APIscopybara-github
authored andcommitted
feat: added support for force field for API and API version deletion
docs: updated proto comments to align with the public documentation Clients can now set the `force` field while sending delete request to allow cascade deletion of resources in the registry. PiperOrigin-RevId: 468760464
1 parent ed55a83 commit b965a25

3 files changed

Lines changed: 110 additions & 102 deletions

File tree

google/cloud/apigeeregistry/v1/provisioning_service.proto

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,7 @@ message Instance {
185185
}
186186

187187
// Format: `projects/*/locations/*/instance`.
188-
// Currently only locations/global is supported.
188+
// Currently only `locations/global` is supported.
189189
string name = 1;
190190

191191
// Output only. Creation timestamp.

google/cloud/apigeeregistry/v1/registry_models.proto

Lines changed: 22 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@ option java_package = "com.google.cloud.apigeeregistry.v1";
2828
option php_namespace = "Google\\Cloud\\ApigeeRegistry\\V1";
2929
option ruby_package = "Google::Cloud::ApigeeRegistry::V1";
3030

31-
// An Api is a top-level description of an API.
32-
// Apis are produced by producers and are commitments to provide services.
31+
// A top-level description of an API.
32+
// Produced by producers and are commitments to provide services.
3333
message Api {
3434
option (google.api.resource) = {
3535
type: "apigeeregistry.googleapis.com/Api"
@@ -53,17 +53,17 @@ message Api {
5353

5454
// A user-definable description of the availability of this service.
5555
// Format: free-form, but we expect single words that describe availability,
56-
// e.g. "NONE", "TESTING", "PREVIEW", "GENERAL", "DEPRECATED", "SHUTDOWN".
56+
// e.g., "NONE", "TESTING", "PREVIEW", "GENERAL", "DEPRECATED", "SHUTDOWN".
5757
string availability = 6;
5858

5959
// The recommended version of the API.
60-
// Format: apis/{api}/versions/{version}
60+
// Format: `apis/{api}/versions/{version}`
6161
string recommended_version = 7 [(google.api.resource_reference) = {
6262
type: "apigeeregistry.googleapis.com/ApiVersion"
6363
}];
6464

6565
// The recommended deployment of the API.
66-
// Format: apis/{api}/deployments/{deployment}
66+
// Format: `apis/{api}/deployments/{deployment}`
6767
string recommended_deployment = 8 [(google.api.resource_reference) = {
6868
type: "apigeeregistry.googleapis.com/ApiDeployment"
6969
}];
@@ -73,13 +73,13 @@ message Api {
7373
//
7474
// Label keys and values can be no longer than 64 characters
7575
// (Unicode codepoints), can only contain lowercase letters, numeric
76-
// characters, underscores and dashes. International characters are allowed.
76+
// characters, underscores, and dashes. International characters are allowed.
7777
// No more than 64 user labels can be associated with one resource (System
7878
// labels are excluded).
7979
//
8080
// See https://goo.gl/xmQnxf for more information and examples of labels.
8181
// System reserved label keys are prefixed with
82-
// "apigeeregistry.googleapis.com/" and cannot be changed.
82+
// `apigeeregistry.googleapis.com/` and cannot be changed.
8383
map<string, string> labels = 9;
8484

8585
// Annotations attach non-identifying metadata to resources.
@@ -90,7 +90,7 @@ message Api {
9090
map<string, string> annotations = 10;
9191
}
9292

93-
// An ApiVersion describes a particular version of an API.
93+
// Describes a particular version of an API.
9494
// ApiVersions are what consumers actually use.
9595
message ApiVersion {
9696
option (google.api.resource) = {
@@ -115,7 +115,7 @@ message ApiVersion {
115115

116116
// A user-definable description of the lifecycle phase of this API version.
117117
// Format: free-form, but we expect single words that describe API maturity,
118-
// e.g. "CONCEPT", "DESIGN", "DEVELOPMENT", "STAGING", "PRODUCTION",
118+
// e.g., "CONCEPT", "DESIGN", "DEVELOPMENT", "STAGING", "PRODUCTION",
119119
// "DEPRECATED", "RETIRED".
120120
string state = 6;
121121

@@ -130,7 +130,7 @@ message ApiVersion {
130130
//
131131
// See https://goo.gl/xmQnxf for more information and examples of labels.
132132
// System reserved label keys are prefixed with
133-
// "apigeeregistry.googleapis.com/" and cannot be changed.
133+
// `apigeeregistry.googleapis.com/` and cannot be changed.
134134
map<string, string> labels = 7;
135135

136136
// Annotations attach non-identifying metadata to resources.
@@ -141,11 +141,11 @@ message ApiVersion {
141141
map<string, string> annotations = 8;
142142
}
143143

144-
// An ApiSpec describes a version of an API in a structured way.
144+
// Describes a version of an API in a structured way.
145145
// ApiSpecs provide formal descriptions that consumers can use to use a version.
146146
// ApiSpec resources are intended to be fully-resolved descriptions of an
147147
// ApiVersion. When specs consist of multiple files, these should be bundled
148-
// together (e.g. in a zip archive) and stored as a unit. Multiple specs can
148+
// together (e.g., in a zip archive) and stored as a unit. Multiple specs can
149149
// exist to provide representations in different API description formats.
150150
// Synchronization of these representations would be provided by tooling and
151151
// background services.
@@ -183,8 +183,8 @@ message ApiSpec {
183183

184184
// A style (format) descriptor for this spec that is specified as a Media Type
185185
// (https://en.wikipedia.org/wiki/Media_type). Possible values include
186-
// "application/vnd.apigee.proto", "application/vnd.apigee.openapi", and
187-
// "application/vnd.apigee.graphql", with possible suffixes representing
186+
// `application/vnd.apigee.proto`, `application/vnd.apigee.openapi`, and
187+
// `application/vnd.apigee.graphql`, with possible suffixes representing
188188
// compression types. These hypothetical names are defined in the vendor tree
189189
// defined in RFC6838 (https://tools.ietf.org/html/rfc6838) and are not final.
190190
// Content types can specify compression. Currently only GZip compression is
@@ -221,7 +221,7 @@ message ApiSpec {
221221
//
222222
// See https://goo.gl/xmQnxf for more information and examples of labels.
223223
// System reserved label keys are prefixed with
224-
// "apigeeregistry.googleapis.com/" and cannot be changed.
224+
// `apigeeregistry.googleapis.com/` and cannot be changed.
225225
map<string, string> labels = 14;
226226

227227
// Annotations attach non-identifying metadata to resources.
@@ -232,7 +232,7 @@ message ApiSpec {
232232
map<string, string> annotations = 15;
233233
}
234234

235-
// An ApiDeployment describes a service running at particular address that
235+
// Describes a service running at particular address that
236236
// provides a particular version of an API. ApiDeployments have revisions which
237237
// correspond to different configurations of a single deployment in time.
238238
// Revision identifiers should be updated whenever the served API spec or
@@ -269,9 +269,9 @@ message ApiDeployment {
269269
// Output only. Last update timestamp: when the represented revision was last modified.
270270
google.protobuf.Timestamp revision_update_time = 7 [(google.api.field_behavior) = OUTPUT_ONLY];
271271

272-
// The full resource name (including revision id) of the spec of the API being
272+
// The full resource name (including revision ID) of the spec of the API being
273273
// served by the deployment. Changes to this value will update the revision.
274-
// Format: apis/{api}/deployments/{deployment}
274+
// Format: `apis/{api}/deployments/{deployment}`
275275
string api_spec_revision = 8 [(google.api.resource_reference) = {
276276
type: "apigeeregistry.googleapis.com/ApiSpec"
277277
}];
@@ -280,7 +280,7 @@ message ApiDeployment {
280280
// update the revision.
281281
string endpoint_uri = 9;
282282

283-
// The address of the external channel of the API (e.g. the Developer
283+
// The address of the external channel of the API (e.g., the Developer
284284
// Portal). Changes to this value will not affect the revision.
285285
string external_channel_uri = 10;
286286

@@ -303,7 +303,7 @@ message ApiDeployment {
303303
//
304304
// See https://goo.gl/xmQnxf for more information and examples of labels.
305305
// System reserved label keys are prefixed with
306-
// "apigeeregistry.googleapis.com/" and cannot be changed.
306+
// `apigeeregistry.googleapis.com/` and cannot be changed.
307307
map<string, string> labels = 14;
308308

309309
// Annotations attach non-identifying metadata to resources.
@@ -318,8 +318,8 @@ message ApiDeployment {
318318
// and are used to store metadata that is too large or numerous to be stored
319319
// directly on the resource. Since artifacts are stored separately from parent
320320
// resources, they should generally be used for metadata that is needed
321-
// infrequently, i.e. not for display in primary views of the resource but
322-
// perhaps displayed or downloaded upon request. The ListArtifacts method
321+
// infrequently, i.e., not for display in primary views of the resource but
322+
// perhaps displayed or downloaded upon request. The `ListArtifacts` method
323323
// allows artifacts to be quickly enumerated and checked for presence without
324324
// downloading their (potentially-large) contents.
325325
message Artifact {

0 commit comments

Comments
 (0)