I have a question about sharing contracts between services using a message broker (more specifically, Azure Service Bus). I searched for it in various articles and asked a chatbot, but I didn't get a clear answer.
I'm talking about topic topology. Let's say I have services called Order, Cart, and Monitoring. Until now, I thought that an order was created in the Order service and published an event called "order created." Anyone could respond to this event as needed. The owner of this contract (Order) is the Order service—this really means that there is a SharedContracts project and that's where it is. Anyone who wants to subscribe to it will pull in the dependency (it doesn't matter how, for example, Nuget).
However, I have now read that there should be one shared project where all contracts are stored.
My question: What is more suitable in terms of designing a large application with many services?
Thank you very much.