opensearch-project / opensearch-spark

Spark Accelerator framework ; It enables secondary indices to remote data stores.
Apache License 2.0
22 stars 33 forks source link

[FEATURE] REPL concurrent query execution #382

Open noCharger opened 5 months ago

noCharger commented 5 months ago

Is your feature request related to a problem?

https://github.com/opensearch-project/opensearch-spark/blob/main/spark-sql-application/src/main/scala/org/apache/spark/sql/FlintREPL.scala#L814-L825

      val futureQueryExecution = Future {
        executeQuery(
          spark,
          flintStatement.query,
          dataSource,
          flintStatement.queryId,
          sessionId,
          false)
      }(executionContext)

      // time out after 10 minutes
      ThreadUtils.awaitResult(futureQueryExecution, queryExecutionTimeOut)

Currrently REPL query loop will wait on async query execution.

What solution would you like?

Need some thoughts around to support REPL concurrent query execution.

What alternatives have you considered?

Concurrent execution outside of Spark. The problem of this approach is code start.

dblock commented 4 months ago

Thanks for opening this.

[Catch All Triage - Attendees 1, 2, 3, 4, 5]