Replies: 3 comments 6 replies
-
In case of infinite loop what we will have ?
No enough gas happens while executing not before. I assume you wanted to say "failed for reason non-user (sc developer) designed" ?
I don't understand this point
For me this point out to something more bigger that we need to think of with the new API. What should be served by the node ? And what should be interpreted for the data we serve to create something more high level (like the block explorer that could serve an high level API). I don't think we want to include a lot of complex things directly in the node and in the module themself. @aoudiamoncef it would be nice to have your input on that |
Beta Was this translation helpful? Give feedback.
-
In any case, all kinds of polling will have very limited usefulness because blocks/ops are forgotten. Massa is fundamentally a streaming-oriented system. The best course would be that Execution reports every action it does and its outcome through an outbound GRPC stream. The client can then listen to all the events of interest, store them, notify the user etc... Example of stream (I wrote the entries in plaintext but it should be proto objects):
|
Beta Was this translation helpful? Give feedback.
-
IMHO, the polling model showed it's limits in the Massa API V1. If a resource(Block/Operation...etc) is designed to be forgot, we shouldn't confuse the client who thinks that the resource is idempotent. We should rely on external solutions to keep track and query the node produced data. In case of persisted resources, it's fine to have a simple RPC call. We could be verbose in term of generated events as it's designed in fire and forget model. But sometimes, we have to adjust some responses depending on the content of requests(at runtime) so every client will have a custom output. We should avoid introducing additional complexity to our node. |
Beta Was this translation helpful? Give feedback.
-
Context
This idea comes from a discussion with @damip following the work currently being done by @bilboquet in #3562.
Currently, if a user sends an operation in the network he has no information on the status of this operation. He knows only:
The PR about showing the execution status will add:
But the following information is still unavailable to the user:
Solution
The goal is to have some kind of execution report of what happened in which order for each slot. The data structure could be something like:
Now the question is what system would we rather have to handle the reports? Do we want to save them in the node and make them available through the API? Do we want emit the reports as they come and allow users to listen to them? Are other systems better suited for this purpose?
Beta Was this translation helpful? Give feedback.
All reactions