Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -537,7 +537,7 @@ private FragmentPlan prepareFragment(BaseQueryContext ctx, String jsonFragment)
);

case EXPLAIN:
return executeExplain(qry, (ExplainPlan)plan);
return executeExplain((ExplainPlan)plan);

case DDL:
return executeDdl(qry, (DdlPlan)plan);
Expand Down Expand Up @@ -883,7 +883,7 @@ private IgniteRel authorize(IgniteRel rel, IgniteTable.Operation op) {
}

/** */
private FieldsQueryCursor<List<?>> executeExplain(RootQuery<Row> qry, ExplainPlan plan) {
private FieldsQueryCursor<List<?>> executeExplain(ExplainPlan plan) {
QueryCursorImpl<List<?>> cur = new QueryCursorImpl<>(singletonList(singletonList(plan.plan())));
cur.fieldsMeta(plan.fieldsMeta().queryFieldsMetadata(Commons.typeFactory()));

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,12 @@
import java.util.List;
import java.util.Map;
import java.util.UUID;
import org.apache.ignite.IgniteCheckedException;
import org.apache.ignite.internal.MarshallableMessage;
import org.apache.ignite.internal.Order;
import org.apache.ignite.marshaller.Marshaller;
import org.apache.ignite.plugin.extensions.communication.Message;
import org.jetbrains.annotations.Nullable;

/** */
public class FragmentDescription implements MarshallableMessage {
public class FragmentDescription implements Message {
/** */
@Order(0)
long fragmentId;
Expand All @@ -41,20 +40,22 @@ public class FragmentDescription implements MarshallableMessage {

/** */
@Order(3)
ColocationGroup target;
@Nullable ColocationGroup target;

/** */
public FragmentDescription() {
// No-op.
}

/** */
public FragmentDescription(long fragmentId, FragmentMapping mapping, ColocationGroup target,
public FragmentDescription(long fragmentId, FragmentMapping mapping, @Nullable ColocationGroup target,
Map<Long, List<UUID>> remoteSources) {
this.fragmentId = fragmentId;
this.mapping = mapping;
this.target = target;
this.remoteSources = remoteSources;

if (target != null)
this.target = target.explicitMapping();
}

/** */
Expand All @@ -73,7 +74,7 @@ public List<UUID> nodeIds() {
}

/** */
public ColocationGroup target() {
public @Nullable ColocationGroup target() {
return target;
}

Expand All @@ -96,15 +97,4 @@ public FragmentMapping mapping() {
public void mapping(FragmentMapping mapping) {
this.mapping = mapping;
}

/** */
@Override public void prepareMarshal(Marshaller marsh) throws IgniteCheckedException {
if (target != null)
target = target.explicitMapping();
}

/** */
@Override public void finishUnmarshal(Marshaller marsh, ClassLoader clsLdr) throws IgniteCheckedException {
// No-op.
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@
import org.apache.ignite.internal.processors.query.calcite.rel.IgniteSender;
import org.apache.ignite.internal.util.typedef.F;
import org.apache.ignite.internal.util.typedef.internal.U;
import org.jetbrains.annotations.Nullable;

/**
*
Expand Down Expand Up @@ -72,7 +73,7 @@ public FragmentMapping mapping(Fragment fragment) {
}

/** */
public ColocationGroup target(Fragment fragment) {
public @Nullable ColocationGroup target(Fragment fragment) {
if (fragment.rootFragment())
return null;

Expand Down
Loading