Package org.apache.hadoop.hive.ql.processors

Examples of org.apache.hadoop.hive.ql.processors.CommandProcessor.run()


          } else {
            isHiveQuery = false;
            driver = null;
            // need to reset output for each non-Hive query
            setupSessionIO(session);
            response = proc.run(cmd_1);
          }

          ret = response.getResponseCode();
          SQLState = response.getSQLState();
          errorMessage = response.getErrorMessage();
View Full Code Here


          } finally {
            qp.close();
          }
        } else {
          try {
            queryRet.add(Integer.valueOf(proc.run(cmd_1).getResponseCode()));
          } catch (CommandNeedRetryException e) {
            // this should never happen if there is no bug
            l4j.error(getSessionName() + " Exception when executing", e);
          }
        }
View Full Code Here

          } else {
            isHiveQuery = false;
            driver = null;
            // need to reset output for each non-Hive query
            setupSessionIO(session);
            response = proc.run(cmd_1);
          }

          ret = response.getResponseCode();
          SQLState = response.getSQLState();
          errorMessage = response.getErrorMessage();
View Full Code Here

          } else {
            isHiveQuery = false;
            driver = null;
            // need to reset output for each non-Hive query
            setupSessionIO(session);
            response = proc.run(cmd_1);
          }

          ret = response.getResponseCode();
          SQLState = response.getSQLState();
          errorMessage = response.getErrorMessage();
View Full Code Here

            ((Driver)proc).destroy();
            isHiveQuery = true;
            response = driver.run(cmd);
          } else {
            isHiveQuery = false;
            response = proc.run(cmd_1);
          }

          ret = response.getResponseCode();
          SQLState = response.getSQLState();
          errorMessage = response.getErrorMessage();
View Full Code Here

            l4j.error(getSessionName() + " getting results " + getResultFile()
                + " caused exception.", ex);
          }
          qp.close();
        } else {
          queryRet.add(new Integer(proc.run(cmd_1).getResponseCode()));
        }
      } else {
        // processor was null
        l4j.error(getSessionName()
            + " query processor was not found for query " + cmd);
View Full Code Here

            int res = driver.compile(cmd);
            Schema sch = driver.getSchema();
            List <FieldSchema> fields = sch.getFieldSchemas();
            return fields;
        } else {
            ret = proc.run(cmd_1).getResponseCode();
        }
        return null;
    }

    public static String join(List<? extends CharSequence> s, String delimiter) {
View Full Code Here

                //many things could go wrong here
                e1.printStackTrace();
            }
        }
        if (proc instanceof Driver) {
            ret = proc.run(cmd).getResponseCode();
        } else {
            ret = proc.run(cmd_1).getResponseCode();
        }

        return ret;
View Full Code Here

            }
        }
        if (proc instanceof Driver) {
            ret = proc.run(cmd).getResponseCode();
        } else {
            ret = proc.run(cmd_1).getResponseCode();
        }

        return ret;
    }
View Full Code Here

    ArrayList<String> out = Lists.newArrayList();

    if (proc instanceof Driver) {
      try {
        ret = proc.run(cmd).getResponseCode();
        ((Driver) proc).getResults(out);
      } catch (CommandNeedRetryException ex) {
        Logger.getLogger(HiveTestEmbedded.class.getName()).log(Level.SEVERE, null, ex);
      } catch (IOException e) {
        e.printStackTrace();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.