Using custom tables instead of default Act_ru_variable table for process data

I am using mySql database instead of H2 in Camunda. By default, the process data(variables) are stored in Act_ru_variable table and Act_ge_Bytearray table(in case of non-primitive datatypes). I want to store the process data in my custom tables (instead of the default Act_ru_variable table and Act_ge_Bytearray tables) so that I can have more control over my data and manipulate it during process execution by accessing it at each activity(reading and writing). Any guidance please?

I would suggest storing your data objects in their own tables and then just keep an ID for those in your process instance. then you can query for the objects as you need them from the context of your process instance.

Dear Niall. Thank you for your prompt response. Can you please refer me some resource material on how to divert the storage of my data objects(process variables) to custom tables instead of the default (Act_ru_variable table and Act_ge_Bytearray tables)? And external tasks are a suitable candidate for querying those objects from the context of my process instance then? Thank you.