This issue describes the current approach, features, and APIs for searching metadata and downloading data and aims to:
help identify if the current structure should be refined for the next planned features
document the current code structure.
Related issues
Current structure and design
The diagram describes the relationships between the types and concepts that are currently implemented.
graph TB
subgraph CLI
subgraph CombinedParamsArgs
SearchParamsArgs:::type
DownloadParamsArgs:::type
end
Recipe:::concept
end
subgraph DataRequest API
DataRequestSpec:::type
GeometrySpec["GeometrySpec"]:::type
MetricSpecs:::type
Years:::type
end
subgraph Combined API
Params:::type
RegionSpecs:::type
end
subgraph SearchAPI["Search API"]
SearchParams:::type
end
subgraph DownloadAPI
DownloadParams:::type
Config:::type
SearchResults:::type
end
Recipe -- Deserializes to --> DataRequestSpec
DataRequestSpec -- 'TryFrom' --> Params
DataRequestSpec --- GeometrySpec
DataRequestSpec --- RegionSpecs
DataRequestSpec --- MetricSpecs
DataRequestSpec --- Years
Params --- SearchParams
Params --- DownloadParams
subgraph Outputs
Metrics:::concept
Geometries:::concept
end
SearchParamsArgs -- 'From' --> SearchParams
CombinedParamsArgs -- 'From' --> DownloadParams
SearchParams -- '.search()' --> SearchResults
DownloadAPI -- '.download()' --> Outputs
subgraph Key["Key"]
Concept:::concept
Type:::type
end
classDef api fill:#cbd5e8,stroke:#333,stroke-width:2px
classDef type fill:##cbd5e8,stroke:#333,stroke-width:2px
classDef field fill:#fdcdac,stroke:#333,stroke-width:2px
classDef concept fill:#f4cae4,stroke:#333,stroke-width:2px
classDef methods fill:#e6f5c9,stroke:#333,stroke-width:2px
Loading
Search API SearchParams
Design goal: aiming to enable flexible, composable and expressive searching of the metadata structure
Current features implemented/planned for search:
Download API (DataRequestSpec / SearchParams and DownloadParams)
Design goal: to enable the download of data products in various customizable output structures and formats that various users may require
Current features implemented/planned for download:
User stories
Some example user stories with use cases to help motivate modifications to the design.
15m neighbourhood tool
See PR10
Other enhancements
This issue describes the current approach, features, and APIs for searching metadata and downloading data and aims to:
Related issues
dataandmetricscommands #57Current structure and design
The diagram describes the relationships between the types and concepts that are currently implemented.
graph TB subgraph CLI subgraph CombinedParamsArgs SearchParamsArgs:::type DownloadParamsArgs:::type end Recipe:::concept end subgraph DataRequest API DataRequestSpec:::type GeometrySpec["GeometrySpec"]:::type MetricSpecs:::type Years:::type end subgraph Combined API Params:::type RegionSpecs:::type end subgraph SearchAPI["Search API"] SearchParams:::type end subgraph DownloadAPI DownloadParams:::type Config:::type SearchResults:::type end Recipe -- Deserializes to --> DataRequestSpec DataRequestSpec -- 'TryFrom' --> Params DataRequestSpec --- GeometrySpec DataRequestSpec --- RegionSpecs DataRequestSpec --- MetricSpecs DataRequestSpec --- Years Params --- SearchParams Params --- DownloadParams subgraph Outputs Metrics:::concept Geometries:::concept end SearchParamsArgs -- 'From' --> SearchParams CombinedParamsArgs -- 'From' --> DownloadParams SearchParams -- '.search()' --> SearchResults DownloadAPI -- '.download()' --> Outputs subgraph Key["Key"] Concept:::concept Type:::type end classDef api fill:#cbd5e8,stroke:#333,stroke-width:2px classDef type fill:##cbd5e8,stroke:#333,stroke-width:2px classDef field fill:#fdcdac,stroke:#333,stroke-width:2px classDef concept fill:#f4cae4,stroke:#333,stroke-width:2px classDef methods fill:#e6f5c9,stroke:#333,stroke-width:2pxSearch API
SearchParamsDesign goal: aiming to enable flexible, composable and expressive searching of the metadata structure
Current features implemented/planned for search:
Download API (
DataRequestSpec/SearchParamsandDownloadParams)Design goal: to enable the download of data products in various customizable output structures and formats that various users may require
Current features implemented/planned for download:
User stories
Some example user stories with use cases to help motivate modifications to the design.
15m neighbourhood tool
See PR10
Other enhancements
SearchParams)