Uploaded image for project: 'Sqoop'
  1. Sqoop
  2. SQOOP-3241

ImportAllTablesTool uses the same SqoopOptions object for every table import

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 1.4.6
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None

      Description

      ImportAllTablesTool queries the list of tables from the database and invokes ImportTool#importTable method for each table.
      The problem is that it passes the same SqoopOptions object in every invocation and since SqoopOptions is not immutable this can lead to issues.

      For example in case of Parquet imports the CodeGenTool#generateORM method modifies the className field of the SqoopOptions object which is then remains the same for all the subsequent table imports and can cause job failures.
      One solution could be to create a new SqoopOptions object with the same field values for every ImportTool#importTable invocation.

        Attachments

        1. SQOOP-3241.patch
          10 kB
          Fero Szabo
        2. SQOOP-3241.patch
          10 kB
          Fero Szabo

          Issue Links

            Activity

              People

              • Assignee:
                fero Fero Szabo
                Reporter:
                vasas Szabolcs Vasas
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: