thephpleague / tactician-bundle

Bundle to integrate Tactician with Symfony projects
MIT License
245 stars 43 forks source link

Tactician v2 #115

Open simPod opened 5 years ago

simPod commented 5 years ago

I started working on v2

rosstuck commented 5 years ago

Hey, thanks for getting the jump on this. I confess I'm not using Symfony anymore so I was dreading this a bit. :sweat_smile:

To answer some of your questions:

Also because I haven't written these down anywhere, here's my paper sketch ideas for Bundle 2.0

Anyways, none of that second part is a hard contract, just something to keep in mind. :)

simPod commented 4 years ago

@rosstuck The problem with debug command is, that we know only handlers on container build.

The mapping happens in CommandHandlerMiddleware by running $this->mapping->getClassName($commandClassName).

We would have to implement reverse mapping and run handlers through it to generate mapping up front. Currently, I don't see a way to do it 🤔

simPod commented 4 years ago

I see the tag based mapping/handling stuff was deleted in this PR but I think it might still be needed. Don't forget, the bundle has some other features base tactician doesn't have (yet) like detecting mapping based on typehints.

I decided to revisit it when the rest is done. After looking into it for a while, does not seem that trivial.

simPod commented 4 years ago

Just to be sure, it's correct to drop service locator, amirite?