public DatabaseLockBackend::schemaDefinition()
Defines the schema for the semaphore table.
public function schemaDefinition() { return [ 'description' => 'Table for holding semaphores, locks, flags, etc. that cannot be stored as state since they must not be cached.', 'fields' => [ 'name' => [ 'description' => 'Primary Key: Unique name.', 'type' => 'varchar_ascii', 'length' => 255, 'not null' => TRUE, 'default' => '' ], 'value' => [ 'description' => 'A value for the semaphore.', 'type' => 'varchar_ascii', 'length' => 255, 'not null' => TRUE, 'default' => '' ], 'expire' => [ 'description' => 'A Unix timestamp with microseconds indicating when the semaphore should expire.', 'type' => 'float', 'size' => 'big', 'not null' => TRUE ], ], 'indexes' => [ 'value' => ['value'], 'expire' => ['expire'], ], 'primary key' => ['name'], ]; }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/core!lib!Drupal!Core!Lock!DatabaseLockBackend.php/function/DatabaseLockBackend::schemaDefinition/8.1.x