Doctrine 2 - ORM
  1. Doctrine 2 - ORM
  2. DDC-561

Metadata caching broken due to incomplete __sleep functions

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.0-BETA2
    • Component/s: Mapping Drivers
    • Security Level: All
    • Labels:
      None

      Description

      When using a persistent Metadata cache, the serialized ClassMetadata objects are not complete.

      This leads to very strange behavior since not all Metadata is loaded in the next request (which uses cached Metadata). The problem is that the __sleep methods of Doctrine\ORM\Mapping\AssociationMapping and Doctrine\ORM\Mapping\ClassMetadata are note complete (missing "namespace", "fetchMode" properties).

        Activity

        Nico Kaiser created issue -
        Hide
        Nico Kaiser added a comment -

        This patch fixes the issue for AssociationMapping and ClassMetadata. I'm not sure if there are more properties missing...

        Show
        Nico Kaiser added a comment - This patch fixes the issue for AssociationMapping and ClassMetadata. I'm not sure if there are more properties missing...
        Nico Kaiser made changes -
        Field Original Value New Value
        Attachment ddc-561.patch [ 10588 ]
        Hide
        Roman S. Borschel added a comment -

        Ouch, bad oversight. Sorry for that. We do actually have tests for serializing and unserializing the metadata, obviously not enough... will fix it asap.

        Show
        Roman S. Borschel added a comment - Ouch, bad oversight. Sorry for that. We do actually have tests for serializing and unserializing the metadata, obviously not enough... will fix it asap.
        Show
        Roman S. Borschel added a comment - Fixed in http://github.com/doctrine/doctrine2/commit/db2be55e27c87fa513073b2bf44456f1d1423582 . Thanks for your help.
        Roman S. Borschel made changes -
        Status Open [ 1 ] Closed [ 6 ]
        Fix Version/s 2.0-BETA2 [ 10050 ]
        Resolution Fixed [ 1 ]
        Hide
        Benjamin Eberlei added a comment -

        Should we re-release Beta1? This is pretty serious and might annoy people

        Show
        Benjamin Eberlei added a comment - Should we re-release Beta1? This is pretty serious and might annoy people
        Hide
        Roman S. Borschel added a comment -

        Hehe, no its fine. You can easily patch it manually if needed and beta2 is only a few weeks away.

        Show
        Roman S. Borschel added a comment - Hehe, no its fine. You can easily patch it manually if needed and beta2 is only a few weeks away.
        Hide
        Roman S. Borschel added a comment -

        And you can just use HEAD and not the tag, of course

        Show
        Roman S. Borschel added a comment - And you can just use HEAD and not the tag, of course
        Benjamin Eberlei made changes -
        Workflow jira [ 11300 ] jira-feedback [ 15622 ]
        Benjamin Eberlei made changes -
        Workflow jira-feedback [ 15622 ] jira-feedback2 [ 17486 ]
        Benjamin Eberlei made changes -
        Workflow jira-feedback2 [ 17486 ] jira-feedback3 [ 19743 ]

        This list may be incomplete, as errors occurred whilst retrieving source from linked applications:

        • Request to http://www.doctrine-project.org/fisheye/ failed: Error in remote call to 'FishEye 0 (http://www.doctrine-project.org/fisheye/)' (http://www.doctrine-project.org/fisheye) [AbstractRestCommand{path='/rest-service-fe/search-v1/crossRepositoryQuery', params={query=DDC-561, expand=changesets[0:20].revisions[0:29],reviews}, methodType=GET}] : Received status code 503 (Service Temporarily Unavailable)

          People

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

            Dates

            • Created:
              Updated:
              Resolved: