seojangho commented on a change in pull request #114: [NEMO-203] Beam SQL 
Aggregation fails to match RowCoder in Combine transform
URL: https://github.com/apache/incubator-nemo/pull/114#discussion_r214563933
 
 

 ##########
 File path: 
compiler/frontend/beam/src/main/java/edu/snu/nemo/compiler/frontend/beam/PipelineTranslator.java
 ##########
 @@ -288,6 +305,51 @@ private static void loopTranslator(final 
TranslationContext ctx,
     Class<? extends PTransform>[] value();
   }
 
+  private static Coder<?> getCoder(final PValue input, final 
CompositeTransformVertex pipeline) {
+    final Coder<?> coder;
+    if (input instanceof PCollection) {
+      coder = ((PCollection) input).getCoder();
+    } else if (input instanceof PCollectionView) {
+      coder = getCoderForView((PCollectionView) input, pipeline);
+    } else {
+      coder = null;
 
 Review comment:
   Minor 'how about' comment: how about throwing an exception here?

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to