/** * Writes shard information to {@link StreamOutput} without writing index name and shard id * * @param out {@link StreamOutput} to write shard information to * @throws IOException if something happens during write */ public void writeToThin(StreamOutput out) throws IOException { out.writeOptionalString(currentNodeId); out.writeOptionalString(relocatingNodeId); out.writeBoolean(primary); out.writeByte(state.value()); if (state == ShardRoutingState.UNASSIGNED || state == ShardRoutingState.INITIALIZING) { recoverySource.writeTo(out); } out.writeOptionalWriteable(unassignedInfo); out.writeOptionalWriteable(allocationId); if (state == ShardRoutingState.RELOCATING || state == ShardRoutingState.INITIALIZING) { out.writeLong(expectedShardSize); } }
@Override public void writeTo(StreamOutput out) throws IOException { timer.writeTo(out); out.writeByte(stage.id()); shardId.writeTo(out); recoverySource.writeTo(out); targetNode.writeTo(out); out.writeOptionalWriteable(sourceNode); index.writeTo(out); translog.writeTo(out); verifyIndex.writeTo(out); out.writeBoolean(primary); }
@Override public void writeTo(StreamOutput out) throws IOException { timer.writeTo(out); out.writeByte(stage.id()); shardId.writeTo(out); recoverySource.writeTo(out); targetNode.writeTo(out); out.writeOptionalWriteable(sourceNode); index.writeTo(out); translog.writeTo(out); verifyIndex.writeTo(out); out.writeBoolean(primary); }
/** * Writes shard information to {@link StreamOutput} without writing index name and shard id * * @param out {@link StreamOutput} to write shard information to * @throws IOException if something happens during write */ public void writeToThin(StreamOutput out) throws IOException { out.writeOptionalString(currentNodeId); out.writeOptionalString(relocatingNodeId); out.writeBoolean(primary); out.writeByte(state.value()); if (state == ShardRoutingState.UNASSIGNED || state == ShardRoutingState.INITIALIZING) { recoverySource.writeTo(out); } out.writeOptionalWriteable(unassignedInfo); out.writeOptionalWriteable(allocationId); if (state == ShardRoutingState.RELOCATING || state == ShardRoutingState.INITIALIZING) { out.writeLong(expectedShardSize); } }
/** * Writes shard information to {@link StreamOutput} without writing index name and shard id * * @param out {@link StreamOutput} to write shard information to * @throws IOException if something happens during write */ public void writeToThin(StreamOutput out) throws IOException { out.writeOptionalString(currentNodeId); out.writeOptionalString(relocatingNodeId); out.writeBoolean(primary); out.writeByte(state.value()); if (state == ShardRoutingState.UNASSIGNED || state == ShardRoutingState.INITIALIZING) { recoverySource.writeTo(out); } out.writeOptionalWriteable(unassignedInfo); out.writeOptionalWriteable(allocationId); if (state == ShardRoutingState.RELOCATING || state == ShardRoutingState.INITIALIZING) { out.writeLong(expectedShardSize); } }
/** * Writes shard information to {@link StreamOutput} without writing index name and shard id * * @param out {@link StreamOutput} to write shard information to * @throws IOException if something happens during write */ public void writeToThin(StreamOutput out) throws IOException { out.writeOptionalString(currentNodeId); out.writeOptionalString(relocatingNodeId); out.writeBoolean(primary); out.writeByte(state.value()); if (state == ShardRoutingState.UNASSIGNED || state == ShardRoutingState.INITIALIZING) { recoverySource.writeTo(out); } out.writeOptionalWriteable(unassignedInfo); out.writeOptionalWriteable(allocationId); if (state == ShardRoutingState.RELOCATING || state == ShardRoutingState.INITIALIZING) { out.writeLong(expectedShardSize); } }
@Override public void writeTo(StreamOutput out) throws IOException { timer.writeTo(out); out.writeByte(stage.id()); shardId.writeTo(out); recoverySource.writeTo(out); targetNode.writeTo(out); out.writeOptionalWriteable(sourceNode); index.writeTo(out); translog.writeTo(out); verifyIndex.writeTo(out); out.writeBoolean(primary); }
@Override public void writeTo(StreamOutput out) throws IOException { timer.writeTo(out); out.writeByte(stage.id()); shardId.writeTo(out); recoverySource.writeTo(out); targetNode.writeTo(out); out.writeOptionalWriteable(sourceNode); index.writeTo(out); translog.writeTo(out); verifyIndex.writeTo(out); out.writeBoolean(primary); }