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

ASF GitHub Bot commented on TINKERPOP-2745:
-------------------------------------------

li-boxuan commented on code in PR #1659:
URL: https://github.com/apache/tinkerpop/pull/1659#discussion_r878761723


##########
gremlin-core/src/main/java/org/apache/tinkerpop/gremlin/process/computer/VertexProgram.java:
##########
@@ -48,6 +50,10 @@
 
     public static final String VERTEX_PROGRAM = "gremlin.vertexProgram";
 
+    default List<Pair<String, Class>> getVertexPropertyKeys() {

Review Comment:
   > It defines COMPONENT when i think it should be property
   
   You are right, I was wrong. I used the default property name in the test so 
didn't catch this bug.
   
   > Is there a reason you can't get this information from 
getVertexComputeKeys()
   
   Thanks, I totally forgot about it 😅 . That should mostly suffice the use 
case I described, except that I am not 100% sure why other vertex programs 
don't contain `HALTED_TRAVERSERS` and `ACTIVE_TRAVERSERS` in 
`vertexComputeKeys`. Anyways, this PR is not very useful now so I am closing 
it. Thank you @mikepersonick and @spmallette for your reviews!





> Add getter for vertex properties in vertex programs
> ---------------------------------------------------
>
>                 Key: TINKERPOP-2745
>                 URL: https://issues.apache.org/jira/browse/TINKERPOP-2745
>             Project: TinkerPop
>          Issue Type: Improvement
>            Reporter: Boxuan Li
>            Priority: Major
>
> Many if not all vertex programs will mutate vertex properties during the 
> computation process. For graphs that enforce a schema, this could lead to 
> failure. JanusGraph, for example, when used with FulgoraGraphComputer and 
> disabled automatic schema maker, will report error for vertex programs. See 
> [https://gitter.im/janusgraph/janusgraph?at=626c568910cfc315bc5781a0]
>  
> This ticket proposes a getter method for each vertex program, which would 
> return the vertex properties together with their data types needed in the 
> computation. The graph providers or users could then leverage this 
> information to create the corresponding schema.



--
This message was sent by Atlassian Jira
(v8.20.7#820007)

Reply via email to