You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@juddi.apache.org by "Jeff Faath (JIRA)" <ju...@ws.apache.org> on 2008/09/25 05:37:46 UTC
[jira] Created: (JUDDI-142) JPA retrievals result in sporadic
ordering of collections
JPA retrievals result in sporadic ordering of collections
---------------------------------------------------------
Key: JUDDI-142
URL: https://issues.apache.org/jira/browse/JUDDI-142
Project: jUDDI
Issue Type: Bug
Affects Versions: 3.0
Reporter: Jeff Faath
Assignee: Kurt Stam
Fix For: 3.0
When retrieving results from the persistence layer (currently using Hibernate), collections of objects are coming back with sporadic ordering. I cannot identify the any concrete reasons as it doesn't happen every time and to every collection.
Not only is it causing havoc with the unit tests, it is probably desirable that results are returned in the order that they're are saved.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: juddi-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: juddi-dev-help@ws.apache.org
[jira] Closed: (JUDDI-142) JPA retrievals result in sporadic
ordering of collections
Posted by "Kurt Stam (JIRA)" <ju...@ws.apache.org>.
[ https://issues.apache.org/jira/browse/JUDDI-142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kurt Stam closed JUDDI-142.
---------------------------
Resolution: Fixed
- Refactored the unittests, going back to junit.
- Fixed the List ordering issue.
tested with derby and mysql
> JPA retrievals result in sporadic ordering of collections
> ---------------------------------------------------------
>
> Key: JUDDI-142
> URL: https://issues.apache.org/jira/browse/JUDDI-142
> Project: jUDDI
> Issue Type: Bug
> Affects Versions: 3.0
> Reporter: Jeff Faath
> Assignee: Kurt Stam
> Priority: Critical
> Fix For: 3.0alpha
>
>
> When retrieving results from the persistence layer (currently using Hibernate), collections of objects are coming back with sporadic ordering. I cannot identify the any concrete reasons as it doesn't happen every time and to every collection.
> Not only is it causing havoc with the unit tests, it is probably desirable that results are returned in the order that they're are saved.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (JUDDI-142) JPA retrievals result in sporadic
ordering of collections
Posted by "Kurt Stam (JIRA)" <ju...@ws.apache.org>.
[ https://issues.apache.org/jira/browse/JUDDI-142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kurt Stam updated JUDDI-142:
----------------------------
Priority: Critical (was: Major)
> JPA retrievals result in sporadic ordering of collections
> ---------------------------------------------------------
>
> Key: JUDDI-142
> URL: https://issues.apache.org/jira/browse/JUDDI-142
> Project: jUDDI
> Issue Type: Bug
> Affects Versions: 3.0
> Reporter: Jeff Faath
> Assignee: Kurt Stam
> Priority: Critical
> Fix For: 3.0
>
>
> When retrieving results from the persistence layer (currently using Hibernate), collections of objects are coming back with sporadic ordering. I cannot identify the any concrete reasons as it doesn't happen every time and to every collection.
> Not only is it causing havoc with the unit tests, it is probably desirable that results are returned in the order that they're are saved.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: juddi-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: juddi-dev-help@ws.apache.org
[jira] Work started: (JUDDI-142) JPA retrievals result in sporadic
ordering of collections
Posted by "Kurt Stam (JIRA)" <ju...@ws.apache.org>.
[ https://issues.apache.org/jira/browse/JUDDI-142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Work on JUDDI-142 started by Kurt Stam.
> JPA retrievals result in sporadic ordering of collections
> ---------------------------------------------------------
>
> Key: JUDDI-142
> URL: https://issues.apache.org/jira/browse/JUDDI-142
> Project: jUDDI
> Issue Type: Bug
> Affects Versions: 3.0
> Reporter: Jeff Faath
> Assignee: Kurt Stam
> Priority: Critical
> Fix For: 3.0alpha
>
>
> When retrieving results from the persistence layer (currently using Hibernate), collections of objects are coming back with sporadic ordering. I cannot identify the any concrete reasons as it doesn't happen every time and to every collection.
> Not only is it causing havoc with the unit tests, it is probably desirable that results are returned in the order that they're are saved.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (JUDDI-142) JPA retrievals result in sporadic
ordering of collections
Posted by "Kurt Stam (JIRA)" <ju...@ws.apache.org>.
[ https://issues.apache.org/jira/browse/JUDDI-142?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Kurt Stam updated JUDDI-142:
----------------------------
Fix Version/s: (was: 3.0)
3.0.alfa
> JPA retrievals result in sporadic ordering of collections
> ---------------------------------------------------------
>
> Key: JUDDI-142
> URL: https://issues.apache.org/jira/browse/JUDDI-142
> Project: jUDDI
> Issue Type: Bug
> Affects Versions: 3.0
> Reporter: Jeff Faath
> Assignee: Kurt Stam
> Priority: Critical
> Fix For: 3.0.alfa
>
>
> When retrieving results from the persistence layer (currently using Hibernate), collections of objects are coming back with sporadic ordering. I cannot identify the any concrete reasons as it doesn't happen every time and to every collection.
> Not only is it causing havoc with the unit tests, it is probably desirable that results are returned in the order that they're are saved.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: juddi-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: juddi-dev-help@ws.apache.org
[jira] Commented: (JUDDI-142) JPA retrievals result in sporadic
ordering of collections
Posted by "Kurt Stam (JIRA)" <ju...@ws.apache.org>.
[ https://issues.apache.org/jira/browse/JUDDI-142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12634471#action_12634471 ]
Kurt Stam commented on JUDDI-142:
---------------------------------
If needed we can specify a 'order-by' clause on collections. However "returned in the order that they are saved" would mean we need a Create TimeStamp on these things. I don't think we have that, do we?
BTW, it coming back in 'random' order is normal if no ordering is specified.
> JPA retrievals result in sporadic ordering of collections
> ---------------------------------------------------------
>
> Key: JUDDI-142
> URL: https://issues.apache.org/jira/browse/JUDDI-142
> Project: jUDDI
> Issue Type: Bug
> Affects Versions: 3.0
> Reporter: Jeff Faath
> Assignee: Kurt Stam
> Fix For: 3.0
>
>
> When retrieving results from the persistence layer (currently using Hibernate), collections of objects are coming back with sporadic ordering. I cannot identify the any concrete reasons as it doesn't happen every time and to every collection.
> Not only is it causing havoc with the unit tests, it is probably desirable that results are returned in the order that they're are saved.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: juddi-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: juddi-dev-help@ws.apache.org
[jira] Commented: (JUDDI-142) JPA retrievals result in sporadic
ordering of collections
Posted by "Jeff Faath (JIRA)" <ju...@ws.apache.org>.
[ https://issues.apache.org/jira/browse/JUDDI-142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12634565#action_12634565 ]
Jeff Faath commented on JUDDI-142:
----------------------------------
I did some more research and found a good solution. We simply need to add the @OrderBy annotation to simple collections (these collections have the parent entity key and an integer as their primary key). Adding the annotation without any arguments will sort the collection on the primary key and since the integer id preserves their insert order, all is good.
For the more high-level collections (ex. business services for a business entity) this solution won't work. But these collections have a timestamp (the last Updated field). However, I'm not sure it's as important to preserve the order of these higher level collections since they are entities unto themselves.
I'm going to try out this solution for two model classes I'm working with now. I'll commit these two classes if the solution works out.
> JPA retrievals result in sporadic ordering of collections
> ---------------------------------------------------------
>
> Key: JUDDI-142
> URL: https://issues.apache.org/jira/browse/JUDDI-142
> Project: jUDDI
> Issue Type: Bug
> Affects Versions: 3.0
> Reporter: Jeff Faath
> Assignee: Kurt Stam
> Fix For: 3.0
>
>
> When retrieving results from the persistence layer (currently using Hibernate), collections of objects are coming back with sporadic ordering. I cannot identify the any concrete reasons as it doesn't happen every time and to every collection.
> Not only is it causing havoc with the unit tests, it is probably desirable that results are returned in the order that they're are saved.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
---------------------------------------------------------------------
To unsubscribe, e-mail: juddi-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: juddi-dev-help@ws.apache.org