From: <tho...@us...> - 2013-12-24 00:33:36
|
Revision: 7692 http://bigdata.svn.sourceforge.net/bigdata/?rev=7692&view=rev Author: thompsonbry Date: 2013-12-24 00:33:28 +0000 (Tue, 24 Dec 2013) Log Message: ----------- Linked the parent query and the RTO subquery. Removed the EndOp from the RTO subquery. RTO is running (for simple queries). Modified Paths: -------------- branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/PartitionedJoinGroup.java branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/rto/JoinGraph.java Modified: branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/PartitionedJoinGroup.java =================================================================== --- branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/PartitionedJoinGroup.java 2013-12-23 22:45:36 UTC (rev 7691) +++ branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/PartitionedJoinGroup.java 2013-12-24 00:33:28 UTC (rev 7692) @@ -1143,14 +1143,14 @@ * * [This should perhaps be moved into the caller.] */ - lastOp = new EndOp(new BOp[] { lastOp }, NV - .asMap(new NV[] { - new NV(JoinGraph.Annotations.BOP_ID, idFactory.nextId()), // - new NV(JoinGraph.Annotations.EVALUATION_CONTEXT, - BOpEvaluationContext.CONTROLLER)// -// new NV(PipelineOp.Annotations.SHARED_STATE,true),// - }) // - ); +// lastOp = new EndOp(new BOp[] { lastOp }, NV +// .asMap(new NV[] { +// new NV(JoinGraph.Annotations.BOP_ID, idFactory.nextId()), // +// new NV(JoinGraph.Annotations.EVALUATION_CONTEXT, +// BOpEvaluationContext.CONTROLLER)// +//// new NV(PipelineOp.Annotations.SHARED_STATE,true),// +// }) // +// ); return lastOp; Modified: branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/rto/JoinGraph.java =================================================================== --- branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/rto/JoinGraph.java 2013-12-23 22:45:36 UTC (rev 7691) +++ branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/rto/JoinGraph.java 2013-12-24 00:33:28 UTC (rev 7692) @@ -44,6 +44,7 @@ import com.bigdata.bop.ap.SampleIndex; import com.bigdata.bop.ap.SampleIndex.SampleType; import com.bigdata.bop.controller.AbstractSubqueryOp; +import com.bigdata.bop.engine.AbstractRunningQuery; import com.bigdata.bop.engine.IRunningQuery; import com.bigdata.bop.engine.QueryEngine; import com.bigdata.bop.joinGraph.PartitionedJoinGroup; @@ -304,6 +305,7 @@ final BOpIdFactory idFactory = new BOpIdFactory(); // Generate the query from the join path. + // FIXME Update this using StaticAnalysis logic. final PipelineOp queryOp = PartitionedJoinGroup.getQuery(idFactory, false/* distinct */, getSelected(), p.getPredicates(), getConstraints()); @@ -361,12 +363,16 @@ ICloseableIterator<IBindingSet[]> subquerySolutionItr = null; - final IRunningQuery runningQuery = queryEngine.eval(queryOp); + final IRunningQuery runningSubquery = queryEngine.eval(queryOp); try { + // Declare the child query to the parent. + ((AbstractRunningQuery) parentContext.getRunningQuery()) + .addChild(runningSubquery); + // Iterator visiting the subquery solutions. - subquerySolutionItr = runningQuery.iterator(); + subquerySolutionItr = runningSubquery.iterator(); // Copy solutions from the subquery to the query. final long nout = BOpUtility.copy(subquerySolutionItr, @@ -377,7 +383,7 @@ // System.out.println("nout=" + nout); // verify no problems. - runningQuery.get(); + runningSubquery.get(); // System.out.println("Future Ok"); @@ -400,7 +406,7 @@ } finally { - runningQuery.cancel(true/* mayInterruptIfRunning */); + runningSubquery.cancel(true/* mayInterruptIfRunning */); if (subquerySolutionItr != null) subquerySolutionItr.close(); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |
From: <tho...@us...> - 2014-01-14 12:46:06
|
Revision: 7789 http://bigdata.svn.sourceforge.net/bigdata/?rev=7789&view=rev Author: thompsonbry Date: 2014-01-14 12:45:59 +0000 (Tue, 14 Jan 2014) Log Message: ----------- javadoc on NoSolutionsException. Showing the paths table if there is cardinality underflow to analyze query41.rq behavior with the RTO. Modified Paths: -------------- branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/NoSolutionsException.java branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/rto/JGraph.java Modified: branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/NoSolutionsException.java =================================================================== --- branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/NoSolutionsException.java 2014-01-14 00:31:41 UTC (rev 7788) +++ branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/NoSolutionsException.java 2014-01-14 12:45:59 UTC (rev 7789) @@ -1,8 +1,33 @@ +/** + +Copyright (C) SYSTAP, LLC 2006-2007. All rights reserved. + +Contact: + SYSTAP, LLC + 4501 Tower Road + Greensboro, NC 27410 + lic...@bi... + +This program is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; version 2 of the License. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with this program; if not, write to the Free Software +Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +*/ package com.bigdata.bop.joinGraph; /** - * Exception thrown when the join graph does not have any solutions in the - * data (running the query does not produce any results). + * Exception thrown when the join graph does not have any solutions in the data + * (running the cutoff joins to explore the join graph does not produce any + * solutions such that we can not complete a path through the join graph without + * a zero cardinality). */ public class NoSolutionsException extends RuntimeException { Modified: branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/rto/JGraph.java =================================================================== --- branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/rto/JGraph.java 2014-01-14 00:31:41 UTC (rev 7788) +++ branches/BIGDATA_RELEASE_1_3_0/bigdata/src/java/com/bigdata/bop/joinGraph/rto/JGraph.java 2014-01-14 12:45:59 UTC (rev 7789) @@ -544,7 +544,8 @@ log.warn("Cardinality estimate underflow - resampling: round=" + round + ", npaths=" + paths.length + ", nunderflow=" - + nunderflow + ", limit=" + limit); + + nunderflow + ", limit=" + limit + "\n" + + showTable(paths)); } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |