It is worth noting that either way there are drawbacks:
* If we DO stop all apps, we risk stopping and potentially
destroying data of systems started by Brooklyn -- hurting QoS/reliability
* If we DON'T stop all apps, we risk leaving things running that
people didn't want -- costing money
To me the second one is the lesser of the two evils. If a `kill -9` is
done, or brooklyn is stopped while offline, then the second one will
occur in any case. So I'm in favour of changing the default to "stop
none on shutdown".
We can work to address the problem of things accidentally left running
with the following:
1) Recommend that people shut down Brooklyn via the GUI (where
there are options to shutdown all apps or no apps, currently buried in
"help" but could be promoted with the "server" tab I proposed in my
other email)
2) Run with persistence ON by default
3) Include a GUI view of all locations and the Brooklyn-provisioned
machines there (including tagging those machines created by this
instance of Brooklyn and by other Brooklyn instances)
Best
Alex
On 30/07/2014 07:00, Andrea Turli wrote:
+1
Andrea
Il 30/lug/2014 12:05 "Aled Sage" <[email protected]> ha scritto:
Hi all,
I'd like to change the default behaviour for stopping apps on brooklyn
shutdown.
Currently it is: if persistence is enabled, leave everything running; if
persistence is disabled then only stop those apps started explicitly at the
command line with `--app` (i.e. though subsequently launched from the
catalog are not stopped). This means that their associated VMs are left
running on brooklyn cntrl-c, unless one manually stops each application
first.
There are a number of configurable options via the `--stopOnShutdown`
command line option [1, 2]. I suggest we change the default to
allIfNotPersisted. i.e. "stop all apps IF persistence is not enabled,
otherwise leave all running".
This CLI option was added after 0.7.0-M1 release so there are no backwards
compatibility issues.
Any objections or comments?
Aled
[1] https://github.com/apache/incubator-brooklyn/blob/
master/usage/cli/src/main/java/brooklyn/cli/Main.java#L278-286
[2] https://github.com/apache/incubator-brooklyn/blob/
master/usage/launcher/src/main/java/brooklyn/launcher/config/
StopWhichAppsOnShutdown.java