You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sdap.apache.org by rk...@apache.org on 2023/03/10 01:04:26 UTC
[incubator-sdap-nexus] branch master updated: SwaggerUI updates & Removal of DOMS terminology (#232)
This is an automated email from the ASF dual-hosted git repository.
rkk pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-sdap-nexus.git
The following commit(s) were added to refs/heads/master by this push:
new aaa1b34 SwaggerUI updates & Removal of DOMS terminology (#232)
aaa1b34 is described below
commit aaa1b3465729e93629d578f3ffca0f31c3918665
Author: Riley Kuttruff <72...@users.noreply.github.com>
AuthorDate: Thu Mar 9 17:04:19 2023 -0800
SwaggerUI updates & Removal of DOMS terminology (#232)
* Updated SwaggerUI to remove DOMS terminology
- Updated platform in match_spark to be multi select
- I think SDAP versioning is working with the /version endpoint so I’ll leave that in. I also updated it to report analysis and data access component versions
- NexusHandlers can now support multiple paths. I did this so that I can add /cdmsresults without breaking anything using /domsresults. Same with /domslist
- Removed /domsvalues endpoint from SwaggerUI
- Added note to /stats entry in SUI to note it is limited to satellite datasets
* Changelog
* Undid endpoint alias and just renamed them
* Changelog reference SDAP ticket
* Made platform list a component object and added it to cdmssubset
* Undid /version changes
* Undid NexusAppBuilder changes
---------
Co-authored-by: rileykk <ri...@jpl.nasa.gov>
---
CHANGELOG.md | 9 +
.../webservice/algorithms/doms/DatasetListQuery.py | 2 +-
.../webservice/algorithms/doms/ResultsRetrieval.py | 2 +-
analysis/webservice/apidocs/openapi.yml | 288 ++++-----------------
4 files changed, 65 insertions(+), 236 deletions(-)
diff --git a/CHANGELOG.md b/CHANGELOG.md
index ae01564..8fc40e1 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -8,6 +8,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
### Added
- Deletebyquery: Parameter to set the number of rows to fetch from Solr. Speeds up time to gather tiles to delete; especially when there is a lot of them.
### Changed
+- SDAP-443:
+ - Replacing DOMS terminology with CDMS terminology:
+ - Renaming endpoints:
+ - `/domsresults` -> `/cdmsresults`
+ - `/domslist` -> `/cdmslist`
+ - Removed `/domsvalues` from Swagger UI
+ - Swagger UI updates:
+ - `platforms` parameter in `/match_spark` is now a multi-select list.
+ - Added note to `/stats` endpoint to note it is limited to satellite datasets
### Deprecated
### Removed
### Fixed
diff --git a/analysis/webservice/algorithms/doms/DatasetListQuery.py b/analysis/webservice/algorithms/doms/DatasetListQuery.py
index 79a89bd..78ba6ab 100644
--- a/analysis/webservice/algorithms/doms/DatasetListQuery.py
+++ b/analysis/webservice/algorithms/doms/DatasetListQuery.py
@@ -29,7 +29,7 @@ from webservice.webmodel import cached
@nexus_handler
class DomsDatasetListQueryHandler(BaseDomsHandler.BaseDomsQueryCalcHandler):
name = "DOMS Dataset Listing"
- path = "/domslist"
+ path = "/cdmslist"
description = ""
params = {}
singleton = True
diff --git a/analysis/webservice/algorithms/doms/ResultsRetrieval.py b/analysis/webservice/algorithms/doms/ResultsRetrieval.py
index 566c718..4007054 100644
--- a/analysis/webservice/algorithms/doms/ResultsRetrieval.py
+++ b/analysis/webservice/algorithms/doms/ResultsRetrieval.py
@@ -24,7 +24,7 @@ from webservice.webmodel import NexusProcessingException
@nexus_handler
class DomsResultsRetrievalHandler(BaseDomsHandler.BaseDomsQueryCalcHandler):
name = "DOMS Resultset Retrieval"
- path = "/domsresults"
+ path = "/cdmsresults"
description = ""
params = {}
singleton = True
diff --git a/analysis/webservice/apidocs/openapi.yml b/analysis/webservice/apidocs/openapi.yml
index 5d90037..36982af 100644
--- a/analysis/webservice/apidocs/openapi.yml
+++ b/analysis/webservice/apidocs/openapi.yml
@@ -16,7 +16,7 @@
openapi: 3.0.3
info:
description: The next generation cloud-based science data service platform.
- version: 0.4.2
+ version: 1.0.0
title: Science Data Analytics Platform (SDAP)
license:
name: Apache 2.0
@@ -91,35 +91,7 @@ paths:
schema:
type: string
example: -45,15,-30,30
- - in: query
- name: platforms
- description: |
- Platforms to include for matchup consideration. Platform
- depends on which insitu dataset is selected. Use platform ID
- in the matchup query.
-
- <details>
- <summary>Expand to see a list of valid platforms IDs:</summary>
- | Platform ID | Platform Name | Web Link |
- | ----------- | --------------------------------------- | ---------------------------------------------------------- |
- | 3B | autonomous surface water vehicle | [Link](http://vocab.nerc.ac.uk/collection/L06/current/3B/) |
- | 6A | glider | [Link](http://vocab.nerc.ac.uk/collection/L06/current/6A/) |
- | 0 | unknown | [Link](http://vocab.nerc.ac.uk/collection/L06/current/0/) |
- | 16 | offshore structure | [Link](http://vocab.nerc.ac.uk/collection/L06/current/16/) |
- | 17 | coastal structure | [Link](http://vocab.nerc.ac.uk/collection/L06/current/17/) |
- | 23 | towed unmanned submersible | [Link](http://vocab.nerc.ac.uk/collection/L06/current/23/) |
- | 30 | ship | [Link](http://vocab.nerc.ac.uk/collection/L06/current/30/) |
- | 31 | research vessel | [Link](http://vocab.nerc.ac.uk/collection/L06/current/31/) |
- | 41 | moored surface buoy | [Link](http://vocab.nerc.ac.uk/collection/L06/current/41/) |
- | 42 | drifting surface float | [Link](http://vocab.nerc.ac.uk/collection/L06/current/42/) |
- | 46 | drifting subsurface profiling float | [Link](http://vocab.nerc.ac.uk/collection/L06/current/46/) |
- | 48 | mooring | [Link](http://vocab.nerc.ac.uk/collection/L06/current/48/) |
- </details>
-
- required: true
- schema:
- type: string
- example: 30
+ - $ref: '#/components/parameters/Platforms'
- in: query
name: depthMin
description: |
@@ -168,7 +140,7 @@ paths:
schema:
type: string
default: sea_surface_temperature
- example: sst
+ example: sea_surface_temperature
- in: query
name: matchOnce
description: |
@@ -454,14 +426,7 @@ paths:
schema:
type: integer
example: 5
- - in: query
- name: platforms
- description: |
- Platforms to include for subset consideration.
- required: false
- schema:
- type: string
- example: 3B,23
+ - $ref: '#/components/parameters/Platforms'
- in: query
name: output
description: |
@@ -492,90 +457,6 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /datainbounds:
- get:
- summary: Fetches point values for a given dataset and geographical area
- operationId: datainbounds
- tags:
- - Subsetting
- parameters:
- - in: query
- name: ds
- description: |
- The Dataset shortname to use in calculation
- required: true
- schema:
- type: string
- x-dspopulate:
- - satellite
- example: avhrr-l4-glob-v2-daily-ncei-ghrsst-sstblend-avhrr-oi-glob-v020-fv020
- - in: query
- name: startTime
- description: |
- Starting time in format YYYY-MM-DDTHH:mm:ssZ or seconds
- since epoch
- required: true
- schema:
- type: string
- format: date-time
- example: '2012-09-28T00:00:00Z'
- - in: query
- name: endTime
- description: |
- Ending time in format YYYY-MM-DDTHH:mm:ssZ or seconds
- since epoch
- required: true
- schema:
- type: string
- format: date-time
- example: '2012-09-28T00:01:00Z'
- - in: query
- name: b
- description: |
- Minimum (Western) Longitude, Minimum (Southern) Latitude,
- Maximum (Eastern) Longitude, Maximum (Northern) Latitude
- required: true
- schema:
- type: string
- example: -45,15,-30,30
- - in: query
- name: parameter
- description: |
- The parameter of interest. One of 'sst', 'sss', 'wind'
- required: true
- schema:
- type: string
- enum: ['sst', 'sss', 'wind']
- example: sst
- - in: query
- name: output
- description: |
- Output type. Only 'CSV' or 'JSON' is currently supported
- required: false
- schema:
- type: string
- default: 'JSON'
- enum: ['CSV', 'JSON']
- example: JSON
- responses:
- '200':
- description: Successful operation
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/MatchupResponse'
- '400':
- description: Bad request
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '500':
- description: Server error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
/version:
get:
summary: List the version of the API
@@ -596,7 +477,7 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /domslist:
+ /cdmslist:
get:
summary: Provides a list of available data sets
operationId: domslist
@@ -615,116 +496,7 @@ paths:
application/json:
schema:
$ref: '#/components/schemas/Error'
- /domsvalues:
- get:
- summary: |
- Fetches stats and data values for the selected in situ source
- and bounding box
- operationId: domsvalues
- tags:
- - Matchup
- parameters:
- - in: query
- name: source
- description: |
- The insitu shortname to find stats and data for
- required: true
- schema:
- type: string
- x-dspopulate:
- - insitu
- example: samos
- - in: query
- name: startTime
- description: |
- Starting time in format YYYY-MM-DDTHH:mm:ssZ or seconds
- since epoch
- required: true
- schema:
- type: string
- format: date-time
- example: '2013-10-21T00:00:00Z'
- - in: query
- name: endTime
- description: |
- Ending time in format YYYY-MM-DDTHH:mm:ssZ or seconds
- since epoch
- required: true
- schema:
- type: string
- format: date-time
- example: '2013-10-21T01:00:00Z'
- - in: query
- name: b
- description: |
- Minimum (Western) Longitude, Minimum (Southern) Latitude,
- Maximum (Eastern) Longitude, Maximum (Northern) Latitude
- required: true
- schema:
- type: string
- example: -30,15,-45,30
- - in: query
- name: tt
- description: |
- Tolerance in time (seconds) when comparing two measurements.
- required: true
- schema:
- type: integer
- example: 86400
- - in: query
- name: rt
- description: |
- Tolerance in radius (meters) when comparing two
- measurements.
- required: true
- schema:
- type: number
- example: 1000.0
- - in: query
- name: depthMin
- description: |
- Minimum depth of measurements. Must be less than depthMax.
- required: false
- schema:
- type: integer
- example: 0
- - in: query
- name: depthMax
- description: |
- Maximum depth of measurements. Must be greater than
- depthMin.
- required: false
- schema:
- type: integer
- example: 5
- - in: query
- name: platforms
- description: |
- Platforms to include for subset consideration.
- required: false
- schema:
- type: string
- example: 1,2,3,4,5,6,7,8,9
- responses:
- '200':
- description: Successful operation
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/DomsValues'
- '400':
- description: Bad request
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- '500':
- description: Server error
- content:
- application/json:
- schema:
- $ref: '#/components/schemas/Error'
- /domsresults:
+ /cdmsresults:
get:
summary: |
Convert matchup result
@@ -780,6 +552,7 @@ paths:
operationId: stats
tags:
- Analytics
+ description: "NOTE: Only supports satellite datasets."
parameters:
- in: query
name: ds
@@ -877,6 +650,53 @@ externalDocs:
description: Documentation
url: https://incubator-sdap-nexus.readthedocs.io/en/latest/index.html
components:
+ parameters:
+ Platforms:
+ in: query
+ name: platforms
+ description: |
+ Platforms to include for matchup consideration. Platform
+ depends on which insitu dataset is selected. Use platform ID
+ in the matchup query.
+
+ <details>
+ <summary>Expand to see a list of valid platforms IDs:</summary>
+ | Platform ID | Platform Name | Web Link |
+ | ----------- | --------------------------------------- | ---------------------------------------------------------- |
+ | 3B | autonomous surface water vehicle | [Link](http://vocab.nerc.ac.uk/collection/L06/current/3B/) |
+ | 6A | glider | [Link](http://vocab.nerc.ac.uk/collection/L06/current/6A/) |
+ | 0 | unknown | [Link](http://vocab.nerc.ac.uk/collection/L06/current/0/) |
+ | 16 | offshore structure | [Link](http://vocab.nerc.ac.uk/collection/L06/current/16/) |
+ | 17 | coastal structure | [Link](http://vocab.nerc.ac.uk/collection/L06/current/17/) |
+ | 23 | towed unmanned submersible | [Link](http://vocab.nerc.ac.uk/collection/L06/current/23/) |
+ | 30 | ship | [Link](http://vocab.nerc.ac.uk/collection/L06/current/30/) |
+ | 31 | research vessel | [Link](http://vocab.nerc.ac.uk/collection/L06/current/31/) |
+ | 41 | moored surface buoy | [Link](http://vocab.nerc.ac.uk/collection/L06/current/41/) |
+ | 42 | drifting surface float | [Link](http://vocab.nerc.ac.uk/collection/L06/current/42/) |
+ | 46 | drifting subsurface profiling float | [Link](http://vocab.nerc.ac.uk/collection/L06/current/46/) |
+ | 48 | mooring | [Link](http://vocab.nerc.ac.uk/collection/L06/current/48/) |
+ </details>
+
+ required: true
+ schema:
+ type: array
+ items:
+ type: string
+ enum:
+ - 0
+ - 3B
+ - 6A
+ - 16
+ - 17
+ - 23
+ - 30
+ - 31
+ - 41
+ - 42
+ - 46
+ - 48
+ example: 30
+ explode: false
schemas:
DomsQueryResult:
type: object