Open the ./notebooks/motivation/xp.ipynb notebook in your browser (make sure your jupyter server is still up and running, following the Requirements_g5k.md instruction).
Before continuing, make sure that the Flink image name in the following file is the same as the one you used during the build phase:
apiVersion: flink.apache.org/v1beta1
kind: FlinkDeployment
metadata:
name: flink
spec:
image: flink-justin:dais <------- Your Flink image name- ./notebooks/motivation/read-only/query.yaml
- ./notebooks/motivation/write-only/query.yaml
- ./notebooks/motivation/update/query.yaml
Follow the instructions in the notebook to execute the motivation benchmarks.
- Flink:
node.id.site:8081 - Grafana:
node.id.site:30300
Open the ./notebooks/nexmark/xp.ipynb notebook in your browser (make sure your jupyter server is still up and running, following the Requirements.md instruction).
Before continuing, make sure that the Flink image name in the following file is the same as the one you used during the build phase:
apiVersion: flink.apache.org/v1beta1
kind: FlinkDeployment
metadata:
name: flink
spec:
image: flink-justin:dais <------- Your Flink image name- ./notebooks/motivation/read-only/query.yaml, with X being the query number.
The notebook contains a cell for each query. These cells will execute the query twice, one with the default auto scaler, and one with the Justin auto scaler.
As explained in the paper, Justin relies on multiple parameters such as a minimum cache hit rate and minimum state access latency. These parameters can be modified via the YAML file of the query, namely the lines:
job.autoscaler.cache-hit-rate.min.threshold: "0.8"(ratio)job.autoscaler.state-latency.threshold: "1000000.0"(nano seconds)
Note that changing those values can result in different scaling decisions.
Additionally, the reader can also modify the stabilization interval (job.autoscaler.stabilization.interval) and metric window (job.autoscaler.metrics.window).
The Justin policy is implemented in the Flink Kubernetes Operator's auto scaler module.
The reader can easily apply its own policy logic by modifying the policy method of the ScalingExecutor.java file.
The reviewer has access to previous Scaling Decisions (if any) through the scaling parameter.
Once modified, the image needs to be rebuilt and pushed to the nodes.
Delete the operator and its resources by executing the script delete.sh located in the scriptsfolder. This script will delete any Flink job pending, the operator, and the 3 custom resource definitions.
Once deleted, you can re-deploy the operator following the previous instructions.