Open amadfida opened 6 years ago
@jameskleeh can you provide your feedback or if you need more information?
Should be a matter of updating the https://github.com/grails/gorm-neo4j/blob/master/grails-datastore-gorm-neo4j/src/main/groovy/org/grails/datastore/gorm/neo4j/Neo4jMappingContext.java#L47 list to include the types and potentially adding converters
However some of the types added require Java 8 so this cannot go into 6.1.x and must wait until 7.x which will be Java 8 only
@amadfida It's possible we can support this through the grails-java8
plugin. I'll be looking into what is necessary to get it to work.
@amadfida I cannot reproduce your claim that all the dates are stored as long. I have the following types in my domain (per the neo4j docs):
LocalDate
OffsetTime
LocalTime
ZonedDateTime
LocalDateTime
Saving an instance produces:
"properties": {
"a": "2018-09-05",
"b": "10:22:27.837-04:00",
"c": "10:22:27.839",
"d": "2018-09-05T10:22:27.841-04:00[America/New_York]",
"e": "2018-09-05T10:22:27.843",
"version": {
"low": 0,
"high": 0
}
}
When I attempt to read the domain, those properties are null, however they look like they are stored correctly to me. Can you verify?
@amadfida Native support for those types was not added until driver version 1.6. Here are things we can do:
grails-java8
plugin to allow JSR310 dates to work in the current 6.1.x neo4j-gorm.I'm not sure we can do anything about the new spatial types in neo4j-gorm 6.1.x since I believe that requires driver support.
Let me know your thoughts
@jameskleeh we can target it for neo4j-gorm 6.2.0.
@amadfida I've updated 6.2.0.BUILD-SNAPSHOT to use the latest driver. Can you test to see if it is working as expected?
We would like to request some enhancements to neo4j-gorm to support new data types
More information can be found here : https://neo4j.com/docs/developer-manual/current/drivers/cypher-values/
Let me know if you have any questions.
Thanks