File tree Expand file tree Collapse file tree 1 file changed +5
-19
lines changed Expand file tree Collapse file tree 1 file changed +5
-19
lines changed Original file line number Diff line number Diff line change @@ -350,25 +350,11 @@ support blocking, and expects a TTL to avoid stalled locks::
350
350
351
351
This store does not support TTL lower than 1 second.
352
352
353
- Before storing locks in the database, you must create the table that stores
354
- the information. The store provides a method called
355
- :method: `Symfony\\ Component\\ Lock\\ Store\\ PdoStore::createTable `
356
- to set up this table for you according to the database engine used::
357
-
358
- try {
359
- $store->createTable();
360
- } catch (\PDOException $exception) {
361
- // the table could not be created for some reason
362
- }
363
-
364
- A great way to set up the table in production is to call the ``createTable() ``
365
- method in your local computer and then generate a
366
- :ref: `database migration <doctrine-creating-the-database-tables-schema >`:
367
-
368
- .. code-block :: terminal
369
-
370
- $ php bin/console doctrine:migrations:diff
371
- $ php bin/console doctrine:migrations:migrate
353
+ The table where values are stored is created automatically on the first call to
354
+ the :method: `Symfony\\ Component\\ Lock\\ Store\\ PdoStore::save ` method.
355
+ You can also create this table explicitly by calling the
356
+ :method: `Symfony\\ Component\\ Lock\\ Store\\ PdoStore::createTable ` method in
357
+ your code.
372
358
373
359
.. _lock-store-redis :
374
360
You can’t perform that action at this time.
0 commit comments