You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openjpa.apache.org by "Rick Curtis (JIRA)" <ji...@apache.org> on 2010/08/12 20:24:15 UTC

[jira] Created: (OPENJPA-1765) TableGenerator doesn't properly utilize all keys when under heavy stress.

TableGenerator doesn't properly utilize all keys when under heavy stress.
-------------------------------------------------------------------------

                 Key: OPENJPA-1765
                 URL: https://issues.apache.org/jira/browse/OPENJPA-1765
             Project: OpenJPA
          Issue Type: Bug
          Components: jdbc
    Affects Versions: 2.0.0
            Reporter: Rick Curtis
            Assignee: Rick Curtis


TableJDBCSeq has a locking problem where multiple threads can run on top of each other resulting in all keys not being used for a given sequence. 

While unit testing a fix I also uncovered another theoretical start up problem where multiple threads can try to insert the same row into the DB resulting in a duplicate key exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OPENJPA-1765) TableGenerator doesn't properly utilize all keys when under heavy stress.

Posted by "Rick Curtis (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1765?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Rick Curtis updated OPENJPA-1765:
---------------------------------

    Attachment: OPENJPA-1765.patch

> TableGenerator doesn't properly utilize all keys when under heavy stress.
> -------------------------------------------------------------------------
>
>                 Key: OPENJPA-1765
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1765
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: jdbc
>    Affects Versions: 2.0.0
>            Reporter: Rick Curtis
>            Assignee: Rick Curtis
>         Attachments: OPENJPA-1765.patch
>
>
> TableJDBCSeq has a locking problem where multiple threads can run on top of each other resulting in all keys not being used for a given sequence. 
> While unit testing a fix I also uncovered another theoretical start up problem where multiple threads can try to insert the same row into the DB resulting in a duplicate key exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OPENJPA-1765) TableGenerator doesn't properly utilize all keys when under heavy stress.

Posted by "Rick Curtis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OPENJPA-1765?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12897935#action_12897935 ] 

Rick Curtis commented on OPENJPA-1765:
--------------------------------------

Committed revision 984943 to trunk.

> TableGenerator doesn't properly utilize all keys when under heavy stress.
> -------------------------------------------------------------------------
>
>                 Key: OPENJPA-1765
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1765
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: jdbc
>    Affects Versions: 2.0.0, 2.1.0
>            Reporter: Rick Curtis
>            Assignee: Rick Curtis
>             Fix For: 2.1.0
>
>         Attachments: OPENJPA-1765.patch
>
>
> TableJDBCSeq has a locking problem where multiple threads can run on top of each other resulting in all keys not being used for a given sequence. 
> While unit testing a fix I also uncovered another theoretical start up problem where multiple threads can try to insert the same row into the DB resulting in a duplicate key exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (OPENJPA-1765) TableGenerator doesn't properly utilize all keys when under heavy stress.

Posted by "Rick Curtis (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1765?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Rick Curtis resolved OPENJPA-1765.
----------------------------------

    Resolution: Fixed

> TableGenerator doesn't properly utilize all keys when under heavy stress.
> -------------------------------------------------------------------------
>
>                 Key: OPENJPA-1765
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1765
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: jdbc
>    Affects Versions: 2.0.0, 2.1.0
>            Reporter: Rick Curtis
>            Assignee: Rick Curtis
>             Fix For: 2.0.2, 2.1.0
>
>         Attachments: OPENJPA-1765.patch
>
>
> TableJDBCSeq has a locking problem where multiple threads can run on top of each other resulting in all keys not being used for a given sequence. 
> While unit testing a fix I also uncovered another theoretical start up problem where multiple threads can try to insert the same row into the DB resulting in a duplicate key exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OPENJPA-1765) TableGenerator doesn't properly utilize all keys when under heavy stress.

Posted by "Michael Dick (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1765?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Michael Dick updated OPENJPA-1765:
----------------------------------

    Fix Version/s: 2.0.2

> TableGenerator doesn't properly utilize all keys when under heavy stress.
> -------------------------------------------------------------------------
>
>                 Key: OPENJPA-1765
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1765
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: jdbc
>    Affects Versions: 2.0.0, 2.1.0
>            Reporter: Rick Curtis
>            Assignee: Rick Curtis
>             Fix For: 2.0.2, 2.1.0
>
>         Attachments: OPENJPA-1765.patch
>
>
> TableJDBCSeq has a locking problem where multiple threads can run on top of each other resulting in all keys not being used for a given sequence. 
> While unit testing a fix I also uncovered another theoretical start up problem where multiple threads can try to insert the same row into the DB resulting in a duplicate key exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (OPENJPA-1765) TableGenerator doesn't properly utilize all keys when under heavy stress.

Posted by "Rick Curtis (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/OPENJPA-1765?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Rick Curtis updated OPENJPA-1765:
---------------------------------

        Fix Version/s: 2.1.0
    Affects Version/s: 2.1.0

> TableGenerator doesn't properly utilize all keys when under heavy stress.
> -------------------------------------------------------------------------
>
>                 Key: OPENJPA-1765
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1765
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: jdbc
>    Affects Versions: 2.0.0, 2.1.0
>            Reporter: Rick Curtis
>            Assignee: Rick Curtis
>             Fix For: 2.1.0
>
>         Attachments: OPENJPA-1765.patch
>
>
> TableJDBCSeq has a locking problem where multiple threads can run on top of each other resulting in all keys not being used for a given sequence. 
> While unit testing a fix I also uncovered another theoretical start up problem where multiple threads can try to insert the same row into the DB resulting in a duplicate key exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OPENJPA-1765) TableGenerator doesn't properly utilize all keys when under heavy stress.

Posted by "Rick Curtis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OPENJPA-1765?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12899192#action_12899192 ] 

Rick Curtis commented on OPENJPA-1765:
--------------------------------------

@Milosz - Yes I believe so. 

> TableGenerator doesn't properly utilize all keys when under heavy stress.
> -------------------------------------------------------------------------
>
>                 Key: OPENJPA-1765
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1765
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: jdbc
>    Affects Versions: 2.0.0, 2.1.0
>            Reporter: Rick Curtis
>            Assignee: Rick Curtis
>             Fix For: 2.1.0
>
>         Attachments: OPENJPA-1765.patch
>
>
> TableJDBCSeq has a locking problem where multiple threads can run on top of each other resulting in all keys not being used for a given sequence. 
> While unit testing a fix I also uncovered another theoretical start up problem where multiple threads can try to insert the same row into the DB resulting in a duplicate key exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (OPENJPA-1765) TableGenerator doesn't properly utilize all keys when under heavy stress.

Posted by "Michael Dick (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/OPENJPA-1765?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12899132#action_12899132 ] 

Michael Dick commented on OPENJPA-1765:
---------------------------------------

Looks similar, but I think it's different. Can OPENJPA-1372 be reproduced without sharing the EM between threads? 

The added locking in this fix will prevent two EMs from getting the same sequences, I'm not sure about a single thread using the same EM. Might be worth running the test from 1372 to see if it still fails. 



> TableGenerator doesn't properly utilize all keys when under heavy stress.
> -------------------------------------------------------------------------
>
>                 Key: OPENJPA-1765
>                 URL: https://issues.apache.org/jira/browse/OPENJPA-1765
>             Project: OpenJPA
>          Issue Type: Bug
>          Components: jdbc
>    Affects Versions: 2.0.0, 2.1.0
>            Reporter: Rick Curtis
>            Assignee: Rick Curtis
>             Fix For: 2.1.0
>
>         Attachments: OPENJPA-1765.patch
>
>
> TableJDBCSeq has a locking problem where multiple threads can run on top of each other resulting in all keys not being used for a given sequence. 
> While unit testing a fix I also uncovered another theoretical start up problem where multiple threads can try to insert the same row into the DB resulting in a duplicate key exception.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.