iop07695432 opened a new issue, #3868:
URL: https://github.com/apache/hertzbeat/issues/3868
### Is there an existing issue for this?
- [x] I have searched the existing issues
### Current Behavior
1. HertzBeat AI页面新建会话 A,发送消息后能正常看到用户和 AI 的聊天记录
2. 新建会话 B,发送消息后能正常看到聊天记录
3. 切换回会话 A 时,A 的聊天记录全部消失,只显示默认的欢迎页面("欢迎使用 HertzBeat AI!我是您的智能可观测伙伴...")
4. 在多个会话(A/B/C/D...)之间任意切换,都会出现相同问题:当前会话的历史聊天记录消失
### Expected Behavior
1. 聊天记录持久化:用户新建会话后,只要不主动点击"删除会话"按钮,聊天记录应该一直保留(受限于数据库存储空间)
2. 会话上下文保持:AI 聊天会话的上下文连接应该一直保持,直到用户手动关闭会话
3. 会话隔离:会话 A 的聊天记录不能串到会话 B 显示,每个会话的消息列表必须严格隔离
4. 资源释放机制:只有当用户手动删除会话时,后端才释放该会话的资源(避免 OOM 风险)
### Steps To Reproduce
macos环境,我通过git clone 拉取源码到本地,前后端启动,直接点击右下角机器人图标,在HertzBeat AI页面就能复现。
### Environment
```markdown
HertzBeat version(s):2.0-SNAPSHOT
```
### Debug logs
_No response_
### Anything else?
_No response_
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail:
notifications-unsubscr...@hertzbeat.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscr...@hertzbeat.apache.org
For additional commands, e-mail: notifications-h...@hertzbeat.apache.org