Skip to content

Commit

Permalink
Merge pull request #59 from bento-platform/chore/update
Browse files Browse the repository at this point in the history
chore: update dependencies (+ small new bento lib usage tweaks)
  • Loading branch information
davidlougheed authored May 24, 2024
2 parents 5fe7867 + 130019b commit b78e9ce
Show file tree
Hide file tree
Showing 6 changed files with 1,099 additions and 415 deletions.
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
FROM ghcr.io/bento-platform/bento_base_image:python-debian-2024.02.01
FROM ghcr.io/bento-platform/bento_base_image:python-debian-2024.05.01

# Run as root in the Dockerfile until we drop down to the service user in the entrypoint
USER root

# Use uvicorn (instead of hypercorn) in production since I've found
# multiple benchmarks showing it to be faster - David L
RUN pip install --no-cache-dir "uvicorn[standard]==0.27.1"
RUN pip install --no-cache-dir "uvicorn[standard]==0.29.0"

WORKDIR /aggregation

Expand Down
4 changes: 2 additions & 2 deletions bento_aggregation_service/config.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
from functools import lru_cache
from typing import Annotated

from .constants import SERVICE_NAME, SERVICE_TYPE
from .constants import SERVICE_TYPE

__all__ = [
"Config",
Expand All @@ -14,7 +14,7 @@

class Config(BentoBaseConfig):
service_id: str = str(":".join(list(SERVICE_TYPE.values())[:2]))
service_name: str = SERVICE_NAME
service_name: str = "Bento Aggregation Service"

request_timeout: int = 180 # seconds

Expand Down
13 changes: 2 additions & 11 deletions bento_aggregation_service/constants.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,13 @@
from __future__ import annotations

from bento_lib.service_info.helpers import build_bento_service_type
from . import __version__


__all__ = [
"BENTO_SERVICE_KIND",
"SERVICE_ORGANIZATION",
"SERVICE_ARTIFACT",
"SERVICE_TYPE",
"SERVICE_NAME",
]

BENTO_SERVICE_KIND = "aggregation"
SERVICE_ORGANIZATION = "ca.c3g.bento"
SERVICE_ARTIFACT = BENTO_SERVICE_KIND
SERVICE_TYPE = {
"group": "ca.c3g.bento",
"artifact": SERVICE_ARTIFACT,
"version": __version__,
}
SERVICE_NAME = "Bento Aggregation Service"
SERVICE_TYPE = build_bento_service_type(BENTO_SERVICE_KIND, __version__)
4 changes: 2 additions & 2 deletions dev.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
FROM ghcr.io/bento-platform/bento_base_image:python-debian-2024.02.01
FROM ghcr.io/bento-platform/bento_base_image:python-debian-2024.05.01

LABEL org.opencontainers.image.description="Local development image the Bento aggregation service."
LABEL devcontainer.metadata='[{ \
Expand All @@ -14,7 +14,7 @@ LABEL devcontainer.metadata='[{ \
# Run as root in the Dockerfile until we drop down to the service user in the entrypoint
USER root

RUN pip install --no-cache-dir "uvicorn[standard]==0.27.1"
RUN pip install --no-cache-dir "uvicorn[standard]==0.29.0"

WORKDIR /aggregation

Expand Down
Loading

0 comments on commit b78e9ce

Please sign in to comment.