It may be good to clarify the current process being used for deployments. The process for deployments is as follows:
- Create a sub-batch for the deployment
- Create a high-level service that represents the deployment (parent service)
- Add a sub-batch level dependency on the deployment service created in step 2
Having a high-level service for the deployment allows the deployment to be stopped/started/removed in a single unit based on the the batch level dependency.
There are a couple additions that could be made to the process to add richer failure handling. One would be to add a sub-batch level listener that would watch for service start failures and decide whether to stop the whole deployment or to allow a partial deployment service start. This could then be a user provided configuration to decide how to handle partial starts. The second addition would be to add support to roll-back the services added to the batch if any activation errors occur prior to the batch installation. This could be driven with the same user configuration to allow partial deployments. This would require an API addition to batches in MSC.