Deploy Apache Spark application from another application in Java, best practice

后端 未结 3 1022
有刺的猬
有刺的猬 2021-02-10 04:37

I am a new user of Spark. I have a web service that allows a user to request the server to perform a complex data analysis by reading from a database and pushing the results bac

3条回答
  •  感动是毒
    2021-02-10 05:00

    I've had a similar requirement. Here's what I did:

    1. To submit apps, I use the hidden Spark REST Submission API: http://arturmkrtchyan.com/apache-spark-hidden-rest-api

    2. Using this same API you can query status for a Driver or you can Kill your Job later

    3. There's also another hidden UI Json API: http://[master-node]:[master-ui-port]/json/ which exposes all information available on the master UI in JSON format.

    Using "Submission API" I submit a driver and using the "Master UI API" I wait until my Driver and App state are RUNNING

提交回复
热议问题