Are there performance implications using the "timestamp" property of ImportMulti in the following way?

2

Based on the Developer Reference for importmulti, it seems the the timestamp property is purely used to determine how far back to rescan. If I have, say, 100 addresses and I simply set all of their timestamps to the same value (the earliest known timestamp), does this have any performance impact compared to setting each address' timestamp uniquely?

If the answer is no, then I'm wondering why this property was implemented as opposed to having a 3rd parameter holding a single "timestamp" for the entire list of addresses.

dimsumcode

Posted 2017-11-23T01:48:13.730

Reputation: 168

Answers

2

importmulti finds the earliest of the timestamps, and rescans from that point after all imports are done, yes. The wallet stores metadata about keys including the timestamp, which is why a timestamp is provided individually for each address rather than a single timestamp overall. Other commands like dumpwallet export a timestamp per key as well so this makes sense to provide it per-key when importing too, to save you having to look for the earliest before passing them in.

MeshCollider

Posted 2017-11-23T01:48:13.730

Reputation: 8 735

So, essentially the timestamp is used for ordering the list?Max Vernon 2017-11-23T03:48:43.983

@MaxVernon No need to order them, just start rescanning from the earliest, because in doing so you'll encounter all of them :)MeshCollider 2017-11-23T04:39:16.277

That makes sense. I can see how the timestamp can be a useful piece of info. Thanks for the answer.dimsumcode 2017-11-23T13:15:44.183