Avoid XData from Freeing object

Hi, in our application we use XData to send data from client to server.
Serverside we would like to process the data in a TASK/Thread (since it takes some time).
However when trying this we experience problems with XData "cleaning up" the data from memory before the thread/task is done, resulting in errors.

Is there any way to prevent this?

We are now taking the "RAW JSON" in our server. By using the Bcl deserialize function we create an object which isn't freed

Indeed, you have to somehow copy the data received/sent by XData.

Especially the input parameters, XData creates them internally, and it needs to destroy it to make sure no memory leaks happen..