Skip to content

Conversation

sungwy
Copy link
Collaborator

@sungwy sungwy commented Feb 28, 2025

This is a follow up item from a recent discussion on the mailing list[1], where the community decided that 401 response should be preferred over 419 response on token expiry.

[1] mailing list discussion: https://lists.apache.org/thread/443skhqr59j3fj0ovg4tyxh9d4f4gysc
[2] REST Catalog Spec update PR: apache/iceberg#12376

@sungwy sungwy requested review from kevinjqliu and Fokko February 28, 2025 03:09
Copy link
Contributor

@kevinjqliu kevinjqliu left a comment

Choose a reason for hiding this comment

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

LGTM.

At first it was a bit unintuitive to retry 401 "Unauthorized" since if the request is unauthorized, why try again?
Reading into the thread, it seems that there is a mechanism for the server to signal the client to retry with a different state.

From https://developer.mozilla.org/en-US/docs/Web/HTTP/Status/401

This status code is sent with an HTTP WWW-Authenticate response header that contains information on the authentication scheme the server expects the client to include to make the request successfully 

@sungwy sungwy merged commit a268f83 into apache:main Mar 3, 2025
7 checks passed
@sungwy sungwy deleted the 401-should-retry branch March 3, 2025 14:10
@Fokko Fokko added this to the PyIceberg 0.9.1 milestone Apr 20, 2025
Fokko pushed a commit that referenced this pull request Apr 25, 2025
This is a follow up item from a recent discussion on the mailing
list[1], where the community decided that 401 response should be
preferred over 419 response on token expiry.

[1] mailing list discussion:
https://lists.apache.org/thread/443skhqr59j3fj0ovg4tyxh9d4f4gysc
[2] REST Catalog Spec update PR:
apache/iceberg#12376
gabeiglio pushed a commit to Netflix/iceberg-python that referenced this pull request Aug 13, 2025
This is a follow up item from a recent discussion on the mailing
list[1], where the community decided that 401 response should be
preferred over 419 response on token expiry.

[1] mailing list discussion:
https://lists.apache.org/thread/443skhqr59j3fj0ovg4tyxh9d4f4gysc
[2] REST Catalog Spec update PR:
apache/iceberg#12376
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.

3 participants