870 Commits

Author SHA1 Message Date
Sergi Delgado Segura
3767412cb9 Merge branch 'master' into master 2020-06-15 11:30:01 +02:00
Sergi Delgado Segura
f684b91807 Merge pull request #149 from sr-gi/138-locator-cache
Adds locator cache to the Watcher
2020-06-15 11:29:17 +02:00
Sergi Delgado Segura
a49e587d7c watcher - adds RWLocks for the LocatorCache
Threads should aboit reading the cache when it is being updated/fixed. The latter is specially relevant since during a reorg most of the cache may change.
2020-06-15 11:25:26 +02:00
Sergi Delgado Segura
5748c73da3 plugin - Adds start_block log after an accepted appointment 2020-06-12 12:10:57 +02:00
Sergi Delgado Segura
4c66d6c2cd cli - Adds start_block log after an accepted appointment 2020-06-12 12:10:45 +02:00
Sergi Delgado Segura
6d48041906 tests - Adds checks of overwritten fields in the ConfigLoader 2020-06-11 16:56:58 +02:00
Sergi Delgado Segura
3c1b646065 tests - Adds test for get_default_rpc_port and removes useless tests 2020-06-11 16:56:58 +02:00
Sergi Delgado Segura
782806595c general - Adds default RPC port based on network param 2020-06-11 16:56:58 +02:00
Sergi Delgado Segura
4621a08dc5 docs - nits 2020-06-11 16:56:58 +02:00
Sergi Delgado Segura
7d5e595be3 docs - Bind API to all the interfaces of the container
Fixes the issues that requests could not be sent from the host in Windows and Mac by binding the API to all the container interfaces instead of only localhost.
This may create issues with get_all_appointments, since it can only be called from inside the container. Not a big deal since that's more of a dev endpoint, but it'll
be nice to give it a fix eventually.
2020-06-11 16:56:53 +02:00
Sergi Delgado Segura
df326465a7 watcher - Updates the LocatorCache so it is self handled
With the current approach the cache deals with deletion and provides getters and setters so consumers do not directly access the internals
2020-06-10 17:44:50 +02:00
Sergi Delgado Segura
2facd61f6c teos - addresses minor comments from #149 2020-06-09 16:59:01 +02:00
Sergi Delgado Segura
3f8bc46bc3 docs - Adds volumes to docker 2020-06-09 11:52:53 +02:00
Sergi Delgado Segura
6698a1a892 docs - updates readme with feed data 2020-06-09 09:45:00 +02:00
Sergi Delgado Segura
10da7d2a10 teos - feed_* -> btc_feed_* 2020-06-09 09:44:52 +02:00
Sergi Delgado Segura
d91e9bb534 Updates README with docker section 2020-06-08 23:29:03 +02:00
Sergi Delgado Segura
7da2933c48 Move files to docker/ and fixes Dockerfile and entrypoint 2020-06-08 23:28:50 +02:00
Sergi Delgado Segura
2f3ee89bd9 Merge branch 'master' of git://github.com/aljazceru/python-teos into aljazceru-master 2020-06-05 13:35:06 +02:00
Sergi Delgado Segura
08c794590c teos - additional docs 2020-06-03 17:39:27 +02:00
Sergi Delgado Segura
6ea3e8e3ff watcher - simplifies locator_cache and check_breach
locator_cache.blocks was storing a dictionary with both the locator and txid pair, when only the locators were actually necessary. Reworks the code a bit to only use locators.
check_breach was returning some values that could be worked out from the unaltered inputs.

Also fixes some comments and docs.
2020-06-03 17:23:29 +02:00
Sergi Delgado Segura
37d1bd9b12 testing - fixes e2e test utxo management
e2e tests where reusing utxos for transactions that where not confirmed, meaning than some times we were actually sending the same appointment over and over.
2020-06-02 20:05:13 +02:00
Sergi Delgado Segura
837f7d428a watcher - Fixes cache setup for regtest
Cache setup in regtest was raising some warnings due to the blocks not being found
2020-06-02 20:05:03 +02:00
Sergi Delgado Segura
e1aab63940 tests - unit tests LocatorCache reorg protection 2020-05-22 19:57:48 +02:00
Sergi Delgado Segura
5af0658720 watcher - Adds reorg protection for the LocatorCache 2020-05-22 19:57:20 +02:00
Sergi Delgado Segura
2a52006c03 tests - Removes Wartcher from LocatorCache tests 2020-05-22 19:56:16 +02:00
Sergi Delgado Segura
77d1ea21c8 teos - BLOCK_CACHE_SIZE -> LOCATOR_CACHE_SIZE 2020-05-22 19:56:11 +02:00
Sergi Delgado Segura
c05f96b738 tests - Adds e2e tests to cover the cache 2020-05-22 18:25:08 +02:00
Sergi Delgado Segura
386642ff42 Adds checks of add_appointment returning current block 2020-05-22 14:18:37 +02:00
Sergi Delgado Segura
76e4780f4c teos - Adds start_block to add_appointment response 2020-05-21 19:39:42 +02:00
Sergi Delgado Segura
708f2e1f3b teos - Changes the behavior for updates of already triggered appointments
If an update for an already triggered appointment is received, it will be drop no matter if the locator is in the cache or not. This tries to prevent inconsistencies between the Watcher and the Responder, specially in the case of a reorg when data may have to flow backwards.
2020-05-21 19:37:33 +02:00
Sergi Delgado Segura
3228eeac6b tests - Adds LocatorCache unittests and updates existing ones to match 2020-05-21 17:06:20 +02:00
Sergi Delgado Segura
17128edada teos - Renames get_locator to check_locator, adds LocatorCache.init and docstrings 2020-05-21 16:40:36 +02:00
Sergi Delgado Segura
699da54aa0 teos - Adds LocatorCache 2020-05-19 18:24:40 +02:00
Sergi Delgado Segura
9c10f7964f teosd- First bits of locator cache 2020-05-18 20:40:17 +02:00
Sergi Delgado Segura
01bf857161 Merge pull request #145 from talaia-labs/cli-readme
Cli readme
2020-05-08 20:11:28 +02:00
Sergi Delgado Segura
6855168e30 Merge branch 'master' into cli-readme 2020-05-08 20:02:45 +02:00
Sergi Delgado Segura
8a9e985362 Merge pull request #144 from talaia-labs/cmd_params_hotfix
Fixes cmd parameters edge cases
2020-05-08 20:02:33 +02:00
Sergi Delgado Segura
cdf8a94284 Merge branch 'master' into cmd_params_hotfix 2020-05-08 19:57:08 +02:00
Sergi Delgado Segura
3405490a10 cli - Updates README 2020-05-08 19:55:31 +02:00
Sergi Delgado Segura
1a8bdad3f3 Merge pull request #143 from talaia-labs/watchtower-plugin
Watchtower plugin
2020-05-08 19:48:54 +02:00
Sergi Delgado Segura
d5dc833bf5 datadir and apibind were not properly working 2020-05-08 19:43:56 +02:00
Sergi Delgado Segura
e91f65048d cli - fixes cli without params
Cli was crashing if no param was provided
2020-05-08 19:43:56 +02:00
Sergi Delgado Segura
f2162b6add plugin - Improves README and defaults misbehaving_proof to empty dict 2020-05-08 19:43:08 +02:00
Sergi Delgado Segura
445d4c0aca plugin - Adds README 2020-05-07 15:10:36 +02:00
Sergi Delgado Segura
1f1fa161cf Merge pull request #142 from talaia-labs/pypi_common
Adds common module to PyPi
2020-05-07 12:01:40 +02:00
Sergi Delgado Segura
a2c010b685 Adds teos-common requirements to the plugin 2020-05-07 11:43:57 +02:00
Sergi Delgado Segura
63cd55c1c6 plugin - removes unused commented line 2020-05-07 11:41:41 +02:00
Sergi Delgado Segura
07e00c2e5e common - Adds requirements for common (added to PyPi) 2020-05-07 10:13:33 +02:00
Sergi Delgado Segura
304af4f8b9 Updates gitignore 2020-05-06 22:49:04 +02:00
Sergi Delgado Segura
0c5ad56a84 Adds common to pypi under teos-common 2020-05-06 22:48:59 +02:00