LayerXcom / cordage

Cordage: the blockchain interoperability project!
https://layerxcom.github.io/cordage/en/
Other
52 stars 6 forks source link

fix: event watch flow bugs #52

Closed etaroid closed 4 years ago

shun-tak commented 4 years ago

@etaroid Why don't you remove rpcUrl from resources/config.conf as well?

etaroid commented 4 years ago

@shun-tak The rpcUrl is also used in other flows, so we can't delete it. Only EventWatchFlow can't use the rpcUrl in config.conf because it can't access the serviceHub in companion object.

In EventWatchFlow, the web3 instance must be made as singleton because the call() is repeatedly called. Therefore, the rpcUrl must be referenced by companion object.