feat(scope): make Belgium and North Sea operational default
This commit is contained in:
@@ -134,8 +134,37 @@ class BathymetryProfileAcquisitionService:
|
||||
)
|
||||
|
||||
@staticmethod
|
||||
def list_sources() -> list[dict[str, Any]]:
|
||||
return [BathymetrySourceRead(**item).model_dump() for item in BathymetryProfileAcquisitionService._SOURCES]
|
||||
def list_sources(settings=None) -> list[dict[str, Any]]:
|
||||
from app.core.config import get_settings
|
||||
|
||||
resolved_settings = settings or get_settings()
|
||||
items: list[dict[str, Any]] = []
|
||||
for source in BathymetryProfileAcquisitionService._SOURCES:
|
||||
item = dict(source)
|
||||
if item["key"] == "mdk_bcp_bathymetry":
|
||||
mdk_configured = bool(
|
||||
resolved_settings.mdk_bathymetry_acquisition_enabled
|
||||
and (resolved_settings.mdk_bathymetry_coverage_id or "").strip()
|
||||
)
|
||||
item["acquisition_supported"] = True
|
||||
item["configured"] = mdk_configured
|
||||
if mdk_configured:
|
||||
item["integration_status"] = "operational"
|
||||
item["limitation_message"] = (
|
||||
"Begrensde WCS-acquisitie is expliciet ingeschakeld en draait alleen wanneer de "
|
||||
"live readiness-probe bereikbaar is en het geconfigureerde coverage-id door de "
|
||||
"capabilities wordt geadverteerd. Dieptes blijven LAT-gerefereerd; watervolume "
|
||||
"blijft zonder compatibel wateroppervlak niet ondersteund."
|
||||
)
|
||||
else:
|
||||
item["limitation_message"] = (
|
||||
"Begrensde WCS-acquisitie bestaat maar staat uit. Zet "
|
||||
"MDK_BATHYMETRY_ACQUISITION_ENABLED=true en configureer MDK_BATHYMETRY_COVERAGE_ID "
|
||||
"pas nadat de readiness-probe live 'reachable' rapporteert. Er wordt nooit "
|
||||
"onbeveiligd of ongevalideerd gedownload."
|
||||
)
|
||||
items.append(item)
|
||||
return [BathymetrySourceRead(**item).model_dump() for item in items]
|
||||
|
||||
@staticmethod
|
||||
def _validate_bbox(payload: BathymetryProfileAcquireRequest) -> tuple[float, float, float, float]:
|
||||
|
||||
Reference in New Issue
Block a user