Class StateStoreVersion
java.lang.Object
org.apache.hadoop.hdfs.server.federation.store.records.BaseRecord
org.apache.hadoop.hdfs.server.federation.store.records.StateStoreVersion
- All Implemented Interfaces:
Comparable<BaseRecord>
- Direct Known Subclasses:
StateStoreVersionPBImpl
Entry to track the version of the State Store data stored in the State Store
by a Router.
-
Field Summary
Fields inherited from class org.apache.hadoop.hdfs.server.federation.store.records.BaseRecord
ERROR_MSG_CREATION_TIME_NEGATIVE, ERROR_MSG_MODIFICATION_TIME_NEGATIVE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionlongGet the creation time for the record.longGet the modification time for the record.longGet the expiration time for the record.abstract longabstract longMap of primary key names to values for the record.static StateStoreVersionstatic StateStoreVersionnewInstance(long membershipVersion, long mountTableVersion) voidsetDateCreated(long time) Set the creation time for the record.voidsetDateModified(long time) Set the modification time for the record.abstract voidsetMembershipVersion(long version) abstract voidsetMountTableVersion(long version) toString()Methods inherited from class org.apache.hadoop.hdfs.server.federation.store.records.BaseRecord
checkExpired, compareTo, equals, generateMashupKey, getDeletionMs, getPrimaryKey, hashCode, hasOtherFields, init, isExpired, like, shouldBeDeleted, validate
-
Constructor Details
-
StateStoreVersion
public StateStoreVersion()
-
-
Method Details
-
newInstance
-
newInstance
-
getMembershipVersion
public abstract long getMembershipVersion() -
setMembershipVersion
public abstract void setMembershipVersion(long version) -
getMountTableVersion
public abstract long getMountTableVersion() -
setMountTableVersion
public abstract void setMountTableVersion(long version) -
getPrimaryKeys
Description copied from class:BaseRecordMap of primary key names to values for the record. The primary key can be a combination of 1-n different State Store serialized values.- Specified by:
getPrimaryKeysin classBaseRecord- Returns:
- Map of key/value pairs that constitute this object's primary key.
-
getExpirationMs
public long getExpirationMs()Description copied from class:BaseRecordGet the expiration time for the record.- Specified by:
getExpirationMsin classBaseRecord- Returns:
- Expiration time for the record.
-
setDateModified
public void setDateModified(long time) Description copied from class:BaseRecordSet the modification time for the record.- Specified by:
setDateModifiedin classBaseRecord- Parameters:
time- Modification time of the record.
-
getDateModified
public long getDateModified()Description copied from class:BaseRecordGet the modification time for the record.- Specified by:
getDateModifiedin classBaseRecord- Returns:
- Modification time of the record.
-
setDateCreated
public void setDateCreated(long time) Description copied from class:BaseRecordSet the creation time for the record.- Specified by:
setDateCreatedin classBaseRecord- Parameters:
time- Creation time of the record.
-
getDateCreated
public long getDateCreated()Description copied from class:BaseRecordGet the creation time for the record.- Specified by:
getDateCreatedin classBaseRecord- Returns:
- Creation time of the record
-
toString
- Overrides:
toStringin classBaseRecord
-