[MapServer-users] wms time validation of time parameter against timeextent gives unexpected results

Marcel.Clausen at swisstopo.ch Marcel.Clausen at swisstopo.ch
Thu Feb 2 01:27:44 PST 2023


Dear all

We have the following question concerning the configuration and usage of time enabled wms layers.

We are using the following metadata section for a time-enabled layer:

    METADATA
        "wms_enable_request" "*"
        "wms_title" "lubis_bildstreifen"
        "wms_extent" "2100000 1050000 2850000 1400000"
        "wms_timeextent" "2005/2022"
        "wms_timeitem" "flugdatum" # this is a date column in postgres
    END


The time precision/resolution of the timeextent has to be set as year.

The validation of the time parameter against the time extent with year precision gives some strange results. We were using the following getmap request for the tests:  

localhost:7777/local/?SERVICE=WMS&VERSION=1.3.0&REQUEST=GetMap&FORMAT=image/png&TRANSPARENT=true&LAYERS=ch.swisstopo.lubis-bildstreifen&CRS=EPSG:2056&STYLES=&WIDTH=860&HEIGHT=600&BBOX=2420000,1050000,2850000,1350000&TIME=2022

parameter:		time=2005
result: 			returns all features of 2005
expected result:	ok

parameter:		time=2022
result: 			returns all features of 2022
expected result:	ok

parameter:		time=2023
result: 			returns ServiceException [1]
expected result:	ok

parameter:		time=2022-01-01
result: 			returns ServiceException [2]
expected result:	we would expect this to be a valid timestamp

parameter:		time=2022-01-01/2022-12-31
result: 			returns ServiceException [3]
expected result:	we would expect this to be a valid timestamp

It seems that if the precision of the time parameter is of YYYY-MM or YYYY-MM-TT the upper bound of the defined timextent 2005/2022 is not respected correctly.
We got the same result with the timextent defined  as: 2005/2022/P1Y

our mapserver version is:
<!--  MapServer version 7.6.4 OUTPUT=PNG OUTPUT=JPEG OUTPUT=KML SUPPORTS=PROJ SUPPORTS=AGG SUPPORTS=FREETYPE SUPPORTS=CAIRO SUPPORTS=SVG_SYMBOLS SUPPORTS=RSVG SUPPORTS=ICONV SUPPORTS=FRIBIDI SUPPORTS=WMS_SERVER SUPPORTS=WMS_CLIENT SUPPORTS=WFS_SERVER SUPPORTS=WFS_CLIENT SUPPORTS=WCS_SERVER SUPPORTS=SOS_SERVER SUPPORTS=FASTCGI SUPPORTS=GEOS SUPPORTS=POINT_Z_M SUPPORTS=PBF INPUT=JPEG INPUT=POSTGIS INPUT=OGR INPUT=GDAL INPUT=SHAPEFILE  -->

Does someone have some insights or hints?

Best regards 
Clausen Marcel

[1]
<ServiceException code="InvalidDimensionValue">msWMSApplyTime: WMS server error. Time value(s) 2023 given is invalid or outside the time extent defined (2005/2022).</ServiceException>

[2]
<ServiceException code="InvalidDimensionValue"> msWMSApplyTime: WMS server error. Time value(s) 2022-01-01 given is invalid or outside the time extent defined (2005/2022). </ServiceException>

[3]
<ServiceException code="InvalidDimensionValue"> msWMSApplyTime: WMS server error. Time value(s) 2022-01-01/2022-12-31 given is invalid or outside the time extent defined (2005/2022). </ServiceException>








      


More information about the MapServer-users mailing list