Open notsoluckycharm opened 9 months ago
For the TypeError you mentioned, I have a ticket on the main repo for that: https://github.com/prisma/prisma/issues/21139
I'm running into this same issue. @casey-chow thanks for PR, @SevInf can we get some traction on getting this merged in? Thanks all!
I think a minor change is required on the readOperations list. If you run a $queryRaw it will not match, as inserting a log statement yields the operation to contain the dollar sign. So these will not use the replica.
'$queryRaw', '$queryRawUnsafe',
I ask because making this change (and I would have PR'd it) loses the return types that the top level client gives you.
TypeError: Cannot destructure property 'prisma__type' of 'object null' as it is null.
So it would seem raw query on the replicas is currently unsupported.