public String unzip(String archiveFilePath, String destDirectory, String extension, Boolean isUnzipRecursively) {
        
        logger.debug(extension + " archive path requested for unzipping: " + archiveFilePath);
        
        File archiveFile = new File(archiveFilePath);
        
        String unzippedName = archiveFile.getName() + App.ARCHIVE_INDICATOR;
        
        try {
    	
	    	if(extension.contains("zip")) {
	        	
	    		destDirectory = destDirectory + File.separator + unzippedName;
	        	File destDir = new File(destDirectory);
	            if(!destDir.exists()) {
	            	destDir.mkdir();            	
	            }
	            
	            logger.debug("Unzipping into directory: " + destDir);
	        	
	        	ZipInputStream zipIn = null;
				try {
					zipIn = new ZipInputStream(new FileInputStream(archiveFilePath));
				} catch (FileNotFoundException e) {
					logger.error("Archive not found", e);
					return (App.ARCHIVE_NOT_FOUND);
				}
		        ZipEntry entry = zipIn.getNextEntry();
	        
		        // Iterate over entries in the zip file
		        while (entry != null) {
		        	String filePath = destDirectory + File.separator + entry.getName();
		            if (!entry.isDirectory()) {
		                // If the entry is a file, extract it
		                extractFile(zipIn, filePath);
		            } else {
		                // If the entry is a directory, make the directory
		                File dir = new File(filePath);
		                dir.mkdir();
		            }
		            zipIn.closeEntry();
		            entry = zipIn.getNextEntry();
		        }
		        zipIn.close();
		        
		        if(isUnzipRecursively) {
		        	// Go inside unzipped directory. Log its content. Unzip further
			        RecursiveFileIterator recurser = new RecursiveFileIterator();
			        recurser.iterateDirectoryContents(destDir, null, true);
		        }
		        
		        return destDirectory;
	        
	        } else if (extension.contains("gz")) {
	        
	        	GZIPInputStream zipIn = new GZIPInputStream(new FileInputStream(archiveFilePath));
	        	
	        	String ungrzipedFile = destDirectory + File.separator + unzippedName + ".txt";
	        	
	        	extractFile(zipIn, ungrzipedFile);
	        	
	        	return ungrzipedFile;
	        
	        }
    	
		} catch (IOException e) {
			
			logger.error("IOException", e);
			
		}
    	
    	return "";
    	
    }