-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: handle eligible deal stats via spark-api #206
Conversation
Rework the endpoints `{miner/client/allocator}/:id/deals/eligible/summary` to return a (temporary) redirect to spark-api. Signed-off-by: Miroslav Bajtoš <oss@bajtos.net>
@@ -17,7 +18,7 @@ const logger = { | |||
request: ['1', 'true'].includes(REQUEST_LOGGING) ? console.info : () => {} | |||
} | |||
|
|||
const handler = createHandler({ pgPools, logger }) | |||
const handler = createHandler({ SPARK_API_BASE_URL, pgPools, logger }) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
in this PR, SPARK_API_BASE_URL
is never overridden, so it should be removed from args and added to config instead
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I want to make this configurable via env vars so we can run spark-stats locally with redirects to the local spark-api instance. With your proposal, I would have to edit the local config file and then remember to discard the changes before committing to git.
In that light, do you still prefer to move this to the config file? I don't have a strong opinion.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Got it, I didn't see that possibility. I never run these services in dev 😅
@bajtos there's a type error |
Co-authored-by: Julian Gruber <julian@juliangruber.com>
Co-authored-by: Julian Gruber <julian@juliangruber.com>
Signed-off-by: Miroslav Bajtoš <oss@bajtos.net>
Do you know why we don't run |
Signed-off-by: Miroslav Bajtoš <oss@bajtos.net>
Signed-off-by: Miroslav Bajtoš <oss@bajtos.net>
All CI checks are green now 🚀 |
Yes please add that 👌 |
Signed-off-by: Miroslav Bajtoš <oss@bajtos.net>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👏
Rework the endpoints
{miner/client/allocator}/:id/deals/eligible/summary
to return a (temporary) redirect to spark-api, as discussed in #194 (comment).Links: