-
Notifications
You must be signed in to change notification settings - Fork 690
feat: dyn namespace scoping for trtllm #2970
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
WalkthroughIntroduces an environment-configurable namespace (DYN_NAMESPACE) and updates three default endpoint constants to interpolate this namespace, falling back to "dynamo" if the environment variable is unset. No other logic or constants are changed. Changes
Sequence Diagram(s)sequenceDiagram
autonumber
actor Env as Environment
participant Utils as trtllm_utils.py
participant Client as Caller
Env->>Utils: DYN_NAMESPACE (optional)
Note over Utils: On import
Utils->>Utils: DYN_NAMESPACE = os.getenv("DYN_NAMESPACE", "dynamo")
Utils->>Utils: DEFAULT_ENDPOINT = dyn://{DYN_NAMESPACE}.tensorrt_llm.generate
Utils->>Utils: DEFAULT_NEXT_ENDPOINT = dyn://{DYN_NAMESPACE}.tensorrt_llm_next.generate
Utils->>Utils: DEFAULT_ENCODE_ENDPOINT = dyn://{DYN_NAMESPACE}.tensorrt_llm_encode.generate
Client->>Utils: Import constants
Utils-->>Client: Resolved endpoints (namespace-aware)
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
Tip 👮 Agentic pre-merge checks are now available in preview!Pro plan users can now enable pre-merge checks in their settings to enforce checklists before merging PRs.
Example: reviews:
pre_merge_checks:
custom_checks:
- name: "Undocumented Breaking Changes"
mode: "warning"
instructions: |
Pass/fail criteria: All breaking changes to public APIs, CLI flags, environment variables, configuration keys, database schemas, or HTTP/GraphQL endpoints must be documented in the "Breaking Change" section of the PR description and in CHANGELOG.md. Exclude purely internal or private changes (e.g., code not exported from package entry points or explicitly marked as internal).Please share your feedback with us on this Discord post. Pre-merge checks (2 passed, 1 warning)❌ Failed checks (1 warning)
✅ Passed checks (2 passed)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 1
🧹 Nitpick comments (1)
components/backends/trtllm/src/dynamo/trtllm/utils/trtllm_utils.py (1)
20-23: Deduplicate endpoint construction in trtllm_utils
Replace the three hard-coded DEFAULT_* constants in components/backends/trtllm/src/dynamo/trtllm/utils/trtllm_utils.py with the_build_endpointhelper. Similar hard-coded dyn://… defaults still exist in examples, docs, and launch scripts—consider extending this helper globally for consistency.
📜 Review details
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
components/backends/trtllm/src/dynamo/trtllm/utils/trtllm_utils.py(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
- GitHub Check: Build and Test - dynamo
🔇 Additional comments (1)
components/backends/trtllm/src/dynamo/trtllm/utils/trtllm_utils.py (1)
5-5: Import for env-based config — OKNo issues adding
os; needed for env-driven defaults.
13992c8 to
14d2782
Compare
Signed-off-by: Biswa Panda <biswa.panda@gmail.com>
14d2782 to
680254b
Compare
|
/ok to test 680254b |
Signed-off-by: Biswa Panda <biswa.panda@gmail.com>
Signed-off-by: Biswa Panda <biswa.panda@gmail.com> Signed-off-by: ayushag <ayushag@nvidia.com>
Signed-off-by: Biswa Panda <biswa.panda@gmail.com>
Signed-off-by: Biswa Panda <biswa.panda@gmail.com>
Signed-off-by: Biswa Panda <biswa.panda@gmail.com> Signed-off-by: ayushag <ayushag@nvidia.com>
Signed-off-by: Biswa Panda <biswa.panda@gmail.com> Signed-off-by: zhongdaor <zhongdaor@nvidia.com>
Overview:
Scope trtllm worker to DYN_NAMESPACE for namespace isolation
Related PR: #2475
closes: DYN-838
fixes : https://nvbugspro.nvidia.com/bug/5507011
Supports scoping backend to a specific dynamo namespace based on env variable DYN_NAMESPACE
Details:
Where should the reviewer start?
Related Issues: (use one of the action keywords Closes / Fixes / Resolves / Relates to)
Summary by CodeRabbit