Delegate has dependency on jre version and we download particular jre version.
You can find the version details:
- Delegate yaml in case of k8 type delegate:
- name: JRE_VERSION value: 1.8.0_242
- Similarly for docker we have the version as environment variable and so on:
And finally the jre version is downloaded and you can find the url in start.sh something similar as below:
So changing this version manually will result into frequent restart of delegate, as we do check for version once the delegate is started and if we see a mismatch in version which will try to download the above version and can result into loop.
Here is an example of such case, so we can see delegate was started with some other jre version(JRE 1.8.0_301)
2021-09-11 06:20:28,107 Starting Delegate 2021-09-11 06:20:35,858 **Delegate will start running on JRE 1.8.0_301** 2021-09-11 06:20:35,860 [New] Delegate process started. Sending confirmation
So once the version check ran, it reported difference in version:
2021-09-11 06:20:37,361 - **JRE version different. Migrating to 1.8.0_242**
Then watcher will ask delegate to stop taking new task and will try to download and restart the delegate process:
2021-09-11 06:31:47,900 Sending delegate process 246 stop-acquiring message to drain 2021-09-11 06:39:45,740 Shutdown is pending for delegate process 246 with version 1.0.71204
Note: So to avoid this behaviour, please do not change the JRE version as delegate/watcher process has dependency on jre version.