Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Initial vector data support #30

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Dukestep
Copy link
Contributor

@Dukestep Dukestep commented Jul 26, 2022

This MR adds initial vector data support, enabling the generation and serving of vector data via the use of MapServer's OGR vector layers support.

Layers with underlying vector data can now be defined in the configuration as such:

RADAR_COVERAGE_RRAI:
    type: polygon
    temporal_config: /path/to/radar_coverage_mmhr_merged_realtime.json
    connection:
        type: OGR
        url: ES:localhost:9200
        data: radar_coverage-mmhr-merged-realtime
        options:
            layer: radar_coverage-mmhr-merged-realtime
    filters:
        - type: datetime
          field: properties.datetime_mapserver
    [...]

The connection key is used to setup the appropriate CONNECTION, CONNECTIONTYPE, CONNECTIONOPTIONS and DATA directives.

Rudimentary filters can be defined as an array of objects under the filter key. If multiple filters are defined, they are concatenated using the operators provided via the operator key in filters subsequent to the first filter defined. If a filter of type datetime is specified, a metadata key is set in order to retrieve the filter and format it accordingly when a request is received, either with the default time value or via the TIME query param value contained in the request.

If the temporal_config key is defined, the temporal metadata is retrieved from a file instead of retrieving it from geomet-data-registry's store.

The wsgi.py application is modified to intercept any MapServer layer objects of type point, line, polygon. If they are time-enabled, the application then verifies that the time is valid given the start/end/interval , and sets the PROCESSING "NATIVE_FILTER=<filter> directive. The rest of the request and response is managed by MapServer.

@Dukestep Dukestep force-pushed the implement-vector-data branch 2 times, most recently from 7eb9459 to 80256a0 Compare July 28, 2022 13:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants