0

I have a job scan eth addresses and transfer usdt token.

But sometimes transaction cannot transfer and stuck in pending queue in geth.

And when the job run again, it still check balance and transfer token again.

It makes create a lot of pending transactions which are same from and to.

This reason burn a lot of eth fee.

I tried set --txpool.accountslots 1 --txpool.accountqueue 1 but it seems it doesn't work.

Can I can get pending txns and queued txns in txpool from geth by web3 java?

1 Answers1

0

I found the answer:

HttpService httpService = new HttpService(endpoint);

Response response = new Request<>("txpool_content", Arrays.asList(), httpService, Response.class).send();```