Skip to content

Commit 0eed50d

Browse files
niket-intcTadeusz Matenkodaniele-moro
authored
Align CustomConfig API with inventy proto (#266)
Co-authored-by: Tadeusz Matenko <tadeusz.matenko@intel.com> Co-authored-by: Daniele Moro <9449199+daniele-moro@users.noreply.github.com>
1 parent 0e5ec4c commit 0eed50d

9 files changed

Lines changed: 333 additions & 333 deletions

File tree

.gitleaksignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,4 @@ inventory/internal/store/host_test.go:generic-api-key:1010
44
inventory/internal/store/host_test.go:generic-api-key:1050
55
apiv2/pkg/api/v2/edge-infrastructure-manager-openapi-server.gen.go:generic-api-key:2555
66
apiv2/pkg/api/v2/edge-infrastructure-manager-openapi-server.gen.go:generic-api-key:2739
7+
apiv2/pkg/api/v2/edge-infrastructure-manager-openapi-server.gen.go:generic-api-key:2707

apiv2/VERSION

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2.1.2
1+
2.1.3

apiv2/api/openapi/openapi.yaml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4022,7 +4022,7 @@ components:
40224022
name:
40234023
type: string
40244024
title: name
4025-
maxLength: 32
4025+
maxLength: 40
40264026
pattern: ^[a-z][a-z0-9-]{0,31}$
40274027
description: Config provided by admin
40284028
description:
@@ -4032,9 +4032,9 @@ components:
40324032
minLength: 1
40334033
pattern: ^$|^[a-zA-Z-_0-9./:;=@?!#,<>*()" ]+$
40344034
description: (OPTIONAL) Config description
4035-
configContent:
4035+
config:
40364036
type: string
4037-
title: config_content
4037+
title: config
40384038
maxLength: 16384
40394039
description: Config content
40404040
timestamps:
@@ -4045,7 +4045,7 @@ components:
40454045
title: CustomConfigResource
40464046
required:
40474047
- name
4048-
- configContent
4048+
- config
40494049
additionalProperties: false
40504050
ProviderKind:
40514051
type: string

apiv2/api/proto/resources/customconfig/v1/customconfig.proto

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ message CustomConfigResource {
2525
string name = 2 [
2626
(buf.validate.field).string = {
2727
pattern: "^[a-z][a-z0-9-]{0,31}$"
28-
max_len: 32
28+
max_len: 40
2929
},
3030
(google.api.field_behavior) = REQUIRED
3131
];
@@ -40,7 +40,7 @@ message CustomConfigResource {
4040
(google.api.field_behavior) = OPTIONAL
4141
];
4242
// Config content
43-
string config_content = 4 [
43+
string config = 4 [
4444
(buf.validate.field).string = {
4545
max_len: 16384
4646
},

apiv2/docs/proto.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -355,7 +355,7 @@ A metadata item, represented by a key:value pair.
355355
| resource_id | [string](#string) | | resource identifier |
356356
| name | [string](#string) | | Config provided by admin |
357357
| description | [string](#string) | | Config description |
358-
| config_content | [string](#string) | | Config content |
358+
| config | [string](#string) | | Config content |
359359
| timestamps | [resources.common.v1.Timestamps](#resources-common-v1-Timestamps) | | Timestamps associated to the resource. |
360360

361361

apiv2/internal/pbapi/resources/customconfig/v1/customconfig.pb.go

Lines changed: 20 additions & 21 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

apiv2/internal/pbapi/resources/customconfig/v1/customconfig_constants.pb.go

Lines changed: 5 additions & 5 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)