Skip to content

Conversation

@007gzs
Copy link
Collaborator

@007gzs 007gzs commented Oct 27, 2025

Ⅰ. Describe what this PR did

fix OnHttpStreamDone OnHttpStreamDone 回调逻辑错误

Ⅱ. Does this pull request fix one issue?

proxy-wasm/proxy-wasm-go-sdk#12
合并 higress-group/proxy-wasm-go-sdk#18 之后使用新的commitid替换replcae

Ⅲ. Why don't you add test cases (unit test/integration test)?

Ⅳ. Describe how to verify it

Ⅴ. Special notes for reviews

@lingma-agents
Copy link

lingma-agents bot commented Oct 27, 2025

修复 OnHttpStreamDone 回调逻辑并更新依赖

变更概述
  • 问题修复
    • 修复了 OnHttpStreamDone 回调函数的逻辑错误,确保在配置未初始化或回调函数未设置时能正确返回。
    • 修正了旧版 onHttpStreamDone 函数适配逻辑,使用新的函数签名以保持一致性。
  • 依赖更新
    • 更新了 proxy-wasm-go-sdk 的依赖版本,替换为 github.com/007gzs/proxy-wasm-go-sdk 的新提交版本。
    • go.mod 中添加了 replace 指令以指向特定的 SDK 提交版本,确保使用修复后的代码。
变更文件
文件路径 变更说明
plugins/wasm-go/go.mod 添加了对 proxy-wasm-go-sdk 的 replace 指令,指向修复后的版本。
plugins/wasm-go/go.sum 更新了依赖校验和,以匹配新的 proxy-wasm-go-sdk 版本。
plugins/​wasm-go/​pkg/​wrapper/​plugin_​wrapper.​go 修正了 OnHttpStreamDone 回调逻辑,添加了新的函数类型定义并更新了适配逻辑。
时序图
sequenceDiagram
    participant CH as CommonHttpCtx
    participant VM as CommonVmCtx
    CH->>VM: OnHttpStreamDone()
    alt config is nil
        VM-->>CH: return true
    else onHttpStreamDone is nil
        VM-->>CH: return true
    else
        VM->>VM: call onHttpStreamDone(ctx, *config)
        VM-->>CH: return result
Loading

💡 小贴士

与 lingma-agents 交流的方式

📜 直接回复评论
直接回复本条评论,lingma-agents 将自动处理您的请求。例如:

  • 在当前代码中添加详细的注释说明。

  • 请详细介绍一下你说的 LRU 改造方案,并使用伪代码加以说明。

📜 在代码行处标记
在文件的特定位置创建评论并 @lingma-agents。例如:

  • @lingma-agents 分析这个方法的性能瓶颈并提供优化建议。

  • @lingma-agents 对这个方法生成优化代码。

📜 在讨论中提问
在任何讨论中 @lingma-agents 来获取帮助。例如:

  • @lingma-agents 请总结上述讨论并提出解决方案。

  • @lingma-agents 请根据讨论内容生成优化代码。

@codecov-commenter
Copy link

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 43.44%. Comparing base (ef31e09) to head (2469d03).
⚠️ Report is 757 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #3058      +/-   ##
==========================================
+ Coverage   35.91%   43.44%   +7.53%     
==========================================
  Files          69       82      +13     
  Lines       11576    10917     -659     
==========================================
+ Hits         4157     4743     +586     
+ Misses       7104     5845    -1259     
- Partials      315      329      +14     

see 97 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants