Project: mule
Issue MULE-9158: Change TransformationService to not mutate MuleMessage
There are two parts to this: * applyTransformers() methods: ** Update applyTransformers() method signatures to return a MuleMessage instance. ** Change implementation of applyTransformers() to return a new message instance with the result of the transformation rather than mutating the original message instance. ** Update all uses to use the return value as the result of the transformation. * getPayload() methods: ** Remove the logic that transparently transforms consumable payloads by mutating the message and setting a byte[] representation. ** Calls to getPayload() that require transformation of a consumable payload will now fail. ** Update uses to perform transformation to non-consumable prior to getPayload() if required. ** Update getPayloadForLogging() implementation to return something like “Stream payload (InputStream)” instead of failing or performing translation. ** Ensure getPayloadForLogging() is only used for system logging and not used be user configured component.
Story points: 8