spring-modulith icon indicating copy to clipboard operation
spring-modulith copied to clipboard

Modules PUML diagram to follow event dispatch source

Open znaczek opened this issue 1 year ago • 1 comments
trafficstars

I have 3 domain modules:

  • Orders,
  • Products,
  • Payments.

To avoid having too many similar/identical DTOs/events in the above modules, I decided to put them in a Shared module of typeApplicationModule.Type.OPEN. I've set up async communication between them using @EventListener/@TransactionalEventListener.

When I generate docs with Documenter#writeModulesAsPlantUml I am getting a diagram, where business modules listen to Shared module: image while I would expect something like: image

As I understand based on the above images, doc generator simply checks in which module an event class resides. To get the desired output, it might check in which module an event class is dispatched instead.

Would that be possible?

znaczek avatar Jul 14 '24 15:07 znaczek