-
Notifications
You must be signed in to change notification settings - Fork 323
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Refresh memcached.ini and set sess_binary_protocol off by default with older libmemcached #330
Conversation
- remove deprecated options - add missing memcached.sess_server_failure_limit option - comment all options default value (only needed when not default value) see php.ini-production which follow this convention
Thanks! I think this makes sense for a 3.1 minor rather than a 3.0.x micro? |
As you prefer, your the lead ;) But for downstream distribution (I maintain the Fedora, EPEL [1] and CentOS SCL packages [2]) we have to provide a clean an working configuration. Having the current one have to be fixed to avoid the "touch" warning, so I will probably have to apply this patch there, and I don't like to diverge from upstream. [1] https://apps.fedoraproject.org/packages/php-pecl-memcached P.S. relying on the provided configuration is usually not enough, as this file is not updated when touch by the system admin, reason why I prefer the default value in the code. |
@@ -332,7 +332,11 @@ PHP_INI_BEGIN() | |||
MEMC_SESSION_INI_ENTRY("lock_wait_max", "2000", OnUpdateLongGEZero, lock_wait_max) | |||
MEMC_SESSION_INI_ENTRY("lock_retries", "5", OnUpdateLong, lock_retries) | |||
MEMC_SESSION_INI_ENTRY("lock_expire", "0", OnUpdateLongGEZero, lock_expiration) | |||
#if defined(LIBMEMCACHED_VERSION_HEX) && LIBMEMCACHED_VERSION_HEX < 0x01000018 | |||
MEMC_SESSION_INI_ENTRY("binary_protocol", "0", OnUpdateBool, binary_protocol_enabled) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If this isn't already mentioned in the (package.xml) changelog, could you mention it?
- E.g. someone could upgrade memcached, not notice that the default session binary/text protocol varied based on libmemcached version, use Memcached with something that only supports text protocol(twemproxy), and then upgrade libmemcached, then see something break.
- Or they could have libmemcached and a proxy only working with binary protocol, but I'm not aware of proxies like that.
I believe I made a mistake by merging this with 3.0.4 in mind. I will branch |
1st commit is mostly cleanup, follow php practice, but needed by the second one
2nd commit is another way to (try to) improve user experience with older libmemcached version and avoid the warning about using touch (which can be confusing) => for discussion.