Hi!
How exactly are the INSERT statements done?
How many clients?
BR
-- Martin
Hendrik Woltersdorf wrote:
> Hi,
>
> I have already set ndb_autoincrement_prefetch_sz to 1. It does not force
> order.
> What I get is this:
>
> ID DATE_INSERT
> -------------------------------------
> 14757, '2010-01-29 10:15:51'
> 14756, '2010-01-29 10:15:50'
> 14755, '2010-01-29 10:15:50'
> 14721, '2010-01-29 10:15:50'
> 14720, '2010-01-29 10:15:50'
> 14719, '2010-01-29 10:15:50'
> 14739, '2010-01-29 10:13:37'
> 14738, '2010-01-29 10:13:37'
> 14737, '2010-01-29 10:13:37'
> 14736, '2010-01-29 10:13:37'
>
> kind regards
>
> Hendrik Woltersdorf
> XCOM AG
> Tel.: 0375/27008-580
> Tel. mobil: 0178/5710078
> Email: Hendrik.Woltersdorf@stripped
>
> Inactive hide details for Martin Skold ---29.01.2010
> 11:14:58---Hi!Martin Skold ---29.01.2010 11:14:58---Hi!
>
> *Martin Skold <Martin.Skold@stripped>*
> Gesendet von: Martin.Skold@stripped
>
> 29.01.2010 11:13
>
>
>
> An
>
> Hendrik Woltersdorf <hendrik.woltersdorf@stripped>
>
> Kopie
>
> cluster@stripped
>
> Thema
>
> Re: howto implement a fifo queue in MySQL Cluster ?
>
>
>
>
> Hi!
>
> Autoincrement values are inserted in order, but we prefetch
> series of values to get better performance. So if you are
> inserting from several connections (or mysqld's) you will
> not get a total ordering. If you want that you can set
> ndb_autoincrement_prefetch_sz to 1 should force order.
> This will, however, degrade performance for inserts.
>
> BR
> -- Martin
> Hendrik Woltersdorf wrote:
> > Hi all,
> >
> > how do I implement a fifo queue in MySQL Cluster ?
> >
> > What I want to do:
> >
> > I write inserts and updates to some tables with triggers into a queue.
> > These rows have to be read and processed in chronological order.
> > My first attempt was to use a table with an autoincrement column as the
> > primary key. But tests show, that these autoincrement values are not
> > inserted in chronological order. A datetime column does not help either,
> > because it is by far not precise enough, and it depends on the
> > synchronization of the clocks of the different sql node machines.
> >
> > Any ideas, how to read these data rows in chronological order ?
> >
> > The second best idea is, to use "select max(PK)+1", but this will cause
> > lots of duplicate key errors.
> >
> > I am using MySQL Cluster version 7.0.7 with 2 data nodes, 2 management
> > nodes and 2 sql nodes.
> >
> > kind regards
> >
> > Hendrik Woltersdorf
> > XCOM AG
> > Tel.: 0375/27008-580
> > Tel. mobil: 0178/5710078
> > Email: Hendrik.Woltersdorf@stripped
> >
> >
> >
> > *** XCOM AG Legal Disclaimer ***
> >
> > Diese E-Mail einschliesslich ihrer Anhaenge ist vertraulich und ist
> allein
> > für den Gebrauch durch den vorgesehenen Empfaenger bestimmt. Dritten ist
> > das Lesen, Verteilen oder Weiterleiten dieser E-Mail untersagt. Wir
> bitten,
> > eine fehlgeleitete E-Mail unverzueglich vollstaendig zu loeschen und uns
> > eine Nachricht zukommen zu lassen.
> >
> > This email may contain material that is confidential and for the sole use
> > of the intended recipient. Any review, distribution by others or
> forwarding
> > without express permission is strictly prohibited. If you are not the
> > intended recipient, please contact the sender and delete all copies.
> >
> > Hauptsitz: Bahnstrasse 37, D-47877 Willich, USt-IdNr.: DE 812 885 664
> > Kommunikation: Telefon +49 2154 9209-70, Telefax +49 2154 9209-900,
> > www.xcom.de
> > Handelsregister: Amtsgericht Krefeld, HRB 10340
> > Vorstand: Matthias Albrecht, Marco Marty, Dr. Rainer Fuchs, Dirk Werner
> > Vorsitzender des Aufsichtsrates: Stefan H. Tarach
>
> --
> MySQL Cluster Mailing List
> For list archives: http://lists.mysql.com/cluster
> To unsubscribe:
> http://lists.mysql.com/cluster?unsub=1
>
>
>
>
>
>
> *** XCOM AG Legal Disclaimer ***
>
> Diese E-Mail einschliesslich ihrer Anhaenge ist vertraulich und ist
> allein für den Gebrauch durch den vorgesehenen Empfaenger bestimmt.
> Dritten ist das Lesen, Verteilen oder Weiterleiten dieser E-Mail
> untersagt. Wir bitten, eine fehlgeleitete E-Mail unverzueglich
> vollstaendig zu loeschen und uns eine Nachricht zukommen zu lassen.
>
> This email may contain material that is confidential and for the sole
> use of the intended recipient. Any review, distribution by others or
> forwarding without express permission is strictly prohibited. If you are
> not the intended recipient, please contact the sender and delete all copies.
>
> Hauptsitz: Bahnstrasse 37, D-47877 Willich, USt-IdNr.: DE 812 885 664
> Kommunikation: Telefon +49 2154 9209-70, Telefax +49 2154 9209-900,
> www.xcom.de
> Handelsregister: Amtsgericht Krefeld, HRB 10340
> Vorstand: Matthias Albrecht, Marco Marty, Dr. Rainer Fuchs, Dirk Werner
> Vorsitzender des Aufsichtsrates: Stefan H. Tarach
>