Updated according to Tobi's comments.

Cleaned up code, default GROUP_BY operator to a value of 2 if no value
specified.
App endpoints should block.

For the start/stop app endpoints, it makes sense to block while awaiting
a result.  The previous behaviour was to always return success, which is
confusing.  To make matters worse, Marathon would start tasks before the
app state is stored, resulting in phantom tasks.