Synthesis Of Distributed Protocols From Scenarios And Specifications