Details

    • Type: Improvement Improvement
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 1.2.1
    • Fix Version/s: 1.2.2, 1.3.0, 2.0.0-beta
    • Component/s: kernel
    • Labels:
      None

      Description

      In performance runs, a lot of the time is spent on detach processing. This is partially because a detach all is always done after an EntityManager clear() or close(). Therefore, we nee to make the detach processing as efficient as possible. There are 2 areas that we've found where this can be done:

      1 - DetachManager always attempts to load fields when detaching all. This does not appear to be necessary when the default DetachState option of "loaded" is used.

      2 - Detach goes through a bunch of processing to "detach version", which essentially copies the version to the entity that is to be returned. But, when detach all internal is, no copy is being made of the original entity. And, it appears that the original entity always has the version. So, this processing is not necessary in this scenario.

      To be cautious, a new Compatibility property option is being created - reloadOnDetach - to control both of these behavior. In 1.2.x, it will be true by default, so behavior will not be changed for current users. The user will have to set this property to false in order to get the performance benefit.

      If all goes well, the property will be set to false by default in 2.0.

      1. 2.0_doc_patch.txt
        2 kB
        Dianne Richards
      2. 1.2.x_doc_patch.txt
        3 kB
        Dianne Richards
      3. DM_testcase_patch.txt
        11 kB
        Dianne Richards
      4. DM_2.0_patch.txt
        5 kB
        Dianne Richards
      5. DM_1.2.x_patch.txt
        6 kB
        Dianne Richards

        Activity

        Hide
        Dianne Richards added a comment -

        Attaching patches for 1.2.x and 2.0, both containing the new reloadOnDetach Compatibility property. The 1.2.x patch has the default value set to true. The default value in the 2.0 patch is false.

        Show
        Dianne Richards added a comment - Attaching patches for 1.2.x and 2.0, both containing the new reloadOnDetach Compatibility property. The 1.2.x patch has the default value set to true. The default value in the 2.0 patch is false.
        Hide
        Rick Curtis added a comment -

        The changes have been committed to 1.2.x, 1.3.x, and trunk.

        Show
        Rick Curtis added a comment - The changes have been committed to 1.2.x, 1.3.x, and trunk.
        Hide
        Dianne Richards added a comment -

        Providing a patch containing a test case for the changes. The patch can go into both 1.2.x and 2.0.

        Show
        Dianne Richards added a comment - Providing a patch containing a test case for the changes. The patch can go into both 1.2.x and 2.0.
        Hide
        Dianne Richards added a comment -

        Reopening this issue to add doc patches

        Show
        Dianne Richards added a comment - Reopening this issue to add doc patches
        Hide
        Dianne Richards added a comment -

        Attaching doc patches

        Show
        Dianne Richards added a comment - Attaching doc patches

          People

          • Assignee:
            Dianne Richards
            Reporter:
            Dianne Richards
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development