org.apache.ignite.internal.processors.cache

## Class DynamicCacheChangeBatch

- java.lang.Object
- - org.apache.ignite.internal.processors.cache.DynamicCacheChangeBatch

All Implemented Interfaces:
  Serializable, DiscoveryCustomMessage

    public class DynamicCacheChangeBatch
    extends Object
    implements DiscoveryCustomMessage

Cache change batch.

See Also:
  Serialized Form

### Constructor Summary

Constructors
Constructor and Description
`DynamicCacheChangeBatch(Collection<DynamicCacheChangeRequest> reqs)`

### Method Summary

All Methods Instance Methods Concrete Methods
`@Nullable DiscoveryCustomMessage` `ackMessage()` Called when custom message has been handled by all nodes.
`DiscoCache` `createDiscoCache(GridDiscoveryManager mgr, AffinityTopologyVersion topVer, DiscoCache discoCache)` Creates new discovery cache if message caused topology version change.
`ExchangeActions` `exchangeActions()`
`boolean` `exchangeNeeded()`
`IgniteUuid` `id()`
`boolean` `isMutable()`
`Collection<DynamicCacheChangeRequest>` `requests()`
`Set<String>` `restartingCaches()`
`DynamicCacheChangeBatch` `restartingCaches(Set<String> restartingCaches)`
`@Nullable ServiceDeploymentActions` `servicesDeploymentActions()`
`void` `servicesDeploymentActions(ServiceDeploymentActions serviceDeploymentActions)`
`boolean` `startCaches()`
`void` `startCaches(boolean startCaches)`
`String` `toString()`

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

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

### Methods inherited from interface org.apache.ignite.internal.managers.discovery.DiscoveryCustomMessage

`stopProcess`

### Constructor Detail

#### DynamicCacheChangeBatch

    public DynamicCacheChangeBatch(Collection<DynamicCacheChangeRequest> reqs)

Parameters:
  `reqs` - Requests.

### Method Detail

#### id

    public IgniteUuid id()

Specified by:
  `id` in interface `DiscoveryCustomMessage`
Returns:
  Unique custom message ID.

#### ackMessage

    @Nullable
    public @Nullable DiscoveryCustomMessage ackMessage()

Called when custom message has been handled by all nodes.

Specified by:
  `ackMessage` in interface `DiscoveryCustomMessage`
Returns:
  Ack message or `null` if ack is not required.

#### isMutable

    public boolean isMutable()

Specified by:
  `isMutable` in interface `DiscoveryCustomMessage`
Returns:
  `True` if message can be modified during listener notification. Changes will be sent to next nodes.

#### createDiscoCache

    public DiscoCache createDiscoCache(GridDiscoveryManager mgr,
                                       AffinityTopologyVersion topVer,
                                       DiscoCache discoCache)

Creates new discovery cache if message caused topology version change.

Specified by:
  `createDiscoCache` in interface `DiscoveryCustomMessage`
Parameters:
  `mgr` - Discovery manager.
  `topVer` - New topology version.
  `discoCache` - Current discovery cache.
Returns:
  Reused discovery cache.

#### requests

    public Collection<DynamicCacheChangeRequest> requests()

Returns:
  Collection of change requests.

#### exchangeNeeded

    public boolean exchangeNeeded()

Returns:
  `True` if request should trigger partition exchange.

#### exchangeActions

    public ExchangeActions exchangeActions()

Returns:
  Cache updates to be executed on exchange.

#### servicesDeploymentActions

    @Nullable
    public @Nullable ServiceDeploymentActions servicesDeploymentActions()

Returns:
  Services deployment actions to be processed on services deployment process.

#### servicesDeploymentActions

    public void servicesDeploymentActions(ServiceDeploymentActions serviceDeploymentActions)

Parameters:
  `serviceDeploymentActions` - Services deployment actions to be processed on services deployment process.

#### startCaches

    public boolean startCaches()

Returns:
  `True` if required to start all caches on client node.

#### restartingCaches

    public DynamicCacheChangeBatch restartingCaches(Set<String> restartingCaches)

Parameters:
  `restartingCaches` - Restarting caches.

#### restartingCaches

    public Set<String> restartingCaches()

Returns:
  Set of restarting caches.

#### startCaches

    public void startCaches(boolean startCaches)

Parameters:
  `startCaches` - `True` if required to start all caches on client node.

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`

${current.year} Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Database and Caching Platform | : ver. 2.14.0
Release Date | : September 29 2022