Skip to content

Commit

Permalink
Rename ch11-mr-features to ch09-mr-features
Browse files Browse the repository at this point in the history
  • Loading branch information
tomwhite committed Nov 13, 2014
1 parent 5f6208d commit e29b15e
Show file tree
Hide file tree
Showing 82 changed files with 34 additions and 34 deletions.
2 changes: 1 addition & 1 deletion ch11-mr-features/pom.xml → ch09-mr-features/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<relativePath>../hadoop-meta/pom.xml</relativePath>
</parent>
<groupId>com.hadoopbook</groupId>
<artifactId>ch11-mr-features</artifactId>
<artifactId>ch09-mr-features</artifactId>
<packaging>jar</packaging>
<version>3.0</version>
<name>Chapter 11: MapReduce Features</name>
Expand Down
21 changes: 21 additions & 0 deletions ch09-mr-features/src/main/python/mean_max_daily_temp.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
STREAM="hadoop jar $HADOOP_HOME/share/hadoop/tools/lib/hadoop-streaming-*.jar -conf conf/hadoop-localhost.xml"

$STREAM \
-D stream.num.map.output.key.fields=2 \
-files ch09-mr-features/src/main/python/max_daily_temp_map.py,\
ch09-mr-features/src/main/python/max_daily_temp_reduce.py \
-input input/ncdc/all \
-output out_max_daily \
-mapper ch09-mr-features/src/main/python/max_daily_temp_map.py \
-reducer ch09-mr-features/src/main/python/max_daily_temp_reduce.py

$STREAM \
-D stream.num.map.output.key.fields=2 \
-files ch09-mr-features/src/main/python/mean_max_daily_temp_map.py,\
ch09-mr-features/src/main/python/mean_max_daily_temp_map.py \
-input out_max_daily \
-output out_mean_max_daily \
-mapper ch09-mr-features/src/main/python/mean_max_daily_temp_map.py \
-reducer ch09-mr-features/src/main/python/mean_max_daily_temp_reduce.py


Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ org.apache.hadoop.mapred.lib.KeyFieldBasedComparator \
-files secondary_sort_map.py,secondary_sort_reduce.py \
-input input/ncdc/all \
-output output-secondarysort-streaming \
-mapper ch11-mr-features/src/main/python/secondary_sort_map.py \
-mapper ch09-mr-features/src/main/python/secondary_sort_map.py \
-partitioner org.apache.hadoop.mapred.lib.KeyFieldBasedPartitioner \
-reducer ch11-mr-features/src/main/python/secondary_sort_reduce.py
-reducer ch09-mr-features/src/main/python/secondary_sort_reduce.py

File renamed without changes.
File renamed without changes.
21 changes: 0 additions & 21 deletions ch11-mr-features/src/main/python/mean_max_daily_temp.sh

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
import static org.apache.crunch.types.writable.Writables.strings;
import static org.apache.crunch.types.writable.Writables.tableOf;

// Crunch version of ch11-mr-features JoinRecordWithStationName
// Crunch version of ch09-mr-features JoinRecordWithStationName
public class JoinRecordWithStationNameCrunch {

public static void main(String[] args) throws Exception {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
import static org.apache.crunch.types.writable.Writables.strings;
import static org.apache.crunch.types.writable.Writables.tableOf;

// Crunch version of ch11-mr-features MaxTemperatureByStationNameUsingDistributedCacheFile
// Crunch version of ch09-mr-features MaxTemperatureByStationNameUsingDistributedCacheFile
public class MaxTemperatureByStationNameCrunch {

public static void main(String[] args) throws Exception {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import static org.apache.crunch.types.writable.Writables.ints;
import static org.apache.crunch.types.writable.Writables.pairs;

// Crunch version of ch11-mr-features MaxTemperatureUsingSecondarySort
// Crunch version of ch09-mr-features MaxTemperatureUsingSecondarySort
public class MaxTemperatureUsingSecondarySortCrunch {

public static void main(String[] args) throws Exception {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@
import static org.apache.crunch.types.writable.Writables.strings;
import static org.apache.crunch.types.writable.Writables.tableOf;

// Crunch version of ch11-mr-features MaxTemperatureWithCountersCrunch and MissingTemperatureFields
// Crunch version of ch09-mr-features MaxTemperatureWithCountersCrunch and MissingTemperatureFields
// Note that both are naturally combined into a single program.
public class MaxTemperatureWithCountersCrunch {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
import static org.apache.crunch.types.writable.Writables.strings;
import static org.apache.crunch.types.writable.Writables.tableOf;

// Crunch version of ch11-mr-features SortByTemperatureUsingTotalOrderPartitioner
// Crunch version of ch09-mr-features SortByTemperatureUsingTotalOrderPartitioner
public class SortByTemperatureCrunch {

public static void main(String[] args) throws Exception {
Expand Down
2 changes: 1 addition & 1 deletion hadoop-examples/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
</dependency>
<dependency>
<groupId>com.hadoopbook</groupId>
<artifactId>ch11-mr-features</artifactId>
<artifactId>ch09-mr-features</artifactId>
<version>3.0</version>
</dependency>
</dependencies>
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<module>ch07-parquet</module>
<module>ch06-mr-dev</module>
<module>ch08-mr-types</module>
<module>ch11-mr-features</module>
<module>ch09-mr-features</module>
<module>ch15-sqoop</module>
<module>ch16-pig</module>
<module>ch17-hive</module>
Expand Down
2 changes: 1 addition & 1 deletion snippet/bin/check_manuscript.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ bin=`cd "$bin"; pwd`
actual="$bin"/../actual
book_workspace=~/book-workspace/htdg-git

for ch in ch02-mr-intro ch03-hdfs ch05-io ch06-mr-dev ch08-mr-types ch11-mr-features ch16-pig ch17-hive ch21-zk
for ch in ch02-mr-intro ch03-hdfs ch05-io ch06-mr-dev ch08-mr-types ch09-mr-features ch16-pig ch17-hive ch21-zk
do
# remove id attributes from program listings, and add a newline before </programlisting>
sed '/<programlisting/s/ id="[^"]*"//; s|</programlisting>|\
Expand Down
2 changes: 1 addition & 1 deletion snippet/bin/generate_listings.sh
Original file line number Diff line number Diff line change
Expand Up @@ -15,5 +15,5 @@ perl $bin/phragmite_db.pl $actual/ch06-mr-dev/ $bin/../../../hadoop-book-mr-dev/
perl $bin/phragmite_db.pl $actual/ch06-mr-dev/ $bin/../../ch06-mr-dev/src/main/resources/max-temp-workflow/workflow.xml
perl $bin/phragmite_db.pl $actual/ch08-mr-types/ $(grep -ElR '(// ?cc|// ?==)' --include '*.java' $bin/../../ch08-mr-types)
perl $bin/phragmite_db.pl $actual/common/ $(grep -ElR '(// ?cc|// ?==)' --include '*.java' $bin/../../common)
perl $bin/phragmite_db.pl $actual/ch11-mr-features/ $(grep -ElR '(// ?cc|// ?==)' --include '*.java' $bin/../../ch11-mr-features)
perl $bin/phragmite_db.pl $actual/ch09-mr-features/ $(grep -ElR '(// ?cc|// ?==)' --include '*.java' $bin/../../ch09-mr-features)
perl $bin/phragmite_db.pl $actual/ch21-zk/ $(grep -ElR '(// ?cc|// ?==)' --include '*.java' $bin/../../ch21-zk)
2 changes: 1 addition & 1 deletion snippet/src/test/java/ExamplesIT.java
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public class ExamplesIT {
private static final String MODE_DEFAULT = "local";

private static final String EXAMPLE_CHAPTERS_PROPERTY = "example.chapters";
private static final String EXAMPLE_CHAPTERS_DEFAULT = "ch02-mr-intro,ch05-io,ch06-avro,ch06-mr-dev,ch08-mr-types,ch11-mr-features";
private static final String EXAMPLE_CHAPTERS_DEFAULT = "ch02-mr-intro,ch05-io,ch06-avro,ch06-mr-dev,ch08-mr-types,ch09-mr-features";

private static final IOFileFilter HIDDEN_FILE_FILTER =
new OrFileFilter(HiddenFileFilter.HIDDEN, new PrefixFileFilter("_"));
Expand Down

0 comments on commit e29b15e

Please sign in to comment.