Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description:
Changes from 3.2.5:
Added
ENABLE_DIRECT_RESPONSE
environment variable. When enabled (ENABLE_DIRECT_RESPONSE=true
), endpoints return Starlette Response objects directly, bypassing FastAPI's jsonable_encoder and Pydantic serialization for significantly improved performance on large search responses. Note: In this mode, all FastAPI dependencies (including authentication, custom status codes, and validation) are disabled for all routes. Default isfalse
for safety. A warning is logged at startup if enabled. See issue #347 and PR #359.ENABLE_DIRECT_RESPONSE
environment variable, covering both Elasticsearch and OpenSearch backends. Tests gracefully handle missing backends by attempting to import both configs and skipping if neither is available. #359Changed
fastapi-slim
withfastapi
dependency #351stac_fastapi.opensearch
tostac_fastapi_opensearch
stac_fastapi.elasticsearch
tostac_fastapi_elasticsearch
stac_fastapi.core
tostac_fastapi_core
docker-compose.yml
tocompose.yml
to align with Docker Compose V2 conventions #358version
field from all compose files #358STAC_FASTAPI_VERSION
environment variables to 4.0.0 in all compose files #362httpx.ASGITransport(app=...)
for FastAPI app testing (removes deprecation warning). #359put_template
to composableput_index_template
API indatabase_logic.py
. This resolves deprecation warnings and ensures compatibility with Elasticsearch 7.x and 8.x. #359ConfigDict
instead of class-basedConfig
for Pydantic v2 compatibility. This resolves deprecation warnings and prepares for Pydantic v3. #359@root_validator
validators to@model_validator
for Pydantic v2 compatibility. #359@app.on_event("startup")
to FastAPI's recommended lifespan context manager. This removes deprecation warnings and ensures compatibility with future FastAPI versions. #361get_bool_env
utility. This ensures robust and consistent handling of environment variables such asES_USE_SSL
,ES_HTTP_COMPRESS
, andES_VERIFY_CERTS
across both backends. #359Fixed
mk_actions
andfilter-links
methods #351PR Checklist:
pre-commit run --all-files
)make test
)