FANNG1 commented on code in PR #7397:
URL: https://github.com/apache/gravitino/pull/7397#discussion_r2152110741


##########
lineage/src/main/java/org/apache/gravitino/lineage/Utils.java:
##########
@@ -35,4 +38,58 @@ public static String getJobName(RunEvent event) {
     Job job = event.getJob();
     return job == null ? "Unknown" : job.getName().toString();
   }
+
+  public static OpenLineage.RunEvent mapLineageServertoClientRunEvent(

Review Comment:
   the one challenge to convert server runEvent to client runEvent is the 
facets is not one-to-one mapping. Another solution may leverage the existing 
ser&de method for the run event.
   ```
   import io.openlineage.server.OpenLineage.RunEvent;
   
     public static OpenLineage.RunEvent getClientRunEvent(RunEvent event)
         throws JsonProcessingException {
       String value = 
ObjectMapperProvider.objectMapper().writeValueAsString(event);
       return ObjectMapperProvider.objectMapper().readValue(value, 
OpenLineage.RunEvent.class);
     }
   ```



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to