-
Notifications
You must be signed in to change notification settings - Fork 114
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[infra-proxy-service] Add Environments gRPC & HTTP API #2985
Conversation
b5e8811
to
e3ea212
Compare
return nil, status.Error(codes.InvalidArgument, err.Error()) | ||
} | ||
|
||
defaultAttributes, _ := json.Marshal(en.DefaultAttributes) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Specific data type to hold DefaultAttributes
data?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Took the reference from NodeAttribute
for dynamic attributes as:
automate/api/external/cfgmgmt/response/nodes.proto
Lines 65 to 72 in 440f656
// Stringified json of the normal attributes for the node. | |
string normal = 5; | |
// Stringified json of the default attributes for the node. | |
string default = 6; | |
// Stringified json of the override attributes for the node. | |
string override = 7; | |
// Stringified json of the automatic attributes for the node. | |
string automatic = 13; |
Signed-off-by: Vivek Singh <[email protected]>
Signed-off-by: Vivek Singh <[email protected]>
e3ea212
to
a9e8431
Compare
string org_id = 1; | ||
// Id of the Server. | ||
string server_id = 2; | ||
// Name of the environment. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
thanks for including the descriptions of the fields!! (the proto comments)
} | ||
|
||
defaultAttributes, _ := json.Marshal(en.DefaultAttributes) | ||
overrideAttributes, _ := json.Marshal(en.OverrideAttributes) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
err check? same comment for a couple lines up too
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sure @vjeffrey thanks for pointing it out!
…al err Signed-off-by: Vivek Singh <[email protected]>
🔩 Description: What code changed, and why?
gRPC API:
HTTP API:
gRPC API:
HTTP API:
⛓️ Related Resources
#1544
👍 Definition of Done
👟 How to Build and Test the Change
rebuild components/infra-proxy-service
rebuild components/automate-gateway
In order to test these features, we can try to curl command to test the API describes in the description.
✅ Checklist
📷 Screenshots, if applicable
Signed-off-by: Vivek Singh [email protected]