Skip to content

<feature>[ai]: refresh SDK for vLLM template upgrade#4436

Open
MatheMatrix wants to merge 1 commit into
feature-5.5.28-aiosfrom
sync/xinhao.huang/feat/vllm-0.24.0-aios-premium
Open

<feature>[ai]: refresh SDK for vLLM template upgrade#4436
MatheMatrix wants to merge 1 commit into
feature-5.5.28-aiosfrom
sync/xinhao.huang/feat/vllm-0.24.0-aios-premium

Conversation

@MatheMatrix

Copy link
Copy Markdown
Owner

Summary

Validation

  • git diff --check HEAD~1..HEAD
  • generated files match local runMavenProfile sdk output from the full premium build

Jira: http://jira.zstack.io/browse/ZSTAC-86068

sync from gitlab !10391

Regenerate Java SDK outputs for AI model cache APIs.

This makes update_sdk produce no diff on feature-5.5.28-aios.

Resolves: ZSTAC-86068

Change-Id: I8606800000000000000000000000000000000003
@coderabbitai

coderabbitai Bot commented Jul 3, 2026

Copy link
Copy Markdown

Review Change Stack

Warning

.coderabbit.yaml has a parsing error

The CodeRabbit configuration file in this repository has a parsing error and default settings were used instead. Please fix the error(s) in the configuration file. You can initialize chat with CodeRabbit to get help with the configuration file.

💥 Parsing errors (1)
Could not fetch remote config from http://open.zstack.ai:20001/code-reviews/zstack-cloud.yaml: TimeoutError: The operation was aborted due to timeout
⚙️ Configuration instructions
  • Please see the configuration documentation for more information.
  • You can also validate your configuration using the online YAML validator.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Walkthrough

该PR将三个SDK结果类(GetAiHostModelCacheCapacityResult、QueryAiHostModelCacheResult、RefreshAiHostModelCacheResult)中的inventories字段类型及其setInventories/getInventories方法签名从带泛型的List<T>改为原生java.util.List,移除了编译期类型约束。

Changes

SDK结果类泛型移除

Layer / File(s) Summary
移除inventories字段泛型约束
sdk/src/main/java/org/zstack/sdk/GetAiHostModelCacheCapacityResult.java, sdk/src/main/java/org/zstack/sdk/QueryAiHostModelCacheResult.java, sdk/src/main/java/org/zstack/sdk/RefreshAiHostModelCacheResult.java
三个类的inventories字段及其setter/getter方法的类型从List<AiHostCacheStorageInventory>List<AiHostModelCacheInventory>统一改为原生java.util.List

Estimated code review effort: 1 (Trivial) | ~3 minutes

Poem

泛型退场,原生登台,
三份结果,同心裁剪,
兔耳竖起,代码轻快,
编译警告,静待除害,
一跳一跃,PR新载!🐇✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed 标题简洁且与本次刷新 AI 模型缓存相关 SDK 代码生成的变更一致。
Description check ✅ Passed 描述明确说明了刷新 AI 模型缓存 API 的 Java SDK,并补充了关联 MR 和验证信息。
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch sync/xinhao.huang/feat/vllm-0.24.0-aios-premium

Comment @coderabbitai help to get the list of available commands.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In `@sdk/src/main/java/org/zstack/sdk/GetAiHostModelCacheCapacityResult.java`:
- Around line 6-10: The GetAiHostModelCacheCapacityResult inventories field is
using a raw List, which drops type safety and IDE support. Update the
inventories member along with setInventories and getInventories to use
List<AiHostCacheStorageInventory> instead of the raw List so the result model
preserves its generic type information.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Repository UI

Review profile: CHILL

Plan: Pro

Run ID: 534883d4-839b-4639-8e37-ef5babe20b96

📥 Commits

Reviewing files that changed from the base of the PR and between d483a3d and 2d640ac.

📒 Files selected for processing (3)
  • sdk/src/main/java/org/zstack/sdk/GetAiHostModelCacheCapacityResult.java
  • sdk/src/main/java/org/zstack/sdk/QueryAiHostModelCacheResult.java
  • sdk/src/main/java/org/zstack/sdk/RefreshAiHostModelCacheResult.java

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