Add purge to ProducerInterface#16
Conversation
d8228ac to
dc5bef3
Compare
d626d09 to
97cab30
Compare
There was a problem hiding this comment.
Why the less specific PHPDoc argument?
There was a problem hiding this comment.
Personal preference as the type hint is for array, but happy to undo.
There was a problem hiding this comment.
ah, I see. I'm sure it's fine then.
dc5bef3 to
8972b9b
Compare
|
looks good otherwise (not tested). |
e936770 to
86956d0
Compare
There was a problem hiding this comment.
Given the talk today, any thoughts on this @wpillar?
There was a problem hiding this comment.
Here are my thoughts:
ClientimplementsProducerInterfaceandClientInterface, so addingpurge()toProducerInterfacedoes not unreasonably affect that class.- You've already got segregated interfaces in
ProducerInterfaceandClientInterfaceand sinceClientimplements both, the only consideration really is how people might extend this code. Are we burdening people who might write separateProducerInterfaceimplementations with a method they can't implement? My thinking here is if we could reasonably assume that all queue implementations have a way of purging then it's fine to put this onProducerInterface, as a purge operation is similar to a send operation. If we think this assumption is unreasonable then you can segregate further with aPurgeableInterface.
What's your thinking on this?
There was a problem hiding this comment.
My thinking here is if we could reasonably assume that all queue implementations have a way of purging then it's fine to put this on ProducerInterface, as a purge operation is similar to a send operation.
So far it's 👌, but I doubt every queue implementation supports purging.
We're not 1.0.0, so I'm going to go with this and see what Mat thinks if he makes use of it.
86956d0 to
0da424b
Compare
Add purge to ProducerInterface
Initial draft for resolving #14.
Depends on / based off #15.
Adds the
purgemethod toProductInterface.