Commit Graph

7373 Commits

Author SHA1 Message Date
Jude Nelson
d69734656b use the right query formatter 2018-02-08 19:16:28 -05:00
Jude Nelson
61b9ec1b93 use dedicated variable for queue file name 2018-02-08 19:16:15 -05:00
Jude Nelson
fc50f48fc9 handle timeouts in db queries 2018-02-08 19:16:06 -05:00
Jude Nelson
ec0d37cb20 handle db timeouts in the queue creation 2018-02-08 19:15:55 -05:00
Jude Nelson
8ce40b5462 fix up bugs in imports and packages 2018-02-08 19:15:12 -05:00
Jude Nelson
2d4c1af141 bugfixes: use the right variable; don't set the ping result to None unless there's an error 2018-02-08 19:13:26 -05:00
Jude Nelson
ce69ff0add better logging of peer discovery 2018-02-08 19:13:14 -05:00
Jude Nelson
0a774e8492 do not depend on blockstack_client (#720) 2018-02-08 19:12:56 -05:00
Jude Nelson
e03434e50e Merge branch 'feature/clean-chainstate' into feature/blockstackd-subdomain-indexing 2018-02-08 17:02:32 -05:00
Jude Nelson
841f1bbe93 do peer exchange in addition to getting atlas peers 2018-02-08 17:02:04 -05:00
Jude Nelson
f65ab918ba use atlas_peer_exchange() over get_atlas_peers() 2018-02-08 17:01:47 -05:00
Jude Nelson
e1e6dee503 add atlas_peer_exchange() call 2018-02-08 17:01:36 -05:00
Jude Nelson
4607063c98 make sure subdomain transfers can only happen on their domains 2018-02-07 19:06:29 -05:00
Jude Nelson
bdd448c496 verify that adding the "_missing" TXT RR stops a subdomain from showing up as pending if only the listed zone files are actually missing 2018-02-07 19:06:02 -05:00
Jude Nelson
708c1c002b make sure we can reorg a pending subdomain's owner history, but that it shows as not pending once reorged 2018-02-07 19:05:38 -05:00
Jude Nelson
b03a1f13e2 verify that domain names show up as pending if the domain name is missing any zone files 2018-02-07 19:05:20 -05:00
Jude Nelson
8f68a98edd verify that we can transfer subdomains via their domain names 2018-02-07 19:04:56 -05:00
Jude Nelson
18cfa89bf9 make sure we change the domain name on each update 2018-02-07 19:04:18 -05:00
Jude Nelson
7173c91e3b really test independence--change the domain name each time we send an update 2018-02-07 19:03:37 -05:00
Jude Nelson
47ffb6c655 add db_format_query 2018-02-07 19:02:49 -05:00
Jude Nelson
821e7d4d62 rewrite subdomain processor to support history reorgs on subdomains based on ownership or sequence number conflicts, and have the subdomain query method determine at runtime whether or not the subdomain is in a "pending" state (i.e. are there missing zone files out there that could reorg the subdomain's owner) 2018-02-07 19:02:02 -05:00
Jude Nelson
9091720bd3 add 'pending' field 2018-02-07 19:01:50 -05:00
Jude Nelson
79742bc8c1 use db_format_query 2018-02-07 19:01:43 -05:00
Jude Nelson
68c0b1fd33 add method to count missing zone files by name 2018-02-07 19:01:28 -05:00
Jude Nelson
c462acb53d report pending status on subdomains 2018-02-07 19:01:18 -05:00
Jude Nelson
3b4bdc1718 remove blockstack_client in a few places; be more judicious about how we compare subdomain databases 2018-02-02 18:41:22 -05:00
Jude Nelson
b9ad8cba1d WIP: address some of the concerns in #726. Only allow an address-change from a subdomain's creator domain (for now; needs testing). Also, be more efficient in how we address subdomain reorgs 2018-02-02 18:40:25 -05:00
Jude Nelson
13c415cb6e not required to build up the subdomain index using the instance provided in the db state 2018-02-02 18:39:51 -05:00
Jude Nelson
11e4b40802 more methods moved from blockstack_client/proxy.py to blockstack/lib/client.py 2018-02-02 18:39:33 -05:00
Jude Nelson
98c69d139a remove dead code; return JSON on subdomain lookup 2018-02-02 18:39:18 -05:00
Jude Nelson
20097b00df make sure that when we give zone files sequentially, that subdomain updates spanning different names' zone files are still processed in the right order 2018-01-30 17:51:48 -05:00
Jude Nelson
dbe1dd78b4 verify that when we reorganize a subdomain's history, that regardless of which zone file contains its updates, we always rebuild its history off of the earliest-discovered name transfer 2018-01-30 17:51:20 -05:00
Jude Nelson
7361eb012e when reorganizing a subdomain's history, make sure that if an earlier transfer gets discovered, we invalidate the subsequent history and build off of the earliest transfer 2018-01-30 17:50:54 -05:00
Jude Nelson
c9732038ed verify that no matter which zone file a subdomain arrives in, we correctly reorganize its history to reflect the earliest valid sequence numbers for each update 2018-01-30 17:50:21 -05:00
Jude Nelson
3d8fb3d44a test that zone files that arrive out of order cause the subdomains' histories to be reorganized internally, selecting the earliest records with a given sequence 2018-01-30 17:49:46 -05:00
Jude Nelson
5e58703099 test that the arrival of multiple subdomain updates with the same sequence number selects the earliest valid one 2018-01-30 17:49:14 -05:00
Jude Nelson
8585237e29 verify that we do not create zone files until the initial zone file that created it arrives. verify that this works when subdomains are updated across domain names 2018-01-30 17:48:48 -05:00
Jude Nelson
33ab09f3ac test subdomain processing works when the initial subdomain records get lost, but subsequent ones arrive. verify that they are not processed until the initial subdomain record is discovered 2018-01-30 17:48:17 -05:00
Jude Nelson
cf06b77bb9 test subdomain db reindexing 2018-01-30 17:48:06 -05:00
Jude Nelson
43c5065478 verify that we cannot accept subdomain creation from names for which we do not have all zone files 2018-01-30 17:47:45 -05:00
Jude Nelson
90a32b7627 test when zone files arrive in different orders, leaving holes in the history. test that this also works when subdomain records are spread across multiple domains 2018-01-30 17:47:22 -05:00
Jude Nelson
4a3b19515e test subdomain processing when some zone files arrive but others do not, leaving holes in the history. 2018-01-30 17:46:56 -05:00
Jude Nelson
6a97e023ec test subdomain processing when zone files arrive in reverse order, and subdomains are spread across multiple domains 2018-01-30 17:46:38 -05:00
Jude Nelson
7ffc0ad97e test subdomain processing when zone files arrive in batches, and subdomain records are on different zone files than those belonging to their stem names 2018-01-30 17:45:53 -05:00
Jude Nelson
cf912947a8 test that we will "discover" zone files even if they're already present 2018-01-30 17:45:33 -05:00
Jude Nelson
8ba80dbd88 add method to reindex subdomains and verify that they are consistent with the subdomain db calculated by discovering zonefiles 2018-01-30 17:44:30 -05:00
Jude Nelson
46e544088d make sure we can reindex from scratch 2018-01-30 17:44:20 -05:00
Jude Nelson
2f8ffca1da make sure we can reindex from scratch 2018-01-30 17:44:09 -05:00
Jude Nelson
643fc62f23 make sure we can reindex from scratch 2018-01-30 17:43:50 -05:00
Jude Nelson
db95a49021 make sure the atlasdb and subdomaindb are preserved on fastsync 2018-01-30 17:43:35 -05:00