@Override public void write(DataOutputView out) throws IOException { out.writeShort(this.value); }
@Override public void serialize(Short record, DataOutputView target) throws IOException { target.writeShort(record); }
@Override public void write(DataOutputView out) throws IOException { out.writeShort(this.value); }
@Override public void copy(DataInputView source, DataOutputView target) throws IOException { target.writeShort(source.readShort()); }
@Override public void serialize(short[] record, DataOutputView target) throws IOException { if (record == null) { throw new IllegalArgumentException("The record must not be null."); } final int len = record.length; target.writeInt(len); for (int i = 0; i < len; i++) { target.writeShort(record[i]); } }
@Override public void write(DataOutputView out) throws IOException { out.writeInt(position); for (int i = 0; i < position; i++) { out.writeShort(data[i]); } }
@Override public void copy(DataInputView source, DataOutputView target) throws IOException { target.writeShort(source.readShort()); }
@Override public void write(DataOutputView out) throws IOException { out.writeShort(this.value); }
@Override public void serialize( KafkaTransactionState record, DataOutputView target) throws IOException { if (record.transactionalId == null) { target.writeBoolean(false); } else { target.writeBoolean(true); target.writeUTF(record.transactionalId); } target.writeLong(record.producerId); target.writeShort(record.epoch); }
@Override public void serialize( FlinkKafkaProducer.KafkaTransactionState record, DataOutputView target) throws IOException { if (record.transactionalId == null) { target.writeBoolean(false); } else { target.writeBoolean(true); target.writeUTF(record.transactionalId); } target.writeLong(record.producerId); target.writeShort(record.epoch); }
@Override public void copy( DataInputView source, DataOutputView target) throws IOException { boolean hasTransactionalId = source.readBoolean(); target.writeBoolean(hasTransactionalId); if (hasTransactionalId) { target.writeUTF(source.readUTF()); } target.writeLong(source.readLong()); target.writeShort(source.readShort()); }
@Override public void copy( DataInputView source, DataOutputView target) throws IOException { boolean hasTransactionalId = source.readBoolean(); target.writeBoolean(hasTransactionalId); if (hasTransactionalId) { target.writeUTF(source.readUTF()); } target.writeLong(source.readLong()); target.writeShort(source.readShort()); }
@Override public void write(DataOutputView out) throws IOException { out.writeShort(this.value); }
@Override public void serialize(short[] record, DataOutputView target) throws IOException { if (record == null) { throw new IllegalArgumentException("The record must not be null."); } final int len = record.length; target.writeInt(len); for (int i = 0; i < len; i++) { target.writeShort(record[i]); } }
@Override public void copy(DataInputView source, DataOutputView target) throws IOException { target.writeShort(source.readShort()); }
@Override public void copy(DataInputView source, DataOutputView target) throws IOException { target.writeShort(source.readShort()); }
private void writeStateMetaInfoSnapshots( List<StateMetaInfoSnapshot> snapshots, DataOutputView out) throws IOException { out.writeShort(snapshots.size()); for (StateMetaInfoSnapshot state : snapshots) { StateMetaInfoSnapshotReadersWriters.getWriter().writeStateMetaInfoSnapshot(state, out); } }
@Override public void write(DataOutputView out) throws IOException { super.write(out); out.writeShort(stateMetaInfoSnapshots.size()); for (RegisteredOperatorBackendStateMetaInfo.Snapshot<?> kvState : stateMetaInfoSnapshots) { OperatorBackendStateMetaInfoSnapshotReaderWriters .getWriterForVersion(VERSION, kvState) .writeStateMetaInfo(out); } }
@Override public void write(DataOutputView out) throws IOException { super.write(out); // write the compression format used to write each key-group out.writeBoolean(usingKeyGroupCompression); TypeSerializerSnapshotSerializationUtil.writeSerializerSnapshot(out, keySerializerConfigSnapshot, keySerializer); // write individual registered keyed state metainfos out.writeShort(stateMetaInfoSnapshots.size()); for (StateMetaInfoSnapshot metaInfoSnapshot : stateMetaInfoSnapshots) { StateMetaInfoSnapshotReadersWriters.getWriter().writeStateMetaInfoSnapshot(metaInfoSnapshot, out); } }
@Override public void serialize( KafkaTransactionState record, DataOutputView target) throws IOException { if (record.transactionalId == null) { target.writeBoolean(false); } else { target.writeBoolean(true); target.writeUTF(record.transactionalId); } target.writeLong(record.producerId); target.writeShort(record.epoch); }