You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "stevenzwu (via GitHub)" <gi...@apache.org> on 2023/06/23 16:41:23 UTC

[GitHub] [iceberg] stevenzwu commented on a diff in pull request #7866: Flink: fix TableSink anonymous object

stevenzwu commented on code in PR #7866:
URL: https://github.com/apache/iceberg/pull/7866#discussion_r1240028825


##########
flink/v1.15/flink/src/main/java/org/apache/iceberg/flink/FlinkDynamicTableFactory.java:
##########
@@ -105,18 +105,21 @@ public DynamicTableSource createDynamicTableSource(Context context) {
 
   @Override
   public DynamicTableSink createDynamicTableSink(Context context) {
-    ObjectPath objectPath = context.getObjectIdentifier().toObjectPath();
+    ObjectIdentifier objectIdentifier = context.getObjectIdentifier();

Review Comment:
   what is the anonymous class issue? which class is anonymous? do you have the full stack trace?
   
   `toObjectPath` seems fine to me.
   ```
       public ObjectPath toObjectPath() throws TableException {
           if (catalogName == null) {
               throw new TableException(
                       "This ObjectIdentifier instance refers to an anonymous object, "
                               + "hence it cannot be converted to ObjectPath and cannot be serialized.");
           }
           return new ObjectPath(databaseName, objectName);
       }
   ```



-- 
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: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org