You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enhancement Request: Enable JWT Access Token Update for PIT Context Manager to Prevent Expiry
Currently, the context manager for a Point-in-Time (PIT) in Elasticsearch does not allow for the update of JWT access tokens, which can lead to token expiry issues. When using the iterate method to paginate through all data for a given PIT, the underlying Elastic client cannot be updated. This is because the context manager for a PIT creates a new instance of the Search object, which is not accessible in the consuming code.
As a result, authentication details, such as JWT access tokens, cannot be changed during the iteration process. If a JWT access token expires before the iteration through all data covered by a PIT is complete, the process will fail. This is because a new JWT access token cannot be used without losing the PIT.
This enhancement request seeks to address this limitation by allowing the update of JWT access tokens within the PIT context manager, ensuring seamless data iteration without authentication interruptions.
The text was updated successfully, but these errors were encountered:
I'm curious to know how do you handle this for other tasks. Do you catch 401 errors and in the error handler refresh the token and retry? If you can share some code that you use for this it would help me figure out how to best support this in the PIT context manager.
Enhancement Request: Enable JWT Access Token Update for PIT Context Manager to Prevent Expiry
Currently, the context manager for a Point-in-Time (PIT) in Elasticsearch does not allow for the update of JWT access tokens, which can lead to token expiry issues. When using the
iterate
method to paginate through all data for a given PIT, the underlying Elastic client cannot be updated. This is because the context manager for a PIT creates a new instance of theSearch
object, which is not accessible in the consuming code.Reference: Elasticsearch DSL Search Code
As a result, authentication details, such as JWT access tokens, cannot be changed during the iteration process. If a JWT access token expires before the iteration through all data covered by a PIT is complete, the process will fail. This is because a new JWT access token cannot be used without losing the PIT.
This enhancement request seeks to address this limitation by allowing the update of JWT access tokens within the PIT context manager, ensuring seamless data iteration without authentication interruptions.
The text was updated successfully, but these errors were encountered: