Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Change name of pig and hive jars to have 'examples' in the name to av…

…oid confusion with the runtime jar.
  • Loading branch information...
commit f5f99ffd5675514e86124aa3a9f4937b4f6ffc35 1 parent 55a7d17
@tomwhite authored
View
4 build.xml
@@ -139,11 +139,11 @@
</target>
<target name="pig" depends="compile" description="Creates a jar containing Pig UDFs.">
- <jar destfile="pig.jar" basedir="${classes.dir}"/>
+ <jar destfile="pig-examples.jar" basedir="${classes.dir}"/>
</target>
<target name="hive" depends="compile" description="Creates a jar containing Hive UDFs.">
- <jar destfile="hive.jar" basedir="${classes.dir}"/>
+ <jar destfile="hive-examples.jar" basedir="${classes.dir}"/>
</target>
<target name="findbugs" depends="jar">
View
2  ch11/src/main/grunt/udfs.grunt
@@ -5,7 +5,7 @@
-- == udfs_schema_given
-- == udfs_load
-- vv udfs_register
-REGISTER pig.jar;
+REGISTER pig-examples.jar;
-- ^^ udfs_register
records = LOAD 'input/ncdc/micro-tab/sample.txt' AS (year:chararray, temperature:int, quality);
-- vv udfs_invoke_long
View
2  ch11/src/main/pig/max_temp_filter_udf.pig
@@ -1,5 +1,5 @@
-- max_temp_filter_udf.pig
-REGISTER pig.jar;
+REGISTER pig-examples.jar;
DEFINE isGood com.hadoopbook.pig.IsGoodQuality();
records = LOAD 'input/ncdc/micro-tab/sample.txt'
AS (year:chararray, temperature:int, quality:int);
View
2  ch11/src/main/pig/max_temp_station_name.pig
@@ -1,5 +1,5 @@
-- max_temp_station_name.pig
-REGISTER pig.jar;
+REGISTER pig-examples.jar;
DEFINE isGood com.hadoopbook.pig.IsGoodQuality();
stations = LOAD 'input/ncdc/metadata/stations-fixed-width.txt'
View
2  ch11/src/main/pig/year_stats.pig
@@ -1,5 +1,5 @@
-- year_stats.pig
-REGISTER pig.jar;
+REGISTER pig-examples.jar;
DEFINE isGood com.hadoopbook.pig.IsGoodQuality();
records = LOAD 'input/ncdc/all/19{1,2,3,4,5}0*'
USING com.hadoopbook.pig.CutLoadFunc('5-10,11-15,16-19,88-92,93-93')
View
3  ch11/src/main/python/is_good_quality.py
@@ -1,10 +1,9 @@
#!/usr/bin/env python
import re
-import string
import sys
for line in sys.stdin:
- (year, temp, q) = string.strip().split(line)
+ (year, temp, q) = line.strip().split()
if (temp != "9999" and re.match("[01459]", q)):
print "%s\t%s" % (year, temp)
View
2  snippet/expected/ch11/grunt/udfs_register.xml
@@ -1 +1 @@
-<screen format="linespecific"><prompt moreinfo="none">grunt&gt; </prompt><userinput moreinfo="none">REGISTER pig.jar;</userinput></screen>
+<screen format="linespecific"><prompt moreinfo="none">grunt&gt; </prompt><userinput moreinfo="none">REGISTER pig-examples.jar;</userinput></screen>
Please sign in to comment.
Something went wrong with that request. Please try again.