Skip to content
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

[BUG] Stop Spark context and JVM explicitly in FlintJob #270

Closed
dai-chen opened this issue Mar 5, 2024 · 0 comments
Closed

[BUG] Stop Spark context and JVM explicitly in FlintJob #270

dai-chen opened this issue Mar 5, 2024 · 0 comments
Assignees
Labels
0.3 bug Something isn't working

Comments

@dai-chen
Copy link
Collaborator

dai-chen commented Mar 5, 2024

What is the bug?

Spark application job doesn't stop when exception thrown from underlying API layer (FlintSpark).

What is the expected behavior?

Spark application job can exit. Instead of stopping Spark context explicitly, FlintJob register a shutdown hook. However, FlintREPL clean up resource explicitly.

Do you have any additional context?

Error log:

# Exception thrown out
24/02/29 06:49:52 ERROR JobOperator: Fail to run query, cause: Failed to recover Flint index
java.lang.IllegalStateException: Failed to recover Flint index
  at org.opensearch.flint.spark.FlintSpark.recoverIndex(FlintSpark.scala:301)
  at org.opensearch.flint.spark.sql.job.FlintSparkIndexJobAstBuilder.$anonfun$visitRecoverIndexJobStatement$1(FlintSparkIndexJobAstBuilder.scala:22)
  at org.opensearch.flint.spark.sql.FlintSparkSqlCommand.run(FlintSparkSqlCommand.scala:27)
...

# FlintJob clean up resource
24/02/29 06:49:55 INFO JobOperator: shut down thread threadpool

# Shutdown hook not triggered. Job hung up for 29 mins
...
24/02/29 07:18:57 INFO BlockManagerInfo: Removed broadcast_0_piece0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
0.3 bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants