class CompressUtil {

    private CompressUtil() { }

    /**
     * Helper method that attempts to automatically identify an archive and its type,
     * extract the contents as a byte array. If this fails, it will gracefully return
     * the original input byte array without exception. If the input was not an archive
     * or compressed, it will return the original byte array.
     * @param input the
     * @return a byte array
     */
    public static byte[] optionallyDecompress(final byte[] input) {<FILL_FUNCTION_BODY>}

}

        try (final ByteArrayInputStream bis = new ByteArrayInputStream(input);
             final ArchiveInputStream ais = new ArchiveStreamFactory().createArchiveInputStream(bis)) {
            final ArchiveEntry entry = ais.getNextEntry();
            if (ais.canReadEntryData(entry)) {
                return IOUtils.toByteArray(ais);
            }
        } catch (ArchiveException | IOException e) {
            // throw it away and return the original byte array
        }
        return input;
    
<no_super_class>