Doing this will enable a more appropriate (a key/value store for example) storage system to be used.

An example: The SQLite driver might store these variables in a separate SQLite file, or indeed to use a different engine altogether: a static file, tokyocabinet, whatever suits best.

I'd like to see a long term aim to be moving non-SQL data (which is probably most of it) away from the SQL database.

Comments

mnicholas’s picture

By non-SQL I mean any data that never has a proper SQL query run on it.

damien tournoud’s picture

Can you clarify what you mean by "Move persistent variables to database system"?

int’s picture

Status: Active » Postponed (maintainer needs more info)

drupal use the variables database table to save persistent variables.

mnicholas’s picture

Currently (Drupal 7) routines shuch as: variable_get() and variable_set() are in bootstrap.inc. If they were moved into:
/includes/database/*/persistent.inc for example; then one could then make hay with optimisations, some of which I've set out above.

Similar possibilities exist for cached data - currently also stored in a database table, I believe. A memcached driver might be a candidate here. Call it the "Cache Abstraction Layer" if you like.

I wonder if cacheing improves performance with all the database implementations (Can this be easily be tested?)? If not, then there is another reason to shuffle these into the database layer.

pasqualle’s picture

Issue summary: View changes
Status: Postponed (maintainer needs more info) » Closed (won't fix)