stub.GetHistoryKeys()报告GetHistoryKeys()函数未定义。 当尝试去建立我的Chaincode

I am new to Hyperledger .I am using docker to run Hyperledger. Pulled hyperledger/fabric-peer:latest from Docker hub and able to run stub.CreateTable() ,stub.GetRows() , stub.InsertRows() and some other functions in my Chaincode. But when i tried to run

stub.GetHistoryKeys() or stub.GetCompositeKeys() ...etc in my chaincode It's reporting an error

 stub.GetHistoryForKey undefined (type shim.ChaincodeStubInterface has no field 
  or method GetHistoryForKey)

I found that in my interface.go file there are no such functions . Googled a lot but found nothing .Can anyone tell the correct hyperledger/fabric-peer image to pull so that the above functions can run in Chaincode.

查看全部
doudoulb1234
doudoulb1234
2017/04/24 06:34
  • hyperledger
  • blockchain
  • docker
  • 点赞
  • 收藏
  • 回答
    私信
满意答案
查看全部

2个回复