# resource
jar_path=
clazz=
#
jobName=
bootstrap_server=
topic=
groupId=
isSecurity=true
consumerStrategy=
redis_hostname=
redis_port=
if [ "$isSecurity" == true ]; then
/software/servers/flink/bin/flink run
-m yarn-cluster
-yD env.java.opts="-Djava.security.auth.login.config=/software/servers/keytab/kafka_client_jass.conf"
-yqu root.budata.ads
-c $clazz $jar_path --jobName $jobName --bootstrap-server $bootstrap_server --topic $topic --groupId $groupId --isSecurity $isSecurity --consumerStrategy $consumerStrategy --redis_hostname $redis_hostname --redis_port $redis_port
else
echo "/software/servers/flink/bin/flink run -m yarn-cluster -yqu root.budata.ads -c $clazz $jar_path --jobName $jobName --bootstrap-server $bootstrap_server --topic $topic --groupId $groupId --isSecurity $isSecurity --consumerStrategy $consumerStrategy --redis.hostname $redis_hostname --redis.port $redis_port"
/software/servers/flink/bin/flink run -m yarn-cluster -yqu root.budata.ads -c $clazz $jar_path --jobName $jobName --bootstrap-server $bootstrap_server --topic $topic --groupId $groupId --isSecurity $isSecurity --consumerStrategy $consumerStrategy --redis_hostname $redis_hostname --redis_port $redis_port
fi
更多参数:
https://ci.apache.org/projects/flink/flink-docs-release-1.3/setup/config.html