From [this comment](https://github.com/stellar/go-stellar-xdr-json/pull/13#pullrequestreview-3156764790) it looks like there was a memory leak issue that was fixed [here](https://github.com/stellar/stellar-rpc/commit/e7ec889a0e776a5e4df108ef26be8e07d986134f) in stellar-rpc This fix should be added to go-stellar-xdr-json