Skip to content

Add 'extended-redis-compatibility' config#306

Merged
zuiderkwast merged 7 commits intovalkey-io:unstablefrom
zuiderkwast:redis-compatility-knob
Apr 18, 2024
Merged

Add 'extended-redis-compatibility' config#306
zuiderkwast merged 7 commits intovalkey-io:unstablefrom
zuiderkwast:redis-compatility-knob

Conversation

@zuiderkwast
Copy link
Contributor

@zuiderkwast zuiderkwast commented Apr 12, 2024

New config 'extended-redis-compatibility' (yes/no) default no

  • When yes:

    • Use "Redis" in the following error replies:
      • -LOADING Redis is loading the dataset in memory
      • -BUSY Redis is busy...
      • -MISCONF Redis is configured to...
    • Use === REDIS BUG REPORT in the crash log delimiters (START and END).
    • The HELLO command returns "server" => "redis" and "version" => "7.2.4" (our Redis OSS compatibility version).
    • The INFO field for mode is called "redis_mode".
  • When no:

    • Use "Valkey" instead of "Redis" in the mentioned errors and crash log delimiters.
    • The HELLO command returns "server" => "valkey" and the Valkey version for "version".
    • The INFO field for mode is called "server_mode".
  • Documentation added in valkey.conf:

    Valkey is largely compatible with Redis OSS, apart from a few cases where
    Redis OSS compatibility mode makes Valkey pretend to be Redis. Enable this
    only if you have problems with tools or clients. This is a temporary
    configuration added in Valkey 8.0 and is scheduled to have no effect in Valkey
    9.0 and be completely removed in Valkey 10.0.

  • A test case for the config is added. It is designed to fail if the config is not deprecated (has no effect) in Valkey 9 and deleted in Valkey 10.

  • Other test cases are adjusted to work regardless of this config.

Fixes #274
Fixes #61

@madolson madolson added major-decision-pending Major decision pending by TSC team major-decision-approved Major decision approved by TSC team and removed major-decision-pending Major decision pending by TSC team labels Apr 15, 2024
Add the config, including docs as comments in valkey.conf.

Define SERVER_TITLE "Valkey" in version.h.

Make the errors -LOADING, -BUSY and -MISCONF depend on the config.

Signed-off-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
… config

Signed-off-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
This commit includes a test that will remind us to delete the temporary
config when the time comes.

Signed-off-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
Signed-off-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
Signed-off-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
@zuiderkwast zuiderkwast force-pushed the redis-compatility-knob branch from 161b6d0 to 82b95c8 Compare April 17, 2024 12:58
Explain the plans for removal in future versions.

Signed-off-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
Add the config, including docs as comments in valkey.conf.

Define SERVER_TITLE "Valkey" in version.h.

Make the errors -LOADING, -BUSY and -MISCONF depend on the config.

Signed-off-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
@zuiderkwast zuiderkwast force-pushed the redis-compatility-knob branch from 82b95c8 to 8c26e98 Compare April 17, 2024 12:59
@zuiderkwast zuiderkwast added release-notes This issue should get a line item in the release notes breaking-change Indicates a possible backwards incompatible change labels Apr 18, 2024
@zuiderkwast zuiderkwast merged commit 9e2b783 into valkey-io:unstable Apr 18, 2024
@zuiderkwast zuiderkwast deleted the redis-compatility-knob branch April 18, 2024 12:10
PatrickJS pushed a commit to PatrickJS/placeholderkv that referenced this pull request Apr 24, 2024
New config 'extended-redis-compatibility' (yes/no) default no

* When yes:
  * Use "Redis" in the following error replies:
    - `-LOADING Redis is loading the dataset in memory`
    - `-BUSY Redis is busy`...
    - `-MISCONF Redis is configured to`...
* Use `=== REDIS BUG REPORT` in the crash log delimiters (START and
END).
* The HELLO command returns `"server" => "redis"` and `"version" =>
"7.2.4"` (our Redis OSS compatibility version).
  * The INFO field for mode is called `"redis_mode"`.
* When no:
* Use "Valkey" instead of "Redis" in the mentioned errors and crash log
delimiters.
* The HELLO command returns `"server" => "valkey"` and the Valkey
version for `"version"`.
  * The INFO field for mode is called `"server_mode"`.

* Documentation added in valkey.conf:

> Valkey is largely compatible with Redis OSS, apart from a few cases
where
> Redis OSS compatibility mode makes Valkey pretend to be Redis. Enable
this
  > only if you have problems with tools or clients. This is a temporary
> configuration added in Valkey 8.0 and is scheduled to have no effect
in Valkey
  > 9.0 and be completely removed in Valkey 10.0.

* A test case for the config is added. It is designed to fail if the
config is not deprecated (has no effect) in Valkey 9 and deleted in
Valkey 10.

* Other test cases are adjusted to work regardless of this config.

Fixes valkey-io#274
Fixes valkey-io#61

---------

Signed-off-by: Viktor Söderqvist <viktor.soderqvist@est.tech>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

breaking-change Indicates a possible backwards incompatible change major-decision-approved Major decision approved by TSC team release-notes This issue should get a line item in the release notes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[NEW] Redis-compatibility mode The reply from HELLO

3 participants