Skip to content

Remove redundant query parameters from API surface #128

@borland

Description

@borland

Example:

ProjectsQuery in the library has this shape:

type ProjectsQuery struct {
	ClonedFromProjectID string   `url:"clonedFromProjectId"`
	IDs                 []string `uri:"ids,omitempty" url:"ids,omitempty"`
	IsClone             bool     `uri:"clone,omitempty" url:"clone,omitempty"`
	Name                string   `uri:"name,omitempty" url:"name,omitempty"`
	PartialName         string   `uri:"partialName,omitempty" url:"partialName,omitempty"`
	Skip                int      `uri:"skip,omitempty" url:"skip,omitempty"`
	Take                int      `uri:"take,omitempty" url:"take,omitempty"`
}

Note the presence of both Name and PartialName.
To a casual observer, Name implies an exact name match -- however in practice the Octopus Server treats them both as a partial match.

I.e. given a project "Integrations", Query for {Name: "gr"} will find it. This is legacy behaviour in the server, and to avoid confusion we should remove the Name field from ProjectsQuery.

As part of this work, we should sweep the library's API surface and remove any other similarly redundant fields if there are others beyond Project Name

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions