MyNearWallet PSA

Kate L
MyNearWallet Blog
Published in
3 min readJul 21, 2022

Concerning the Balances Issue (July 18–21, 2022)

Hello, NEAR Community! This is Kate L, Marketing & Community Lead at MyNearWallet. I am here to address the issues wallet.near.org and mynearwallet.com have been experiencing for the past few days and answer any questions or concerns you might have.

The issue is now fixed — we thank you for your patience and we are here to explain everything behind this instance.

We thank the Pagoda team for tackling the issue and working on the solution tirelessly and efficiently. We, at MNW, would like to take a moment to appreciate this invaluable help and support.

Message to the NEAR Community from the MNW Team

First and foremost, thank you for bearing with us! Bugs and their fixes are part of the development process — this is how we streamline the flow, introduce new features and improve protocols.

Now that we are aware of the issue, we are working on an effective solution to avoid the likes of it in the future — more details in the post below.

Stay tuned for more information on updates

As you may have heard, wallet.near.org will be moving to a new domain (stay tuned for an official announcement in August). The legacy wallet does have a few issues that we set out to improve. WIP! So, more improvements and updates are underway.

And to the issue at hand, let me describe the balances problem, why it happened and what we have been doing to handle it, together with Pagoda.

Why were the balances not showing?

  • To show the balances, allow wallet access and more, we make queries to an indexer.
  • As the community has been quite actively using the wallets, the number of queries for the data-bases has drastically grown.
  • The queries were not optimized, their processing was ineffective
  • Also, the volume of data stored on-chain is growing. As NEAR is generating new blocks, the database gets bigger with each second. Existing solution is not scalable enough to keep up with that pace — we are working on a new scalable and optimized solution.
  • As a result of the growing volume, the wallet started experiencing some problems with executing indexer queries

What’s an indexer?

An indexer listens to the stream of data as it’s being written on-chain. It processes raw data and stores it in the database in an efficient way to provide quick access to the blockchain data.

Are my funds safe?

Your funds are safe. MyNearWallet is non-custodial, which means it can’t sign transactions or transfer funds without users’ permission. All the funds are stored on the blockchain only, and may be equally accessed from any other wallet or by interacting with the blockchain directly (via near-cli, for example).

The issue with the balances not showing did not affect the funds state.

What was being done to fix the problem?

The issue was being tackled by:

  • Optimizing the queries
  • Using cache solution to reduce number of such queries

Near Inc (Pagoda) and MNW Team were consulting together to fix the issue.

Our support team were all on call.

How was the problem fixed?

  • A new indexer replica was deployed
  • Load balancing between replicas was added
  • Scaled up the number of instances temporarily as a way to increase the odds of exercising all available indexer nodes.
  • Planned: rejecting requests from unapproved domains

Right now, the wallet is working as it should be, the balances are showing.

Why did it take so long?

Fixing the wallet’s ability to execute an ever-growing number of queries takes some time, for which we apologize. At the same time, we are trying to ensure problems like this won’t appear in the future.

We are not looking for a quick, temporary fix. We are creating a secure, permanent solution to make sure you can use the wallet conveniently.

What’s the solution you are working on to make sure this doesn’t happen again?

We are working on our own indexing service based on near-lake — with all the data saved. That means we won’t have to look for it in real-time.

With the fix we have already implemented, we have time to perfect the solution and release it in a few months.

This will speed up processes and help avoid such lags: we’ll be able to process the requests in milli-seconds instead of seconds.

--

--