In the following example, you configure the File Connector Read operation to read a file. Then, the Compress operation compresses the file and saves it in GZip format. Subsequently, the File Connector Write operation writes the content into the given path on demand.
-
In Studio, drag the File Connector Read operation to your flow.
-
Set Path to file.txt.
-
Drag the Compress operation alongside the Read operation.
-
Set Compressor to Gzip compressor
-
Drag the Write operation alongside the Compress operation.
-
Set Path to file-txt.gz.
In the Configuration XML editor, the configuration looks like this:
<file:read path="file.txt"/>
<compression:compress>
<compression:compressor>
<compression:gzip-compressor/>
</compression:compressor>
</compression:compress>
<file:write path="file-txt.gz"/>