Bitcoin Forum
June 19, 2019, 04:24:59 PM *
News: Latest Bitcoin Core release: 0.18.0 [Torrent] (New!)
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: WalletNotify with Multiple Wallet on Same Node  (Read 91 times)
gladiator9120
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile WWW
June 10, 2019, 02:20:25 PM
 #1

Hi,

I am part of a fintech project and we have thousands of users. Instead of getnewaddress, we are using createwallet for all users. Everything is working pretty perfectly, except one critical part.

We are stuck with walletnotify. In our earlier mechanism, we were using one wallet with multiple addresses and thus, walletnotify was helpful. But now the problem is that walletnofity sends the txID, and when we pass the txID in separate gettransaction call, in response we get "specify -rpcwallet=<>"

Now as we ourself don't know which user has made the deposit, how do we keep track of it.

I have check github and there are a few commits on expanding the walletnotify functionality with %s and %w for wallet name. However, that still seems to be in work in progress as the latest pull didn't bring that functionality.

Can someone help how to maintain wallet per user bases and also use walletnotify ?
1560961499
Hero Member
*
Offline Offline

Posts: 1560961499

View Profile Personal Message (Offline)

Ignore
1560961499
Reply with quote  #2

1560961499
Report to moderator
1560961499
Hero Member
*
Offline Offline

Posts: 1560961499

View Profile Personal Message (Offline)

Ignore
1560961499
Reply with quote  #2

1560961499
Report to moderator
1560961499
Hero Member
*
Offline Offline

Posts: 1560961499

View Profile Personal Message (Offline)

Ignore
1560961499
Reply with quote  #2

1560961499
Report to moderator
COINSWITCH
Trade 300+ coins
No Login
No KYC
Get $5 on 1st order
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
1560961499
Hero Member
*
Offline Offline

Posts: 1560961499

View Profile Personal Message (Offline)

Ignore
1560961499
Reply with quote  #2

1560961499
Report to moderator
1560961499
Hero Member
*
Offline Offline

Posts: 1560961499

View Profile Personal Message (Offline)

Ignore
1560961499
Reply with quote  #2

1560961499
Report to moderator
achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 1792
Merit: 2459


bc1qshxkrpe4arppq89fpzm6c0tpdvx5cfkve2c8kl


View Profile WWW
June 10, 2019, 08:29:40 PM
 #2

There is currently no way to use walletnotify with released versions of Bitcoin Core. The PR implementing the necessary changes is not yet merged and is still under review.

A dumb way to get around this issue is to just go through each wallet and call gettransaction in each one until you get the wallet that responds correctly.

gladiator9120
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile WWW
June 11, 2019, 05:14:27 AM
 #3

Just out of curiosity, then how does wallets like blockchain.com manage millions of wallet? They may be receiving walletnotify callback every second.

I got your point and we also thought of the same, to run loop for every wallet on our node to check for gettransaction.
HCP
Legendary
*
Offline Offline

Activity: 994
Merit: 1615

<insert witty quote here>


View Profile
June 11, 2019, 08:55:48 AM
 #4

blockchain.com don't control or manage the wallets... they are effectively just "storage" for the encrypted wallet data. So they don't need to know when coins are received to be able to "credit" a user's balance. That happens when a user logs in and the wallet then queries the server for transactions etc. via API calls.

Custodial wallets like the exchanges etc that do manage user wallets, are most likely running custom software... not a "simple" Bitcoin Core node.


achow101
Moderator
Legendary
*
expert
Offline Offline

Activity: 1792
Merit: 2459


bc1qshxkrpe4arppq89fpzm6c0tpdvx5cfkve2c8kl


View Profile WWW
June 11, 2019, 05:09:16 PM
 #5

Just out of curiosity, then how does wallets like blockchain.com manage millions of wallet? They may be receiving walletnotify callback every second.
They don't use Bitcoin Core. They use their own custom software to receive blocks and transactions and notify other systems.

gladiator9120
Newbie
*
Offline Offline

Activity: 11
Merit: 0


View Profile WWW
June 12, 2019, 03:19:10 PM
 #6

Gotcha ! Thanks.
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!