Github user ahgittin commented on the pull request:

    https://github.com/apache/incubator-brooklyn/pull/987#issuecomment-151469204
  
    I've added a comment on the double dispatch via `EntityRelations` statics:
    
    ```
    /** This abstract impl delegates to {@link EntityRelations} for all 
changes, routing through a local backing store.
     * This allows us to make the changes in both directions simultaneously 
when a relationship is bi-directional,
     * and should facilitate changing a backing datastore or remote instances 
when that is supported.
     * <p>
     * Currently it can be implemented without it, simplifying things a bit 
(avoiding the double dispatch)
     * apart from the {@link #add(Relationship, BrooklynObject)} method 
triggering the reverse addition
     * if it isn't already present. TBD which is better (and the internal call 
to get the backing store is 
     * marked as Beta). */
    ```
    
    WDYT?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to