org.apache.ignite.internal.processors.service

## Class GridServiceDeploymentCompoundFuture<T extends Serializable>

- java.lang.Object
- - org.apache.ignite.internal.util.future.GridFutureAdapter<R>
  - - org.apache.ignite.internal.util.future.GridCompoundFuture<Object,Object>
    - - org.apache.ignite.internal.processors.service.GridServiceDeploymentCompoundFuture<T>

All Implemented Interfaces:
  Serializable, IgniteInternalFuture<Object>, IgniteInClosure<IgniteInternalFuture<Object>>

    public class GridServiceDeploymentCompoundFuture<T extends Serializable>
    extends GridCompoundFuture<Object,Object>

Service deployment compound future. If any exceptions are thrown during deployment, then `IgniteCheckedException` with `ServiceDeploymentException` as a cause will be thrown from `get()` method after all futures complete or fail. Inner exception will contain configurations of failed services.

See Also:
  Serialized Form

### Constructor Summary

Constructors
Constructor and Description
`GridServiceDeploymentCompoundFuture()`

### Method Summary

All Methods Instance Methods Concrete Methods
`void` `add(GridServiceDeploymentFuture<T> fut, boolean own)`
`protected boolean` `onDone(@Nullable Object res, @Nullable Throwable err, boolean cancel)`
`protected boolean` `processFailure(Throwable err, IgniteInternalFuture<Object> fut)` Processes error thrown by some of the inner futures.
`Collection<T>` `servicesToRollback()`

### Methods inherited from class org.apache.ignite.internal.util.future.GridCompoundFuture

`add, apply, cancel, clear, future, futures, futuresCountNoLock, hasFutures, hasPending, ignoreFailure, initialized, logDebug, logError, markInitialized, toString`

### Methods inherited from class org.apache.ignite.internal.util.future.GridFutureAdapter

`chain, chain, error, get, get, get, getUninterruptibly, ignoreInterrupts, isCancelled, isDone, isFailed, listen, logger, onCancelled, onDone, onDone, onDone, onDone, reset, result`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

### Constructor Detail

#### GridServiceDeploymentCompoundFuture

    public GridServiceDeploymentCompoundFuture()

### Method Detail

#### processFailure

    protected boolean processFailure(Throwable err,
                                     IgniteInternalFuture<Object> fut)

Processes error thrown by some of the inner futures.

Overrides:
  `processFailure` in class `GridCompoundFuture<Object,Object>`
Parameters:
  `err` - Thrown exception.
  `fut` - Failed future.
Returns:
  `True` if this error should be ignored.

#### onDone

    protected boolean onDone(@Nullable
                             @Nullable Object res,
                             @Nullable
                             @Nullable Throwable err,
                             boolean cancel)

Overrides:
  `onDone` in class `GridFutureAdapter<Object>`
Parameters:
  `res` - Result.
  `err` - Error.
  `cancel` - `True` if future is being cancelled.
Returns:
  `True` if result was set by this call.

#### add

    public void add(GridServiceDeploymentFuture<T> fut,
                    boolean own)

Parameters:
  `fut` - Child future.
  `own` - If `true`, then corresponding service will be cancelled on failure.

#### servicesToRollback

    public Collection<T> servicesToRollback()

Returns:
  Collection of ids of services that were written to cache during current deployment.

${current.year} Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Database and Caching Platform | : ver. 2.11.0
Release Date | : September 11 2021