Skip to content

[Misc]Harden batch status-copy key encoding across storages - #2415

Merged
zhangjyr merged 3 commits into
vllm-project:mainfrom
zhangjyr:issues/santicizing_metadata_keys
Jul 6, 2026
Merged

zhangjyr merged 3 commits into
vllm-project:mainfrom
zhangjyr:issues/santicizing_metadata_keys

Conversation

@zhangjyr

@zhangjyr zhangjyr commented Jul 2, 2026

Copy link
Copy Markdown
Collaborator

Pull Request Description

This PR improves batch status-copy keys for Redis-backed flows and aligns tests with the updated key model.

Motivation

Worker IDs and status-copy keys can contain /, which collides with hierarchical storage semantics in both local and Redis-backed backends. Redis-backed tests also need stronger isolation and more tolerant polling to reflect asynchronous status propagation. This PR standardizes key encoding/normalization and adds the fixture/test support needed to validate it.

What changed

  • normalize runtime-derived worker IDs to avoid / leaking into storage keys
  • switch Kubernetes runtime owner refs from namespace/name to namespace:name
  • add Redis global-prefix support across object operations, indexes, and listing paths
  • harden Redis v3 upgrade logic to remove legacy batchstatus_copies artifacts and their stale indexes
  • add Redis-aware E2E backend setup, connectivity checks, per-test prefixes, and cleanup
  • extend E2E wait/poll behavior for Redis-metastore runs to reduce timing-related flakes
  • expand unit/integration coverage for encoded keys, owner refs, upgrade cleanup, and Redis-specific execution paths

Important: Before submitting, please complete the description above and review the checklist below.


Contribution Guidelines (Expand for Details)

We appreciate your contribution to aibrix! To ensure a smooth review process and maintain high code quality, please adhere to the following guidelines:

Pull Request Title Format

Your PR title should start with one of these prefixes to indicate the nature of the change:

  • [Bug]: Corrections to existing functionality
  • [CI]: Changes to build process or CI pipeline
  • [Docs]: Updates or additions to documentation
  • [API]: Modifications to aibrix's API or interface
  • [CLI]: Changes or additions to the Command Line Interface
  • [Misc]: For changes not covered above (use sparingly)

Note: For changes spanning multiple categories, use multiple prefixes in order of importance.

Submission Checklist

  • PR title includes appropriate prefix(es)
  • Changes are clearly explained in the PR description
  • New and existing tests pass successfully
  • Code adheres to project style and best practices
  • Documentation updated to reflect changes (if applicable)
  • Thorough testing completed, no regressions introduced

By submitting this PR, you confirm that you've read these guidelines and your changes align with the project's contribution standards.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Code Review

This pull request introduces support for global Redis key prefixing via DB_REDIS_PREFIX and implements percent-encoding for hierarchical keys (such as worker IDs containing slashes) to ensure safe storage across local and Redis backends. It also updates the Redis v3 upgrade and verification logic to clean up legacy batch status copy entries. The review feedback correctly identifies that the Redis upgrade and verification scripts do not account for the new global prefix when matching legacy keys, and provides actionable suggestions to strip the prefix before performing checks and remapping.

@zhangjyr
zhangjyr force-pushed the issues/santicizing_metadata_keys branch from e6ebca3 to 65fb051 Compare July 2, 2026 23:26

@DwyaneShi DwyaneShi left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

LGTM

Jingyuan Zhang added 2 commits July 6, 2026 13:20
Refactor batch/confest to support redis as e2e metastore and provide test namespace isolation.

Signed-off-by: Jingyuan Zhang <[email protected]>
Signed-off-by: Jingyuan Zhang <[email protected]>
@zhangjyr
zhangjyr force-pushed the issues/santicizing_metadata_keys branch from 65fb051 to 7cee1ba Compare July 6, 2026 20:21
@zhangjyr
zhangjyr merged commit 98aa315 into vllm-project:main Jul 6, 2026
11 checks passed
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