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

Support `--filter mode=global|replicated` for `docker service ls` #31538

Merged
merged 1 commit into from Mar 16, 2017

Conversation

@yongtang
Member

yongtang commented Mar 4, 2017

- What I did
This fix tries to address the request in #31325 by adding --filter mode=global|replicated to docker service ls.

As docker service ls has a MODE column by default, it is natural to support --filter mode=global|replicated for docker service ls.

- How I did it

There are multiple ways to address the issue. One way is to pass the filter of mode to SwarmKit, another way is to process the filter of mode in the daemon.

This fix process the filter in the daemon.

NOTE: Alternatively, we could update SwarmKit to add the mode filter as well. Suggestion is welcomed if other way is preferred.

Related docs has been updated.

- How to verify it

An integration test has been added.

- Description for the changelog

- A picture of a cute animal (not mandatory but encouraged)

siberian-freestyle-list-photo-u1

This fix fixes #31325.

Signed-off-by: Yong Tang yong.tang.github@outlook.com

@allencloud

This comment has been minimized.

Show comment
Hide comment
@allencloud

allencloud Mar 5, 2017

Contributor

I think we still need to update swagger.yml. WDYT? @yongtang

Contributor

allencloud commented Mar 5, 2017

I think we still need to update swagger.yml. WDYT? @yongtang

@yongtang

This comment has been minimized.

Show comment
Hide comment
@yongtang

yongtang Mar 5, 2017

Member

@allencloud The PR has been updated. Thanks.

Member

yongtang commented Mar 5, 2017

@allencloud The PR has been updated. Thanks.

@yongtang

This comment has been minimized.

Show comment
Hide comment
@yongtang

yongtang Mar 6, 2017

Member

@allencloud The swagger.yaml and service_ls.md have been updated. Thanks.

Member

yongtang commented Mar 6, 2017

@allencloud The swagger.yaml and service_ls.md have been updated. Thanks.

@vdemeester

design LGTM 🦁

@AkihiroSuda

LGTM

@thaJeztah

This comment has been minimized.

Show comment
Hide comment
@thaJeztah

thaJeztah Mar 15, 2017

Member

moved to docs review; @yongtang can you add a note to https://github.com/docker/docker/blob/master/docs/api/version-history.md#v128-api-changes to mention that a new filter is accepted by the API? Then I think we're ready to merge 👍

Member

thaJeztah commented Mar 15, 2017

moved to docs review; @yongtang can you add a note to https://github.com/docker/docker/blob/master/docs/api/version-history.md#v128-api-changes to mention that a new filter is accepted by the API? Then I think we're ready to merge 👍

Support `--filter mode=global|replicated` for `docker service ls`
This fix tries to address the request in 31325 by adding
`--filter mode=global|replicated` to `docker service ls`.

As `docker service ls` has a `MODE` column by default, it is natural
to support `--filter mode=global|replicated` for `docker service ls`.

There are multiple ways to address the issue. One way is to pass
the filter of mode to SwarmKit, another way is to process the filter
of mode in the daemon.

This fix process the filter in the daemon.

Related docs has been updated.

An integration test has been added.

This fix fixes 31325.

Signed-off-by: Yong Tang <yong.tang.github@outlook.com>
@yongtang

This comment has been minimized.

Show comment
Hide comment
@yongtang

yongtang Mar 15, 2017

Member

Thanks @thaJeztah for the review and sorry for the late reply. The PR has been updated with doc in api history added.

Member

yongtang commented Mar 15, 2017

Thanks @thaJeztah for the review and sorry for the late reply. The PR has been updated with doc in api history added.

@thaJeztah

LGTM

@thaJeztah

This comment has been minimized.

Show comment
Hide comment
@thaJeztah

thaJeztah Mar 16, 2017

Member

all green

Member

thaJeztah commented Mar 16, 2017

all green

@thaJeztah thaJeztah merged commit b36ce6f into moby:master Mar 16, 2017

6 checks passed

dco-signed All commits are signed
experimental Jenkins build Docker-PRs-experimental 31776 has succeeded
Details
janky Jenkins build Docker-PRs 40397 has succeeded
Details
powerpc Jenkins build Docker-PRs-powerpc 484 has succeeded
Details
windowsRS1 Jenkins build Docker-PRs-WoW-RS1 11473 has succeeded
Details
z Jenkins build Docker-PRs-s390x 374 has succeeded
Details

@GordonTheTurtle GordonTheTurtle added this to the 17.05.0 milestone Mar 16, 2017

@yongtang yongtang deleted the yongtang:31325-service-ls-filter-mode branch Mar 16, 2017

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