org.apache.ignite.internal.processors.igfs

## Class IgfsColocatedMetadataAffinityKeyMapper

- java.lang.Object
- - org.apache.ignite.internal.processors.igfs.IgfsColocatedMetadataAffinityKeyMapper

All Implemented Interfaces:
  Serializable, AffinityKeyMapper

    public class IgfsColocatedMetadataAffinityKeyMapper
    extends Object
    implements AffinityKeyMapper

Special implementation of affinity mapper which maps all metadata to the same primary.

See Also:
  Serialized Form

### Constructor Summary

Constructors
Constructor and Description
`IgfsColocatedMetadataAffinityKeyMapper()`

### Method Summary

All Methods Instance Methods Concrete Methods
`Object` `affinityKey(Object key)` Maps passed in key to an alternate key which will be used for node affinity.
`void` `reset()` Resets cache affinity mapper to its initial state.
`String` `toString()`

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

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

### Constructor Detail

#### IgfsColocatedMetadataAffinityKeyMapper

    public IgfsColocatedMetadataAffinityKeyMapper()

### Method Detail

#### affinityKey

    public Object affinityKey(Object key)

Maps passed in key to an alternate key which will be used for node affinity.

Specified by:
  `affinityKey` in interface `AffinityKeyMapper`
Parameters:
  `key` - Key to map.
Returns:
  Key to be used for node-to-affinity mapping (may be the same key as passed in).

#### reset

    public void reset()

Resets cache affinity mapper to its initial state. This method will be called by the system any time the affinity mapper has been sent to remote node where it has to be reinitialized. If your implementation of affinity mapper has no initialization logic, leave this method empty.

Specified by:
  `reset` in interface `AffinityKeyMapper`

#### toString

    public String toString()

Overrides:
  `toString` in class `Object`

2018 Copyright © Apache Software Foundation

Follow @ApacheIgnite

Ignite Database and Caching Platform | : ver. 2.7.5
Release Date | : June 4 2019