Git Product home page Git Product logo

Comments (3)

nkarpov avatar nkarpov commented on September 27, 2024

Hi Randy,

I'm able to get this working on my local Mac w/ Hadoop & Hive installed through Homebrew.

Confirm Hadoop & Hive versions

$ hadoop version
Hadoop 2.7.1
Subversion https://git-wip-us.apache.org/repos/asf/hadoop.git -r 15ecc87ccf4a0228f35af08fc56de536e6ce657a
Compiled by jenkins on 2015-06-29T06:04Z
Compiled with protoc 2.5.0
From source with checksum fc0a1a23fc1868e4d5ee7fa2b28a58a
This command was run using /usr/local/Cellar/hadoop/2.7.1/libexec/share/hadoop/common/hadoop-common-2.7.1.jar
$ hive --version
Hive 1.2.1
Subversion git://localhost.localdomain/home/sush/dev/hive.git -r 243e7c1ac39cb7ac8b65c5bc6988f5cc3162f558
Compiled by sush on Fri Jun 19 02:03:48 PDT 2015
From source with checksum ab480aca41b24a9c3751b8c023338231

Update pom.xml w/ versions

<properties>
        <hive.version>1.2.1</hive.version>
        <hadoop.version>2.7.1</hadoop.version>
        <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
        <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>
</properties>

Update Jetty dependencies (commented out previous def)

        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-server</artifactId>
            <version>9.3.6.v20151106</version>
        </dependency>
        <dependency>
            <groupId>org.eclipse.jetty</groupId>
            <artifactId>jetty-util</artifactId>
            <version>9.3.6.v20151106</version>
        </dependency>
        <!--<dependency>
            <groupId>org.mortbay.jetty</groupId>
            <artifactId>jetty-util</artifactId>
            <version>6.1.26.hwx</version>
        </dependency>
        <dependency>
            <groupId>org.mortbay.jetty</groupId>
            <artifactId>jetty</artifactId>
            <version>6.1.26.hwx</version>
        </dependency> -->

Comment out or remove remaining HDP repos (will grab common hadoop common & hive from maven central). The repo section should only have localjars now like below:

<repositories>
        <repository>
                <id>localjars</id>
                <url>file://${basedir}/localjars</url>
        </repository>
</repositories>

This should compile and package successfully. Hope this helps.

$ mvn clean
$ mvn compile
$ mvn package -Dmaven.test.skip=true
hive> add jar /Users/nickkarpov/h2o-world-2015-training/tutorials/hive_udf_template/localjars/h2o-genmodel.jar;
Added [/Users/nickkarpov/h2o-world-2015-training/tutorials/hive_udf_template/localjars/h2o-genmodel.jar] to class path
Added resources: [/Users/nickkarpov/h2o-world-2015-training/tutorials/hive_udf_template/localjars/h2o-genmodel.jar]
hive> add jar /Users/nickkarpov/h2o-world-2015-training/tutorials/hive_udf_template/target/ScoreData-1.0-SNAPSHOT.jar;
Added [/Users/nickkarpov/h2o-world-2015-training/tutorials/hive_udf_template/target/ScoreData-1.0-SNAPSHOT.jar] to class path
Added resources: [/Users/nickkarpov/h2o-world-2015-training/tutorials/hive_udf_template/target/ScoreData-1.0-SNAPSHOT.jar]
hive> CREATE TEMPORARY FUNCTION scoredata AS 'ai.h2o.hive.udf.ScoreDataUDF';
OK
Time taken: 0.729 seconds

from h2o-tutorials.

randyzwitch avatar randyzwitch commented on September 27, 2024

Thanks Nick, I'll try that out.

from h2o-tutorials.

nkarpov avatar nkarpov commented on September 27, 2024

Hi Randy - did you have a chance to try this?

from h2o-tutorials.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.