Giter Site home page Giter Site logo

Comments (8)

sjudeng avatar sjudeng commented on June 15, 2024

I haven't tried enabling the Time dimension in GeoServer for Elasticsearch layers. I'll try to take a look. Datetime fields themselves should be supported. The format used is taken from the Elasticsearch mapping, if defined, or dateOptionalTime otherwise. In the meantime I'd welcome a pull request if you find the issue first. Take a look at the DescribeFeatureType output for the layer and confirm the field type is Date.

IP:PORT/geoserver/ows?service=wfs&version=1.0.0&request=DescribeFeatureType&typeName=your_workspace:your_layer_name

If you have access to the server you can also turn logging up and see the request being sent to the server that's causing the error. Add the below line to your logging file (e.g. data/DEFAULT_LOGGING.properties, etc.).

log4j.category.mil.nga.giat.data.elasticsearch=DEBUG

You can confirm the logging file being used through GeoServer global settings.

GeoServer global settings

from elasticgeo.

rastafford avatar rastafford commented on June 15, 2024

I have been looking into this same issue, and what I have found is that the ISO 8601 DateTime format that GeoServer sends seems to be causing an issue. I get an ElasticsearchParseException of Invalid format: "2008-12-21T00:00:00.000Z" is malformed at "Z". Is there a specific date format that ElasticGeo is expecting? Or is it possible that I can add a parser to the ElasticGeo source code to handle this situation?

Any advice/help is greatly appreciated! Thank you

from elasticgeo.

sjudeng avatar sjudeng commented on June 15, 2024

It wasn't using the custom date format when building these filters. The previous commit should fix this. Thanks for reporting the issue.

from elasticgeo.

rastafford avatar rastafford commented on June 15, 2024

I was able to get the new build (thank you) and I am no longer getting those errors. However, when I enable the time dimension, I still don't get any data. If I have it disabled, the data comes back fine. I am using the date_hour_minute_second_millis format for my dates in elasticsearch. Could this still be the problem?

from elasticgeo.

sjudeng avatar sjudeng commented on June 15, 2024

Are you querying for exact values or a time range? Could it be a timezone issue? Try a time range that covers your data, e.g 'TIME=2015-01/2016-01'. If that doesn't help and you have access to the server, try enabling logging as described above to see the requests being sent to Elasticsearch.

from elasticgeo.

rastafford avatar rastafford commented on June 15, 2024

I am doing both. Actually, initially, I am not using any time at all. I am just clicking the OpenLayers option under Layers Preview, and I was hoping with no time it would just return everything (I am guessing that is probably a wrong assumption?)

I will check what it is sending to ElasticSearch. Like I said, I turned on all of the GeoServer logging and nothing is coming back weird. I will let you know.

Thank you again for your help and your quick response.

from elasticgeo.

sjudeng avatar sjudeng commented on June 15, 2024

Make sure to add "log4j.category.mil.nga.giat.data.elasticsearch=DEBUG" to the relevant logging.properties file.

from elasticgeo.

rastafford avatar rastafford commented on June 15, 2024

Yep, I got that. And you called it with the time formatting. I had to remove the PT1H at the end of the WMS time (not sure why that would make it return nothing), and the data I was looking at in the preview window was converting the time from zulu to EST. So with all of that squared away, I am well on my way. Thank you again for all of your help!

from elasticgeo.

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.