Skip to content

Catch FileSystemException when opening direct IO #128834

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

Open
wants to merge 1 commit into
base: lucene_snapshot
Choose a base branch
from

Conversation

thecoop
Copy link
Member

@thecoop thecoop commented Jun 3, 2025

The exceptions seen in #128463 is likely to also be seen in other live scenarios with filesystems that do not support direct IO. This should be handled in production ES.

@thecoop thecoop requested a review from ChrisHegarty June 3, 2025 13:48
@elasticsearchmachine elasticsearchmachine added the Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch label Jun 3, 2025
@elasticsearchmachine
Copy link
Collaborator

Pinging @elastic/es-search-relevance (Team:Search Relevance)

@thecoop thecoop added the v9.1.0 label Jun 3, 2025
} else {
return super.openInput(name, context);
try {
Log.debug("Opening {} with direct IO", name);
Copy link
Contributor

@ChrisHegarty ChrisHegarty Jun 3, 2025

Choose a reason for hiding this comment

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

How does this affect the DirectIOIT test ? Maybe we wanna make the test assertions conditional rather than skip? That way we can assert the fallback case, no? Maybe we move the log line to after the creation of the input. That way we can have a single log line in the output to know what it's doing.

Copy link
Member Author

Choose a reason for hiding this comment

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

Currently the direct IO test is unaffected, as that doesn't run the test at all if this would have thrown. We could include the negative test - that the exception is logged if direct IO is not supported?

@thecoop thecoop force-pushed the handle-fs-exception branch from 9e1e4e2 to f706519 Compare June 4, 2025 10:49
@thecoop thecoop force-pushed the handle-fs-exception branch from f706519 to 72249f3 Compare June 4, 2025 13:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
>refactoring :Search Relevance/Vectors Vector search Team:Search Relevance Meta label for the Search Relevance team in Elasticsearch v9.1.0
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants