An example of setting up Spring-Boot with Spark with simple word count application
- It can be run either in IDE or an maven application.
- $ spark-springboot> mvn clean install package -e -DskipTests=true
- If you don't want to skip the tests exclude -DskipTests=true in above step 2.
- $ spark-springboot/target> java -jar spark-springboot.jar
- Else in shot you can call $ spark-springboot> mvn clean install spring-boot:run -e
- You can hit http://localhost:8080/api/wordcount to view the output.
- You can also visualize your spark-jobs execution using http://localhost:4040/
- oc new-project demo
- oc create -f https://raw.githubusercontent.com/Pkrish15/spark-drools/master/resources.yaml
- oc new-app oshinko-webui
- oc get routes
- oc new-app --template oshinko-java-spark-build-dc
-p APPLICATION_NAME=spark-springboot
-p APP_MAIN_CLASS=com.redhat.gpte.SparkExperimentApplication
-p GIT_URI=https://github.com/Pkrish15/spark-springboot
-p APP_FILE=spark-springboot.jar