com.bigdata.bop.engine
Interface IChunkMessage<E>

Type Parameters:
E - The generic type of the elements in the chunk (binding sets, elements from a relation, etc).
All Superinterfaces:
IOpMessage, Serializable
All Known Implementing Classes:
EmptyChunkMessage, LocalChunkMessage, NIOChunkMessage, ThickChunkMessage

public interface IChunkMessage<E>
extends IOpMessage

A message describing a chunk of intermediate results which are available for processing. There are several implementations of this interface supporting same-JVM messages, thick RMI messages, and RMI messages where the payload is materialized using NIO transfers from the ResourceService.

See Also:
Optimize serialization for query messages on cluster

Method Summary
 IChunkAccessor<E> getChunkAccessor()
          Return an interface which may be used to access the chunk's data.
 IQueryClient getQueryController()
          Deprecated. This forces us to serialize and send the proxy for the query controller on a cluster. The message format is slimmer if we instead rely on resolution of getQueryControllerId() against a service discovery cache.

We can not discover the query controller using river because it is not registered as a service. We can find the query peers on the data service nodes easily enough because they are all registered with river. However, the QueryEngine serving as the query controller is not currently registered with river and hence it can not be discovered using the UUID of the query controller alone. Probably the right thing to do is to register the query controller with river so it can be discovered. We could then modify getQueryPeer() (or add getQueryClient(UUID)) which would hit the discovery cache.

 UUID getQueryControllerId()
          The UUID of the query controller (the IQueryClient to which the query was submitted).
 int getSolutionCount()
          Return the #of solutions which are available from this message.
 boolean isLastInvocation()
          Return true iff the IChunkMessage is for the last evaluation pass of an operator.
 boolean isMaterialized()
          Return true if the chunk is materialized on the receiver.
 void materialize(FederatedRunningQuery runningQuery)
          Materialize the chunk on the receiver.
 void release()
          Release all resources associated with this chunk.
 
Methods inherited from interface com.bigdata.bop.engine.IOpMessage
getBOpId, getPartitionId, getQueryId
 

Method Detail

getQueryController

IQueryClient getQueryController()
Deprecated. This forces us to serialize and send the proxy for the query controller on a cluster. The message format is slimmer if we instead rely on resolution of getQueryControllerId() against a service discovery cache.

We can not discover the query controller using river because it is not registered as a service. We can find the query peers on the data service nodes easily enough because they are all registered with river. However, the QueryEngine serving as the query controller is not currently registered with river and hence it can not be discovered using the UUID of the query controller alone. Probably the right thing to do is to register the query controller with river so it can be discovered. We could then modify getQueryPeer() (or add getQueryClient(UUID)) which would hit the discovery cache.

The proxy for the query controller.

See Also:
Optimize serialization for query messages on cluster, The query controller should be discoverable

getQueryControllerId

UUID getQueryControllerId()
The UUID of the query controller (the IQueryClient to which the query was submitted).

See Also:
https://sourceforge.net/apps/trac/bigdata/ticket/475

isLastInvocation

boolean isLastInvocation()
Return true iff the IChunkMessage is for the last evaluation pass of an operator. The last evaluation pass for an operator must be requested using an annotation. When it is requested, the operator will be invoked one more time for each node or shard on which it was run (depending on the BOpEvaluationContext). When so invoked, the IChunkMessage will be associated with an empty source and this flag will be set.

See Also:
PipelineOp.Annotations#LAST_PASS

isMaterialized

boolean isMaterialized()
Return true if the chunk is materialized on the receiver.


materialize

void materialize(FederatedRunningQuery runningQuery)
Materialize the chunk on the receiver.

Parameters:
runningQuery - The running query.

release

void release()
Release all resources associated with this chunk. If the source has been opened, then ensure that it is closed. If the data has been materialized, then discard the materialized data.


getChunkAccessor

IChunkAccessor<E> getChunkAccessor()
Return an interface which may be used to access the chunk's data.


getSolutionCount

int getSolutionCount()
Return the #of solutions which are available from this message.



Copyright © 2006-2012 SYSTAP, LLC. All Rights Reserved.