Skip to content

Commit

Permalink
Core: Remove deprecated method from BaseMetadataTable
Browse files Browse the repository at this point in the history
  • Loading branch information
ajantha-bhat committed Dec 14, 2023
1 parent 5e62e47 commit 5d14bf1
Show file tree
Hide file tree
Showing 3 changed files with 74 additions and 9 deletions.
71 changes: 71 additions & 0 deletions .palantir/revapi.yml
Original file line number Diff line number Diff line change
Expand Up @@ -874,9 +874,80 @@ acceptedBreaks:
justification: "Static utility class - should not have public constructor"
"1.4.0":
org.apache.iceberg:iceberg-core:
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.AllDataFilesTable"
new: "class org.apache.iceberg.AllDataFilesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.AllDeleteFilesTable"
new: "class org.apache.iceberg.AllDeleteFilesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.AllEntriesTable"
new: "class org.apache.iceberg.AllEntriesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.AllFilesTable"
new: "class org.apache.iceberg.AllFilesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.AllManifestsTable"
new: "class org.apache.iceberg.AllManifestsTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.BaseMetadataTable"
new: "class org.apache.iceberg.BaseMetadataTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.DataFilesTable"
new: "class org.apache.iceberg.DataFilesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.DeleteFilesTable"
new: "class org.apache.iceberg.DeleteFilesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.FilesTable"
new: "class org.apache.iceberg.FilesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.HistoryTable"
new: "class org.apache.iceberg.HistoryTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.ManifestEntriesTable"
new: "class org.apache.iceberg.ManifestEntriesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.ManifestsTable"
new: "class org.apache.iceberg.ManifestsTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.MetadataLogEntriesTable"
new: "class org.apache.iceberg.MetadataLogEntriesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.PartitionsTable"
new: "class org.apache.iceberg.PartitionsTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.PositionDeletesTable"
new: "class org.apache.iceberg.PositionDeletesTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.RefsTable"
new: "class org.apache.iceberg.RefsTable"
justification: "Removing deprecated code"
- code: "java.class.noLongerImplementsInterface"
old: "class org.apache.iceberg.SnapshotsTable"
new: "class org.apache.iceberg.SnapshotsTable"
justification: "Removing deprecated code"
- code: "java.field.serialVersionUIDChanged"
new: "field org.apache.iceberg.util.SerializableMap<K, V>.serialVersionUID"
justification: "Serialization is not be used"
- code: "java.method.removed"
old: "method org.apache.iceberg.TableOperations org.apache.iceberg.BaseMetadataTable::operations()"
justification: "Removing deprecated code"
apache-iceberg-0.14.0:
org.apache.iceberg:iceberg-api:
- code: "java.class.defaultSerializationChanged"
Expand Down
10 changes: 1 addition & 9 deletions core/src/main/java/org/apache/iceberg/BaseMetadataTable.java
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,7 @@
* the metadata table using a {@link StaticTableOperations}. This way no Catalog related calls are
* needed when reading the table data after deserialization.
*/
public abstract class BaseMetadataTable extends BaseReadOnlyTable
implements HasTableOperations, Serializable {
public abstract class BaseMetadataTable extends BaseReadOnlyTable implements Serializable {
private final PartitionSpec spec = PartitionSpec.unpartitioned();
private final SortOrder sortOrder = SortOrder.unsorted();
private final BaseTable table;
Expand Down Expand Up @@ -103,13 +102,6 @@ protected BaseTable table() {
return table;
}

/** @deprecated will be removed in 1.4.0; do not use metadata table TableOperations */
@Override
@Deprecated
public TableOperations operations() {
return table.operations();
}

@Override
public String name() {
return name;
Expand Down
2 changes: 2 additions & 0 deletions core/src/main/java/org/apache/iceberg/SerializableTable.java
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,8 @@ private String metadataFileLocation(Table table) {
if (table instanceof HasTableOperations) {
TableOperations ops = ((HasTableOperations) table).operations();
return ops.current().metadataFileLocation();
} else if (table instanceof BaseMetadataTable) {
return ((BaseMetadataTable) table).table().operations().current().metadataFileLocation();
} else {
return null;
}
Expand Down

0 comments on commit 5d14bf1

Please sign in to comment.