private void checkForSharedSourceCommand(AccessNode aNode) { //create a top level key to avoid the full command toString String modelName = aNode.getModelName(); Command cmd = aNode.getCommand(); //don't share full scans against internal sources, it's a waste of buffering if (CoreConstants.SYSTEM_MODEL.equals(modelName) || CoreConstants.SYSTEM_ADMIN_MODEL.equals(modelName) || TempMetadataAdapter.TEMP_MODEL.getName().equals(modelName)) { if (!(cmd instanceof Query)) { return; } Query query = (Query)cmd; if (query.getOrderBy() == null && query.getCriteria() == null) { return; } } AccessNode other = sharedCommands.get(cmd); if (other == null) { sharedCommands.put(cmd, aNode); } else { if (other.info == null) { other.info = new RegisterRequestParameter.SharedAccessInfo(); other.info.id = sharedId.getAndIncrement(); } other.info.sharingCount++; aNode.info = other.info; } }
private void checkForSharedSourceCommand(AccessNode aNode, PlanNode node) { String modelName = aNode.getModelName(); Command cmd = aNode.getCommand();
private void checkForSharedSourceCommand(AccessNode aNode, PlanNode node) { String modelName = aNode.getModelName(); Command cmd = aNode.getCommand();
if (rPlan.getRootNode() instanceof AccessNode) { AccessNode aNode = (AccessNode)rPlan.getRootNode(); String modelName = aNode.getModelName(); command = aNode.getCommand(); SourceCapabilities caps = capabilitiesFinder.findCapabilities(modelName);
@Test public void testConformedJoin() throws Exception { String sql = "select pm1.g1.e1 from pm1.g1, pm2.g2 where g1.e1=g2.e1"; RelationalPlan plan = (RelationalPlan)helpPlan(sql, tm, new String[] {"SELECT g_0.e1 FROM pm1.g1 AS g_0, pm2.g2 AS g_1 WHERE g_0.e1 = g_1.e1"}, ComparisonMode.EXACT_COMMAND_STRING); AccessNode anode = (AccessNode) plan.getRootNode(); assertEquals("pm2", anode.getModelName()); //it should work either way sql = "select pm1.g1.e1 from pm2.g2, pm1.g1 where g1.e1=g2.e1"; plan = (RelationalPlan)helpPlan(sql, tm, new String[] {"SELECT g_1.e1 FROM pm2.g2 AS g_0, pm1.g1 AS g_1 WHERE g_1.e1 = g_0.e1"}, ComparisonMode.EXACT_COMMAND_STRING); anode = (AccessNode) plan.getRootNode(); assertEquals("pm2", anode.getModelName()); }
AccessNode aNode = CriteriaCapabilityValidatorVisitor.getAccessNode(this.processPlan); if (aNode != null) { String modelName = aNode.getModelName(); command = aNode.getCommand(); SourceCapabilities caps = capabilitiesFinder.findCapabilities(modelName);
AccessNode aNode = CriteriaCapabilityValidatorVisitor.getAccessNode(this.processPlan); if (aNode != null) { String modelName = aNode.getModelName(); command = aNode.getCommand(); SourceCapabilities caps = capabilitiesFinder.findCapabilities(modelName);
synchronized (this) { //the description can be obtained asynchly, so we need to synchronize VDBMetaData vdb = getContext().getVdb(); ModelMetaData model = vdb.getModel(getModelName()); List<String> sources = model.getSourceNames(); this.connectorBindingId = (String) getEvaluator(Collections.emptyMap()).evaluate(this.connectorBindingExpression, null); VDBMetaData vdb = getContext().getVdb(); ModelMetaData model = vdb.getModel(getModelName()); List<String> sources = model.getSourceNames(); String replacement = this.connectorBindingId;
synchronized (this) { //the description can be obtained asynchly, so we need to synchronize VDBMetaData vdb = getContext().getVdb(); ModelMetaData model = vdb.getModel(getModelName()); List<String> sources = model.getSourceNames(); this.connectorBindingId = (String) getEvaluator(Collections.emptyMap()).evaluate(this.connectorBindingExpression, null); VDBMetaData vdb = getContext().getVdb(); ModelMetaData model = vdb.getModel(getModelName()); List<String> sources = model.getSourceNames(); String replacement = this.connectorBindingId;
synchronized (this) { //the description can be obtained asynchly, so we need to synchronize VDBMetaData vdb = getContext().getVdb(); ModelMetaData model = vdb.getModel(getModelName()); List<String> sources = model.getSourceNames(); this.connectorBindingId = (String) getEvaluator(Collections.emptyMap()).evaluate(this.connectorBindingExpression, null); VDBMetaData vdb = getContext().getVdb(); ModelMetaData model = vdb.getModel(getModelName()); List<String> sources = model.getSourceNames(); String replacement = this.connectorBindingId;
if (sh != null && aliasGroups) { VDBMetaData vdb = context.getDQPWorkContext().getVDB(); ModelMetaData model = vdb.getModel(aNode.getModelName()); List<String> sourceNames = model.getSourceNames(); SpecificHint sp = null;
if (sh != null && aliasGroups) { VDBMetaData vdb = context.getDQPWorkContext().getVDB(); ModelMetaData model = vdb.getModel(aNode.getModelName()); List<String> sourceNames = model.getSourceNames(); SpecificHint sp = null;
if (sh != null && aliasGroups) { VDBMetaData vdb = context.getDQPWorkContext().getVDB(); ModelMetaData model = vdb.getModel(aNode.getModelName()); List<String> sourceNames = model.getSourceNames(); SpecificHint sp = null;