Interface PlanStreamInput
public interface PlanStreamInput
Interface for streams that can serialize plan components. This exists so
ESQL proper can expose streaming capability to ESQL-core. If the world is kind
and just we'll remove this when we flatten everything from ESQL-core into
ESQL proper.
-
Method Summary
Modifier and TypeMethodDescriptionmapNameId(long id) <A extends Attribute>
AreadAttributeWithCache(org.elasticsearch.core.CheckedFunction<StreamInput, A, IOException> constructor) Reads an Attribute using the attribute cache.static StringreadCachedStringWithVersionCheck(StreamInput planStreamInput) <A extends EsField>
AThe query sent by the user to build this plan.
-
Method Details
-
sourceText
String sourceText()The query sent by the user to build this plan. This is used to rebuildSourcewithout sending the query over the wire over and over and over again. -
mapNameId
Translate alonginto aNameId, mapping the samelonginto the sameNameIdeach time. Each newlonggets assigned a unique id to the node, but when the same id is sent in the stream we get the same result.- Throws:
IOException
-
readAttributeWithCache
<A extends Attribute> A readAttributeWithCache(org.elasticsearch.core.CheckedFunction<StreamInput, A, throws IOExceptionIOException> constructor) Reads an Attribute using the attribute cache.- Parameters:
constructor- the constructor needed to build the actual attribute when read from the wire- Returns:
- An attribute; this will generally be the same type as the provided constructor
- Throws:
IOException
-
readEsFieldWithCache
- Throws:
IOException
-
readCachedString
- Throws:
IOException
-
readCachedStringWithVersionCheck
- Throws:
IOException
-
readOptionalCachedString
- Throws:
IOException
-