From 664cf93668c0ce92750858f6aa40837b9d10edf8 Mon Sep 17 00:00:00 2001 From: Bryan Stitt Date: Tue, 27 Sep 2022 00:35:33 +0000 Subject: [PATCH] add influxdb to example prod config --- TODO.md | 4 ++++ docker-compose.prod.yml | 11 +++++++++++ 2 files changed, 15 insertions(+) diff --git a/TODO.md b/TODO.md index 3f96c54c..b0f27cd2 100644 --- a/TODO.md +++ b/TODO.md @@ -173,6 +173,7 @@ These are roughly in order of completition - since users are actively using our service, we will need to support both - [x] get to /, when not serving a websocket, should have a simple welcome page. maybe with a button to update your wallet. - [ ] active requests per second per api key +- [ ] parallel requests per api key - [ ] distribution of methods per api key (eth_call, eth_getLogs, etc.) - [-] let users choose a % to log (or maybe x/second). someone like curve logging all reverts will be a BIG database very quickly - this must be opt-in or spawned since it will slow things down and will make their calls less private @@ -183,6 +184,8 @@ These are roughly in order of completition - [ ] option to rotate api key - [ ] read the cookie key from a file. easy to re-use and no giant blob of hex in our app config - [ ] if no bearer token found in redis (likely because it expired), send 401 unauthorized +- [ ] user create script should allow a description field +- [ ] user create script should allow multiple keys per user ## V1 @@ -226,6 +229,7 @@ These are not yet ordered. - if total difficulty is not on the block and we aren't on ETH, fetch the full block instead of just the header - if total difficulty is set and non-zero, use it for consensus instead of just the number - [ ] if we subscribe to a server that is syncing, it gives us null block_data_limit. when it catches up, we don't ever send queries to it. we need to recheck block_data_limit +- [ ] we need concurrent requests limits. these should NOT throw rate limit exceeded, instead they should wait on a dashmap of semaphores. or maybe an unbounded cache of semaphores. if the request timeout is exceeded, then we can return a rate limit exceeded error new endpoints for users (not totally sure about the exact paths, but these features are all needed): diff --git a/docker-compose.prod.yml b/docker-compose.prod.yml index 78382a49..3921190e 100644 --- a/docker-compose.prod.yml +++ b/docker-compose.prod.yml @@ -28,6 +28,17 @@ services: environment: ADMINER_DEFAULT_SERVER: db + influxdb: + image: influxdb:latest + ports: + - '127.0.0.1:8086:8086' + volumes: + - ./data/influxdb:/var/lib/influxdb + environment: + - INFLUXDB_DB=db0 + - INFLUXDB_ADMIN_USER=web3_proxy + - INFLUXDB_ADMIN_PASSWORD=web3_proxy + arbitrum: extends: file: docker-compose.common.yml