public static String deflate(final String data) {
        val output = deflateToByteArray(data);
        return EncodingUtils.encodeBase64(output);
    }
Deflate the given string via a {@link Deflater}.

@param data the data
@return base64 encoded string
core/cas-server-core-util-api/src/main/java/org/apereo/cas/util/CompressionUtils.java