Fixing task v2 specification

* Fixed task specification to support only lists in 'on-complete',
  'on-success' and 'on-error'
* Minor changes

Change-Id: I3c43883a828c0ccb6845328ae0bfafd90c2ac79d