Uploaded image for project: 'Doctrine 2 - ORM'
  1. Doctrine 2 - ORM
  2. DDC-21

Already fetched associations should not be overriden by subsequent queries.

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0-ALPHA3
    • Component/s: ORM
    • Security Level: All
    • Labels:
      None

      Description

      The discussion about this was brought up by DC-41. After checking the behavior of other ORMs (notably Hibernate), already fetched associations should not be overridden by subsequent queries, just like with other persistent state of already fetched entities. This saves performance and can assure a better integrity of the object model in-memory.

      Entities and their associations that are already in-memory should only be refreshed if this is done explicitly either through EntityManager#refresh($entity) or through using the Query::HINT_REFRESH query hint on any query.

        Issue Links

          Activity

            People

            • Assignee:
              romanb Roman S. Borschel
              Reporter:
              romanb Roman S. Borschel
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: