Class DistributionMetaData
-
- All Implemented Interfaces:
-
java.io.Externalizable
,java.io.Serializable
,java.lang.Comparable
,org.apache.avro.generic.GenericContainer
,org.apache.avro.generic.GenericRecord
,org.apache.avro.generic.IndexedRecord
,org.apache.avro.specific.SpecificRecord
public class DistributionMetaData extends SpecificRecordBase implements SpecificRecord
Basic information regarding a data distribution package which will be sent over the wire, wrapped into the MembershipPackage and the MembershipSyncRequest.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public class
DistributionMetaData.Builder
RecordBuilder for DistributionMetaData instances.
-
Field Summary
Fields Modifier and Type Field Description public final static Schema
SCHEMA$
public String
syncId
public Instant
syncRequested
-
Constructor Summary
Constructors Constructor Description DistributionMetaData()
Default constructor. DistributionMetaData(String syncId, Instant syncRequested)
All-args constructor.
-
Method Summary
Modifier and Type Method Description String
getSyncId()
Gets the value of the 'syncId' field. void
setSyncId(String value)
Sets the value of the 'syncId' field. Instant
getSyncRequested()
Gets the value of the 'syncRequested' field. void
setSyncRequested(Instant value)
Sets the value of the 'syncRequested' field. static Schema
getClassSchema()
static BinaryMessageEncoder<DistributionMetaData>
getEncoder()
Return the BinaryMessageEncoder instance used by this class. static BinaryMessageDecoder<DistributionMetaData>
getDecoder()
Return the BinaryMessageDecoder instance used by this class. static BinaryMessageDecoder<DistributionMetaData>
createDecoder(SchemaStore resolver)
Create a new BinaryMessageDecoder instance for this class that uses the specified SchemaStore. ByteBuffer
toByteBuffer()
Serializes this DistributionMetaData to a ByteBuffer. static DistributionMetaData
fromByteBuffer(ByteBuffer b)
Deserializes a DistributionMetaData from a ByteBuffer. SpecificData
getSpecificData()
Schema
getSchema()
Object
get(int field$)
Conversion<out Object>
getConversion(int field)
void
put(int field$, Object value$)
static DistributionMetaData.Builder
newBuilder()
Creates a new DistributionMetaData RecordBuilder. static DistributionMetaData.Builder
newBuilder(DistributionMetaData.Builder other)
Creates a new DistributionMetaData RecordBuilder by copying an existing Builder. static DistributionMetaData.Builder
newBuilder(DistributionMetaData other)
Creates a new DistributionMetaData RecordBuilder by copying an existing DistributionMetaData instance. void
writeExternal(ObjectOutput out)
void
readExternal(ObjectInput in)
-
Methods inherited from class org.apache.avro.specific.SpecificRecordBase
compareTo, customDecode, customEncode, equals, hashCode, toString
-
Methods inherited from class org.apache.avro.generic.GenericRecord
hasField
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
DistributionMetaData
DistributionMetaData()
Default constructor.
-
DistributionMetaData
DistributionMetaData(String syncId, Instant syncRequested)
All-args constructor.- Parameters:
syncId
- ID of the sync process, in case of standard distribution type, the syncId will be generated by the MGM.syncRequested
- Time ([Instant]) in milliseconds when the sync was requested.
-
-
Method Detail
-
setSyncId
void setSyncId(String value)
Sets the value of the 'syncId' field. ID of the sync process, in case of standard distribution type, the syncId will be generated by the MGM.
- Parameters:
value
- the value to set.
-
getSyncRequested
Instant getSyncRequested()
Gets the value of the 'syncRequested' field.
-
setSyncRequested
void setSyncRequested(Instant value)
Sets the value of the 'syncRequested' field. Time ([Instant]) in milliseconds when the sync was requested.
- Parameters:
value
- the value to set.
-
getClassSchema
static Schema getClassSchema()
-
getEncoder
static BinaryMessageEncoder<DistributionMetaData> getEncoder()
Return the BinaryMessageEncoder instance used by this class.
-
getDecoder
static BinaryMessageDecoder<DistributionMetaData> getDecoder()
Return the BinaryMessageDecoder instance used by this class.
-
createDecoder
static BinaryMessageDecoder<DistributionMetaData> createDecoder(SchemaStore resolver)
Create a new BinaryMessageDecoder instance for this class that uses the specified SchemaStore.
- Parameters:
resolver
- a SchemaStore used to find schemas by fingerprint
-
toByteBuffer
ByteBuffer toByteBuffer()
Serializes this DistributionMetaData to a ByteBuffer.
-
fromByteBuffer
static DistributionMetaData fromByteBuffer(ByteBuffer b)
Deserializes a DistributionMetaData from a ByteBuffer.
- Parameters:
b
- a byte buffer holding serialized data for an instance of this class
-
getSpecificData
SpecificData getSpecificData()
-
getSchema
Schema getSchema()
-
getConversion
Conversion<out Object> getConversion(int field)
-
newBuilder
static DistributionMetaData.Builder newBuilder()
Creates a new DistributionMetaData RecordBuilder.
-
newBuilder
static DistributionMetaData.Builder newBuilder(DistributionMetaData.Builder other)
Creates a new DistributionMetaData RecordBuilder by copying an existing Builder.
- Parameters:
other
- The existing builder to copy.
-
newBuilder
static DistributionMetaData.Builder newBuilder(DistributionMetaData other)
Creates a new DistributionMetaData RecordBuilder by copying an existing DistributionMetaData instance.
- Parameters:
other
- The existing instance to copy.
-
writeExternal
void writeExternal(ObjectOutput out)
-
readExternal
void readExternal(ObjectInput in)
-
-
-
-