web3-java

Web3j Pending Transactions on Polygon Mumbai Network but works with Goerli Testnet Network


I'm having issues with Web3j with the Polygon Mumbai network, I've tried several ways to communicate with a smart contract but it sends the request to the network but the transaction will stay in a pending state for a few mins and then disappear. It states

"This txn hash was found in our secondary node and should be picked up by our indexer in a short while."

at first and then no transaction was found in a few mins. Below are a few things that I've tried

Finally, Tried connecting to Goerli Testnet Network with just an URL Change, and Both Contract deploy and Transaction got success within Seconds.

Any Idea why I'm getting this behavior? Any pointers

ERC - 721 Contract in Mumbai - https://mumbai.polygonscan.com/address/0x13fb4790d16f59f5ce98e10b61c3210a41c60261

Test Simple Contract in Mumbai - https://mumbai.polygonscan.com/address/0x1adc1ee6ab16571368a71db7841274bcaaadaf62

ERC-721 Web3j Deployed Contract in Goerli - https://goerli.etherscan.io/address/0xb5342a93b37e4685a529f68110bc51afa0465a81 ** Please note that code has some errors so Contract got deployed with some errors but was able to call methods tho it never minted the token due to the error

Goerli Transaction via Web3j - https://goerli.etherscan.io/tx/0xf9c29957824049baa0c7b1d44f0e347840986baf2b6018fda0a03dec627596de

Thanks, Mihindu Karunarathne


Solution

  • Yet to investigate why it's happening but seems like TransactionManager implementation has some issues, when I switched to Raw Transaction That did work

    https://mumbai.polygonscan.com/tx/0x4ed966585a41aab48bd950483fddf4e9516ca435bf8c891ab318a4c55e58ed3b

    Thanks, Mihindu K