@java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; } int hash = 41; hash = (19 * hash) + getDescriptorForType().hashCode(); if (hasQueryIdentifier()) { hash = (37 * hash) + QUERY_IDENTIFIER_FIELD_NUMBER; hash = (53 * hash) + getQueryIdentifier().hashCode(); } if (hasFragmentIdentifierString()) { hash = (37 * hash) + FRAGMENT_IDENTIFIER_STRING_FIELD_NUMBER; hash = (53 * hash) + getFragmentIdentifierString().hashCode(); } if (hasIsGuaranteed()) { hash = (37 * hash) + IS_GUARANTEED_FIELD_NUMBER; hash = (53 * hash) + hashBoolean(getIsGuaranteed()); } hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; }
@Override public UpdateFragmentResponseProto updateFragment( UpdateFragmentRequestProto request) throws IOException { String fragmentId = request.getFragmentIdentifierString(); boolean isGuaranteed = request.hasIsGuaranteed() && request.getIsGuaranteed(); LOG.info("DBG: Received updateFragment request for {}", fragmentId); // TODO: ideally, QueryTracker should have fragment-to-query mapping. QueryIdentifier queryId = executorService.findQueryByFragment(fragmentId); // checkPermissions returns false if query is not found, throws on failure. boolean result = false; if (queryId != null && queryTracker.checkPermissionsForQuery(queryId)) { result = executorService.updateFragment(fragmentId, isGuaranteed); } return UpdateFragmentResponseProto.newBuilder() .setResult(result).setIsGuaranteed(isGuaranteed).build(); }
@java.lang.Override public boolean equals(final java.lang.Object obj) { if (obj == this) { return true; } if (!(obj instanceof org.apache.hadoop.hive.llap.daemon.rpc.LlapDaemonProtocolProtos.UpdateFragmentRequestProto)) { return super.equals(obj); } org.apache.hadoop.hive.llap.daemon.rpc.LlapDaemonProtocolProtos.UpdateFragmentRequestProto other = (org.apache.hadoop.hive.llap.daemon.rpc.LlapDaemonProtocolProtos.UpdateFragmentRequestProto) obj; boolean result = true; result = result && (hasQueryIdentifier() == other.hasQueryIdentifier()); if (hasQueryIdentifier()) { result = result && getQueryIdentifier() .equals(other.getQueryIdentifier()); } result = result && (hasFragmentIdentifierString() == other.hasFragmentIdentifierString()); if (hasFragmentIdentifierString()) { result = result && getFragmentIdentifierString() .equals(other.getFragmentIdentifierString()); } result = result && (hasIsGuaranteed() == other.hasIsGuaranteed()); if (hasIsGuaranteed()) { result = result && (getIsGuaranteed() == other.getIsGuaranteed()); } result = result && getUnknownFields().equals(other.getUnknownFields()); return result; }
@Override public UpdateFragmentResponseProto updateFragment( UpdateFragmentRequestProto request) throws IOException { String fragmentId = request.getFragmentIdentifierString(); boolean isGuaranteed = request.hasIsGuaranteed() && request.getIsGuaranteed(); LOG.info("DBG: Received updateFragment request for {}", fragmentId); // TODO: ideally, QueryTracker should have fragment-to-query mapping. QueryIdentifier queryId = executorService.findQueryByFragment(fragmentId); // checkPermissions returns false if query is not found, throws on failure. boolean result = false; if (queryId != null && queryTracker.checkPermissionsForQuery(queryId)) { result = executorService.updateFragment(fragmentId, isGuaranteed); } return UpdateFragmentResponseProto.newBuilder() .setResult(result).setIsGuaranteed(isGuaranteed).build(); }
/** * <code>optional string fragment_identifier_string = 2;</code> */ public Builder clearFragmentIdentifierString() { bitField0_ = (bitField0_ & ~0x00000002); fragmentIdentifierString_ = getDefaultInstance().getFragmentIdentifierString(); onChanged(); return this; } /**