-
Notifications
You must be signed in to change notification settings - Fork 2.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bump Nessie to 0.8.2 + related changes #2588
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changes LGTM
Should worth to have projectnessie/nessie#1249 merged into Nessie first and use Nessie 0.6.1 in this PR then. |
Looks like this needs a rebase. @snazy do you still want to update to |
a25ee34
to
ebc441f
Compare
Yup, updated this PR to bump Nessie to 0.6.1. |
@snazy looks like the build failed for java8. Presumably its the recent chagne to nessie server to not support java8? |
Oh yea, projectnessie/nessie#1245 broke the test runs. It's not that the Nessie Client in Iceberg is broken, it's "just" the server that cannot run. Reverting projectnessie/nessie#1245 doesn't make much sense, because Quarkus 2 drops support for Java 8 entirely. I see these options here:
I think, option 1 is a good workaround for now and then follow-up with option 2 within a short time. WDYT? |
I see no rush to get this patch in. The only deadline is the 0.12.0 release. So lets fix the tests correctly. Lets go with the uber-jar too. I don't want to complicate the CI and introduce another build dependency. |
3abe81e
to
14cc6d4
Compare
070c269
to
bd0a28b
Compare
nessie/src/main/java/org/apache/iceberg/nessie/NessieCatalog.java
Outdated
Show resolved
Hide resolved
2b6bbb5
to
53ab73a
Compare
3e5c976
to
5e425d6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, with one question
nessie/src/main/java/org/apache/iceberg/nessie/UpdateableReference.java
Outdated
Show resolved
Hide resolved
Tests pass locally w/ Java 11 + Java 8 against latest in-dev Nessie. |
nessie/src/main/java/org/apache/iceberg/nessie/UpdateableReference.java
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there are two things:
- more documentation of the individual changes - some aren't clear
- separate into a few changes
nessie/src/main/java/org/apache/iceberg/nessie/TableReference.java
Outdated
Show resolved
Hide resolved
2badb38
to
8bd6f75
Compare
nessie/src/main/java/org/apache/iceberg/nessie/NessieCatalog.java
Outdated
Show resolved
Hide resolved
nessie/src/main/java/org/apache/iceberg/nessie/UpdateableReference.java
Outdated
Show resolved
Hide resolved
nessie/src/test/java/org/apache/iceberg/nessie/TestBranchVisibility.java
Show resolved
Hide resolved
More changes in this PR in following commits. Replace Gradle plugin with new JUnit extension. See [Add JAX-RS tests and add JUnit/Jupyter extension](projectnessie/nessie#1566)
Apply changes to Iceberg required by API changes in Nessie: * [Re-introduce wrapper classes for query params of CommitLog/Entries](projectnessie/nessie#1595) * [Server-side commit range filtering](projectnessie/nessie#1596) * [Add hashOnRef query param to support time travel on a named ref](projectnessie/nessie#1589) * [Only accept NamedRefs in REST API](projectnessie/nessie#1583)
Nessie's `Contents.id` is a random ID generated when the `Contents.Key` is first used (think: CREATE TABLE) and must not be changed. This change addresses a bug in the Iceberg-Nesie code that caused a new id for every change.
When commiting a change, the Nessie-API now returns the hash of the commit for the change. This returned hash should then be used as the "expected hash" for the next commit. The previous approach was to commit the change to Nessie and then do another request to retrieve the new hash of HEAD. This old approach is prone to a race condition, namely when another commit happens after "this" commit but before retrieving the "new HEAD", so "this" instance would wrongly ignore the other commit's changes during conflict checks. See [Let VersionStore.create()+commit() return the current hash](projectnessie/nessie#1089)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @snazy !!
* Bump Nessie to 0.8.2 + replace Gradle plugin with new JUnit extension More changes in this PR in following commits. Replace Gradle plugin with new JUnit extension. See [Add JAX-RS tests and add JUnit/Jupyter extension](projectnessie/nessie#1566) * Changes required by Nessie-API changes Apply changes to Iceberg required by API changes in Nessie: * [Re-introduce wrapper classes for query params of CommitLog/Entries](projectnessie/nessie#1595) * [Server-side commit range filtering](projectnessie/nessie#1596) * [Add hashOnRef query param to support time travel on a named ref](projectnessie/nessie#1589) * [Only accept NamedRefs in REST API](projectnessie/nessie#1583) * Bugfix: must send the Contents.id of the existing table Nessie's `Contents.id` is a random ID generated when the `Contents.Key` is first used (think: CREATE TABLE) and must not be changed. This change addresses a bug in the Iceberg-Nesie code that caused a new id for every change. * Throw `CommitStateUnknownException` for `renameTable` as well Follow-up of apache#2515 * Fix race-condition & save one roundtrip to Nessie during "commit" When commiting a change, the Nessie-API now returns the hash of the commit for the change. This returned hash should then be used as the "expected hash" for the next commit. The previous approach was to commit the change to Nessie and then do another request to retrieve the new hash of HEAD. This old approach is prone to a race condition, namely when another commit happens after "this" commit but before retrieving the "new HEAD", so "this" instance would wrongly ignore the other commit's changes during conflict checks. See [Let VersionStore.create()+commit() return the current hash](projectnessie/nessie#1089)
Bump Nessie to 0.8.2 + replace Gradle plugin with new JUnit extension
See Add JAX-RS tests and add JUnit/Jupyter extension
Apply changes to Iceberg required by API changes in Nessie:
Bugfix: must send the Contents.id of the existing table
Nessie's
Contents.id
is a random ID generated when theContents.Key
is first used (think:CREATE TABLE) and must not be changed. This change addresses a bug in the Iceberg-Nesie code
that caused a new id for every change.
Throw
CommitStateUnknownException
forrenameTable
as wellFollow-up of Use
CommitStatusUnknownException
for Nessie #2515Fix race-condition & save one roundtrip to Nessie during "commit"
When commiting a change, the Nessie-API now returns the hash of the commit for the change.
This returned hash should then be used as the "expected hash" for the next commit.
The previous approach was to commit the change to Nessie and then do another request to
retrieve the new hash of HEAD.
This old approach is prone to a race condition, namely when another commit happens after
"this" commit but before retrieving the "new HEAD", so "this" instance would wrongly
ignore the other commit's changes during conflict checks.
See Let VersionStore.create()+commit() return the current hash