Index: src/test/e2e/hcatalog/tools/generate/generate_data.pl
===================================================================
--- src/test/e2e/hcatalog/tools/generate/generate_data.pl (revision 1426097)
+++ src/test/e2e/hcatalog/tools/generate/generate_data.pl (working copy)
@@ -330,7 +330,7 @@
sub findAllJars()
{
- my @files = <../../../../../build/ivy/lib/default/*.jar>;
+ my @files = <../../../../../core/build/lib/test/*.jar>;
my $classpath = "";
my $file = undef;
foreach $file (@files) {
Index: src/test/e2e/hcatalog/udfs/java/build.xml
===================================================================
--- src/test/e2e/hcatalog/udfs/java/build.xml (revision 1426097)
+++ src/test/e2e/hcatalog/udfs/java/build.xml (working copy)
@@ -22,10 +22,15 @@
+
+
+
-
-
+
+
+
+
Index: src/test/e2e/hcatalog/tests/hive.conf
===================================================================
--- src/test/e2e/hcatalog/tests/hive.conf (revision 1426097)
+++ src/test/e2e/hcatalog/tests/hive.conf (working copy)
@@ -137,7 +137,7 @@
'num' => 4,
'sql' => q?
drop table if exists hive_read_4;
-create table hive_read_4 (name string, age int, gpa double) partitioned by (b string) row format delimited fields terminated by '\t' stored as textfile;
+create external table hive_read_4 (name string, age int, gpa double) partitioned by (b string) row format delimited fields terminated by '\t' stored as textfile;
alter table hive_read_4 add partition (b='1') location '/user/hcat/tests/data/studenttab10k';
alter table hive_read_4 set fileformat rcfile;
alter table hive_read_4 add partition (b='2') location '/user/hcat/tests/data/all100krc';
Index: src/test/e2e/hcatalog/tests/pig.conf
===================================================================
--- src/test/e2e/hcatalog/tests/pig.conf (revision 1426097)
+++ src/test/e2e/hcatalog/tests/pig.conf (working copy)
@@ -161,7 +161,7 @@
# A table with one partition in text and one in rc
'num' => 4
,'hcat_prep'=>q?drop table if exists pig_read_4;
-create table pig_read_4 (name string, age int, gpa double) partitioned by (b string) row format delimited fields terminated by '\t' stored as textfile;
+create external table pig_read_4 (name string, age int, gpa double) partitioned by (b string) row format delimited fields terminated by '\t' stored as textfile;
alter table pig_read_4 add partition (b='1') location '/user/hcat/tests/data/studenttab10k';
alter table pig_read_4 set fileformat rcfile;
alter table pig_read_4 add partition (b='2') location '/user/hcat/tests/data/all100krc';?
@@ -177,7 +177,7 @@
'num' => 5
,'hcat_prep'=>q?create database if not exists pig_db_1;
drop table if exists pig_db_1.pig_read_5;
-create table pig_db_1.pig_read_5 (name string, age int, gpa double) partitioned by (b string) row format delimited fields terminated by '\t' stored as textfile;
+create external table pig_db_1.pig_read_5 (name string, age int, gpa double) partitioned by (b string) row format delimited fields terminated by '\t' stored as textfile;
use pig_db_1;
alter table pig_read_5 add partition (b='1') location '/user/hcat/tests/data/studenttab10k';?
,'pig' => q\a = load 'pig_db_1.pig_read_5' using org.apache.hcatalog.pig.HCatLoader();
Index: src/test/e2e/hcatalog/conf/default.conf
===================================================================
--- src/test/e2e/hcatalog/conf/default.conf (revision 1426097)
+++ src/test/e2e/hcatalog/conf/default.conf (working copy)
@@ -56,6 +56,7 @@
, 'hcatlib' => "$ENV{'HCAT_HOME'}/share/hcatalog/lib"
, 'hcatconf' => "$ENV{'HCAT_HOME'}/etc/hcatalog"
, 'hcatbin' => "$ENV{'HCAT_HOME'}/bin/hcat"
+ , 'hcatcoredevlib' => "../../../../../core/build/lib/test"
#PIG
, 'pighome' => $ENV{'PIG_HOME'}
Index: src/test/e2e/hcatalog/drivers/TestDriverHadoop.pm
===================================================================
--- src/test/e2e/hcatalog/drivers/TestDriverHadoop.pm (revision 1426097)
+++ src/test/e2e/hcatalog/drivers/TestDriverHadoop.pm (working copy)
@@ -254,8 +254,8 @@
# Get all of the additional jars we'll need.
my $additionalJars = Util::getHBaseLibs($testCmd, $log); #hbase before hive for precedence over bundled hbase
+ $additionalJars .= Util::getHCatLibs($testCmd, $log);
$additionalJars .= Util::getHiveLibs($testCmd, $log);
- $additionalJars .= Util::getHCatLibs($testCmd, $log);
$testCmd->{'libjars'} = $additionalJars;
$testCmd->{'libjars'} =~ s/:/,/g;
my $hadoopcmd = Util::replaceParameters( $testCmd->{'hadoop'}, $outfile, $testCmd, $log );
Index: src/test/e2e/hcatalog/drivers/Util.pm
===================================================================
--- src/test/e2e/hcatalog/drivers/Util.pm (revision 1426097)
+++ src/test/e2e/hcatalog/drivers/Util.pm (working copy)
@@ -412,10 +412,10 @@
/hive-.*\.jar$/ && do {
$cp .= $cfg->{'hivelib'} . '/' . $_ . ':';
};
- /libfb303.jar/ && do {
+ /libfb303-.*\.jar/ && do {
$cp .= $cfg->{'hivelib'} . '/' . $_ . ':';
};
- /libthrift.jar/ && do {
+ /libthrift-.*\.jar/ && do {
$cp .= $cfg->{'hivelib'} . '/' . $_ . ':';
};
/datanucleus-.*\.jar$/ && do {
@@ -474,7 +474,7 @@
opendir(LIB, $cfg->{'hcatshare'}) or die "Cannot open $cfg->{'hcatshare'}, $!\n";
my @jars = readdir(LIB);
foreach (@jars) {
- /hcatalog-[0-9].*\.jar$/ && do {
+ (/hcatalog-core-[0-9].*\.jar$/ || /hcatalog-pig-adapter-[0-9].*\.jar$/) && do {
$cp .= $cfg->{'hcatshare'} . '/' . $_ . ':';
};
}
@@ -487,6 +487,18 @@
};
}
closedir(LIB);
+
+ # Get jars required non-hcat jars that are not distributed with Hadoop or Hive
+ opendir(LIB, $cfg->{'hcatcoredevlib'}) or die "Cannot open $cfg->{'hcatcoredevlib'}, $!\n";
+ my @jars = readdir(LIB);
+ foreach (@jars) {
+ /guava.*\.jar$/ && do {
+ $cp .= $cfg->{'hcatcoredevlib'} . '/' . $_ . ':';
+ };
+ }
+ closedir(LIB);
+
+
return $cp;
}