tkalkirill commented on code in PR #2441:
URL: https://github.com/apache/ignite-3/pull/2441#discussion_r1295389895


##########
modules/sql-engine/src/main/java/org/apache/ignite/internal/sql/engine/exec/ExecutableTableRegistryImpl.java:
##########
@@ -77,6 +83,22 @@ public void onSchemaUpdated() {
         tableCache.clear();
     }
 
+    private CompletableFuture<ExecutableTable> loadTable(String tableName, 
TableDescriptor tableDescriptor) {
+        return tableManager.tableAsyncInternal(tableName.toUpperCase())
+                .thenApply(table -> {
+                    InternalTable internalTable = table.internalTable();
+                    SchemaRegistry schemaRegistry = 
schemaManager.schemaRegistry(table.tableId());
+                    SchemaDescriptor schemaDescriptor = 
schemaRegistry.schema();
+                    TableRowConverter rowConverter = new 
TableRowConverterImpl(schemaRegistry, schemaDescriptor, tableDescriptor);
+                    ScannableTable scannableTable = new 
ScannableTableImpl(internalTable, rowConverter, tableDescriptor);
+
+                    UpdatableTableImpl updatableTable = new 
UpdatableTableImpl(table.tableId(), tableDescriptor, internalTable.partitions(),
+                            replicaService, clock, rowConverter, 
schemaDescriptor);
+
+                    return new ExecutableTableImpl(internalTable, 
scannableTable, updatableTable);

Review Comment:
   Let's create a ticket for this. (About the problem that @zstan described 
earlier.)



-- 
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