@@ -0,0 +1,1884 @@
+/*%0A * Copyright (C) 2014-2016 LinkedIn Corp. All rights reserved.%0A *%0A * Licensed under the Apache License, Version 2.0 (the %22License%22); you may not use%0A * this file except in compliance with the License. You may obtain a copy of the%0A * License at  http://www.apache.org/licenses/LICENSE-2.0%0A *%0A * Unless required by applicable law or agreed to in writing, software distributed%0A * under the License is distributed on an %22AS IS%22 BASIS, WITHOUT WARRANTIES OR%0A * CONDITIONS OF ANY KIND, either express or implied.%0A */%0Apackage gobblin.source.extractor.filebased;%0A%0Aimport gobblin.configuration.ConfigurationKeys;%0A%0Aimport java.io.IOException;%0Aimport java.io.InputStream;%0Aimport java.util.Iterator;%0Aimport java.util.zip.GZIPInputStream;%0A%0Aimport lombok.extern.slf4j.Slf4j;%0A%0Aimport org.apache.commons.io.IOUtils;%0A%0A/**%0A * A %7B@link FileDownloader%7D that downloads a single gzip file and iterates line by line.%0A *%0A * @param %3CD%3E record type in the file%0A */%0A@Slf4j%0Apublic class GZIPFileDownloader%3CD%3E extends FileDownloader%3CD%3E %7B%0A%0A  public GZIPFileDownloader(FileBasedExtractor%3C?, ?%3E fileBasedExtractor) %7B%0A    super(fileBasedExtractor);%0A  %7D%0A%0A  @SuppressWarnings(%22unchecked%22)%0A  public Iterator%3CD%3E downloadFile(String file) throws IOException %7B%0A    %0A    log.info(%22Beginning to download gzip compressed file: %22 + file);%0A%0A    try %7B%0A      InputStream inputStream = fileBasedExtractor.getCloser().register(fileBasedExtractor.getFsHelper().getFileStream(file));     %0A      Iterator%3CD%3E fileItr = (Iterator%3CD%3E) IOUtils.lineIterator(new GZIPInputStream(inputStream), ConfigurationKeys.DEFAULT_CHARSET_ENCODING);%0A      if (fileBasedExtractor.isShouldSkipFirstRecord() && fileItr.hasNext()) %7B%0A        fileItr.next();%0A      %7D%0A      return fileItr;%0A    %7D catch (FileBasedHelperException e) %7B%0A      throw new IOException(%22Exception while downloading file %22 + file + %22 with message %22 + e.getMessage(), e);%0A    %7D%0A  %7D%0A%7D%0A

Create GZIPFileDownloader.java