private void deploy(final String accountId, final String appId , Location archive) throws Exception {
try {
Id.Account id = Id.Account.from(accountId);
Location archiveLocation = archive;
Manager<Location, ApplicationWithPrograms> manager = managerFactory.create(new ProgramTerminator() {
@Override
public void stop(Id.Account id, Id.Program programId, ProgramType type) throws ExecutionException {
deleteHandler(programId, type);
}
});