Home | About | Sematext search-lucene.com search-hadoop.com
 Search Hadoop and all its subprojects:

Switch to Threaded View
Sqoop >> mail # dev >> Review Request: Cleaned up error codes in MapreduceExecutionError


Copy link to this message
-
Re: Review Request: Cleaned up error codes in MapreduceExecutionError


On Feb. 18, 2013, 8:31 p.m., Linden Hillenbrand wrote:
> > Jarcec

Hey Jarcec,

I have a quick question (just want to make sure I go about the renumeration correctly), therefore when I renumerate I need to change the error code references in the codebase so they call the proper exceptions. When I grep for example, '0009' which I am about to change to '0001', I get the following:

[linden@localhost sqoop2]$ grep -r -i MAPRED_EXEC_0009 .
./dist/target/sqoop-2.0.0-SNAPSHOT/execution/mapreduce/src/main/java/org/apache/sqoop/job/MapreduceExecutionError.java:  MAPRED_EXEC_0009("Unable to load the specified class"),
./dist/target/sqoop-2.0.0-SNAPSHOT/execution/mapreduce/src/main/java/org/apache/sqoop/job/mr/SqoopSplit.java:      throw new SqoopException(MapreduceExecutionError.MAPRED_EXEC_0009, className);
./dist/target/sqoop-2.0.0-SNAPSHOT/execution/mapreduce/src/main/java/org/apache/sqoop/job/etl/HdfsSequenceImportLoader.java:        throw new SqoopException(MapreduceExecutionError.MAPRED_EXEC_0009, codecname);
./dist/target/sqoop-2.0.0-SNAPSHOT/execution/mapreduce/src/main/java/org/apache/sqoop/job/etl/HdfsTextImportLoader.java:        throw new SqoopException(MapreduceExecutionError.MAPRED_EXEC_0009, codecname);
Binary file ./execution/mapreduce/target/classes/org/apache/sqoop/job/MapreduceExecutionError.class matches
Binary file ./execution/mapreduce/target/classes/org/apache/sqoop/job/mr/SqoopSplit.class matches
Binary file ./execution/mapreduce/target/classes/org/apache/sqoop/job/etl/HdfsSequenceImportLoader.class matches
Binary file ./execution/mapreduce/target/classes/org/apache/sqoop/job/etl/HdfsTextImportLoader.class matches
./execution/mapreduce/src/main/java/org/apache/sqoop/job/MapreduceExecutionError.java:  MAPRED_EXEC_0009("Unable to load the specified class"),
./execution/mapreduce/src/main/java/org/apache/sqoop/job/mr/SqoopSplit.java:      throw new SqoopException(MapreduceExecutionError.MAPRED_EXEC_0009, className);
./execution/mapreduce/src/main/java/org/apache/sqoop/job/etl/HdfsSequenceImportLoader.java:        throw new SqoopException(MapreduceExecutionError.MAPRED_EXEC_0009, codecname);
./execution/mapreduce/src/main/java/org/apache/sqoop/job/etl/HdfsTextImportLoader.java:        throw new SqoopException(MapreduceExecutionError.MAPRED_EXEC_0009, codecname);

What I would like to understand is a few things (happy to jump on a call Monday as well if that is easier to answer):

./dist/target/sqoop-2.0.0-SNAPSHOT/execution/mapreduce/src/main/java/org/apache/sqoop/job/mr/SqoopSplit.java
vs
./execution/mapreduce/src/main/java/org/apache/sqoop/job/mr/SqoopSplit.java

- How are the above to different?
- Is the /dist/target/*-SNAPSHOT just a compiled version of the code that I have on my machine?
- When I make the enumeration change do I need to make it to both files or just one?
- I am guessing the ./execution/mapreduce,...is the actual branch that I want to make the change on.

I appreciate the guidance, I just want to fully understand the change, and if I need to make it in two places then why.

Thank you sir.
- Linden
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9495/#review16714
-----------------------------------------------------------
On Feb. 18, 2013, 4:32 p.m., Linden Hillenbrand wrote:
>
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9495/
> -----------------------------------------------------------
>
> (Updated Feb. 18, 2013, 4:32 p.m.)
>
>
> Review request for Sqoop, Jarek Cecho and Kathleen Ting.
>
>
> Description
> -------
>
> Checked each error in MapreduceExecutionError.java and kept ones referenced in the code base and cleaned up the ones that were not being used.
>
> The ones I was able to remove are the following:
>
> /** Error occurs during job execution. */
> MAPRED_EXEC_0008("Error occurs during job execution"),