<?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 Re: maven build question in Archives of Support Questions (Read Only)</title>
    <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/maven-build-question/m-p/132291#M43573</link>
    <description>&lt;P&gt;If you are trying to use this:&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/hortonworks/hive-json" target="_blank"&gt;https://github.com/hortonworks/hive-json&lt;/A&gt;&lt;/P&gt;&lt;P&gt;these two files have 2.2.2 hardcoded:&lt;/P&gt;&lt;P&gt;bin/shred-json:gsonVersion = "2.2.2"&lt;/P&gt;&lt;P&gt;bin/find-json-schema:gsonVersion = "2.2.2"&lt;/P&gt;&lt;P&gt;Just change them to 2.6.2 and mvn again.&lt;/P&gt;</description>
    <pubDate>Mon, 05 Dec 2016 22:24:35 GMT</pubDate>
    <dc:creator>ed_day</dc:creator>
    <dc:date>2016-12-05T22:24:35Z</dc:date>
    <item>
      <title>maven build question</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/maven-build-question/m-p/132289#M43571</link>
      <description>&lt;P&gt;I can successfully build the maven package  but when I run the code I am getting the error shown below. Its looking for &lt;/P&gt;&lt;P&gt;gson-2.2.2.jar for some reason ,where as the pom file has the version 2.2.6  and the file also exists  "&lt;/P&gt;&lt;P&gt;/root/.m2/repository/com/google/code/gson/gson/2.6.2/gson-2.6.2.jar" &lt;/P&gt;&lt;P&gt;the maven version and the pom.xml files are shown below:&lt;/P&gt;&lt;PRE&gt;[root@hadoop1 hive-json-master]# bin/find-json-schema  /tmp/events.1476299830387.log
Can't find /root/.m2/repository/com/google/code/gson/gson/2.2.2/gson-2.2.2.jar. Please build.
[root@hadoop1 hive-json-master]#

[root@hadoop1 hive-json-master]# more pom.xml
&amp;lt;project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"&amp;gt;
  &amp;lt;modelVersion&amp;gt;4.0.0&amp;lt;/modelVersion&amp;gt;
  &amp;lt;groupId&amp;gt;org.apache.hive&amp;lt;/groupId&amp;gt;
  &amp;lt;artifactId&amp;gt;hive-json&amp;lt;/artifactId&amp;gt;
  &amp;lt;version&amp;gt;1.0-SNAPSHOT&amp;lt;/version&amp;gt;
  &amp;lt;packaging&amp;gt;jar&amp;lt;/packaging&amp;gt;
  &amp;lt;name&amp;gt;Hive-JSON&amp;lt;/name&amp;gt;
  &amp;lt;url&amp;gt;http://hive.apache.org&amp;lt;/url&amp;gt;
  &amp;lt;repositories&amp;gt;
    &amp;lt;repository&amp;gt;
      &amp;lt;id&amp;gt;data-nucleus&amp;lt;/id&amp;gt;
      &amp;lt;name&amp;gt;data-nucleus&amp;lt;/name&amp;gt;
      &amp;lt;url&amp;gt;http://www.datanucleus.org/downloads/maven2/&amp;lt;/url&amp;gt;
    &amp;lt;/repository&amp;gt;
  &amp;lt;/repositories&amp;gt;
  &amp;lt;properties&amp;gt;
    &amp;lt;project.build.sourceEncoding&amp;gt;UTF-8&amp;lt;/project.build.sourceEncoding&amp;gt;
  &amp;lt;/properties&amp;gt;
  &amp;lt;dependencies&amp;gt;
      &amp;lt;dependency&amp;gt;
          &amp;lt;groupId&amp;gt;com.google.code.gson&amp;lt;/groupId&amp;gt;
          &amp;lt;artifactId&amp;gt;gson&amp;lt;/artifactId&amp;gt;
          &amp;lt;version&amp;gt;2.6.2&amp;lt;/version&amp;gt;
      &amp;lt;/dependency&amp;gt;
      &amp;lt;dependency&amp;gt;
        &amp;lt;groupId&amp;gt;junit&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;junit&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;4.10&amp;lt;/version&amp;gt;
    &amp;lt;/dependency&amp;gt;
  &amp;lt;/dependencies&amp;gt;
  &amp;lt;build&amp;gt;
    &amp;lt;plugins&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.apache.maven.plugins&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;maven-compiler-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.5.1&amp;lt;/version&amp;gt;
        &amp;lt;configuration&amp;gt;
          &amp;lt;source&amp;gt;1.6&amp;lt;/source&amp;gt;
          &amp;lt;target&amp;gt;1.6&amp;lt;/target&amp;gt;
        &amp;lt;/configuration&amp;gt;
      &amp;lt;/plugin&amp;gt;
      &amp;lt;!-- make a jar with the source code --&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.apache.maven.plugins&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;maven-source-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.2.1&amp;lt;/version&amp;gt;
        &amp;lt;executions&amp;gt;
          &amp;lt;execution&amp;gt;
            &amp;lt;id&amp;gt;attach-sources&amp;lt;/id&amp;gt;
            &amp;lt;goals&amp;gt;
              &amp;lt;goal&amp;gt;jar&amp;lt;/goal&amp;gt;
            &amp;lt;/goals&amp;gt;
          &amp;lt;/execution&amp;gt;
        &amp;lt;/executions&amp;gt;
      &amp;lt;/plugin&amp;gt;
      &amp;lt;!-- make a jar with the javadoc --&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.apache.maven.plugins&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;maven-javadoc-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.9&amp;lt;/version&amp;gt;
        &amp;lt;configuration&amp;gt;
          &amp;lt;show&amp;gt;public&amp;lt;/show&amp;gt;
          &amp;lt;!-- only include our source, not the protobuf --&amp;gt;
          &amp;lt;sourcepath&amp;gt;${basedir}/src/main/java&amp;lt;/sourcepath&amp;gt;
        &amp;lt;/configuration&amp;gt;
        &amp;lt;executions&amp;gt;
          &amp;lt;execution&amp;gt;
            &amp;lt;id&amp;gt;attach-javadocs&amp;lt;/id&amp;gt;
            &amp;lt;goals&amp;gt;
              &amp;lt;goal&amp;gt;jar&amp;lt;/goal&amp;gt;
            &amp;lt;/goals&amp;gt;
          &amp;lt;/execution&amp;gt;
        &amp;lt;/executions&amp;gt;
      &amp;lt;/plugin&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.apache.maven.plugins&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;maven-site-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.0-beta-6&amp;lt;/version&amp;gt;
      &amp;lt;/plugin&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.codehaus.mojo&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;findbugs-maven-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.5.2&amp;lt;/version&amp;gt;
        &amp;lt;configuration&amp;gt;
          &amp;lt;xmlOutput&amp;gt;true&amp;lt;/xmlOutput&amp;gt;
          &amp;lt;xmlOutputDirectory&amp;gt;target/site&amp;lt;/xmlOutputDirectory&amp;gt;
        &amp;lt;/configuration&amp;gt;
      &amp;lt;/plugin&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.apache.maven.plugins&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;maven-surefire-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.5&amp;lt;/version&amp;gt;
        &amp;lt;configuration&amp;gt;
          &amp;lt;systemProperties&amp;gt;
            &amp;lt;name&amp;gt;test.tmp.dir&amp;lt;/name&amp;gt;
            &amp;lt;value&amp;gt;${project.build.directory}/test/tmp&amp;lt;/value&amp;gt;
            &amp;lt;name&amp;gt;test.resources.dir&amp;lt;/name&amp;gt;
            &amp;lt;value&amp;gt;${basedir}/src/test/resources&amp;lt;/value&amp;gt;
          &amp;lt;/systemProperties&amp;gt;
          &amp;lt;argLine&amp;gt;-Xms256m -Xmx512m&amp;lt;/argLine&amp;gt;
        &amp;lt;/configuration&amp;gt;
      &amp;lt;/plugin&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;artifactId&amp;gt;maven-assembly-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;configuration&amp;gt;
          &amp;lt;archive&amp;gt;
            &amp;lt;manifest&amp;gt;
              &amp;lt;mainClass&amp;gt;org.apache.hadoop.hive.json.JsonSchemaFinder&amp;lt;/mainClass&amp;gt;
            &amp;lt;/manifest&amp;gt;
          &amp;lt;/archive&amp;gt;
          &amp;lt;descriptorRefs&amp;gt;
            &amp;lt;descriptorRef&amp;gt;jar-with-dependencies&amp;lt;/descriptorRef&amp;gt;
          &amp;lt;/descriptorRefs&amp;gt;
        &amp;lt;/configuration&amp;gt;
        &amp;lt;executions&amp;gt;
          &amp;lt;execution&amp;gt;
            &amp;lt;id&amp;gt;make-assembly&amp;lt;/id&amp;gt; &amp;lt;!-- this is used for inheritance merges --&amp;gt;
            &amp;lt;phase&amp;gt;package&amp;lt;/phase&amp;gt; &amp;lt;!-- bind to the packaging phase --&amp;gt;
            &amp;lt;goals&amp;gt;
              &amp;lt;goal&amp;gt;single&amp;lt;/goal&amp;gt;
            &amp;lt;/goals&amp;gt;
          &amp;lt;/execution&amp;gt;
        &amp;lt;/executions&amp;gt;
      &amp;lt;/plugin&amp;gt;
    &amp;lt;/plugins&amp;gt;
  &amp;lt;/build&amp;gt;
  &amp;lt;reporting&amp;gt;
    &amp;lt;plugins&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.apache.maven.plugins&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;maven-project-info-reports-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.4&amp;lt;/version&amp;gt;
        &amp;lt;configuration&amp;gt;
          &amp;lt;dependencyLocationsEnabled&amp;gt;false&amp;lt;/dependencyLocationsEnabled&amp;gt;
        &amp;lt;/configuration&amp;gt;
      &amp;lt;/plugin&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.apache.maven.plugins&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;maven-javadoc-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.9&amp;lt;/version&amp;gt;
        &amp;lt;configuration&amp;gt;
          &amp;lt;show&amp;gt;public&amp;lt;/show&amp;gt;
        &amp;lt;/configuration&amp;gt;
      &amp;lt;/plugin&amp;gt;
      &amp;lt;plugin&amp;gt;
        &amp;lt;groupId&amp;gt;org.codehaus.mojo&amp;lt;/groupId&amp;gt;
        &amp;lt;artifactId&amp;gt;findbugs-maven-plugin&amp;lt;/artifactId&amp;gt;
        &amp;lt;version&amp;gt;2.5.2&amp;lt;/version&amp;gt;
      &amp;lt;/plugin&amp;gt;
    &amp;lt;/plugins&amp;gt;
  &amp;lt;/reporting&amp;gt;
&amp;lt;/project&amp;gt;
[root@hadoop1 hive-json-master]#

&lt;/PRE&gt;</description>
      <pubDate>Sat, 15 Oct 2016 04:05:40 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/maven-build-question/m-p/132289#M43571</guid>
      <dc:creator>aliyesami</dc:creator>
      <dc:date>2016-10-15T04:05:40Z</dc:date>
    </item>
    <item>
      <title>Re: maven build question</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/maven-build-question/m-p/132290#M43572</link>
      <description>&lt;P&gt;Try explicitly excluding 2.2.2 version with maven exclude dependency.&lt;/P&gt;</description>
      <pubDate>Wed, 19 Oct 2016 09:13:22 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/maven-build-question/m-p/132290#M43572</guid>
      <dc:creator>aervits</dc:creator>
      <dc:date>2016-10-19T09:13:22Z</dc:date>
    </item>
    <item>
      <title>Re: maven build question</title>
      <link>https://community.cloudera.com/t5/Archives-of-Support-Questions/maven-build-question/m-p/132291#M43573</link>
      <description>&lt;P&gt;If you are trying to use this:&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/hortonworks/hive-json" target="_blank"&gt;https://github.com/hortonworks/hive-json&lt;/A&gt;&lt;/P&gt;&lt;P&gt;these two files have 2.2.2 hardcoded:&lt;/P&gt;&lt;P&gt;bin/shred-json:gsonVersion = "2.2.2"&lt;/P&gt;&lt;P&gt;bin/find-json-schema:gsonVersion = "2.2.2"&lt;/P&gt;&lt;P&gt;Just change them to 2.6.2 and mvn again.&lt;/P&gt;</description>
      <pubDate>Mon, 05 Dec 2016 22:24:35 GMT</pubDate>
      <guid>https://community.cloudera.com/t5/Archives-of-Support-Questions/maven-build-question/m-p/132291#M43573</guid>
      <dc:creator>ed_day</dc:creator>
      <dc:date>2016-12-05T22:24:35Z</dc:date>
    </item>
  </channel>
</rss>

