IntersectMBO / cardano-node

The core component that is used to participate in a Cardano decentralised blockchain.
https://cardano.org
Apache License 2.0
3.05k stars 721 forks source link

[FR] - executeLocalStateQueryExpr allow tx submission, short-term solution #4358

Open cleverca22 opened 2 years ago

cleverca22 commented 2 years ago

Internal

Describe the feature you'd like executeLocalStateQueryExpr currently sets localTxSubmissionClient = Nothing so there is no way to submit transactions over the same connection as the state query monad

the short-term solution i can see, is to just expose the 2 Maybe's for localTxSubmissionClient and localTxMonitoringClient, and just make those into arguments for executeLocalStateQueryExpr the call-site can then either Nothing Nothing those args to maintain the old behaviour, or they can Just submissionClient to supply a client

the long-term solution i can see, is for the localTxSubmissionClient to also support a monad based interface, like how executeLocalStateQueryExpr adds tolocalStateQueryClient: https://github.com/input-output-hk/cardano-node/issues/4357

CarlosLopezDeLara commented 2 years ago

Reference conversation @newhoggy

https://input-output-rnd.slack.com/archives/G011N23CEAE/p1660788859942189