Affects Version/s: None
Fix Version/s: None
We've been using an older version of Marathon which correctly relays all Mesos status updates associated with a Marathon task through the event bus. I upgraded us to the current version and these updates weren't being sent due to Mesos tasks failing to be matched up with Marathon tasks. It looks like the issue was it was comparing to a task object instead of a task ID string (https://github.com/mesosphere/marathon/pull/35/files#L0L87).
In addition, it seems that only TASK_KILLED events are being relayed due to the order of execution in statusUpdate(), so I reorganized it a little bit. (https://github.com/mesosphere/marathon/pull/35/files#L0R86)
It also appeared that we were possibly querying for tasks before they finished being stored in the datastore, so I surfaced the Future that state.store() returns through TaskTracker's store() and running() methods. This allows running() to fully resolve before attempting to send the Mesos status update notification.
I think this is an okay way to do it and it makes everything work again locally, but let me know if you guys have a better way. Thanks!