Skip to content

Conversation

@gaborkaszab
Copy link
Collaborator

No description provided.

@github-actions github-actions bot added the core label Oct 21, 2025

/**
* @deprecated will be removed in 2.0.0. Use {@link
* @deprecated will be removed in 1.12.0. Use {@link
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this one should be fine to remove before 2.0.0, since the property was only moved to a different class

/**
* @deprecated Use {@link SystemConfigs#WORKER_THREAD_POOL_SIZE WORKER_THREAD_POOL_SIZE} instead;
* will be removed in 2.0.0
* will be removed in 1.12.0
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this should be ok to remove earlier as well

@github-actions
Copy link

This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 1 week if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the [email protected] list. Thank you for your contributions.

@github-actions github-actions bot added the stale label Nov 22, 2025
@pvary
Copy link
Contributor

pvary commented Nov 22, 2025

Limit this to the ones which are trivial, and merge those

@github-actions github-actions bot removed the stale label Nov 23, 2025
@gaborkaszab gaborkaszab force-pushed the main_change_deprecations_core branch from c05ed54 to 398b988 Compare December 1, 2025 08:51
@gaborkaszab
Copy link
Collaborator Author

Thank you for taking a look @nastra and @pvary !
I remove the changes from TableProperties. Do you think the rest is reasonable?

@gaborkaszab gaborkaszab force-pushed the main_change_deprecations_core branch from 398b988 to 82673e6 Compare December 1, 2025 09:12

/**
* @deprecated will be removed in 2.0.
* @deprecated will be removed in 1.12.0.
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

CC: @ggershinsky - is there any particular reason to keep these to 2.0?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should be ok to remove earlier.

*
* @param props table configuration
* @deprecated use {@link MetricsConfig#forTable(Table)}
* @deprecated use {@link MetricsConfig#forTable(Table)}. Will be removed in 1.12.0
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Change back to 2.0.0


/**
* @deprecated since 1.7.0, will be removed in 2.0.0; This method does only best-effort
* @deprecated since 1.7.0, will be removed in 1.12.0; This method does only best-effort
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is an alternative way to empty the cache?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@findepi Do you know any alternative way to invalidate all entries in the cache?

@pvary we discussed that we may want to leave the targeted removal for 2.0.0. However, this is a functionality we'd like the users to come off (due to the race condition) I think we should remove asap, so 1.12.0 still makes sense to me. WDYT?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you know any alternative way to invalidate all entries in the cache?

Depends on the goal.
if you invalidate just to reduce memory usage (rare), this method is fine
if you invalidate because something changed and all values needs to be recomputed (including those in flight), then there is no ready to use solution.

In trino we have additional layer on top of Guava caches that solves this problem. Here we use caffeine, but last time i checked, it had the same invalidation race problem and the author's feedback was that it was fundamentally not solvable.
thus, if full invalidation is needed, you can either copy code from trino-cache trino module (or use the code i already extracted https://github.com/findepi/evictable-cache)

Here i'd hope that invalidation isn't really needed for anything and we can remove the API.


/**
* @deprecated will be removed in 2.0.0, use {@link ViewBuilder#withLocation} instead.
* @deprecated will be removed in 1.12.0, use {@link ViewBuilder#withLocation} instead.
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

set back to 2.0.0

}

@Deprecated(since = "1.2")
/* @deprecated Will be removed in 1.12.0 */
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

check if tests pass without this

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we can remove this once the PreparedStatement.setUnicodeStream is removed in JDK. It's out of our control, so I reset this change to original

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I suggest to use @SuppressWarnings("deprecation") to get rid of the warning. Having @Deprecated(since = "1.2") is misleading. One might think that it is referring to the Iceberg 1.2 release


/**
* @deprecated will be removed in 2.0.0; use applyNameMapping and pruneColumns(Schema, Set)
* @deprecated will be removed in 1.12.0; use applyNameMapping and pruneColumns(Schema, Set)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

did the deprecation removal rules change?
it looks like we considered not ok to remove a public API in a minor update, and now we conclude it's ok.

has this been discussed somewhere already?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There was a discussion about this in one of the community syncs. The conclusion was that we give guarantees for a whole major version in the api/ module, however in the core/ module we could be less strict and provide guarantees for one minor release. Technically deprecate in the upcoming minor, drop in the one after that is OK in core. Hence, this PR collects all the deprecations in core/ marking removal for 2.0.0 to revisit them and drop earlier if possible.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

however in the core/ module we could be less strict and provide guarantees for one minor release

is this written down somewhere so that we can reference the rules of the games when deprecating?
community syncs meeting notes are not normative, we should capture important conclusions somewhere

btw, i don't think this 1 minor release guarantee means much in practice. maven world reality is that minor version update may just happen when combining various artifacts for the final delivery, so removing an API may obviously lead to MethodDefNotFoundError. This may be a fair trade off, i just hope it's a conscious one

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for taking a look, @findepi !
Here are the docs for the api guarantees in different modules. It mentions one minor version guarantee in core module.


/**
* @deprecated since 1.7.0, will be removed in 2.0.0; This method does only best-effort
* @deprecated since 1.7.0, will be removed in 1.12.0; This method does only best-effort
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do you know any alternative way to invalidate all entries in the cache?

Depends on the goal.
if you invalidate just to reduce memory usage (rare), this method is fine
if you invalidate because something changed and all values needs to be recomputed (including those in flight), then there is no ready to use solution.

In trino we have additional layer on top of Guava caches that solves this problem. Here we use caffeine, but last time i checked, it had the same invalidation race problem and the author's feedback was that it was fundamentally not solvable.
thus, if full invalidation is needed, you can either copy code from trino-cache trino module (or use the code i already extracted https://github.com/findepi/evictable-cache)

Here i'd hope that invalidation isn't really needed for anything and we can remove the API.

@gaborkaszab gaborkaszab force-pushed the main_change_deprecations_core branch from 82673e6 to 5bcdeab Compare December 10, 2025 14:15
@pvary
Copy link
Contributor

pvary commented Dec 12, 2025

Let's wait a bit more if somebody has any more comments

* @deprecated Use {@link AuthProperties#AUTH_TYPE}={@link AuthProperties#AUTH_TYPE_SIGV4}
* instead. Will be removed in 1.12.0.
*/
@Deprecated private static final String SIGV4_ENABLED_LEGACY = "rest.sigv4-enabled";
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is actually a fallback mechanism so that older clients still work. When this property is removed, we want to make sure to switch the warn to an error msg but still leave the fallback mechanism in-place

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Taking a second look, I just realize this is a private member, so technically this is already deprecated. I'll revert the changes here. because there isn't much we can do atm.

@gaborkaszab gaborkaszab force-pushed the main_change_deprecations_core branch from 5bcdeab to fc02d3a Compare December 12, 2025 14:47
@pvary pvary merged commit 831b4ea into apache:main Dec 15, 2025
44 checks passed
@pvary
Copy link
Contributor

pvary commented Dec 15, 2025

Merged to main.
Thanks @gaborkaszab for the PR and @nastra, @findepi, @ggershinsky for the review

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants