Skip to content

Commit

Permalink
fix table1 async query get status
Browse files Browse the repository at this point in the history
  • Loading branch information
linzhou-db committed Oct 9, 2024
1 parent cd40567 commit a9ffd0a
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -344,17 +344,18 @@ class DeltaSharingService(serverConfig: ServerConfig) {
}

// simulate async query with 50% chance of return
// asynchronously client should be able to hand both cases
// this is for test purpose only and shouldn't cause flakiness
if(rand.nextInt(100) > 50) {
// asynchronously for a specific table
// client should be able to handle both cases and for server
// test please use other table names.
if(rand.nextInt(100) > 50 && table == "table2" && !request.pageToken.isDefined) {
streamingOutput(
Some(0),
"parquet",
Seq(
SingleAction(queryStatus = QueryStatus(queryId))
)
)
} else {
} else {

// we are reusing the table here to simulate a view query result
val tableConfig = sharedTableManager.getTable(share, schema, table)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -694,7 +694,7 @@ class DeltaSharingServiceSuite extends FunSuite with BeforeAndAfterAll {
)

val lines = response.split("\n")
print(s"response: $response")
print(s"--response--: $response")
assert(lines.length == 4)
}
}
Expand Down

0 comments on commit a9ffd0a

Please sign in to comment.