Uploaded image for project: 'Hive'
  1. Hive
  2. HIVE-8484

HCatalog throws an exception if Pig job is of type 'fetch'

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.14.0
    • 0.14.0
    • HCatalog
    • None
    • Reviewed

    Description

      When Pig tries to retrieve result in fetch mode through HCatalog then HCatLoader#setLocation(String location, Job job) can't set the outputschema because HCatUtil#checkJobContextIfRunningFromBackend(job) always returns false :

      public static boolean checkJobContextIfRunningFromBackend(JobContext j) {
          if (j.getConfiguration().get("mapred.task.id", "").equals("") &&
              !("true".equals(j.getConfiguration().get("pig.illustrating")))) {
            return false;
          }
          return true;
        }
      

      This is because in fetch mode we don't have a mapred.task.id. A null outputschema will raise an exception when HCatBaseLoader#getNext() is called: (ERROR 6018: Error converting read value to tuple).

      Attachments

        1. HIVE-8484.patch
          0.9 kB
          Lorand Bendig

        Issue Links

          Activity

            People

              Unassigned Unassigned
              lbendig Lorand Bendig
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: