The behaviour of these functions is affected by settings in php.ini.
Name | Default | Changeable | Changelog |
---|---|---|---|
mysqlnd_qc.enable_qc | 1 | PHP_INI_SYSTEM | |
mysqlnd_qc.ttl | 30 | PHP_INI_ALL | |
mysqlnd_qc.cache_by_default | 0 | PHP_INI_ALL | |
mysqlnd_qc.cache_no_table | 0 | PHP_INI_ALL | |
mysqlnd_qc.use_request_time | 0 | PHP_INI_ALL | |
mysqlnd_qc.time_statistics | 1 | PHP_INI_ALL | |
mysqlnd_qc.collect_statistics | 0 | PHP_INI_ALL | |
mysqlnd_qc.collect_query_trace | 0 | PHP_INI_SYSTEM | |
mysqlnd_qc.query_trace_bt_depth | 3 | PHP_INI_SYSTEM | |
mysqlnd_qc.slam_defense | 0 | PHP_INI_SYSTEM | |
mysqlnd_qc.slam_defense_ttl | 30 | PHP_INI_SYSTEM | |
mysqlnd_qc.collect_normalized_query_trace | 0 | PHP_INI_SYSTEM | |
mysqlnd_qc.std_data_copy | 0 | PHP_INI_SYSTEM | |
mysqlnd_qc.apc_prefix | qc_ | PHP_INI_ALL | |
mysqlnd_qc.memc_server | 127.0.0.1 | PHP_INI_ALL | |
mysqlnd_qc.memc_port | 11211 | PHP_INI_ALL | |
mysqlnd_qc.sqlite_data_file | :memory: | PHP_INI_ALL |
Here's a short explanation of the configuration directives.
Enables or disables the plugin. If disabled the extension will not plug into mysqlnd to proxy internal mysqlnd C API calls.
Default Time-to-Live (TTL) for cache entries in seconds.
Cache all queries regardless if they begin with the SQL hint that enables caching of a query or not. Storage handler cannot overrule the setting. It is evaluated by the core of the plugin.
Cache queries with no table name in any of columns meta data of their result set, e.g. SELECT SLEEP(1)?
Use PHP global request time to avoid gettimeofday() system calls? If using APC storage handler it should be set to the value of apc.use_request_time , if not warnings will be generated.
Collect run time and store time statistics using gettimeofday() system call? Data will be collected only if you also set mysqlnd_qc.collect_statistics = 1,
Collect statistics for mysqlnd_qc_get_core_stats()()? Does not influence storage handler statistics! Handler statistics can be an integral part of the handler internal storage format. Thereofore, collection of some handler statistics cannot be disabled.
Collect query back traces?
Maximum depth/level of a query code backtrace.
Activates handler based slam defense if available. Supported by Default and APC storage handler
TTL for stale cache entries which are served while another client updates the entries. Supported by APC storage handler.
Collect aggregated normalized query traces? The setting has no effect by default. You compile the extension using the define NORM_QUERY_TRACE_LOG to make use of the setting.
Default storage handler: copy cached wire data? EXPERIMENTAL – use default setting!
The APC storage handler stores data in the APC user cache. The setting sets a prefix to be used for cache entries.
MEMCACHE storage handler: memcache server host.
MEMCACHE storage handler: memcached server port.
sqlite storage handler: data file. Any setting but :memory: may be of little practical value.