Skip to content

Instantly share code, notes, and snippets.

@TimurFayruzov
Created June 29, 2016 17:42
Show Gist options
  • Save TimurFayruzov/c2ec9ddcd49eaef71f89f78ba650a72b to your computer and use it in GitHub Desktop.
Save TimurFayruzov/c2ec9ddcd49eaef71f89f78ba650a72b to your computer and use it in GitHub Desktop.
Setup for running a Flink application on EMR
[
{
"Name": "Ship Flink runtime to cluster",
"Path": "s3://<your_bucket>/flink/ship_flink_runtime.sh"
},
{
"Name": "Ship application to cluster",
"Path": "s3://<your_bucket>/flink/ship_app.sh"
}
]
[
{
"Classification": "hadoop-env",
"Configurations": [
{
"Classification": "export",
"Configurations": [],
"Properties": {
"JAVA_HOME": "/usr/lib/jvm/java-1.8.0",
"HADOOP_CLASSPATH": "$HADOOP_CLASSPATH:/usr/share/aws/emr/s3-dist-cp/lib/"
}
}
],
"Properties": {}
}
]
[{
"InstanceGroupType":"MASTER",
"InstanceCount":1,
"InstanceType":"m1.large"
},
{
"InstanceGroupType":"CORE",
"InstanceCount":1,
"InstanceType":"m1.large"
}]
#!/bin/bash
cd /home/hadoop
aws s3 cp s3://<your_bucket>/flink/<your_app>.jar .
#!/bin/bash
#upload bootstrap scripts
aws s3 cp ship_flink_runtime.sh s3://<your_bucket>/flink/ship_flink_runtime.sh
aws s3 cp ship_app.sh s3://<your_bucket>/flink/ship_app.sh
#upload start flink sript
aws s3 cp start_flink.sh s3://wp-data-west-2/flink/start_flink.sh
aws s3 cp run_flink.sh s3://wp-data-west-2/flink/run_flink.sh
aws emr create-cluster --release-label emr-4.5.0 --configurations file://./configurations.json --use-default-roles --instance-groups file://./instance_groups.json --name "my-flink-app" application="my-flink-app" --applications Name=Hadoop --enable-debugging --log-uri s3://<log_bucket>/elasticmapreduce/ --ec2-attributes KeyName=<AWS_key> --bootstrap-actions file://./bootstrap.json --steps file://./run_flink.json "$@"
@meghashyam6
Copy link

Is there a way to dynamically change parallelism when autoscaling is turned on in EMR?

@austince
Copy link

austince commented Sep 6, 2018

Was there a reason not to set akka.ask.timeout in the EMR configurations.json file?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment