Skip to content

Commit afb8495

Browse files
authored
feat: decouple bento dependency (#1266)
1 parent e31f8d9 commit afb8495

File tree

26 files changed

+119
-2123
lines changed

26 files changed

+119
-2123
lines changed

container/Dockerfile.sglang

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -347,9 +347,6 @@ RUN mkdir -p /opt/dynamo/bindings/wheels && \
347347
RUN uv pip install /workspace/dist/ai_dynamo_runtime*cp312*.whl && \
348348
uv pip install /workspace/dist/ai_dynamo*any.whl
349349

350-
# TODO: remove kantoku as a transitive dependency
351-
RUN uv pip uninstall kantoku circus && uv pip install circus==0.19.0
352-
353350
# Copy launch banner
354351
RUN --mount=type=bind,source=./container/launch_message.txt,target=/workspace/launch_message.txt \
355352
sed '/^#\s/d' /workspace/launch_message.txt > ~/.launch_screen && \
@@ -399,9 +396,6 @@ RUN uv pip install ai-dynamo[vllm] --find-links wheelhouse && \
399396
ln -sf $VIRTUAL_ENV/bin/* /usr/local/bin/ && \
400397
rm -r wheelhouse
401398

402-
# TODO: remove kantoku as a transitive dependency
403-
RUN uv pip uninstall kantoku circus && uv pip install circus==0.19.0
404-
405399
# Tell vllm to use the Dynamo LLM C API for KV Cache Routing
406400
ENV VLLM_KV_CAPI_PATH="/opt/dynamo/bindings/lib/libdynamo_llm_capi.so"
407401

container/Dockerfile.tensorrt_llm

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -323,10 +323,6 @@ RUN . /opt/dynamo/venv/bin/activate && \
323323
uv pip install /workspace/dist/ai_dynamo_runtime*cp312*.whl && \
324324
uv pip install /workspace/dist/ai_dynamo*any.whl
325325

326-
# TODO: remove kantoku as a transitive dependency
327-
RUN . /opt/dynamo/venv/bin/activate && \
328-
uv pip uninstall kantoku circus && uv pip install circus==0.19.0
329-
330326
# Install dynamo.runtime and dynamo.llm wheels globally in container for tests
331327
# TODO: In future, we may use a virtualenv for everything and remove this.
332328
RUN pip install dist/ai_dynamo_runtime*cp312*.whl && \

container/Dockerfile.vllm

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -438,9 +438,6 @@ RUN mkdir -p /opt/dynamo/bindings/wheels && \
438438
RUN uv pip install /workspace/dist/ai_dynamo_runtime*cp312*.whl && \
439439
uv pip install /workspace/dist/ai_dynamo*any.whl
440440

441-
# TODO: remove kantoku as a transitive dependency
442-
RUN uv pip uninstall kantoku circus && uv pip install circus==0.19.0
443-
444441
# Copy launch banner
445442
RUN --mount=type=bind,source=./container/launch_message.txt,target=/workspace/launch_message.txt \
446443
sed '/^#\s/d' /workspace/launch_message.txt > ~/.launch_screen && \
@@ -517,9 +514,6 @@ RUN uv pip install ai-dynamo[vllm] --find-links wheelhouse && \
517514
ln -sf $VIRTUAL_ENV/bin/* /usr/local/bin/ && \
518515
rm -r wheelhouse
519516

520-
# TODO: remove kantoku as a transitive dependency
521-
RUN uv pip uninstall kantoku circus && uv pip install circus==0.19.0
522-
523517
# Tell vllm to use the Dynamo LLM C API for KV Cache Routing
524518
ENV VLLM_KV_CAPI_PATH="/opt/dynamo/bindings/lib/libdynamo_llm_capi.so"
525519

deploy/helm/deploy.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -87,4 +87,4 @@ cd -
8787
# Install the Helm chart with the correct tag (SHA)
8888
echo "Installing Helm chart with image: $docker_tag_for_registry"
8989
HELM_RELEASE="${DYNAMO_MODULE//_/\-}"
90-
helm upgrade -i "$HELM_RELEASE" ./chart -f ~/bentoml/bentos/"$DYNAMO_NAME"/"$docker_sha"/bento.yaml --set image="$docker_tag_for_registry" --set dynamoIdentifier="$DYNAMO_IDENTIFIER" --set configFilePath="$DYNAMO_CONFIG_FILE" -n "$NAMESPACE"
90+
helm upgrade -i "$HELM_RELEASE" ./chart -f ~/.dynamo/packages/"$DYNAMO_MODULE"/"$DYNAMO_NAME"/dynamo.yaml --set image="$docker_tag_for_registry" --set dynamoIdentifier="$DYNAMO_IDENTIFIER" --set configFilePath="$DYNAMO_CONFIG_FILE" -n "$NAMESPACE"

deploy/sdk/src/dynamo/sdk/__init__.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,19 +20,16 @@
2020
# TODO: Remove this line after the bentoml import is removed from this file
2121
warnings.filterwarnings("ignore", category=UserWarning, message=".*pkg_resources.*")
2222

23-
# flake8: noqa: E402
24-
from bentoml import on_shutdown as async_on_shutdown
25-
2623
# flake8: noqa: E402
2724
from dynamo.sdk.core.decorators.endpoint import api, endpoint
2825
from dynamo.sdk.core.lib import DYNAMO_IMAGE, depends, liveness, readiness, service
29-
from dynamo.sdk.lib.decorators import async_on_start
26+
from dynamo.sdk.lib.decorators import async_on_start, on_shutdown
3027

3128
dynamo_context: dict[str, Any] = {}
3229

3330
__all__ = [
3431
"DYNAMO_IMAGE",
35-
"async_on_shutdown",
32+
"on_shutdown",
3633
"async_on_start",
3734
"depends",
3835
"dynamo_context",

deploy/sdk/src/dynamo/sdk/cli/allocator.py

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,7 @@
2121
import os
2222
from typing import Any
2323

24-
from _bentoml_sdk import Service
25-
from simple_di import inject
24+
from dynamo.sdk.core.protocol.interface import ServiceInterface
2625

2726
# Import our own resource module
2827
from dynamo.sdk.lib.resource import (
@@ -149,10 +148,9 @@ def get_gpu_stats(self) -> list[dict[str, Any]]:
149148
"""Get detailed statistics for all GPUs."""
150149
return self.gpu_manager.get_gpu_stats()
151150

152-
@inject
153151
def get_resource_envs(
154152
self,
155-
service: Service[Any],
153+
service: ServiceInterface[Any],
156154
) -> tuple[int, list[dict[str, str]]]:
157155
"""
158156
Get resource environment variables for a service.

deploy/sdk/src/dynamo/sdk/cli/bento_util.py

Lines changed: 0 additions & 276 deletions
This file was deleted.

0 commit comments

Comments
 (0)