Hi, I've opened a PR adding a new attribute to PDO\Sqlite:
https://github.com/php/php-src/pull/19317 <https://github.com/php/php-
src/pull/19317?notification_referrer_id=NT_kwDOAfgLhrQxNzkxMjcwMjYzOTozMzAzMzA5NA#issuecomment-
3176177745>
The change is explained in depth in the PR, but in short, it makes it
possible to use immediate/exclusive transaction modes, rather than the
default deferred mode, when using $pdo->beginTransaction(). Deferred
mode has this particular behavior where if your transaction first reads
before writing, it will only wait for other transactions to finish while
acquiring the initial shared lock. Then when it tries to upgrade to a
write lock it just immediately aborts with SQLITE_BUSY, regardless of
your busy_timeout setting.
This is a real pain point with using SQLite in production. I've
addressed it by adding a new attribute that changes how the PDO driver
begins the transaction.
Is my understanding correct that this doesn't need an RFC? And if that's
the case, is this PR not subject to the PHP 8.5 feature freeze happening
this week?
The changes are pretty basic so I'd appreciate any reviews that could
move this forward. Would love for this to land in PHP 8.5.
Hi, I've opened a PR adding a new attribute to PDO\Sqlite: https://
github.com/php/php-src/pull/19317 <https://github.com/php/php-src/
pull/19317?
notification_referrer_id=NT_kwDOAfgLhrQxNzkxMjcwMjYzOTozMzAzMzA5NA#issuecomment-3176177745>
As far as the form the attribute takes goes, an Enum with the values
DEFERRED/IMMEDIATE/EXCLUSIVE would do the job.
(As for calling it an attribute, I thought at first that what was being
suggested was an Attribute, rather than a connection option.)
By enums I'm assuming you mean PHP enums. That could work and would
solve my issue of trying to represent the values of the attribute (only
thing I'm not sure about is Pdo\SqliteTransactionMode being directly in
the Pdo namespace). I've included a sample implementation in this
comment <https://github.com/php/php-src/pull/19317#issuecomment-
3177353751>
Hi, I've opened a PR adding a new attribute to PDO\Sqlite: https://
github.com/php/php-src/pull/19317 <<https://github.com/php/php-
src/>
pull/19317?notification_referrer_id=NT_kwDOAfgLhrQxNzkxMjcwMjYzOTozMzAzMzA5NA#issuecomment-
3176177745>
As far as the form the attribute takes goes, an Enum with the values
DEFERRED/IMMEDIATE/EXCLUSIVE would do the job.(As for calling it an attribute, I thought at first that what was
being
suggested was an Attribute, rather than a connection option.)
Hi,
Is there anything I could do here to get this reviewed before the 8.5
release? As mentioned earlier the proposed implementation should not be
subject to the feature freeze.
https://github.com/php/php-src/pull/19317
Thank you.
Samuel
By enums I'm assuming you mean PHP enums. That could work and would
solve my issue of trying to represent the values of the attribute
(only thing I'm not sure about is Pdo\SqliteTransactionMode being
directly in the Pdo namespace). I've included a sample implementation
in this comment <https://github.com/php/php-
src/pull/19317#issuecomment-3177353751>Hi, I've opened a PR adding a new attribute to PDO\Sqlite:
https://
github.com/php/php-src/pull/19317 <<https://github.com/php/php-
src/>
pull/19317?notification_referrer_id=NT_kwDOAfgLhrQxNzkxMjcwMjYzOTozMzAzMzA5NA#issuecomment-
3176177745>
As far as the form the attribute takes goes, an Enum with the
values
DEFERRED/IMMEDIATE/EXCLUSIVE would do the job.(As for calling it an attribute, I thought at first that what was
being
suggested was an Attribute, rather than a connection option.)
Hi Samuel,
Il 04/09/2025 00:38, Samuel Štancl ha scritto:
Hi,
Is there anything I could do here to get this reviewed before the 8.5
release? As mentioned earlier the proposed implementation should not be
subject to the feature freeze.https://github.com/php/php-src/pull/19317 <https://github.com/php/php-
src/pull/19317>
I think the 8.5 ship has sailed. Why should it not be subject to feature
freeze? It surely is, unless the RMs approve it.
Cheers
Matteo Beccati
Hi Matteo,
From reading earlier discussions my understanding is the feature freeze
only applies to things that need RFCs. With PRs that add simple
constants not necessarily needing an RFC.
Personally I think the diff in the linked PR itself matches that
description well, while the alternative implementation in the comment
seems more likely to need an RFC.
If I need RM approval how would I go about that. Email one of the RMs
individually?
Thank you.
Samuel Štancl
Hi Samuel,
Il 04/09/2025 00:38, Samuel Štancl ha scritto:
Hi,
Is there anything I could do here to get this reviewed before the
8.5
release? As mentioned earlier the proposed implementation should not
be
subject to the feature freeze.
https://github.com/php/php-src/pull/19317
<https://github.com/php/php-
src/pull/19317>I think the 8.5 ship has sailed. Why should it not be subject to
feature
freeze? It surely is, unless the RMs approve it.Cheers
--
Matteo Beccati
Hi Matteo,
From reading earlier discussions my understanding is the feature freeze
only applies to things that need RFCs. With PRs that add simple
constants not necessarily needing an RFC.Personally I think the diff in the linked PR itself matches that
description well, while the alternative implementation in the comment
seems more likely to need an RFC.If I need RM approval how would I go about that. Email one of the RMs
individually?
Flag the PR up to them by requesting a review from @release-managers
cheers
Derick
Hi,
Can you please not top-reply on this list? It's on our guidelines.