Giter Club home page Giter Club logo

Comments (7)

jtroberts avatar jtroberts commented on July 29, 2024

It looks like you need to include an additional [LAYER]_SUBDAILY variable in the map file. Try the following map configuration:

LAYER
NAME "MYR4ODLOLLDY_global_10km_test"
TYPE RASTER
STATUS ON
VALIDATION
"default_MYR4ODLOLLDY_global_10km_test_TIME" "TTTTTTT"
"MYR4ODLOLLDY_global_10km_test_TIME" "^([0-9]|T){7}$"
"default_MYR4ODLOLLDY_global_10km_test_YEAR" "YYYY"
"MYR4ODLOLLDY_global_10km_test_YEAR" "^([0-9]|Y){4}$"
"default_MYR4ODLOLLDY_global_10km_test_SUBDAILY" "TTTTTT"
"MYR4ODLOLLDY_global_10km_test_SUBDAILY" "^([0-9]|T){6}$"
END
METADATA
"wms_title" "MYR4ODLOLLDY_global_10km_test"
"wms_extent" "-180 -90 180 90"
"wms_timeextent" "2014-10-04T12:00:00Z/2014-10-04T12:00:00Z/PT24H”
"wms_timedefault" "2014-10-04T12:00:00Z"
END
DATA "/data/local/batsc/Work/WebService/onearth_setup/data/EPSG4326/MYR4ODLOLLDY_global_10km_test//%MYR4ODLOLLDY_global_10km_test_YEAR%/MYR4ODLOLLDY%MYR4ODLOLLDY_global_10km_test_TIME%%MYR4ODLOLLDY_global_10km_test_SUBDAILY%_.mrf"
PROJECTION
"init=epsg:4326"
END
END

Are you creating the map files manually? If you use the oe_configure_layer.py tool and have a subdaily time period specified, then the map files should automatically be created with the correct configurations.

Best,
Joe

from onearth.

batsc avatar batsc commented on July 29, 2024

Thanks, yes I was trying manually but have now tried with the configure layer script, which generates the map file with the settings you've shown above. Unfortunately I'm still seeing the same error.

I also noticed in the endpoint configuration documentation that the TWMS endpoints must exist for time snapping to work for WMS, and I had not set these up. Now that I have I get a more appropriate error for the non-subdaily layer when specifying a date outside of the extent (i.e. WMS server error. Unable to access -- invalid TIME for LAYER). For the test subdaily layer, not specifying a TIME parameter in the URL successfully leads to a retrieved image. Specifying TIME=2014-10-04 leads to this same (invalid time) error, whereas TIME=2014-10-04T12%3A00%3A00Z gives Invalid TIME format, must be YYYY-MM-DD or YYYY-MM-DDThh:mm:ssZ.

The WMTS endpoint works perfectly, and I can specify TIME=2014-10-04T12%3A00%3A00Z in a GETTILE URL with success. However I need the WMS endpoint to work.

Out of curiousity is the 'with_python' necessary for the mapserver build? I couldn't get this to work because I'm doing a local build, and make tried to install the mapscript file in a location I did not have permission for. It built fine using with_python=0.

What else might I try to find some clues about what is going wrong?

from onearth.

jtroberts avatar jtroberts commented on July 29, 2024

Does your request work if you replace the URL encoded "%3A" with the actual ":" character? I think the problem is that one of the modules is not handling the URL encoded values correctly. I tested a request successfully using ":" - but when I tested using "%3A" I got the same error that you reported. I'll look into a software fix for that. There might also be a workaround using mod_rewrite or something like that.

I don't think with_python is necessary for the MapServer build, unless you want to use MapScript. If everything built fine then you should be okay.

from onearth.

batsc avatar batsc commented on July 29, 2024

Yes it does, great! However I would really benefit from the potential fix you mention because I'm using an OpenLayers client and it looks like this converts the ':' to %3A in TIME updates (which as I mention work fine for WMTS, but not as it seems WMS).

Many thanks for your help.

from onearth.

jtroberts avatar jtroberts commented on July 29, 2024

I'll leave this ticket open until we get the fix in. A lot of people use OpenLayers, so it would definitely be good to get it working right. Thanks for helping us discover this issue.

from onearth.

jtroberts avatar jtroberts commented on July 29, 2024

I just pushed a fix for the TIME problem with URL encoded characters. It is in the OE 1.3.1 release. You should be able to make the requests successfully using OpenLayers now.

from onearth.

batsc avatar batsc commented on July 29, 2024

Thanks very much, that works perfectly.

from onearth.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.