tkalkirill commented on code in PR #2143:
URL: https://github.com/apache/ignite-3/pull/2143#discussion_r1220957932
##########
modules/index/src/main/java/org/apache/ignite/internal/index/IndexManager.java:
##########
@@ -436,31 +436,39 @@ private CompletableFuture<?>
onIndexCreate(ConfigurationNotificationEvent<TableI
}
try {
- return createIndexLocally(evt.storageRevision(), tableId,
evt.newValue(), evt.newValue(TablesView.class));
+ TablesView tablesView = evt.newValue(TablesView.class);
+
+ TableView tableView = findTableView(tableId,
(NamedListView<TableView>) tablesView.tables());
+
+ org.apache.ignite.internal.catalog.descriptors.TableDescriptor
catalogTableDescriptor = toTableDescriptor(tableView);
+ org.apache.ignite.internal.catalog.descriptors.IndexDescriptor
catalogIndexDescriptor = toIndexDescriptor(indexConfig);
+
+ return createIndexLocally(evt.storageRevision(),
catalogTableDescriptor, catalogIndexDescriptor);
} finally {
busyLock.leaveBusy();
}
}
private CompletableFuture<?> createIndexLocally(
long causalityToken,
- int tableId,
- TableIndexView tableIndexView,
- TablesView tablesView
+ org.apache.ignite.internal.catalog.descriptors.TableDescriptor
catalogTableDescriptor,
Review Comment:
Just for clarity, for example, we have several index descriptors (storage,
event, catalog), so as not to get confused, I think the prefix is enough.
Also in the plans to get rid of the table configuration, so I think there
will be several table descriptors.
Do you want me to remove the **catalog*** prefix?
--
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]