首页 文章

Hyperledger面料,如何在代言前与外部应用程序进行交互?

提问于
浏览
1

我有一个带有 -P 'OR (ORG1.peer, ORG2.peer)' 认可政策的链码 . 当我使用命令 peer chaincode invoke ... 调用链代码时,它只接受交易提议而没有任何中断或等待认可 . 换句话说: endorsement logic 总是返回true . 根据this part of documentation

By default, endorsing logic at a peer accepts the tran-proposal and simply signs the tran-proposal. However, endorsing logic may interpret arbitrary functionality, to, e.g., interact with legacy systems with tran-proposal and tx as inputs to reach the decision whether to endorse a transaction or not.

现在我想覆盖这个逻辑,以便它在端口上侦听来自外部应用程序的接受或拒绝消息 .

可能吗?

如果是这样,我该怎么做?

我是否需要为fabric-peer构建自己的docker镜像?

我的认可逻辑, waiting for an external call (ex. the administrator of organization) 对现实世界的面料用例有什么意义吗?

1 回答

相关问题