Skip to content

Conversation

@biswapanda
Copy link
Contributor

@biswapanda biswapanda commented May 31, 2025

Overview:

  • service args should be resources (plural) not resource

Details:

Where should the reviewer start?

Related Issues: (use one of the action keywords Closes / Fixes / Resolves / Relates to)

  • closes GitHub issue: #xxx

Summary by CodeRabbit

  • New Features

    • Improved resource configuration for services, including more flexible CPU, GPU, and memory settings.
    • Enhanced configuration validation and error messages for missing Docker image settings.
  • Bug Fixes

    • Corrected resource field naming and validation in service configuration.
  • Chores

    • Updated package and dependency versions to 0.3.0 across multiple components.
    • Adjusted Docker build processes and updated related scripts and documentation.
    • Removed an unused optional dependency group.
  • Style

    • Removed unnecessary debug and logging statements.
  • Tests

    • Improved test assertions for resource configuration.
  • Documentation

    • Updated support matrix and version notes for dependencies.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented May 31, 2025

Caution

Review failed

The pull request is closed.

Walkthrough

This update synchronizes version numbers across multiple Rust and Python manifests, adjusts Dockerfiles to copy source code earlier in build stages, and refines resource configuration handling in code and documentation. It also adds conditional logic for controller argument generation, modifies error handling in model uniqueness checks, improves resource validation in tests, and updates type annotations for asynchronous tasks.

Changes

File(s) Change Summary
Cargo.toml, lib/bindings/python/Cargo.toml, lib/runtime/examples/Cargo.toml, pyproject.toml Bumped package and dependency versions from 0.2.1 to 0.3.0; removed "sglang" optional dependency in pyproject.toml.
container/Dockerfile.sglang, container/Dockerfile.tensorrt_llm, container/Dockerfile.vllm Moved or added COPY . /workspace step to earlier build stages; updated vllm package version in Dockerfile.vllm.
container/build.sh Updated NIXL_COMMIT hash to a new commit for Docker builds.
docs/support_matrix.md Updated documented package versions to match new releases and patch versions.
lib/llm/Cargo.toml Updated nixl-sys dependency version from 0.2.1-rc.3 to 0.3.0-rc.2.
lib/llm/src/local_model.rs Changed error handling in ensure_unique to ignore errors from loading entries unless successful.
deploy/cloud/operator/internal/controller/dynamocomponentdeployment_controller.go Added ComponentTypePlanner constant; made environment argument conditional on label value.
deploy/cloud/operator/internal/controller/dynamocomponentdeployment_controller_test.go Updated test to remove now-conditional environment argument from expected command args.
deploy/sdk/src/dynamo/sdk/cli/build.py Improved Docker image resolution logic; fixed resource field name to resources; removed debug print.
deploy/sdk/src/dynamo/sdk/core/lib.py Removed logging statement from the service decorator.
deploy/sdk/src/dynamo/sdk/core/protocol/interface.py Changed resource config field types/defaults; added validator for gpu; renamed resource to resources in ServiceConfig.
deploy/sdk/src/dynamo/sdk/tests/test_resources.py Enhanced test assertions to check resource config fields on service interface.
examples/llm/configs/agg_router.yaml Added explicit CPU and memory resource requests to VllmWorker service configuration.
examples/tensorrt_llm/common/utils.py Updated type annotations for task to expect coroutine callables; adjusted imports accordingly.

Sequence Diagram(s)

sequenceDiagram
    participant Controller as dynamocomponentdeployment_controller.go
    participant K8s as Kubernetes
    Controller->Controller: Check KubeLabelDynamoComponent label
    alt Label == "Planner"
        Controller->Controller: Append --<service>.environment=kubernetes to args
    else
        Controller->Controller: Do not append environment arg
    end
    Controller->K8s: Generate PodTemplateSpec with args
Loading
sequenceDiagram
    participant ServiceInfo as ServiceInfo.from_service
    participant Config as service.config
    ServiceInfo->Config: Check config.image
    alt config.image is set
        ServiceInfo->ServiceInfo: Use config.image
    else
        ServiceInfo->ServiceInfo: Use DYNAMO_IMAGE constant
    end
    ServiceInfo->ServiceInfo: Assert image is not None
    ServiceInfo->ServiceInfo: Use config.resources.model_dump()
Loading
sequenceDiagram
    participant LocalModel as ensure_unique
    participant Etcd as network_name.load_entry
    LocalModel->Etcd: Attempt to load entry
    alt Ok(entry)
        LocalModel->LocalModel: Check entry.name != model_name
        alt Duplicate
            LocalModel->LocalModel: Bail with error
        end
    else
        LocalModel->LocalModel: Ignore error, continue
    end
Loading

Possibly related PRs

Suggested labels

size/M

Suggested reviewers

  • biswapanda
  • grahamking
  • ryanolson
  • paulhendricks
  • kkranen
  • tanmayv25
  • nnshah1
  • alec-flowers
  • GuanLuo
  • tmonty12
  • ishandhanani
  • ptarasiewiczNV
  • oandreeva-nv
  • rmccorm4

Poem

Hopping through configs and code,
Version numbers now in mode.
Dockerfiles copy with care,
Resource fields get a fresh new air.
Controllers check with extra sense—
This bunny’s patch is quite immense!
🐇✨


📜 Recent review details

Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 859944f and 0e550d6.

⛔ Files ignored due to path filters (3)
  • Cargo.lock is excluded by !**/*.lock
  • lib/bindings/python/Cargo.lock is excluded by !**/*.lock
  • lib/runtime/examples/Cargo.lock is excluded by !**/*.lock
📒 Files selected for processing (19)
  • Cargo.toml (2 hunks)
  • container/Dockerfile.sglang (1 hunks)
  • container/Dockerfile.tensorrt_llm (1 hunks)
  • container/Dockerfile.vllm (2 hunks)
  • container/build.sh (1 hunks)
  • deploy/cloud/operator/internal/controller/dynamocomponentdeployment_controller.go (2 hunks)
  • deploy/cloud/operator/internal/controller/dynamocomponentdeployment_controller_test.go (1 hunks)
  • deploy/sdk/src/dynamo/sdk/cli/build.py (1 hunks)
  • deploy/sdk/src/dynamo/sdk/core/lib.py (0 hunks)
  • deploy/sdk/src/dynamo/sdk/core/protocol/interface.py (2 hunks)
  • deploy/sdk/src/dynamo/sdk/tests/test_resources.py (2 hunks)
  • docs/support_matrix.md (1 hunks)
  • examples/llm/configs/agg_router.yaml (1 hunks)
  • examples/tensorrt_llm/common/utils.py (3 hunks)
  • lib/bindings/python/Cargo.toml (2 hunks)
  • lib/llm/Cargo.toml (1 hunks)
  • lib/llm/src/local_model.rs (1 hunks)
  • lib/runtime/examples/Cargo.toml (1 hunks)
  • pyproject.toml (2 hunks)

🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Explain this complex logic.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai explain this code block.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and explain its main purpose.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai generate sequence diagram to generate a sequence diagram of the changes in this PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

7 participants