[
https://issues.apache.org/jira/browse/TINKERPOP-1474?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16164827#comment-16164827
]
stephen mallette commented on TINKERPOP-1474:
---------------------------------------------
> So the only way to gather properties will be explicitly through the traversal
> then
Yes - i think it is analogous to standard SQL practices where you typically
don't do {{select * from table}}. you only request the fields that you want -
same premise for gremlin and graphs. there were a number of discussions on this
in the dev list where consensus always seemed to settle on not trying to
implement property support across glvs so I figured this one didn't need to
stay open any longer.
> Just realized that the GraphSON specification will need to be updated once
> that happens.
again - not something that would happen any time soon. no one every sounded in
favor of doing a takeaway of from the java folks who are still getting
properties, so I don't know that GraphSON's spec needs to change. Also,
GraphSON is still a file storage format for a full graph so properties still
need to be serializable in that sense. there still are some odd sticking points
in my mind, like what constitutes a subgraph with respect to properties (not
that GLVs can work with those directly anyway, which seems like a major missing
piece of functionality in my mind). Anyway....all stuff for the future
> API Alignment Between Java Gremlin Graph Structure and GLVs
> -----------------------------------------------------------
>
> Key: TINKERPOP-1474
> URL: https://issues.apache.org/jira/browse/TINKERPOP-1474
> Project: TinkerPop
> Issue Type: Improvement
> Components: io
> Affects Versions: 3.2.2
> Reporter: Adam Holmberg
> Assignee: stephen mallette
>
> The current Java GraphSON implementation and that in the Python GLV leave
> some question about what *should* be returned from a simple traversal like
> `g.V()`.
> The java implementation presently assumes that properties could be present
> and returns a DetachedVertex:
> https://github.com/apache/tinkerpop/blob/master/gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/structure/io/graphson/GraphSONSerializersV2d0.java#L420-L433
> The python implementation assumes no such thing and returns something more
> reminiscent of a ReferenceVertex:
> https://github.com/apache/tinkerpop/blob/master/gremlin-python/src/main/jython/gremlin_python/structure/io/graphson.py#L238-L242
> Is the java version overreaching, and should not expect properties unless a
> step calls for them (e.g. ` g.V().valueMap()` or `g.V().values('name')`, or
> should the Python version be expanded?
> Is there something we can do to establish guidelines for this, and align
> these APIs?
--
This message was sent by Atlassian JIRA
(v6.4.14#64029)