Uploaded image for project: 'IMPALA'
  1. IMPALA
  2. IMPALA-4262

LZO-scanner fails when reading large index files from S3

Agile BoardAttach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Critical
    • Resolution: Fixed
    • Impala 2.7.0
    • Impala 2.8.0
    • Backend

    Description

      The LZO-scanner always expects the index file to be a multiple of sizeof(uint64_t). In a loop, it reads the file 10MB at a time (which is a multiple of sizeof(uint64_t)) and processes this buffer uint64_t bytes at a time. This works fine for HDFS as HDFS returns the entire buffer as requested.

      However, for S3, the internal read() relies on a stream, therefore it sends as many bytes as currently available. This means that the 'bytes read' may not be a multiple of sizeof(uint64_t). This currently causes the scanner to throw an error in this case.

      We need to modify the LZO-scanner logic so that it carries over (buffer_size % sizeof(uint64_t)) bytes every time and process these remaining bytes as a part of the newly filled buffer.

      Attachments

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            sailesh Sailesh Mukil
            sailesh Sailesh Mukil
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Slack

                Issue deployment