Spread payment requests to subdirs
Currently Electrum stores all payment requests in main requests directory. It's not going to be efficient when we have thousands of thousands of payment requests. This patch spreads that files across two level of subdirectories.
This commit is contained in:
@@ -63,7 +63,7 @@ class WsClientThread(util.DaemonThread):
|
||||
def make_request(self, request_id):
|
||||
# read json file
|
||||
rdir = self.config.get('requests_dir')
|
||||
n = os.path.join(rdir, request_id + '.json')
|
||||
n = os.path.join(rdir, 'req', request_id[0], request_id[1], request_id, request_id + '.json')
|
||||
with open(n) as f:
|
||||
s = f.read()
|
||||
d = json.loads(s)
|
||||
|
||||
Reference in New Issue
Block a user