@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); this.state = ClusterState.readFrom(in, null); }
/** * @param data input bytes * @param localNode used to set the local node in the cluster state. */ public static ClusterState fromBytes(byte[] data, DiscoveryNode localNode, NamedWriteableRegistry registry) throws IOException { StreamInput in = new NamedWriteableAwareStreamInput(StreamInput.wrap(data), registry); return readFrom(in, localNode); } }
@Override public void readFrom(StreamInput in) throws IOException { if (in.getVersion().onOrAfter(Version.V_6_4_0)) { super.readFrom(in); state = ClusterState.readFrom(in, null); explanations = RoutingExplanations.readFrom(in); } else { state = ClusterState.readFrom(in, null); acknowledged = in.readBoolean(); explanations = RoutingExplanations.readFrom(in); } }
@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); clusterName = new ClusterName(in); if (in.getVersion().onOrAfter(Version.V_6_6_0)) { clusterState = in.readOptionalWriteable(innerIn -> ClusterState.readFrom(innerIn, null)); } else { clusterState = ClusterState.readFrom(in, null); } if (in.getVersion().onOrAfter(Version.V_6_0_0_alpha1)) { totalCompressedSize = new ByteSizeValue(in); } else { // in a mixed cluster, if a pre 6.0 node processes the get cluster state // request, then a compressed size won't be returned, so just return 0; // its a temporary situation until all nodes in the cluster have been upgraded, // at which point the correct cluster state size will always be reported totalCompressedSize = new ByteSizeValue(0L); } if (in.getVersion().onOrAfter(Version.V_6_6_0)) { waitForTimedOut = in.readBoolean(); } }
incomingState = ClusterState.readFrom(in, transportService.getLocalNode()); fullClusterStateReceivedCount.incrementAndGet(); logger.debug("received full cluster state version [{}] with size [{}]", incomingState.version(),
/** * @param in input stream * @param localNode used to set the local node in the cluster state. can be null. */ public static ClusterState readFrom(StreamInput in, @Nullable DiscoveryNode localNode) throws IOException { return PROTO.readFrom(in, localNode); }
@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); this.state = ClusterState.readFrom(in, null); }
@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); this.state = ClusterState.readFrom(in, null); }
@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); this.state = ClusterState.readFrom(in, null); }
@Override public ClusterState readFrom(StreamInput in) throws IOException { return readFrom(in, nodes.localNode()); }
/** * @param data input bytes * @param localNode used to set the local node in the cluster state. */ public static ClusterState fromBytes(byte[] data, DiscoveryNode localNode, NamedWriteableRegistry registry) throws IOException { StreamInput in = new NamedWriteableAwareStreamInput(StreamInput.wrap(data), registry); return readFrom(in, localNode); } }
@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); clusterName = new ClusterName(in); clusterState = ClusterState.readFrom(in, null); }
/** * @param data input bytes * @param localNode used to set the local node in the cluster state. */ public static ClusterState fromBytes(byte[] data, DiscoveryNode localNode, NamedWriteableRegistry registry) throws IOException { StreamInput in = new NamedWriteableAwareStreamInput(StreamInput.wrap(data), registry); return readFrom(in, localNode); } }
/** * @param data input bytes * @param localNode used to set the local node in the cluster state. */ public static ClusterState fromBytes(byte[] data, DiscoveryNode localNode, NamedWriteableRegistry registry) throws IOException { StreamInput in = new NamedWriteableAwareStreamInput(StreamInput.wrap(data), registry); return readFrom(in, localNode); } }
@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); state = ClusterState.readFrom(in, null); readAcknowledged(in); explanations = RoutingExplanations.readFrom(in); }
@Override public void readFrom(StreamInput in) throws IOException { if (in.getVersion().onOrAfter(Version.V_6_4_0)) { super.readFrom(in); state = ClusterState.readFrom(in, null); explanations = RoutingExplanations.readFrom(in); } else { state = ClusterState.readFrom(in, null); acknowledged = in.readBoolean(); explanations = RoutingExplanations.readFrom(in); } }
@Override public void readFrom(StreamInput in) throws IOException { if (in.getVersion().onOrAfter(Version.V_6_4_0)) { super.readFrom(in); state = ClusterState.readFrom(in, null); explanations = RoutingExplanations.readFrom(in); } else { state = ClusterState.readFrom(in, null); acknowledged = in.readBoolean(); explanations = RoutingExplanations.readFrom(in); } }
@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); clusterName = new ClusterName(in); clusterState = ClusterState.readFrom(in, null); if (in.getVersion().onOrAfter(Version.V_6_0_0_alpha1)) { totalCompressedSize = new ByteSizeValue(in); } else { // in a mixed cluster, if a pre 6.0 node processes the get cluster state // request, then a compressed size won't be returned, so just return 0; // its a temporary situation until all nodes in the cluster have been upgraded, // at which point the correct cluster state size will always be reported totalCompressedSize = new ByteSizeValue(0L); } }
@Override public void readFrom(StreamInput in) throws IOException { super.readFrom(in); clusterName = new ClusterName(in); clusterState = ClusterState.readFrom(in, null); if (in.getVersion().onOrAfter(Version.V_6_0_0_alpha1)) { totalCompressedSize = new ByteSizeValue(in); } else { // in a mixed cluster, if a pre 6.0 node processes the get cluster state // request, then a compressed size won't be returned, so just return 0; // its a temporary situation until all nodes in the cluster have been upgraded, // at which point the correct cluster state size will always be reported totalCompressedSize = new ByteSizeValue(0L); } }
incomingState = ClusterState.readFrom(in, clusterStateSupplier.get().nodes().getLocalNode()); logger.debug("received full cluster state version [{}] with size [{}]", incomingState.version(), request.bytes().length());