-
Notifications
You must be signed in to change notification settings - Fork 151
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
Inject sdk cache configuration to agents #856
Inject sdk cache configuration to agents #856
Conversation
// These values will be injected into the agent container to configure SDK | ||
// SDKRequestTimeout timeout until the SDK must fallback to the RPC Node | ||
// Value in seconds and can be a float. | ||
SDKRequestTimeout = "5" |
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 would rename this to SDKRequestTimeoutSeconds
and make it 20 if the chain data bucket interval is 10s. Also I think I would exclude the word SDK
from any naming - the bot could be based on anything. Maybe BotCacheRequestTimeout
kind of naming could be used.
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.
Good point. Fixed. Thanks
SDKRequestTimeout = "5" | ||
// SDKRequestInterval interval between SDK requests | ||
// Value in seconds and can be a float. | ||
SDKRequestInterval = "1" |
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.
Let's append Seconds
to the name.
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.
Good point. Fixed. Thanks
config/env.go
Outdated
|
||
EnvJsonRpcHost = "JSON_RPC_HOST" | ||
EnvJsonRpcPort = "JSON_RPC_PORT" | ||
EnvCacheJsonRpcCachePort = "CACHE_JSON_RPC_PORT" |
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.
Can we prefix all of these new cache env vars like JSON_RPC_CACHE_*
? E.g. JSON_RPC_CACHE_PORT
, JSON_RPC_CACHE_REQUEST_TIMEOUT
etc. Prefixing with CACHE
could be confusing if we introduce another cache for the bots to use.
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.
Good point. Fixed. Thanks
e3386d5
to
62efc2b
Compare
ce1e967
into
kisel/forta-1609-accept-json-rpc-cache-requests-from-bots
No description provided.