- Issue created by @scott_euser
- π¬π§United Kingdom scott_euser
Added test coverage for the event as well now, ready for review.
- πΊπΈUnited States AaronBauman Philadelphia
Thank you for the detailed description and the MR.
This is an interesting idea, I think we can make something work here.I don't like having these 2 different events one after another - one event should suffice. And I'd like to see it be a little less single-purpose.
Proposed changes:
1. Build this logic into existing PushParams event, rather than adding a new event
2. Allow subscriber to override push operation and choose any of update, upsert, or createSo maybe that looks like a new method on PushParams, which can be set by a subscriber to override whatever operation would have been selected in MappedObject::push
Does this make sense? I think it would solve your issue, as well as making this more useful in more scenarios.
- π¬π§United Kingdom scott_euser
Sure sounds good, thanks for the quick review!
- π¬π§United Kingdom scott_euser
Okay I believe this is now what you described, I moved the choice of action to before the push params event, then pass it as a new argument with set/get methods. Only odd thing is that push params event is also called in PullBase hence the default value being needed here as changing the action is only appropriate to the MappedObject context.
- πΊπΈUnited States AaronBauman Philadelphia
Looks good to me.
Thanks for jumping on that feedback so quickly.
I'll set to RTBC and get it into the next release.push params event is also called in PullBase
Probably the SalesforcePushParamsEvent in PullBase should be made into its own class.
Seems like it was shoehorned in there, and is not exactly appropriate for the use case.
That's outside the scope of this issue though. - π¬π§United Kingdom scott_euser
Yep makes sense to keep that separate
Thanks!