Skip to content
This repository has been archived by the owner on Jan 30, 2020. It is now read-only.

fleetctl (0.11.5) destroy is not backward compatible #1383

Closed
btalbot opened this issue Oct 21, 2015 · 5 comments · Fixed by #1417
Closed

fleetctl (0.11.5) destroy is not backward compatible #1383

btalbot opened this issue Oct 21, 2015 · 5 comments · Fixed by #1417

Comments

@btalbot
Copy link

btalbot commented Oct 21, 2015

Older versions of fleetctl seems to ignore the request to destroy units which do not actually exist. This was a handy command to use for startup / provisioning / startup scrips to stop and destroy a unit that may or may not actually be loaded.

core@ip-172-11-22-333 ~ $ fleetctl --version
fleetctl version 0.10.2
core@ip-172-11-22-333 ~ $ fleetctl destroy foo
core@ip-172-11-22-333 ~ $ echo $?
0

However, fleetctl 0.11.5 causes destroy show an unhelpful error message and exit with code 1 if the unit is not loaded

core@core-01 ~ $ fleetctl --version
fleetctl version 0.11.5
core@core-01 ~ $ fleetctl destroy fubar
Error destroying units: googleapi: Error 404: unit does not exist
core@core-01 ~ $ echo $?
1

This has now hit the beta channel and broke some of our development and test deployment scripts.

Is the new behavior a regression, bug, or a feature?

@mischief
Copy link
Contributor

this was introduced by 9530eed

@btalbot
Copy link
Author

btalbot commented Oct 21, 2015

Note that other fleetctl commands for units that do not exist do not generate the error message or exit code:

core@core-01 ~ $ fleetctl --version
fleetctl version 0.11.5
core@core-01 ~ $ fleetctl stop fubar; echo $?
0
core@core-01 ~ $ fleetctl unload fubar; echo $?
0

@jonboulle jonboulle added this to the v0.12.0 milestone Jan 19, 2016
tixxdz pushed a commit to endocode/fleet that referenced this issue Feb 1, 2016
fleetctl used to ignore requests to destory units which do not actually exist.
This behaviour was changed by commit 9530eed, restore the older behaviour by calling findUnits()
to get the right list of units.

This fixes: coreos#1383
@tixxdz tixxdz self-assigned this Feb 1, 2016
tixxdz pushed a commit to endocode/fleet that referenced this issue Feb 17, 2016
Do not error out directly if Destroy command fails, check first if the
unit does really exist if no then ignore the destroy error and continue.

Follow-up fix for: coreos#1383
tixxdz pushed a commit to endocode/fleet that referenced this issue Feb 17, 2016
Do not error out directly if Destroy command fails, check first if the
unit does really exist if no then ignore the destroy error and continue.

Follow-up fix for: coreos#1383
kayrus pushed a commit to endocode/fleet that referenced this issue Mar 31, 2016
fleetctl used to ignore requests to destory units which do not actually exist.
This behaviour was changed by commit 9530eed, restore the older behaviour by calling findUnits()
to get the right list of units.

This fixes: coreos#1383
kayrus pushed a commit to endocode/fleet that referenced this issue Mar 31, 2016
fleetctl used to ignore requests to destory units which do not actually exist.
This behaviour was changed by commit 9530eed, restore the older behaviour by calling findUnits()
to get the right list of units.

This fixes: coreos#1383
hectorj2f pushed a commit to giantswarm/fleet that referenced this issue Apr 6, 2016
fleetctl used to ignore requests to destory units which do not actually exist.
This behaviour was changed by commit 9530eed, restore the older behaviour by calling findUnits()
to get the right list of units.

This fixes: coreos#1383
@megahall
Copy link

megahall commented Jul 5, 2016

Would it be possible to backport the fix in #1417 into Fleet v0.11.x or ship a CoreOS which includes Fleet 0.12.x? Because no current version of CoreOS includes Fleet 0.12.x as of yet.

@dongsupark
Copy link
Contributor

@megahall 👍
However this issue is already closed. How about creating a new issue on https://github.com/coreos/bugs/issues, so that other maintainers could easily track it?

@megahall
Copy link

megahall commented Jul 7, 2016

Downstream report filed as coreos/bugs#1448 .

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants