-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
MpoolPushUntrusted API for gateway #3915
Conversation
mp.curTsLk.Unlock() | ||
|
||
mp.lk.Lock() | ||
if err := mp.addLocal(m, msgb); err != nil { |
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.
we don't still want to do addLocal do we?
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.
Well, I am ambivalent about this; if we don't the messages will be transient, ie they might disappear in the next prune.
We can certainly remove the addLocal
incantation.
@@ -55,6 +55,7 @@ var baseFeeLowerBoundFactor = types.NewInt(10) | |||
var baseFeeLowerBoundFactorConservative = types.NewInt(100) | |||
|
|||
var MaxActorPendingMessages = 1000 | |||
var MaxUntrustedActorPendingMessages = 10 |
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.
- Do we use that for messages coming from the messages pubsub?
- If yes, that's likely way too low, many bigger miners have many more messages that that per tipset
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.
no, we only use it for the gateway -- messages coming from pubsub use Add
.
@vyzo Please tell me how to quickly access lotus gateway, such as client.NewGatewayRPC and GetGatewayAPI |
Adds an mpool API for the gateway to push messages, PushUntrusted.
The difference with Push is that strict checks are enabled and in addition there are no nonce gaps
allowed and the number of pending messages for each actor is severely limited.
Hopefully this will make the gateway usable without much fear of spam.