Skip to content
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

渠道自动禁用邮件通知的问题 #1276

Closed
5 tasks
popdo opened this issue Apr 5, 2024 · 2 comments
Closed
5 tasks

渠道自动禁用邮件通知的问题 #1276

popdo opened this issue Apr 5, 2024 · 2 comments
Labels
bug Something isn't working

Comments

@popdo
Copy link

popdo commented Apr 5, 2024

例行检查

  • 我已确认目前没有类似 issue
  • 我已确认我已升级到最新版本
  • 我已完整查看过项目 README,尤其是常见问题部分
  • 我理解并愿意跟进此 issue,协助测试和提供反馈
  • 我理解并认可上述内容,并理解项目维护者精力有限,不遵循规则的 issue 可能会被无视或直接关闭

问题描述

目前自动禁用渠道的判断

if strings.Contains(err.Message, "quota") {
		return true
	}

用户余额不足时是否也会将渠道禁用,是否会不合理,今天突然收到了上百份user quota is not enough自动禁用渠道邮件通知。这里判断的貌似不只是上游或渠道key余额不足,还包含用户的余额不足。

开启redis后,在高并发连续请求下 邮箱通知貌似一直都有bug,会瞬间收到十多二十多份重复的渠道自动禁用通知。不知道其他人是否有同样的情况。

复现步骤

预期结果

相关截图
如果没有的话,请删除此节。

@popdo popdo added the bug Something isn't working label Apr 5, 2024
@songquanpeng
Copy link
Owner

这里的判断有问题,误判了,已经修复,感谢反馈

@songquanpeng
Copy link
Owner

v0.6.5-alpha.7

SheldonLiu0412 pushed a commit to SheldonLiu0412/one-api that referenced this issue Jan 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants