Sqoop
  1. Sqoop
  2. SQOOP-892

Sqoop2: Validate acceptable number of mappers and reducers

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.99.1
    • Fix Version/s: 1.99.2
    • Component/s: sqoop2-client
    • Labels:
      None

      Description

      When configuring a import or export job with the sqoop2 client, an input value of 0 for the number of extactors in a shouldn't be allowed. Currently, entering a 0 value results in:

      Exception: java.lang.ArithmeticException: / by zero
      Stack trace: java.lang.ArithmeticException: / by zero
      at org.apache.sqoop.connector.jdbc.GenericJdbcImportPartitioner.partitionIntegerColumn(GenericJdbcImportPartitioner.java:107)
      at org.apache.sqoop.connector.jdbc.GenericJdbcImportPartitioner.getPartitions(GenericJdbcImportPartitioner.java:57)
      at org.apache.sqoop.connector.jdbc.GenericJdbcImportPartitioner.getPartitions(GenericJdbcImportPartitioner.java:31)
      at org.apache.sqoop.job.mr.SqoopInputFormat.getSplits(SqoopInputFormat.java:69)
      at org.apache.hadoop.mapred.JobClient.writeNewSplits(JobClient.java:1064)

      1. bugSQOOP-892.patch
        9 kB
        Jarek Jarcec Cecho

        Issue Links

          Activity

          Hide
          Jarek Jarcec Cecho added a comment -

          The failure seems to be some glitch on Jenkins side. The build is running locally and rerun on Jenkins has went ok as well.

          Show
          Jarek Jarcec Cecho added a comment - The failure seems to be some glitch on Jenkins side. The build is running locally and rerun on Jenkins has went ok as well.
          Hide
          Hudson added a comment -

          Integrated in Sqoop2-hadoop100 #197 (See https://builds.apache.org/job/Sqoop2-hadoop100/197/)
          SQOOP-892:: Validate acceptable number of mappers and reducers (Revision df3a266c6ca1c50e01c6dd61e099f3662bcccf2f)

          Result = FAILURE
          cheolsoo : https://git-wip-us.apache.org/repos/asf?p=sqoop.git&a=commit&h=df3a266c6ca1c50e01c6dd61e099f3662bcccf2f
          Files :

          • core/src/main/java/org/apache/sqoop/framework/FrameworkValidator.java
          • core/src/test/java/org/apache/sqoop/framework/TestFrameworkValidator.java
          • core/src/main/java/org/apache/sqoop/framework/configuration/ExportJobConfiguration.java
          Show
          Hudson added a comment - Integrated in Sqoop2-hadoop100 #197 (See https://builds.apache.org/job/Sqoop2-hadoop100/197/ ) SQOOP-892 :: Validate acceptable number of mappers and reducers (Revision df3a266c6ca1c50e01c6dd61e099f3662bcccf2f) Result = FAILURE cheolsoo : https://git-wip-us.apache.org/repos/asf?p=sqoop.git&a=commit&h=df3a266c6ca1c50e01c6dd61e099f3662bcccf2f Files : core/src/main/java/org/apache/sqoop/framework/FrameworkValidator.java core/src/test/java/org/apache/sqoop/framework/TestFrameworkValidator.java core/src/main/java/org/apache/sqoop/framework/configuration/ExportJobConfiguration.java
          Hide
          Hudson added a comment -

          Integrated in Sqoop2-hadoop200 #210 (See https://builds.apache.org/job/Sqoop2-hadoop200/210/)
          SQOOP-892:: Validate acceptable number of mappers and reducers (Revision df3a266c6ca1c50e01c6dd61e099f3662bcccf2f)

          Result = SUCCESS
          cheolsoo : https://git-wip-us.apache.org/repos/asf?p=sqoop.git&a=commit&h=df3a266c6ca1c50e01c6dd61e099f3662bcccf2f
          Files :

          • core/src/test/java/org/apache/sqoop/framework/TestFrameworkValidator.java
          • core/src/main/java/org/apache/sqoop/framework/FrameworkValidator.java
          • core/src/main/java/org/apache/sqoop/framework/configuration/ExportJobConfiguration.java
          Show
          Hudson added a comment - Integrated in Sqoop2-hadoop200 #210 (See https://builds.apache.org/job/Sqoop2-hadoop200/210/ ) SQOOP-892 :: Validate acceptable number of mappers and reducers (Revision df3a266c6ca1c50e01c6dd61e099f3662bcccf2f) Result = SUCCESS cheolsoo : https://git-wip-us.apache.org/repos/asf?p=sqoop.git&a=commit&h=df3a266c6ca1c50e01c6dd61e099f3662bcccf2f Files : core/src/test/java/org/apache/sqoop/framework/TestFrameworkValidator.java core/src/main/java/org/apache/sqoop/framework/FrameworkValidator.java core/src/main/java/org/apache/sqoop/framework/configuration/ExportJobConfiguration.java
          Hide
          Cheolsoo Park added a comment -

          +1.

          Committed to sqoop2. Thanks Jarcec!

          Show
          Cheolsoo Park added a comment - +1. Committed to sqoop2. Thanks Jarcec!

            People

            • Assignee:
              Jarek Jarcec Cecho
              Reporter:
              Will McQueen
            • Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development