Closed (fixed)
Project:
Drupal core
Version:
8.7.x-dev
Component:
database system
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
1 Feb 2017 at 13:49 UTC
Updated:
5 Sep 2018 at 01:29 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
opensense commentedComment #3
opensense commentedComment #4
jaykandariOnly 1 instance of "db_transaction()" found. #2 Looks good.
Thanks.
Comment #5
cilefen commentedRead the issue summary carefully about test usage replacements.
Comment #6
xjmComment #7
jeetendrakumar commentedComment #9
jeetendrakumar commentedComment #10
sharique commentedDocumentation will be updated in separate ticket.
Documentation will be updated in separate ticket.
Not sure, this change is required or not in the context of ticket.
Comment #11
jeetendrakumar commented@Sharique
point 1 and 2: Done
Point 3: I think we need to inject the dependency.
Comment #14
volegerNot correct
create()method implementation. Database service should pass through the third argument. Anyway, I guess it is redundant code. Database service injecting already defined incore.services.ymlComment #15
andypostgrep through core shows that *this->connection* is mostly used against *this->database*
Comment #16
andypostRerolled, added triggering deprecated error & test
Also converted
core/tests/Drupal/KernelTests/Core/Database/TransactionTest.phpI'm sure changes are in scope cos test for
inTransaction()should be made from the same connection asstartTransaction()requestedLinked to #2947775: Move setting default target out of db_merge() and other deprecated db_* functions cos setting defaults needs solved somehow
There's is only 2 mentions in docs but that's separate issue
Transactions are per connection but database mostly used in backend specific implementation
Comment #18
mondrakeRerolled, added reference to CR in the deprecation msg, adjusted test to benefit from the $connection property being available from DatabaseTestBase, changed in test the returns to markTestSkipped where necessary.
If it turns back green this should be close to ready now.
Comment #20
volegerLooks good.
Comment #23
catchCommitted/pushed to 8.7.x, thanks!