You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openjpa.apache.org by "Jeremy Bauer (JIRA)" <ji...@apache.org> on 2009/05/08 17:17:45 UTC
[jira] Created: (OPENJPA-1074) OrderColumn does not maintain index
upon inter-list element removal
OrderColumn does not maintain index upon inter-list element removal
-------------------------------------------------------------------
Key: OPENJPA-1074
URL: https://issues.apache.org/jira/browse/OPENJPA-1074
Project: OpenJPA
Issue Type: Bug
Components: jdbc
Affects Versions: 2.0.0
Reporter: Jeremy Bauer
Assignee: Jeremy Bauer
The current order column reordering mechanism does not maintain a contiguous index value when an item is deleted from anywhere except the end of a collection. Per the latest JPA 2.0 spec, a contiguous index value must be maintained.
The current reordering mechanism does a full delete and reinsert of the container/collection table values if a reorder is required for inserts. For deletes, it just removes entries and leaves an empty index value. The first phase of the fix will be to maintain contiguous ordering using the same mechanism as inserts (delete/re-insert). The second phase will be to update the ChangeTracker to record the indexes of the updated list items and to use that information to provide a more intelligent update strategy in the handlers.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (OPENJPA-1074) OrderColumn does not maintain index
upon inter-list element removal - Phase 1
Posted by "Donald Woods (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENJPA-1074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Donald Woods resolved OPENJPA-1074.
-----------------------------------
Resolution: Fixed
Opened OPENJPA-1595 for remaining Phase 2 work.
> OrderColumn does not maintain index upon inter-list element removal - Phase 1
> -----------------------------------------------------------------------------
>
> Key: OPENJPA-1074
> URL: https://issues.apache.org/jira/browse/OPENJPA-1074
> Project: OpenJPA
> Issue Type: Bug
> Components: jdbc
> Affects Versions: 2.0.0-M2
> Reporter: Jeremy Bauer
> Assignee: Jeremy Bauer
> Priority: Critical
> Fix For: 2.0.0-M3
>
>
> The current order column reordering mechanism does not maintain a contiguous index value when an item is deleted from anywhere except the end of a collection. Per the latest JPA 2.0 spec, a contiguous index value must be maintained.
> The current reordering mechanism does a full delete and reinsert of the container/collection table values if a reorder is required for inserts. For deletes, it just removes entries and leaves an empty index value. The first phase of the fix will be to maintain contiguous ordering using the same mechanism as inserts (delete/re-insert). The second phase will be to update the ChangeTracker to record the indexes of the updated list items and to use that information to provide a more intelligent update strategy in the handlers.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OPENJPA-1074) OrderColumn does not maintain index
upon inter-list element removal
Posted by "Donald Woods (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENJPA-1074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Donald Woods updated OPENJPA-1074:
----------------------------------
Due Date: 15/May/09 (was: 15/May/09)
Priority: Critical (was: Major)
Fix Version/s: 2.0.0
marking non-spec compliant behavior as a critical issue for 2.0.0
> OrderColumn does not maintain index upon inter-list element removal
> -------------------------------------------------------------------
>
> Key: OPENJPA-1074
> URL: https://issues.apache.org/jira/browse/OPENJPA-1074
> Project: OpenJPA
> Issue Type: Bug
> Components: jdbc
> Affects Versions: 2.0.0-M2
> Reporter: Jeremy Bauer
> Assignee: Jeremy Bauer
> Priority: Critical
> Fix For: 2.0.0
>
>
> The current order column reordering mechanism does not maintain a contiguous index value when an item is deleted from anywhere except the end of a collection. Per the latest JPA 2.0 spec, a contiguous index value must be maintained.
> The current reordering mechanism does a full delete and reinsert of the container/collection table values if a reorder is required for inserts. For deletes, it just removes entries and leaves an empty index value. The first phase of the fix will be to maintain contiguous ordering using the same mechanism as inserts (delete/re-insert). The second phase will be to update the ChangeTracker to record the indexes of the updated list items and to use that information to provide a more intelligent update strategy in the handlers.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OPENJPA-1074) OrderColumn does not maintain index
upon inter-list element removal
Posted by "Kevin Sutter (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENJPA-1074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kevin Sutter updated OPENJPA-1074:
----------------------------------
Fix Version/s: (was: 2.0.0)
2.1.0
> OrderColumn does not maintain index upon inter-list element removal
> -------------------------------------------------------------------
>
> Key: OPENJPA-1074
> URL: https://issues.apache.org/jira/browse/OPENJPA-1074
> Project: OpenJPA
> Issue Type: Bug
> Components: jdbc
> Affects Versions: 2.0.0-M2
> Reporter: Jeremy Bauer
> Assignee: Jeremy Bauer
> Priority: Critical
> Fix For: 2.1.0
>
>
> The current order column reordering mechanism does not maintain a contiguous index value when an item is deleted from anywhere except the end of a collection. Per the latest JPA 2.0 spec, a contiguous index value must be maintained.
> The current reordering mechanism does a full delete and reinsert of the container/collection table values if a reorder is required for inserts. For deletes, it just removes entries and leaves an empty index value. The first phase of the fix will be to maintain contiguous ordering using the same mechanism as inserts (delete/re-insert). The second phase will be to update the ChangeTracker to record the indexes of the updated list items and to use that information to provide a more intelligent update strategy in the handlers.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (OPENJPA-1074) OrderColumn does not maintain index
upon inter-list element removal - Phase 1
Posted by "Donald Woods (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENJPA-1074?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Donald Woods updated OPENJPA-1074:
----------------------------------
Fix Version/s: (was: 2.1.0)
2.0.0-M3
Summary: OrderColumn does not maintain index upon inter-list element removal - Phase 1 (was: OrderColumn does not maintain index upon inter-list element removal)
Splitting the remaining work into a new JIRA, as code was committed using this one and needs to be resolved.
> OrderColumn does not maintain index upon inter-list element removal - Phase 1
> -----------------------------------------------------------------------------
>
> Key: OPENJPA-1074
> URL: https://issues.apache.org/jira/browse/OPENJPA-1074
> Project: OpenJPA
> Issue Type: Bug
> Components: jdbc
> Affects Versions: 2.0.0-M2
> Reporter: Jeremy Bauer
> Assignee: Jeremy Bauer
> Priority: Critical
> Fix For: 2.0.0-M3
>
>
> The current order column reordering mechanism does not maintain a contiguous index value when an item is deleted from anywhere except the end of a collection. Per the latest JPA 2.0 spec, a contiguous index value must be maintained.
> The current reordering mechanism does a full delete and reinsert of the container/collection table values if a reorder is required for inserts. For deletes, it just removes entries and leaves an empty index value. The first phase of the fix will be to maintain contiguous ordering using the same mechanism as inserts (delete/re-insert). The second phase will be to update the ChangeTracker to record the indexes of the updated list items and to use that information to provide a more intelligent update strategy in the handlers.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (OPENJPA-1074) OrderColumn does not maintain
index upon inter-list element removal
Posted by "Jeremy Bauer (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/OPENJPA-1074?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12840762#action_12840762 ]
Jeremy Bauer commented on OPENJPA-1074:
---------------------------------------
I fixed the non-spec compliant behavior described in this JIRA (ie. phase 1 - Per the latest JPA 2.0 spec, a contiguous index value must be maintained.) but the second phase of the JIRA has not been addressed:
"The current reordering mechanism does a full delete and reinsert of the container/collection table values if a reorder is required for inserts. For deletes, it just removes entries and leaves an empty index value. The first phase of the fix will be to maintain contiguous ordering using the same mechanism as inserts (delete/re-insert). The second phase will be to update the ChangeTracker to record the indexes of the updated list items and to use that information to provide a more intelligent update strategy in the handlers."
A more spec related side effect of OpenJPA's current order column update strategy is that the OrderColumn insertable and updatable attributes may not result in the behavior one may expect since the db operations used to maintain the list do not exactly map to the db operations indicated by these attributes.
I spent a few days looking into implementing phase 2, but it turned into a non trivial exercise.
> OrderColumn does not maintain index upon inter-list element removal
> -------------------------------------------------------------------
>
> Key: OPENJPA-1074
> URL: https://issues.apache.org/jira/browse/OPENJPA-1074
> Project: OpenJPA
> Issue Type: Bug
> Components: jdbc
> Affects Versions: 2.0.0-M2
> Reporter: Jeremy Bauer
> Assignee: Jeremy Bauer
> Priority: Critical
> Fix For: 2.0.0
>
>
> The current order column reordering mechanism does not maintain a contiguous index value when an item is deleted from anywhere except the end of a collection. Per the latest JPA 2.0 spec, a contiguous index value must be maintained.
> The current reordering mechanism does a full delete and reinsert of the container/collection table values if a reorder is required for inserts. For deletes, it just removes entries and leaves an empty index value. The first phase of the fix will be to maintain contiguous ordering using the same mechanism as inserts (delete/re-insert). The second phase will be to update the ChangeTracker to record the indexes of the updated list items and to use that information to provide a more intelligent update strategy in the handlers.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.