Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Expose Comparers and More Information on Push/Update Methods #188

Open
rwemay opened this issue Feb 7, 2020 · 0 comments
Open

Expose Comparers and More Information on Push/Update Methods #188

rwemay opened this issue Feb 7, 2020 · 0 comments
Assignees
Labels
type:feature New capability or enhancement

Comments

@rwemay
Copy link
Member

rwemay commented Feb 7, 2020

Description:

The current default behavior on create or update in the adapters is to overwrite the properties of objects if they meet the comparer conditions. When properties of objects are overwritten, there is no information back to the user that this has happened. I think that a) we should be providing this feedback to the user as a warning, and b) we should allow for an overwriteProperties boolean, either in the adapter settings or actionConfig. A few suggestions:

    1. There should be a warning back to users where properties of any objects have been overwritten. If this can be helped with at the adapter level that would be good, not sure if that's possible.
    1. In order not to flood the UI with warnings I think we could have one-per object type, and then refer the user to a PushReport. I do think we need to include a PushReport as an output to every Push - whether this is part of the 'success' bool + object or otherwise. The report should be a full report on what the adapter has done to each object, similar to a lot of plugins/interop.
    1. I think we should make it possible to pass comparers to the adapters. I don't have a good recommendation on where for this - adapter or push, but naturally makes more sense on Push since comparer isn't relevant(?) for pull (could be relevant for delete?). Either as a new input to the Push component (but then it's getting to big) or as a standard/default actionConfig. This would be the 'advanced user' option as they'd need to construct comparers (that are exposed), and possibly also dependency types.
    1. In addition to 3. I think good to add some more human-readable comparer settings, e.g. overwriteProperties. Again, naturally feels should be on the actionConfig, and perhaps we have a standard 'actionConfig' that has some default/high level options like overwriteProperties.

I've prototyped a lot of this in the now very messy (and needing to be re-PR'd) Robot_Toolkit update panel code here https://github.com/BHoM/Robot_Toolkit/pull/310/files

@IsakNaslundBh , @alelom , I'm going to re-PR/tidy up the Robot PR, and perhaps we can pick this up with a specific meeting next week to review/move forward. For now, in the Robot PR, I'll limit the 'framework' changes and stick to the current approaches.

@rwemay rwemay added the type:feature New capability or enhancement label Feb 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:feature New capability or enhancement
Projects
None yet
Development

No branches or pull requests

3 participants