public String getEntityGuid(final String entityType,
                              final String attributeName, final String qualifiedName) throws SemanticException {
    int entityApiTimeOut = 10;
    final Map<String, String> attributes = new HashMap<String, String>() {
      {
        put(attributeName, qualifiedName);
      }
    };

    try {
      AtlasEntity.AtlasEntityWithExtInfo entityWithExtInfo = runWithTimeout(
        () -> clientV2.getEntityByAttribute(entityType, attributes), entityApiTimeOut, TimeUnit.SECONDS);

      if (entityWithExtInfo == null || entityWithExtInfo.getEntity() == null) {
        LOG.warn("Atlas entity cannot be retrieved using: type: {} and {} - {}",
                entityType, attributeName, qualifiedName);
        return null;
      }
      return entityWithExtInfo.getEntity().getGuid();
    } catch (AtlasServiceException e) {
      int statusCode = e.getStatus() != null ? e.getStatus().getStatusCode() : -1;
      if (statusCode != NOT_FOUND.getStatusCode()) {
        throw new SemanticException(ErrorMsg.REPL_INVALID_INTERNAL_CONFIG_FOR_SERVICE.format("Exception " +
          "while getEntityGuid ", ReplUtils.REPL_ATLAS_SERVICE), e.getCause());
      }
      LOG.warn("getEntityGuid: Could not retrieve entity guid for: {}-{}-{}",
              entityType, attributeName, qualifiedName, e.getMessage());
      return null;
    } catch (Exception e) {
      throw new SemanticException(e);
    }
  }
Implementation of RESTClient, encapsulates Atlas' REST APIs.
ql/src/java/org/apache/hadoop/hive/ql/exec/repl/atlas/AtlasRestClientImpl.java