<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>question Exception when trying to run Hive UDF in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Exception-when-trying-to-run-Hive-UDF/m-p/120681#M34273</link>
    <description>&lt;PRE&gt;hive&amp;gt; add jar urldetector-1.0-jar-with-dependencies.jar;
add jar urldetector-1.0-jar-with-dependencies.jar
Added [urldetector-1.0-jar-with-dependencies.jar] to class path
Added resources: [urldetector-1.0-jar-with-dependencies.jar]
hive&amp;gt; CREATE TEMPORARY FUNCTION urldetector as 'com.dataflowdeveloper.detection.URLDetector';
CREATE TEMPORARY FUNCTION urldetector as 'com.dataflowdeveloper.detection.URLDetector'
OK
Time taken: 0.032 seconds
hive&amp;gt; select urldetector(remote_host), remote_host from AccessLogs limit 100;
select urldetector(remote_host), remote_host from AccessLogs limit 100
OK
_c0	remote_host
Sent: 68.180.229.154
Failed with exception java.io.IOException:org.apache.hadoop.hive.ql.metadata.HiveException: Unable to execute method public org.apache.hadoop.io.Text com.dataflowdeveloper.detection.URLDetector.evaluate(org.apache.hadoop.io.Text) throws java.io.IOException  on object com.dataflowdeveloper.detection.URLDetector@5dbd1a3e of class com.dataflowdeveloper.detection.URLDetector with arguments {68.180.229.154:org.apache.hadoop.io.Text} of size 1
Time taken: 0.147 seconds

&lt;/PRE&gt;&lt;P&gt;This is when trying to load a Hive UDF.&lt;/P&gt;</description>
    <pubDate>Sat, 09 Jul 2016 03:34:45 GMT</pubDate>
    <dc:creator>TimothySpann</dc:creator>
    <dc:date>2016-07-09T03:34:45Z</dc:date>
    <item>
      <title>Exception when trying to run Hive UDF</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Exception-when-trying-to-run-Hive-UDF/m-p/120681#M34273</link>
      <description>&lt;PRE&gt;hive&amp;gt; add jar urldetector-1.0-jar-with-dependencies.jar;
add jar urldetector-1.0-jar-with-dependencies.jar
Added [urldetector-1.0-jar-with-dependencies.jar] to class path
Added resources: [urldetector-1.0-jar-with-dependencies.jar]
hive&amp;gt; CREATE TEMPORARY FUNCTION urldetector as 'com.dataflowdeveloper.detection.URLDetector';
CREATE TEMPORARY FUNCTION urldetector as 'com.dataflowdeveloper.detection.URLDetector'
OK
Time taken: 0.032 seconds
hive&amp;gt; select urldetector(remote_host), remote_host from AccessLogs limit 100;
select urldetector(remote_host), remote_host from AccessLogs limit 100
OK
_c0	remote_host
Sent: 68.180.229.154
Failed with exception java.io.IOException:org.apache.hadoop.hive.ql.metadata.HiveException: Unable to execute method public org.apache.hadoop.io.Text com.dataflowdeveloper.detection.URLDetector.evaluate(org.apache.hadoop.io.Text) throws java.io.IOException  on object com.dataflowdeveloper.detection.URLDetector@5dbd1a3e of class com.dataflowdeveloper.detection.URLDetector with arguments {68.180.229.154:org.apache.hadoop.io.Text} of size 1
Time taken: 0.147 seconds

&lt;/PRE&gt;&lt;P&gt;This is when trying to load a Hive UDF.&lt;/P&gt;</description>
      <pubDate>Sat, 09 Jul 2016 03:34:45 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Exception-when-trying-to-run-Hive-UDF/m-p/120681#M34273</guid>
      <dc:creator>TimothySpann</dc:creator>
      <dc:date>2016-07-09T03:34:45Z</dc:date>
    </item>
    <item>
      <title>Re: Exception when trying to run Hive UDF</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/Exception-when-trying-to-run-Hive-UDF/m-p/120682#M34274</link>
      <description>&lt;P&gt;So the issue was the library I was using was compiled with JDK 8 and everything else is JDK 7.   There was no issue listed, JUnit and local Java applications ran fine.   When I manually uploaded the JAR, it gave me the dreaded  "Unsupported major.minor version 52.0"&lt;/P&gt;&lt;P&gt;With a properly compiled library, we will be fine.&lt;/P&gt;&lt;P&gt;So make sure you compile in JDK 7 if your Hadoop / Hive platform is JDK 7&lt;/P&gt;</description>
      <pubDate>Sat, 09 Jul 2016 04:50:13 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/Exception-when-trying-to-run-Hive-UDF/m-p/120682#M34274</guid>
      <dc:creator>TimothySpann</dc:creator>
      <dc:date>2016-07-09T04:50:13Z</dc:date>
    </item>
  </channel>
</rss>

