Skip to content
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

improve output of oc idle #12718

Merged

Conversation

juanvallejo
Copy link
Contributor

@juanvallejo juanvallejo commented Jan 30, 2017

Related bugzilla: https://bugzilla.redhat.com/show_bug.cgi?id=1402356

Improves the output of oc idle when idling a service with one or more scalable refs, no scalable refs (or a service that has already been idled), and when idling a service with the --dry-run flag.

Before

$ oc idle database
Marked service test-oc-idle/database to unidle resource DeploymentConfig test-oc-idle/database (unidle to 1 replicas)
Idled DeploymentConfig test-oc-idle/database

# idle a svc that has already been marked as idled
$ oc idle database
error: no scalable resources marked as idled for service test-oc-idle/database, not marking as idled

# with --dry-run, the (dry run) text did not appear if the service was already idled
$ oc idle database --dry-run
Marked service test-oc-idle/database to unidle resource DeploymentConfig test-oc-idle/database (unidle to 1 replicas)

After

$ oc idle database
The service "test-oc-idle/database" has been marked as idled
The service will unidle DeploymentConfig "test-oc-idle/database" to 1 replicas once it receives traffic
DeploymentConfig "test-oc-idle/database" has been idled

$ oc idle database
error: unable to mark the service "test-oc-idle/database" as idled.
Make sure that the service is not already marked as idled, and that it is associated with resources that can be scaled.
See 'oc idle -h' for help and examples.

$ oc idle database --dry-run
The service "test-oc-idle/database" has been marked as idled (dry run)
The service will unidle DeploymentConfig "test-oc-idle/database" to 1 replicas once it receives traffic (dry run)

cc @fabianofranz @DirectXMan12 @openshift/cli-review

@juanvallejo
Copy link
Contributor Author

[test]

@juanvallejo juanvallejo force-pushed the jvallejo/improve-oc-idle-output branch 3 times, most recently from d9bdeb9 to 0d26834 Compare January 31, 2017 19:09
Copy link
Contributor

@DirectXMan12 DirectXMan12 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@juanvallejo juanvallejo force-pushed the jvallejo/improve-oc-idle-output branch from 0d26834 to fce85cd Compare February 1, 2017 15:56
@juanvallejo juanvallejo force-pushed the jvallejo/improve-oc-idle-output branch from fce85cd to 9575d79 Compare February 1, 2017 16:18
@openshift-bot
Copy link
Contributor

Evaluated for origin test up to 9575d79

@openshift-bot
Copy link
Contributor

continuous-integration/openshift-jenkins/test SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pr_origin/13479/) (Base Commit: 92ce2c9)

@fabianofranz
Copy link
Member

[merge]

@fabianofranz
Copy link
Member

flaked on #12784 (comment) re[merge]

@openshift-bot
Copy link
Contributor

Evaluated for origin merge up to 9575d79

@openshift-bot
Copy link
Contributor

openshift-bot commented Feb 15, 2017

continuous-integration/openshift-jenkins/merge SUCCESS (https://ci.openshift.redhat.com/jenkins/job/test_pull_requests_origin_future/239/) (Base Commit: c8e60fe) (Image: devenv-rhel7_5920)

@openshift-bot openshift-bot merged commit a0ea9b5 into openshift:master Feb 15, 2017
@juanvallejo juanvallejo deleted the jvallejo/improve-oc-idle-output branch February 15, 2017 21:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants