Skip to content

Commit 37bc3e6

Browse files
authored
Merge branch 'main' into es-os-fresh
2 parents 0d68298 + 7405916 commit 37bc3e6

File tree

13 files changed

+33
-21
lines changed

13 files changed

+33
-21
lines changed

CHANGELOG.md

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,34 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
99

1010
### Added
1111

12+
- Introduced the `DATABASE_REFRESH` environment variable to control whether database operations refresh the index immediately after changes. If set to `true`, changes will be immediately searchable. If set to `false`, changes may not be immediately visible but can improve performance for bulk operations. If set to `wait_for`, changes will wait for the next refresh cycle to become visible. [#370](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/370)
13+
14+
### Changed
15+
16+
- Refactored CRUD methods in `TransactionsClient` to use the `_resolve_refresh` helper method for consistent and reusable handling of the `refresh` parameter. [#370](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/370)
17+
18+
### Fixed
19+
20+
- Fixed an issue where some routes were not passing the `refresh` parameter from `kwargs` to the database logic, ensuring consistent behavior across all CRUD operations. [#370](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/370)
21+
22+
## [v4.1.0] - 2025-05-09
23+
24+
### Added
25+
1226
- Added logging to bulk insertion methods to provide detailed feedback on errors encountered during operations. [#364](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/364)
1327
- Introduced the `RAISE_ON_BULK_ERROR` environment variable to control whether bulk insertion methods raise exceptions on errors (`true`) or log warnings and continue processing (`false`). [#364](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/364)
1428
- Added code coverage reporting to the test suite using pytest-cov. [#87](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/issues/87)
15-
- Introduced the `DATABASE_REFRESH` environment variable to control whether database operations refresh the index immediately after changes. If set to `true`, changes will be immediately searchable. If set to `false`, changes may not be immediately visible but can improve performance for bulk operations. If set to `wait_for`, changes will wait for the next refresh cycle to become visible. [#370](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/370)
1629

1730
### Changed
1831

1932
- Updated dynamic mapping for items to map long values to double versus float. [#326](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/326)
2033
- Extended Datetime Search to search on start_datetime and end_datetime as well as datetime fields. [#182](https://github.com/stac-utils/stac-fastapi-elasticsearch/pull/182)
2134
- Changed item update operation to use Elasticsearch index API instead of delete and create for better efficiency and atomicity. [#75](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/issues/75)
2235
- Bulk insertion via `BulkTransactionsClient` now strictly validates all STAC Items using the Pydantic model before insertion. Any invalid item will immediately raise a `ValidationError`, ensuring consistent validation with single-item inserts and preventing invalid STAC Items from being stored. This validation is enforced regardless of the `RAISE_ON_BULK_ERROR` setting. [#368](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/368)
23-
- Refactored CRUD methods in `TransactionsClient` to use the `_resolve_refresh` helper method for consistent and reusable handling of the `refresh` parameter. [#370](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/370)
2436

2537
### Fixed
2638

2739
- Refactored `create_item` and `update_item` methods to share unified logic, ensuring consistent conflict detection, validation, and database operations. [#368](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/368)
28-
- Fixed an issue where some routes were not passing the `refresh` parameter from `kwargs` to the database logic, ensuring consistent behavior across all CRUD operations. [#370](https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/pull/370)
2940

3041
## [v4.0.0] - 2025-04-23
3142

@@ -362,7 +373,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
362373
- Use genexp in execute_search and get_all_collections to return results.
363374
- Added db_to_stac serializer to item_collection method in core.py.
364375

365-
[Unreleased]: https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/compare/v4.0.0...main
376+
[Unreleased]: https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/compare/v4.1.0...main
377+
[v4.1.0]: https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/compare/v4.0.0...v4.1.0
366378
[v4.0.0]: https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/compare/v3.2.5...v4.0.0
367379
[v3.2.5]: https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/compare/v3.2.4...v3.2.5
368380
[v3.2.4]: https://github.com/stac-utils/stac-fastapi-elasticsearch-opensearch/compare/v3.2.3...v3.2.4

compose.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ services:
99
environment:
1010
- STAC_FASTAPI_TITLE=stac-fastapi-elasticsearch
1111
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Elasticsearch backend
12-
- STAC_FASTAPI_VERSION=4.0.0
12+
- STAC_FASTAPI_VERSION=4.1.0
1313
- APP_HOST=0.0.0.0
1414
- APP_PORT=8080
1515
- RELOAD=true
@@ -41,7 +41,7 @@ services:
4141
environment:
4242
- STAC_FASTAPI_TITLE=stac-fastapi-opensearch
4343
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Opensearch backend
44-
- STAC_FASTAPI_VERSION=4.0.0
44+
- STAC_FASTAPI_VERSION=4.1.0
4545
- APP_HOST=0.0.0.0
4646
- APP_PORT=8082
4747
- RELOAD=true

examples/auth/compose.basic_auth.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ services:
99
environment:
1010
- STAC_FASTAPI_TITLE=stac-fastapi-elasticsearch
1111
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Elasticsearch backend
12-
- STAC_FASTAPI_VERSION=4.0.0
12+
- STAC_FASTAPI_VERSION=4.1.0
1313
- APP_HOST=0.0.0.0
1414
- APP_PORT=8080
1515
- RELOAD=true
@@ -42,7 +42,7 @@ services:
4242
environment:
4343
- STAC_FASTAPI_TITLE=stac-fastapi-opensearch
4444
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Opensearch backend
45-
- STAC_FASTAPI_VERSION=4.0.0
45+
- STAC_FASTAPI_VERSION=4.1.0
4646
- APP_HOST=0.0.0.0
4747
- APP_PORT=8082
4848
- RELOAD=true

examples/auth/compose.oauth2.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ services:
99
environment:
1010
- STAC_FASTAPI_TITLE=stac-fastapi-elasticsearch
1111
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Elasticsearch backend
12-
- STAC_FASTAPI_VERSION=4.0.0
12+
- STAC_FASTAPI_VERSION=4.1.0
1313
- APP_HOST=0.0.0.0
1414
- APP_PORT=8080
1515
- RELOAD=true
@@ -43,7 +43,7 @@ services:
4343
environment:
4444
- STAC_FASTAPI_TITLE=stac-fastapi-opensearch
4545
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Opensearch backend
46-
- STAC_FASTAPI_VERSION=4.0.0
46+
- STAC_FASTAPI_VERSION=4.1.0
4747
- APP_HOST=0.0.0.0
4848
- APP_PORT=8082
4949
- RELOAD=true

examples/auth/compose.route_dependencies.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ services:
99
environment:
1010
- STAC_FASTAPI_TITLE=stac-fastapi-elasticsearch
1111
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Elasticsearch backend
12-
- STAC_FASTAPI_VERSION=4.0.0
12+
- STAC_FASTAPI_VERSION=4.1.0
1313
- APP_HOST=0.0.0.0
1414
- APP_PORT=8080
1515
- RELOAD=true
@@ -42,7 +42,7 @@ services:
4242
environment:
4343
- STAC_FASTAPI_TITLE=stac-fastapi-opensearch
4444
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Opensearch backend
45-
- STAC_FASTAPI_VERSION=4.0.0
45+
- STAC_FASTAPI_VERSION=4.1.0
4646
- APP_HOST=0.0.0.0
4747
- APP_PORT=8082
4848
- RELOAD=true

examples/rate_limit/compose.rate_limit.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ services:
99
environment:
1010
- STAC_FASTAPI_TITLE=stac-fastapi-elasticsearch
1111
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Elasticsearch backend
12-
- STAC_FASTAPI_VERSION=4.0.0
12+
- STAC_FASTAPI_VERSION=4.1.0
1313
- APP_HOST=0.0.0.0
1414
- APP_PORT=8080
1515
- RELOAD=true
@@ -42,7 +42,7 @@ services:
4242
environment:
4343
- STAC_FASTAPI_TITLE=stac-fastapi-opensearch
4444
- STAC_FASTAPI_DESCRIPTION=A STAC FastAPI with an Opensearch backend
45-
- STAC_FASTAPI_VERSION=4.0.0
45+
- STAC_FASTAPI_VERSION=4.1.0
4646
- APP_HOST=0.0.0.0
4747
- APP_PORT=8082
4848
- RELOAD=true
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
"""library version."""
2-
__version__ = "4.0.0"
2+
__version__ = "4.1.0"

stac_fastapi/elasticsearch/setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
desc = f.read()
77

88
install_requires = [
9-
"stac-fastapi-core==4.0.0",
9+
"stac-fastapi-core==4.1.0",
1010
"elasticsearch[async]~=8.18.0",
1111
"uvicorn~=0.23.0",
1212
"starlette>=0.35.0,<0.36.0",

stac_fastapi/elasticsearch/stac_fastapi/elasticsearch/app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@
9090
api = StacApi(
9191
title=os.getenv("STAC_FASTAPI_TITLE", "stac-fastapi-elasticsearch"),
9292
description=os.getenv("STAC_FASTAPI_DESCRIPTION", "stac-fastapi-elasticsearch"),
93-
api_version=os.getenv("STAC_FASTAPI_VERSION", "4.0.0"),
93+
api_version=os.getenv("STAC_FASTAPI_VERSION", "4.1.0"),
9494
settings=settings,
9595
extensions=extensions,
9696
client=CoreClient(
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
"""library version."""
2-
__version__ = "4.0.0"
2+
__version__ = "4.1.0"

stac_fastapi/opensearch/setup.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
desc = f.read()
77

88
install_requires = [
9-
"stac-fastapi-core==4.0.0",
9+
"stac-fastapi-core==4.1.0",
1010
"opensearch-py~=2.8.0",
1111
"opensearch-py[async]~=2.8.0",
1212
"uvicorn~=0.23.0",

stac_fastapi/opensearch/stac_fastapi/opensearch/app.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@
9090
api = StacApi(
9191
title=os.getenv("STAC_FASTAPI_TITLE", "stac-fastapi-opensearch"),
9292
description=os.getenv("STAC_FASTAPI_DESCRIPTION", "stac-fastapi-opensearch"),
93-
api_version=os.getenv("STAC_FASTAPI_VERSION", "4.0.0"),
93+
api_version=os.getenv("STAC_FASTAPI_VERSION", "4.1.0"),
9494
settings=settings,
9595
extensions=extensions,
9696
client=CoreClient(
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
"""library version."""
2-
__version__ = "4.0.0"
2+
__version__ = "4.1.0"

0 commit comments

Comments
 (0)