Topics

#fabric-questions #fabric-sdk-java will fabric sdk event listener get all commit peers call back? #fabric-questions #fabric-sdk-java


Juyuan Cai
 

Hi all,
    
    I am using Fabric-1.3 and java sdk. Everything goes fine, but a tiny question. For now, I have two peers. I use txlistener to listen to event when transaction is written to peer's ledger. So my question is, Since I have two peers, will sdk wait for all peers' call back result, and then give a notification that the transaction has been written to peer's ledger, or once sdk get one peer's call back,it will give a notification that the transaction has been written to peer's ledger ? I did many tests, it seems just need one peer's call back because I only got one peer's result  randomly from the sdk's side if I use debug mode. However, the sdk would still wait until timeout if I shut one peer down. So That makes me very confused, could any one help me about this?  Thank you very much!