RedisShake icon indicating copy to clipboard operation
RedisShake copied to clipboard

v4.2.0版本修改DB出现异常

Open tedgxt opened this issue 1 year ago • 1 comments

问题描述(Issue Description)

使用v4.2.0 release,在function中修改DB号无效

Please provide a brief description of the issue you encountered.

环境信息(Environment)

  • RedisShake 版本(RedisShake Version):v4.2.0
  • Redis 源端版本(Redis Source Version):5.0
  • Redis 目的端版本(Redis Destination Version):5.0
  • Redis 部署方式(standalone/cluster/sentinel):standalone
  • 是否在云服务商实例上部署(Deployed on Cloud Provider):AWS elasticache redis

日志信息(Logs)

如果有错误日志或其他相关日志,请在这里提供。

If there are any error logs or other relevant logs, please provide them here.

其他信息(Additional Information)

请提供任何其他相关的信息,如配置文件、错误信息或截图等。

Please provide any additional information, such as configuration files, error messages, or screenshots. v4.1.1版本是正常的。 function内容如下(源库的db5中的数据同步到目标库的db20):

# shake.toml
function = """

shake.log(DB)
if DB == 5 then
    DB = 20
end
shake.log(DB)
shake.call(DB, ARGV)

"""

tedgxt avatar Oct 17 '24 06:10 tedgxt

配置项改了,需要加一个 [filter] :

[filter]
function = """

shake.log(DB)
if DB == 5 then
    DB = 20
end
shake.log(DB)
shake.call(DB, ARGV)

"""

suxb201 avatar Oct 17 '24 06:10 suxb201