You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@spark.apache.org by "juliuszsompolski (via GitHub)" <gi...@apache.org> on 2023/08/10 23:02:49 UTC

[GitHub] [spark] juliuszsompolski commented on pull request #42441: [CONNECT][POC] Have real server and real simple client in tests

juliuszsompolski commented on PR #42441:
URL: https://github.com/apache/spark/pull/42441#issuecomment-1674031258

   @hvanhovell @HyukjinKwon @grundprinzip @vicennial reaching out to any build experts :-)
   
   What I want to achieve is being able to test a real Spark Connect server, with a real client that will connect to it over a localhost connection.
   The problem with using mocks like the rest of the `connect` module tests do is that threads are different (no real GRPC threads are used), things like `setOnReadyHandler` and GRPC events like `OnReady` are different, so issues like what was surfaced in https://github.com/apache/spark/pull/42355 get missed. I want the real thing with an in-process server that I can poke (inspect the execution manager I'm adding in https://github.com/apache/spark/pull/42423), and a real thin client. I don't need the connect SparkSession, SparkConnectClient will do.
   To do that, I split out the org.apache.spark.sql.connect.client code into `spark-connect-client-jvm-internal` module, that I can pull into the server with `<scope>test</scope>`. That package does not have any conflicts with the server code, like pulling in the client SparkSession would.
   
   What I am doing appears to work. But it could be simpler and easier If I didn't need to create a new module, but could just pull that code and relocate it with shading...


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscribe@spark.apache.org
For additional commands, e-mail: reviews-help@spark.apache.org