in reply to Node approval overriding

I appear to read this question differently than the others who have responded to it.

My interpretation of the question is frodo72 wondering why s/he is shown as having approved the node when ysth had already approved it.

Yes, there will likely always be race conditions like this. That is, if two people approve the same node at near the same time, then both of their actions may cause approval machinery to act. All that matters (much) is that such duplicate "effort" doesn't create real problems.

The oldest style of approval machinery actually inserts duplicate records for such a case, which is only a problem in that it adds inefficiency (as I recall).

The second-generation approval machinery (which was meant to replace the above but never quite got that far) inserts duplicate log records but avoids the inefficiency.

The third-generation approval machinery (which I started and castaway kindly finished writing and which will replace both of the above once it gets deployed, which isn't an easy thing to do which is why it hasn't happened yet despite it having been tested many months ago) is quite a bit more efficient in several ways. It also greatly reduces the size of the windows for such race conditions. It also fixes other race conditions that are actually problems. But it will still (though much less likely, as I recall) sometimes record two approval requests (who cares?).

- tye        

Replies are listed 'Best First'.
Re^2: Node approval overriding (1 2 3)
by Tanktalus (Canon) on Apr 13, 2005 at 20:51 UTC

    I thought it was just simpler than that. The act of front-paging only implicitly approves a node. The approval is not actually stored - when gathering a list of nodes that are approved, I'm guessing PM will just look at any node that is either approved or front-paged (and, as perl programmers, we know that $a or $b is true even when $a and $b are both individually true).

    I noticed this when I had two windows opened to the same thread. In the first window, I had opened the second window as a response. Once I finished the response, I used the second window to view the whole thread again, and noticed it was front-paged by someone. On the first window, I clicked "approve", and hit moderate. It accepted my moderation, and the node showed "approved by Tanktalus" and "front-paged by someone else".

    I dunno. I thought it was funny. :-)