Skip to content

Commit

Permalink
Add comments to Space struct members
Browse files Browse the repository at this point in the history
  • Loading branch information
momer committed May 14, 2024
1 parent 71481c4 commit 6bd91f6
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions bonsai/space.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,24 @@ const (
// CloudProvider contains details about the cloud provider and region
// attributes.
type CloudProvider struct {
// A machine-readable name for the cloud provider in which this space is
// deployed.
Provider string `json:"provider"`
Region string `json:"region"`
// A machine-readable name for the geographic region of the server group.
Region string `json:"region"`
}

// Space represents the server groups and geographic regions available to their
// account, where clusters may be provisioned.
type Space struct {
Path string `json:"path"`
PrivateNetwork bool `json:"private_network"`
Cloud CloudProvider `json:"cloud,omitempty"`
// A machine-readable name for the server group.
Path string `json:"path"`
// Indicates whether the space is isolated and inaccessible from the
// public Internet. A VPC connection will be needed to communicate
// with a private cluster.
PrivateNetwork bool `json:"private_network"`
// Details about the cloud provider and region attributes.
Cloud CloudProvider `json:"cloud,omitempty"`

// The geographic region in which the cluster is running.
Region string `json:"region,omitempty"`
Expand Down Expand Up @@ -125,7 +133,7 @@ func (c *SpaceClient) All(ctx context.Context) ([]Space, error) {
return allResults, fmt.Errorf("client.all failed: %w", err)
}

return allResults, err
return allResults, err //nolint:nolintlint
}

//nolint:dupl // Allow duplicated code blocks in code paths that may change
Expand Down

0 comments on commit 6bd91f6

Please sign in to comment.