I have an aggregate which has a 1 to many relationship with an entity. For this I have a collection attribute in my aggregate annotated with @org.axonframework.modelling.command.AggregateMember(type=MyEntity.class). I have command handler methods in the entity. I have gone through this https://docs.axoniq.io/reference-guide/implementing-domain-logic/command-handling/multi-entity-aggregates but it is not clear to me how the routing of the command will happen to the entity instance. How would axon identify the entity instance to route the command?
Is there any example of how the commands can be routed to the entity class? I am not seeing the entity class shown in documentation in the gift card demo source.