And it's not supposed to. I'm not sure how these made it in, but they need to not do so. Patch coming momentarily.
| Comment | File | Size | Author |
|---|---|---|---|
| #9 | 726344-b-nextIdDelete3.patch | 2.86 KB | berdir |
| #5 | 726344-b-nextIdDelete2.patch | 2.86 KB | berdir |
| #3 | 726344-b-nextIdDelete.patch | 2.79 KB | Crell |
| #1 | 726344-wrapper-functions.patch | 3.05 KB | Crell |
Comments
Comment #1
Crell commentedOK, a bit more than a moment. Sorry. :-) There's 2 remaining db_query() calls in DatabaseConnection_mysql::nextIdDelete(), because it's static. I need to confirm with chx how we can remove those. That will come in a later patch, after we confirm how to do that safely.
Comment #2
Crell commentedWell, this got rolled into #722912: db_index_exists() must conform schemaAPI indexExists() anyway. After that goes in we can use this issue for additional cleanup.
Comment #3
Crell commentedOK, since everything from #1 got moved into another patch, here's the last bit. This still needs testing. The problem is that shutdown functions in PHP are all kindsa weird. However, making this method static breaks because then it will run on whatever connection happens to be active at the end of the request, not on the connection that generated the new ID. (We have no guarantee that those will be the same.) So this tries to move it to a dynamic method.
Someone who has PHP 5.3, please test this there as well. I fear the PHP devs broke shutdown functions there. Again. As always. *sigh*
Comment #5
berdirWe are already inside the connection class, no need to use $this->connection :)
Also changed the patch to use drupal_register_shutdown_function().
Let's try this...
Comment #6
Crell commentedOh Crell you idiot...
#5 makes sense to me, with one predictable caveat. :-) Is there any way we can do it without the Drupal-specific shutdown register function? Please?
Comment #7
berdirYeah, I know, inheritance and stuff :)
The point of drupal_register_shutdown_function() is to be able to catch and report exceptions during shutdown functions. If we don't use it, we have to use the same catching as in http://api.drupal.org/api/function/_drupal_shutdown_function/7 or live with possible, untraceable "Exception thrown without strack trace in line 0" fatal errors.
Comment #8
Crell commentedThe odds of an exception here seem very slim. I am not really worried about that. Can we have a reroll without the dependency?
Comment #9
berdirOk, untested re-roll.
Comment #10
Crell commentedThe bot likes, I like, everybody likes. Thanks Berdir!
Comment #11
dries commentedLooks good. Committed to CVS HEAD. Thanks.