[ 
https://issues.apache.org/jira/browse/TINKERPOP-1345?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15339489#comment-15339489
 ] 

Marko A. Rodriguez commented on TINKERPOP-1345:
-----------------------------------------------

So, I assume you are having this issue with respects to 
DSEGraph/SparkGraphComputer so I'll provide 2 solutions specific to your 
situation.

1. Have your "complex id" object not implement {{Collection}} even if it is a 
"complex id."

2. Like for OLTP, write your own {{GraphStep}} that is added via a 
{{TraversalStrategy}}. {{DseSparkGraphStep}} which will NOT unroll collections.

For TinkerPop, I suppose we could be more specific than {{Collection}} -- 
{{Set}} or {{List}} perhaps? Or do {{DSEGraph}} ids implement one of those? 
Note that this would be a major breaking change for TinkerPop so a solution on 
our side would require a major release and {{dev@}} by in.

> Unrolling of collection for ids
> -------------------------------
>
>                 Key: TINKERPOP-1345
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-1345
>             Project: TinkerPop
>          Issue Type: Bug
>            Reporter: Matthias Broecheler
>
> In GraphStep, TinkerPop does this:
> {code}
> this.ids = (ids.length == 1 && ids[0] instanceof Collection) ? ((Collection) 
> ids[0]).toArray(new Object[((Collection) ids[0]).size()]) : ids;
> {code}
> which means that collections are automatically unrolled when there is only 
> one element. This breaks TP implementations that use collections to represent 
> ids, for instance, because their id representation has multiple components 
> (like a primary key in an RDMBS).  



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to