Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,12 +11,14 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- An `itslive` module with functions to deduplicate already published pairs based on the STAC catalog.

### Changed
- - All environment variable configuration is now centralized in a new `config` module.
- All environment variable configuration is now centralized in a new `config` module.
- HyP3 deduplication of pairs will be skipped if the `JOBS_TABLE_NAME` environment variable is not provided.
- ITS_LIVE STAC deduplication of pairs will be skipped if the `STAC_ITEMS_ENDPOINT` environment variable is not provided
- `deduplicate_hyp3_pairs`, `submit_pairs_for_processing`, and other HyP3 specific functionality has been moved to the `hyp3` module from `main`.

### Fixed
- Monitoring lambda function now uses reserved concurrency to set a maximum number of concurrent executions so it doesn't overwhelm the STAC catalog instance.
- pystac-client is now configured with connection and read timeouts when searching the ITS_LIVE catalog so it does not hang indefinitely waiting for a response.
- Sentinel-1 burst or SLC image pairs are now deduplicated against already published ITS_LIVE pairs in the STAC catalog.See [#331](https://github.com/ASFHyP3/its-live-monitoring/issues/331) for more info.

### Removed
Expand Down
1 change: 1 addition & 0 deletions cloudformation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,7 @@ Resources:
Role: !GetAtt LambdaRole.Arn
MemorySize: 256
Timeout: 900
ReservedConcurrentExecutions: 10
Environment:
Variables:
HYP3_API: !Ref Hyp3Api
Expand Down
10 changes: 8 additions & 2 deletions its_live_monitoring/src/itslive.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@


ITS_LIVE_CATALOG_API = 'https://stac.itslive.cloud/'
ITS_LIVE_CATALOG = pystac_client.Client.open(ITS_LIVE_CATALOG_API)
ITS_LIVE_CATALOG = pystac_client.Client.open(ITS_LIVE_CATALOG_API, timeout=(5, 60))
ITS_LIVE_COLLECTION_NAME = 'itslive-granules'
ITS_LIVE_COLLECTION = ITS_LIVE_CATALOG.get_collection(ITS_LIVE_COLLECTION_NAME)

Expand Down Expand Up @@ -96,7 +96,13 @@ def pair_exists(reference: tuple[str], secondary: tuple[str], name: str) -> bool
results = ITS_LIVE_CATALOG.search(
collections=[ITS_LIVE_COLLECTION_NAME],
datetime=[ref_datetime, sec_datetime],
query=[f'scene_1_id={reference[0]}', f'scene_2_id={secondary[0]}'],
filter={
'op': 'and',
'args': [
{'op': '=', 'args': [{'property': 'scene_1_id'}, reference[0]]},
{'op': '=', 'args': [{'property': 'scene_2_id'}, secondary[0]]},
],
},
)
items = [item for page in results.pages() for item in page]

Expand Down
Loading