private LensConf getLensConf(XJob job, SchedulerJobInstanceHandle instanceHandle, DateTime scheduledTime) { List<MapType> jobConf = job.getExecution().getQuery().getConf(); LensConf queryConf = new LensConf(); for (MapType element : jobConf) { queryConf.addProperty(element.getKey(), element.getValue()); } queryConf.addProperty(JOB_INSTANCE_ID_KEY, instanceHandle.getHandleId()); // Current time is used for resolving date. queryConf.addProperty(LensConfConstants.QUERY_CURRENT_TIME_IN_MILLIS, scheduledTime.getMillis()); return queryConf; }
private void checkQuery(LensSessionHandle sessionHandle, XJob job) throws LensException { List<MapType> jobConf = job.getExecution().getQuery().getConf(); LensConf queryConf = new LensConf(); for (MapType element : jobConf) { queryConf.addProperty(element.getKey(), element.getValue()); } queryConf.addProperty(CubeQueryConfUtil.FAIL_QUERY_ON_PARTIAL_DATA, false); queryService.estimate(LensServices.get().getLogSegregationContext().getLogSegragationId(), sessionHandle, job.getExecution().getQuery().getQuery(), queryConf); }
private void setSessionConf(LensSessionHandle sessionHandle, XJob job) throws LensException { XExecution execution = job.getExecution(); XSessionType executionSession = execution.getSession(); cubeMetastoreService.setCurrentDatabase(sessionHandle, executionSession.getDb()); List<MapType> sessionConfList = executionSession.getConf(); for (MapType element : sessionConfList) { sessionService.setSessionParameter(sessionHandle, element.getKey(), element.getValue()); } List<ResourcePath> resourceList = executionSession.getResourcePath(); for (ResourcePath path : resourceList) { sessionService.addResource(sessionHandle, path.getType(), path.getPath()); } }
theExecution = this.getExecution(); strategy.appendField(locator, this, "execution", buffer, theExecution);
theExecution = this.getExecution(); strategy.appendField(locator, this, "execution", buffer, theExecution);
String query = job.getExecution().getQuery().getQuery(); String queryName = job.getName(); queryName += "-" + scheduledTimeMillis;
lhsExecution = this.getExecution(); XExecution rhsExecution; rhsExecution = that.getExecution(); if (!strategy.equals(LocatorUtils.property(thisLocator, "execution", lhsExecution), LocatorUtils.property(thatLocator, "execution", rhsExecution), lhsExecution, rhsExecution)) { return false;
theExecution = this.getExecution(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "execution", theExecution), currentHashCode, theExecution);
theExecution = this.getExecution(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "execution", theExecution), currentHashCode, theExecution);
lhsExecution = this.getExecution(); XExecution rhsExecution; rhsExecution = that.getExecution(); if (!strategy.equals(LocatorUtils.property(thisLocator, "execution", lhsExecution), LocatorUtils.property(thatLocator, "execution", rhsExecution), lhsExecution, rhsExecution)) { return false;