Skip to content

Spark3: Make views that reference Iceberg tables show current data#1545

Merged
rdblue merged 1 commit into
apache:masterfrom
aokolnychyi:refresh-spark-table
Oct 6, 2020
Merged

Spark3: Make views that reference Iceberg tables show current data#1545
rdblue merged 1 commit into
apache:masterfrom
aokolnychyi:refresh-spark-table

Conversation

@aokolnychyi
Copy link
Copy Markdown
Contributor

@aokolnychyi aokolnychyi commented Oct 2, 2020

This PR makes views that reference Iceberg tables show up-to-date data with and without catalog cache.

See #1485 for more info.

.mode("append")
.save(location.toString());

List<SimpleRecord> actual2 = spark.table("tmp").as(Encoders.bean(SimpleRecord.class)).collectAsList();
Copy link
Copy Markdown
Contributor Author

@aokolnychyi aokolnychyi Oct 2, 2020

Choose a reason for hiding this comment

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

This was failing for tables loaded through IcebergSource in Spark 3. Now, it matches Spark 2.

@aokolnychyi
Copy link
Copy Markdown
Contributor Author

@rdblue I remember we had a note somewhere in the docs about this behavior but I couldn't find it.

@rdblue
Copy link
Copy Markdown
Contributor

rdblue commented Oct 6, 2020

+1

I think this is a reasonable fix that is more in line with user expectations than independent and never-changing data frames.

@rdblue rdblue merged commit 8315781 into apache:master Oct 6, 2020
@rdblue rdblue added this to the Java 0.10.0 Release milestone Nov 16, 2020
rodmeneses pushed a commit to rodmeneses/iceberg that referenced this pull request Jun 23, 2025
…che#1545)

Adds a new configuration `token-refresh-mode` to provide alternative behaviour for token refresh used in RESTSessionCatalog. Potential values and its behaviour is listed below
1. legacy, retain existing token refresh behaviour as rely on token exchange workflow (grant type = "urn:ietf:params:oauth:grant-type:token-exchange") with OAuth2 server. This is the default behaviour from open source.
2. authenticate, by re-authenticate with using existing credential (grant type = "client_credentials") with OAuth2 server. This in intended to use together with IAS based authentication.

## Why do we need a new change?

Existing token exchange workflow used by IAS (https://presidium.ase.apple.com/docs/security-ias/getting-started/) is intended for delegation for service-to-service communication. Iceberg OSS spec implementation of token refresh does not align with IAS requirements and we adopt suggestions from community per apache#12196 (comment).

Co-authored-by: Steve (ASE) Zhang <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants