shangxinli commented on code in PR #1012:
URL: https://github.com/apache/iceberg-cpp/pull/1012#discussion_r4328473800
##########
src/iceberg/table_metadata.cc:
##########
@@ -1006,6 +1006,9 @@ Status TableMetadataBuilder::Impl::RemoveSchemas(
return !schema_ids.contains(schema->schema_id());
}) |
std::ranges::to<std::vector<std::shared_ptr<Schema>>>();
+ for (const auto schema_id : schema_ids) {
+ schemas_by_id_.erase(schema_id);
Review Comment:
This departs from Java - TableMetadata.java 1169-1183 leaves schemasById
stale, so setCurrentSchema on a removed id still succeeds there. Looks right to
me, just worth noting in the description.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]