Uploaded image for project: 'Atlas'
  1. Atlas
  2. ATLAS-2132

Error code during invalid file path/unreadable file provided during import

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 1.0.0
    • 0.8.2, 1.0.0
    • atlas-core
    • None

    Description

      When firing import command using

      /api/atlas/admin/importfile
      

      when file provided in the import_options.json doesn't have read permission or file is not present , Atlas throws 500 Internal server error but with proper error message.

      Example :

      {"errorCode":"ATLAS-500-00-001","errorMessage":"org.apache.atlas.exception.AtlasBaseException: invalid parameters: /exportimport/db5.zip: file not found"}
      
      {"errorCode":"ATLAS-500-00-001","errorMessage":"org.apache.atlas.exception.AtlasBaseException: java.io.IOException: File '/exportimport/db6.zip' cannot be read"}
      

      Expected that Atlas would throw 400 Bad Request instead of 500 Internal Server error.

      Attachments

        1. ATLAS-2132-2.patch
          8 kB
          Ashutosh Mestry
        2. ATLAS-2132.patch
          1.0 kB
          Péter Gergő Barna

        Activity

          People

            bpgergo Péter Gergő Barna
            sharmadhas Sharmadha S
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: