-
Notifications
You must be signed in to change notification settings - Fork 0
360/handle calls with stbx protocol #362
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
Conversation
…store to stbx-store
…ions of the single stores
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.
Looks cool Marco! Green checkmarks all around. I'll now post some things I noticed at first glance here, and then Imma poke around in various bits of the code and push some minor, non-controversial things like we discussed. We can address more intricate stuff in a collab session as needed.
import Statebox.Protocol.Store (StoreActions, StoreActionF(..)) | ||
import Statebox.Store (Actions, get, put) | ||
|
||
data MultipleStoresActionF a |
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.
It's a single store, sort of, but 'many-sorted'.
|
||
type ExecutionStateDictionary = Map TxId ExecutionStateDictionaryValue | ||
|
||
type AppState = Tuple (Ref TransactionDictionary) (Ref ExecutionStateDictionary) |
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 think a (wrapped?) record might be nicer and clearer here than a Tuple
, unless there's a specific reason for the latter. I guess with records, especially unwrapped ones, the Applicative wouldn't work anymore... What do you think?
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.
If I remember correctly, initially I had a record here and then I changed it to a Tuple
when worked on the Embeddable
stuff. I could try to change it back again
Thanks Marco, great work! 👍 |
this uses the protocol to process requests in the http service