I used the following script to submit my application on yarn.
MAIN_CLASS=org.example.app.HelloFlink flink run -m yarn-cluster -yn 4 -ys 1 -ynm FlinkHiveIntegr