Skip to content

Commit 766a4ed

Browse files
authored
Merge pull request #4428 from LiilyZhang/zhangl/updateAgbotSwagger
Issue #4406 - Documentation: Update swagger json for agbo…
2 parents 89a8d5b + ccbec79 commit 766a4ed

File tree

10 files changed

+943
-22
lines changed

10 files changed

+943
-22
lines changed

agreementbot/secrets/secrets.go

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -56,13 +56,11 @@ type AgbotSecrets interface {
5656
// SecretDetails The key value pair of one secret.
5757
// swagger:model SecretDetails
5858
type SecretDetails struct {
59-
// Key is the name of the secret
60-
//
61-
// required: true
59+
// The name of the secret
60+
// required: true
6261
Key string `json:"key"`
63-
// Value is the value of the secret
64-
//
65-
// required: true
62+
// The value of the secret
63+
// required: true
6664
Value string `json:"value"`
6765
}
6866

businesspolicy/business_policy.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ import (
1212

1313
const DEFAULT_MAX_AGREEMENT = 0
1414

15-
// BusinessPolicy the business policy
15+
// BusinessPolicy is the policy for deploying a service to targeted nodes
1616
type BusinessPolicy struct {
1717
Owner string `json:"owner,omitempty"`
1818
Label string `json:"label"`

compcheck/comp_check.go

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -164,7 +164,7 @@ func NewCompCheckOutput(compatible bool, reason map[string]string, input *CompCh
164164
}
165165
}
166166

167-
// To store the resource (pattern, bp, services etc) used for compatibility check
167+
// The resource that is used for the compatibility check. The resource is a pattern, business policy, service, or other type of resource
168168
type CompCheckResource struct {
169169
NodeId string `json:"node_id,omitempty"`
170170
NodeArch string `json:"node_arch,omitempty"`
@@ -180,11 +180,9 @@ type CompCheckResource struct {
180180
Pattern common.AbstractPatternFile `json:"pattern,omitempty"`
181181
ServicePolicy map[string]externalpolicy.ExternalPolicy `json:"service_policy,omitempty"`
182182
Service []common.AbstractServiceFile `json:"service,omitempty"`
183-
DepServices map[string]exchange.ServiceDefinition `json:"dependent_services,omitempty"` // for internal use for performance. A map of service definition keyed by id.
184-
// It is either empty or provides ALL the dependent services needed. It is expected the top level service definitions are provided
185-
// in the 'Service' attribute when this attribute is not empty.
186-
NeededSB []exchangecommon.SecretBinding `json:"needed_secret_binding,omitempty"`
187-
ExtraneousSB []exchangecommon.SecretBinding `json:"extraneous_secret_binding,omitempty"`
183+
DepServices map[string]exchange.ServiceDefinition `json:"dependent_services,omitempty"` // for internal use for performance. A map of service definition keyed by id. It is either empty or provides ALL the dependent services needed. It is expected the top level service definitions are provided in the 'Service' attribute when this attribute is not empty.
184+
NeededSB []exchangecommon.SecretBinding `json:"needed_secret_binding,omitempty"`
185+
ExtraneousSB []exchangecommon.SecretBinding `json:"extraneous_secret_binding,omitempty"`
188186
}
189187

190188
func (p CompCheckResource) String() string {

0 commit comments

Comments
 (0)