mirror of
https://github.com/friendica/friendica
synced 2025-04-23 23:10:10 +00:00
Add support for Memcached/Improve database cache
- Create Cache Driver interface - Update cache table fields - Add CacheSessionHandler
This commit is contained in:
parent
7bd4a52156
commit
3628b62aeb
9 changed files with 326 additions and 192 deletions
|
@ -712,16 +712,16 @@ class DBStructure
|
|||
]
|
||||
];
|
||||
$database["cache"] = [
|
||||
"comment" => "Used to store different data that doesn't to be stored for a long time",
|
||||
"comment" => "Stores temporary data",
|
||||
"fields" => [
|
||||
"k" => ["type" => "varbinary(255)", "not null" => "1", "primary" => "1", "comment" => ""],
|
||||
"v" => ["type" => "mediumtext", "comment" => ""],
|
||||
"expire_mode" => ["type" => "tinyint unsigned", "not null" => "1", "default" => "0", "comment" => ""],
|
||||
"updated" => ["type" => "datetime", "not null" => "1", "default" => NULL_DATE, "comment" => ""],
|
||||
"k" => ["type" => "varbinary(255)", "not null" => "1", "primary" => "1", "comment" => "cache key"],
|
||||
"v" => ["type" => "mediumtext", "comment" => "cached serialized value"],
|
||||
"expires" => ["type" => "datetime", "not null" => "1", "default" => NULL_DATE, "comment" => "datetime of cache expiration"],
|
||||
"updated" => ["type" => "datetime", "not null" => "1", "default" => NULL_DATE, "comment" => "datetime of cache insertion"],
|
||||
],
|
||||
"indexes" => [
|
||||
"PRIMARY" => ["k"],
|
||||
"expire_mode_updated" => ["expire_mode", "updated"],
|
||||
"k_expires" => ["k", "expires"],
|
||||
]
|
||||
];
|
||||
$database["challenge"] = [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue