Is there any way to override the send method of NESTJS ClientTCP?

Solution 1:

It was resolved by creating my own ClientTCP. Instead of using the ClientProxyFactory I initialise the customised client by new. I thought I have to handle the other ClientProxies, but turn out that my use case is just TCP.

Referenced to doc: https://docs.nestjs.com/microservices/custom-transport#custom-transporters