Because Mule now manages the data streams for you, data access becomes simpler. You do not need to be concerned with the underlying Java representation of that type whether it is a byte[], InputStream, String, or some other format.
A common pattern observed in Mule 3 applications is that users would convert things to strings in order to log them or send them through some transport. This was necessary because streams cannot be consumed twice, so a Transformer was needed:
<http:listener ... /> <!-- Obtains an InputStream payload -->
<object-to-string/> <!-- consume the stream and convert it to a String -->
<logger message="#[payload]"/> <!-- log the String -->
<http:request .../> <!-- send the String somewhere else-->
In Mule 4, you can simply log or send the data without worrying about the underlying type or how many times the stream is consumed. Instead of thinking about the InputStream, you should just think about the payload as binary data. Or, if you know the content type, you can think about it directly as JSON, XML,
or whatever data type corresponds to the content type.
<http:listener ... /> <!-- payload is JSON document -->
<logger message="#[payload]"/> <!-- log the JSON document -->
<http:request .../> <!-- send the JSON document somewhere else-->