db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Rick Hillegas (Updated) (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (DERBY-5493) Same value returned by successive calls to a sequence generator.
Date Wed, 18 Apr 2012 21:08:40 GMT

     [ https://issues.apache.org/jira/browse/DERBY-5493?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel

Rick Hillegas updated DERBY-5493:

    Attachment: derby-5493-02-aa-boostPreallocationTo100.diff

Attaching derby-5493-02-aa-boostPreallocationTo100.diff. This boosts the preallocation size
to 100 in order to get slightly better concurrency than we saw in 10.8. Tests passed cleanly
for me. Committed at subversion revision 1327682.

Touches the following files:


M       java/engine/org/apache/derby/impl/sql/catalog/SequenceRange.java

The actual change.


M       java/testing/org/apache/derbyTesting/functionTests/tests/lang/SequenceGeneratorTest.java

Boosting the preallocation size caused a combinatorial explosion in the number of cases stressed
in the boundary test for sequences. I pared that test back to a manageble set of cases.

> Same value returned by successive calls to a sequence generator.
> ----------------------------------------------------------------
>                 Key: DERBY-5493
>                 URL: https://issues.apache.org/jira/browse/DERBY-5493
>             Project: Derby
>          Issue Type: Bug
>          Components: SQL
>    Affects Versions:,,,,,
>            Reporter: Rick Hillegas
>            Assignee: Rick Hillegas
>              Labels: derby_triage10_9
>         Attachments: derby-5493-01-aa-correctnessPlusPeekerPlusTest.diff, derby-5493-01-ad-simplerApproach.diff,
derby-5493-01-ae-simplerApproachWithCrashJUnitTest.diff, derby-5493-01-af-usersubtran.diff,
derby-5493-01-ag-mergedWith5494.diff, derby-5493-02-aa-boostPreallocationTo100.diff
> The following script shows the same value being returned from a sequence generator by
two successive NEXT VALUE FOR calls. Thanks to Knut for finding this:
> connect 'jdbc:derby:memory:db;create=true';
> create table t (x int);
> create sequence s;
> autocommit off;
> select count(*) from sys.syssequences with rs;
> values next value for s;
> drop table t;
> rollback;
> -- same value as previous call
> values next value for s; 

This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira


View raw message