public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) { { XSessionType theSession; theSession = this.getSession(); strategy.appendField(locator, this, "session", buffer, theSession); } { XJobQuery theQuery; theQuery = this.getQuery(); strategy.appendField(locator, this, "query", buffer, theQuery); } return buffer; }
public StringBuilder appendFields(ObjectLocator locator, StringBuilder buffer, ToStringStrategy strategy) { { XSessionType theSession; theSession = this.getSession(); strategy.appendField(locator, this, "session", buffer, theSession); } { XJobQuery theQuery; theQuery = this.getQuery(); strategy.appendField(locator, this, "query", buffer, theQuery); } return buffer; }
public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) { int currentHashCode = 1; { XSessionType theSession; theSession = this.getSession(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "session", theSession), currentHashCode, theSession); } { XJobQuery theQuery; theQuery = this.getQuery(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "query", theQuery), currentHashCode, theQuery); } return currentHashCode; }
public int hashCode(ObjectLocator locator, HashCodeStrategy strategy) { int currentHashCode = 1; { XSessionType theSession; theSession = this.getSession(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "session", theSession), currentHashCode, theSession); } { XJobQuery theQuery; theQuery = this.getQuery(); currentHashCode = strategy.hashCode(LocatorUtils.property(locator, "query", theQuery), currentHashCode, theQuery); } return currentHashCode; }
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) { if (!(object instanceof XExecution)) { return false; } if (this == object) { return true; } final XExecution that = ((XExecution) object); { XSessionType lhsSession; lhsSession = this.getSession(); XSessionType rhsSession; rhsSession = that.getSession(); if (!strategy.equals(LocatorUtils.property(thisLocator, "session", lhsSession), LocatorUtils.property(thatLocator, "session", rhsSession), lhsSession, rhsSession)) { return false; } } { XJobQuery lhsQuery; lhsQuery = this.getQuery(); XJobQuery rhsQuery; rhsQuery = that.getQuery(); if (!strategy.equals(LocatorUtils.property(thisLocator, "query", lhsQuery), LocatorUtils.property(thatLocator, "query", rhsQuery), lhsQuery, rhsQuery)) { return false; } } return true; }
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; }
public boolean equals(ObjectLocator thisLocator, ObjectLocator thatLocator, Object object, EqualsStrategy strategy) { if (!(object instanceof XExecution)) { return false; } if (this == object) { return true; } final XExecution that = ((XExecution) object); { XSessionType lhsSession; lhsSession = this.getSession(); XSessionType rhsSession; rhsSession = that.getSession(); if (!strategy.equals(LocatorUtils.property(thisLocator, "session", lhsSession), LocatorUtils.property(thatLocator, "session", rhsSession), lhsSession, rhsSession)) { return false; } } { XJobQuery lhsQuery; lhsQuery = this.getQuery(); XJobQuery rhsQuery; rhsQuery = that.getQuery(); if (!strategy.equals(LocatorUtils.property(thisLocator, "query", lhsQuery), LocatorUtils.property(thatLocator, "query", rhsQuery), lhsQuery, rhsQuery)) { return false; } } return true; }
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); }
String query = job.getExecution().getQuery().getQuery(); String queryName = job.getName(); queryName += "-" + scheduledTimeMillis;