Child Workflow creation API should allow user to specify a custom data converter
Is your feature request related to a problem? Please describe. The user starts a child workflow on a different namespace or task queue, so it will be handled by a different worker. This different worker may have a completely different configuration of data converters. Such a situation is pretty legit if we have two different teams developing different modules listening on different task queues. Right now there is no way for a parent workflow to specify a different data converter for such a child workflow invocation.
Describe the solution you'd like
ChildWorkflowOptions should allow specifying a custom data converter that may be different from the data converter of the current worker.
Describe alternatives you've considered
Currently, users may work around this problem by creating a PayloadConverter that applies only to an input class of the child workflow. This approach is hacky and has limitations.
We have a setup with multiple workers, hosted by different parties, using separate queues for each workflow Worker A - hosts the main workflow, having keys p1 and s1 Worker B - hosts a child workflow doing work needed by the main workflow on worker A, having keys p2 and s2
All communication between the different workers and clients must be encrypted and protected.
A client starts the main workflow using encrypted payload (using p1) that is decrypted on worker A using a payloadconverter with S1, giving the main workflow the information it needs. When the main workflow on worker A starts the child workflow on worker B, the payload needed for the child workflow must be encrypted using P2 on worker A before leaving the server. Once worker B receives this request, it decrypts the payload using S2, and starts the child workflow to do its thing. The result from the child workflow must then be encoded using P1, and sent back to the main workflow decrypting it using S1 once the result is back on worker A.
Currently there is no way of specifying a custom dataconverter/payloadconverter to be used for the child workflow when starting it in the main workflow on worker A, leaving me to use a hack to get it working.