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

Compatible with more date formats #284

Closed
javeme opened this issue Dec 17, 2018 · 0 comments
Closed

Compatible with more date formats #284

javeme opened this issue Dec 17, 2018 · 0 comments
Labels
feature New feature
Milestone

Comments

@javeme
Copy link
Contributor

javeme commented Dec 17, 2018

Expected behavior 期望表现

The following formats are accepted for date type:
yyyy-MM-dd
yyyy-MM-dd HH:mm:ss
yyyy-MM-dd HH:mm:ss.SSS

Actual behavior 实际表现

{
"message": "Unparseable date: "2016-1-1", expect format: yyyy-MM-dd HH:mm:ss.SSS",
"Exception-Class": "java.lang.IllegalArgumentException",
"exceptions":[
"java.lang.IllegalArgumentException"
],
"stackTrace": "java.lang.IllegalArgumentException: Unparseable date: "2016-1-1", expect format: yyyy-MM-dd HH:mm:ss.SSS\n\tat com.google.common.base.Preconditions.checkArgument(Preconditions.java:146)\n\tat com.baidu.hugegraph.util.E.checkArgument(E.java:56)\n\tat com.baidu.hugegraph.type.define.DataType.valueToDate(DataType.java:138)\n\tat com.baidu.hugegraph.schema.PropertyKey.convSingleValue(PropertyKey.java:185)\n\tat com.baidu.hugegraph.schema.PropertyKey.convValue(PropertyKey.java:152)\n\tat com.baidu.hugegraph.traversal.optimize.TraversalUtil.validPredicateValue(TraversalUtil.java:562)\n\tat com.baidu.hugegraph.traversal.optimize.TraversalUtil.convPredicateValue(TraversalUtil.java:487)\n\tat com.baidu.hugegraph.traversal.optimize.TraversalUtil.convHasStep(TraversalUtil.java:473)\n\tat com.baidu.hugegraph.traversal.optimize.TraversalUtil.convAllHasSteps(TraversalUtil.java:466)\n\tat com.baidu.hugegraph.traversal.optimize.HugeVertexStepStrategy.apply(HugeVertexStepStrategy.java:49)\n\tat org.apache.tinkerpop.gremlin.process.traversal.util.DefaultTraversalStrategies.applyStrategies(DefaultTraversalStrategies.java:86)\n\tat org.apache.tinkerpop.gremlin.process.traversal.util.DefaultTraversal.applyStrategies(DefaultTraversal.java:119)\n\tat org.apache.tinkerpop.gremlin.process.traversal.util.DefaultTraversal.hasNext(DefaultTraversal.java:191)\n\tat org.apache.tinkerpop.gremlin.util.iterator.IteratorUtils.fill(IteratorUtils.java:62)\n\tat org.apache.tinkerpop.gremlin.util.iterator.IteratorUtils.list(IteratorUtils.java:85)\n\tat org.apache.tinkerpop.gremlin.util.iterator.IteratorUtils.asList(IteratorUtils.java:382)\n\tat org.apache.tinkerpop.gremlin.server.handler.HttpGremlinEndpointHandler.lambda$channelRead$1(HttpGremlinEndpointHandler.java:239)\n\tat org.apache.tinkerpop.gremlin.util.function.FunctionUtils.lambda$wrapFunction$0(FunctionUtils.java:36)\n\tat org.apache.tinkerpop.gremlin.groovy.engine.GremlinExecutor.lambda$eval$2(GremlinExecutor.java:320)\n\tat java.util.concurrent.FutureTask.run(FutureTask.java:266)\n\tat com.baidu.hugegraph.auth.HugeGraphAuthProxy$ContextTask.run(HugeGraphAuthProxy.java:282)\n\tat java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)\n\tat java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)\n\tat java.lang.Thread.run(Thread.java:745)\n"
}

Linary added a commit that referenced this issue Dec 18, 2018
Implement #284

Change-Id: Ie1b3c3496b4427e3141b34b71a5ebb518678a258
@Linary Linary added the feature New feature label Dec 19, 2018
Linary added a commit that referenced this issue Dec 21, 2018
Implement #284

Change-Id: Ie1b3c3496b4427e3141b34b71a5ebb518678a258
zhoney pushed a commit that referenced this issue Dec 21, 2018
Implement #284

Change-Id: Ie1b3c3496b4427e3141b34b71a5ebb518678a258
@Linary Linary closed this as completed Dec 26, 2018
@javeme javeme added this to the 0.9 milestone Apr 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature
Projects
None yet
Development

No branches or pull requests

2 participants