{"record":{"id":"73503a893ec2684c","repo":"apache/iceberg","slug":"the-iceberg-property-and-or-is-enabled-o","errorCode":null,"errorMessage":"The Iceberg property '{}' and/or '{}' is enabled on table '{}' in NessieCatalog. This will likely make data in other Nessie branches and tags and in earlier, historical Nessie commits inaccessible. The recommended setting for those properties is 'false'. Use the 'nessie-gc' tool for Nessie reference-aware garbage collection.","messagePattern":"The Iceberg property '(.+?)' and/or '(.+?)' is enabled on table '(.+?)' in NessieCatalog\\. This will likely make data in other Nessie branches and tags and in earlier, historical Nessie commits inaccessible\\. The recommended setting for those properties is 'false'\\. Use the 'nessie-gc' tool for Nessie reference-aware garbage collection\\.","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"nessie/src/main/java/org/apache/iceberg/nessie/NessieUtil.java","lineNumber":145,"sourceCode":"        NessieTableOperations.NESSIE_GC_NO_WARNING_PROPERTY, false)) {\n      return;\n    }\n\n    // To prevent accidental deletion of files that are still referenced by other branches/tags,\n    // setting GC_ENABLED to 'false' is recommended, so that all Iceberg's gc operations like\n    // expire_snapshots, remove_orphan_files, drop_table with purge will fail with an error.\n    // `nessie-gc` CLI provides a reference-aware GC functionality for the expired/unreferenced\n    // files.\n    // Advanced users may still want to use the simpler Iceberg GC tools iff their Nessie Server\n    // contains only one branch (in which case the full Nessie history will be reflected in the\n    // Iceberg sequence of snapshots).\n    if (tableMetadata.propertyAsBoolean(\n            TableProperties.GC_ENABLED, TableProperties.GC_ENABLED_DEFAULT)\n        || tableMetadata.propertyAsBoolean(\n            TableProperties.METADATA_DELETE_AFTER_COMMIT_ENABLED,\n            TableProperties.METADATA_DELETE_AFTER_COMMIT_ENABLED_DEFAULT)) {\n      updatedProperties.put(NessieTableOperations.NESSIE_GC_NO_WARNING_PROPERTY, \"true\");\n      LOG.warn(\n          \"The Iceberg property '{}' and/or '{}' is enabled on table '{}' in NessieCatalog.\"\n              + \" This will likely make data in other Nessie branches and tags and in earlier, historical Nessie\"\n              + \" commits inaccessible. The recommended setting for those properties is 'false'. Use the 'nessie-gc'\"\n              + \" tool for Nessie reference-aware garbage collection.\",\n          TableProperties.GC_ENABLED,\n          TableProperties.METADATA_DELETE_AFTER_COMMIT_ENABLED,\n          identifier);\n    }\n  }\n\n  public static TableMetadata updateTableMetadataWithNessieSpecificProperties(\n      TableMetadata tableMetadata,\n      String metadataLocation,\n      IcebergTable table,\n      String identifier,\n      Reference reference) {\n    // Update the TableMetadata with the Content of NessieTableState.\n    Map<String, String> newProperties = Maps.newHashMap(tableMetadata.properties());","sourceCodeStart":127,"sourceCodeEnd":163,"githubUrl":"https://github.com/apache/iceberg/blob/86d9c8fc543e7c56c9f624eb725f76c9baff9570/nessie/src/main/java/org/apache/iceberg/nessie/NessieUtil.java#L127-L163","documentation":"NessieUtil.checkAndUpdateGCProperties warns when write.delete.mode/GC-related Iceberg properties write.metadata.delete-after-commit.enabled or write.metadata.previous-versions-max style GC settings are enabled on a Nessie table. Because Nessie keeps historical references, deleting metadata/data files via Iceberg GC can make data in other branches, tags, or older commits inaccessible; Nessie recommends disabling these and using nessie-gc.","triggerScenarios":"Committing table metadata through NessieCatalog while write.delete.mode, garbage-collection, or metadata-delete-after-commit style properties (write.metadata.delete-after-commit.enabled / write.metadata.previous-versions-max equivalents) are enabled.","commonSituations":"Tables created against other catalogs then accessed via NessieCatalog with GC defaults enabled; routine expiry/deleteOrphanFiles jobs that delete metadata files; copying TableProperties from non-Nessie setups.","solutions":["Set the offending properties to false on the table (e.g. write.metadata.delete-after-commit.enabled=false) or set the nessie no-gc-warning marker property","Use the nessie-gc tool for reference-aware garbage collection instead of Iceberg's built-in expiry","Audit scheduled expireSnapshots/removeOrphanFiles jobs that operate on Nessie tables"],"exampleFix":"// before\nALTER TABLE catalog.db.t SET TBLPROPERTIES ('write.metadata.delete-after-commit.enabled'='true');\n// after\nALTER TABLE catalog.db.t SET TBLPROPERTIES ('write.metadata.delete-after-commit.enabled'='false');","handlingStrategy":"validation","validationCode":"boolean gcEnabled = table.propertyAsBoolean(TableProperties.GC_ENABLED, TableProperties.GC_ENABLED_DEFAULT);\nboolean delMeta = table.propertyAsBoolean(TableProperties.METADATA_DELETE_AFTER_COMMIT_ENABLED, TableProperties.METADATA_DELETE_AFTER_COMMIT_ENABLED_DEFAULT);\nif (gcEnabled || delMeta) { /* unset before writing via Nessie */ }","typeGuard":null,"tryCatchPattern":null,"preventionTips":["Never enable Iceberg GC properties on Nessie-managed tables","Schedule nessie-gc as the only garbage-collection mechanism","Audit table properties after migrating tables from other catalogs"],"tags":["nessie","garbage-collection","data-loss-risk"],"backgroundTag":"conflicting-config-options","analyzedSha":"86d9c8fc543e7c56c9f624eb725f76c9baff9570","analyzedAt":"2026-09-12T00:46:39.097Z","contentChangedAt":"2026-09-12T00:46:39.097Z","schemaVersion":2},"datasetVersion":"2026-09-14T11:17:12.474Z"}