Skip to content

Improve usability of Project & Service objects #305

Open
@milas

Description

@milas

Description

The Project and Service objects returned by this library often
confuse users because certain fields are not always initialized.

For example, CustomLabels (a map[string]string) will be nil
on each Service.

Potential Solutions

  • Add NewProject and NewService constructors that initialize
    all fields consistently
  • Add helper methods, e.g. AddCustomLabel that internally handle
    initialization lazily

Related Issues

docker/compose#9808

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions