tkalkirill commented on code in PR #3917:
URL: https://github.com/apache/ignite-3/pull/3917#discussion_r1639339794
##########
modules/table/src/main/java/org/apache/ignite/internal/table/distributed/index/IndexMeta.java:
##########
@@ -42,43 +44,60 @@ public class IndexMeta implements Serializable {
@IgniteToStringInclude
private final Map<MetaIndexStatus, MetaIndexStatusChange> statusChanges;
- /** Constructor. */
- IndexMeta(CatalogIndexDescriptor catalogIndexDescriptor, Catalog catalog) {
- this(
- catalogIndexDescriptor.id(),
- catalogIndexDescriptor.tableId(),
- catalogIndexDescriptor.name(),
- MetaIndexStatus.convert(catalogIndexDescriptor.status()),
- Map.of(
-
MetaIndexStatus.convert(catalogIndexDescriptor.status()),
- new MetaIndexStatusChange(catalog.version(),
catalog.time())
- )
- );
- }
-
/**
* Constructor.
*
+ * @param catalogVersion Catalog version in which the current meta was
created.
* @param indexId Index ID.
* @param tableId Table ID to which the index belongs.
* @param indexName Index name.
* @param currentStatus Current status of the index
* @param statusChanges <b>Immutable</b> map of index statuses with change
info (for example catalog version) in which they appeared.
*/
private IndexMeta(
+ int catalogVersion,
int indexId,
int tableId,
String indexName,
MetaIndexStatus currentStatus,
Map<MetaIndexStatus, MetaIndexStatusChange> statusChanges
) {
+ this.catalogVersion = catalogVersion;
this.indexId = indexId;
this.tableId = tableId;
this.indexName = indexName;
this.currentStatus = currentStatus;
this.statusChanges = unmodifiableMap(statusChanges);
}
+ /**
+ * Creates a index meta instance.
+ *
+ * @param catalogIndexDescriptor Catalog index descriptor based on which
the meta will be created.
Review Comment:
fix it
--
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]