Moralis Sync issue on BSC Mainnet

Hi all,
We have an issue with Moralis server “Sync and Watch Contract Events”, we have that configured on 2 servers, 1 on BSC testnet and one on BSC mainnet, both monitor USDT Transfer events with a filter of “to” addresses.
The event handling and firing works as expected on testnet without any issues, and we have Cloud function that POSTS them to our own servers.

The problem on the mainnet is that the events are either not synced (don’t appear on the Dashboard) or seem to be synced VERY late: https://bscscan.com/tx/0xf5d1bb8b39db67f0bbea03bac9ac7366e7113f25fa657685ab223c53cb6cdc56 sample.

This event appeared in the dashboard table with “createdAt” = 20 Apr 2022 at 19:11:23 UTC whereas BSC scan shows Apr-20-2022 06:43:25 PM +UTC (event in our logs appears: 20 April 2022 19:13:49 UTC)
What can we do to handle this huge time gap?

Hi,

I think that we had some problems yesterday with publishing events. How it is working today? and did the events that didn’t sync yesterday appear in the database meanwhile?

Hi Ivan,

Its the same, we’ve been doing tests none stop with different variations of the config and the filters and it never works

Alex.

Get Outlook for Android


can you paste the server url? (found it, I don’t see an event sync there now)

Can you please check if there’s a quota or something we’ve exceeded? The orginal event was for USDT without filtering,

Regarding the current server we’ve been experimenting with it since we didn’t expect a reply honestly.

I can check later. I guess that you didn’t sync historical data for USDT on mainnet.

I’ve recreated the scenario for the purpose of troubleshooting:

Server: https://b8irllr1f7bm.usemoralis.com:2083/
Table: TransferUSDTFiltered
Transaciton Not synched: https://bscscan.com/tx/0x07037e21ef0f1b804bc320130d6a86ee010df88c56d19311cfbb084d78006899

Noting that we think the issue is localized to some servers (we managed to get a London server to work, but Frankfurt ones don’t)

We’re not doing historical data @cryptokid, we create the server, with historical data off, and user events off, and configure SYNC and cloud functions, then do a transfer, we check that the receiving address is in the filter (lower case) and check the Dashboard (and our server which receives the POST from the cloud function) and there’s nothing (possibly for 10+ hours)

I mean historical sync for the event sync.

Yes we don’t need it, and in the first place Moralis doesn’t allow that (shows error: returned more than 500000, contact support if you really need this much in all cases including with the filters which is like 20 mainnet history events).

Ok, I’m not at computer now to test. You can sync historical too if you add the event sync from code.

Did you look in the server log to see if there is any error?

We did, there appear sometimes errors related to the core plugin, but normally when we test, they are not there (restart of the server ususally blows them away)

You can ignore those errors with core plugins. They appear when server restarts.

That is all, nothing more in logs?

Nope nothing more, we get more coreservices_getConfig messages for user undefined ususally that’s all

Currently running 3 servers concurrent test:

  1. Frankfurt + USDT Transfers, with ABI, filtered, no history, topic as plain text Transfer(address,address,uint256)
  2. London + USDT Transfers, with ABI, filtered, with history, topic as keccak256 0xddf252ad1be2c89b69c2b068fc378daa952ba7f163c4a11628f55a4df523b3ef
  3. London + USDT Transfers, with ABI, filtered, with history, topic as plain text (like 1), with Client Class Creation Enabled

Didn’t receive the transaction on any of the 3

And the transaction https://bscscan.com/tx/0x07037e21ef0f1b804bc320130d6a86ee010df88c56d19311cfbb084d78006899 was just received on the Frankfurt server: 47 minutes later

It shouldn’t matter the server location. I’ll look in an hour.

1 Like

0x8f101d78a5223c92d544c7be75dbb6374a26226ca4cc02050b8cca917c4d11be
Block timestamp: Apr-21-2022 05:44:06 PM +UTC
Moralis Logged at:

  1. 21 Apr 2022 at 18:15:44 UTC --> Frankfurt
  2. 21 Apr 2022 at 18:15:41 UTC --> London

Ie that’s ~30minutes later

I added the event sync on one of my servers that is an upgraded server.
Can you try to make a transaction again?