Skip to content

Commit 9742f91

Browse files
authored
Harmonize YML internal variables to proper case (#638)
1 parent 521cdb5 commit 9742f91

File tree

4 files changed

+5
-4
lines changed

4 files changed

+5
-4
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ All notable changes to this project will be documented in this file.
1414
- Refactor `RestTemplateConfig` to use `HttpClient 5` and improve proxy handling. (#626)
1515
- Replace deprecated `connect` with `connectAsync` in `StompClientService`. (#627)
1616
- Remove redundant blockchain calls to diminish pressure on Ethereum JSON-RPC API. (#632)
17+
- Harmonize YML internal variables to proper case. (#638)
1718

1819
### Breaking API changes
1920

src/main/java/com/iexec/worker/config/SchedulerConfiguration.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public class SchedulerConfiguration {
3838
public SchedulerConfiguration(@Value("${core.protocol}") String protocol,
3939
@Value("${core.host}") String host,
4040
@Value("${core.port}") String port,
41-
@Value("${core.poolAddress}") String poolAddress) {
41+
@Value("${core.pool-address}") String poolAddress) {
4242
this.protocol = protocol;
4343
this.host = host;
4444
this.port = port;

src/main/resources/application.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ core:
55
protocol: ${IEXEC_CORE_PROTOCOL:http}
66
host: ${IEXEC_CORE_HOST:localhost}
77
port: ${IEXEC_CORE_PORT:13000}
8-
poolAddress: ${POOL_ADDRESS:0x0}
8+
pool-address: ${POOL_ADDRESS:0x0}
99

1010
worker:
1111
name: ${IEXEC_WORKER_NAME:worker}

src/test/java/com/iexec/worker/config/SchedulerConfigurationTests.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ class SchedulerConfigurationTests {
3232

3333
@Test
3434
void shouldCreateBeanInstance() {
35-
runner.withPropertyValues("core.protocol=http", "core.host=localhost", "core.port=13000", "core.poolAddress=0x365E7BABAa85eC61Dffe5b520763062e6C29dA27")
35+
runner.withPropertyValues("core.protocol=http", "core.host=localhost", "core.port=13000", "core.pool-address=0x365E7BABAa85eC61Dffe5b520763062e6C29dA27")
3636
.withConfiguration(UserConfigurations.of(SchedulerConfiguration.class))
3737
.run(context -> {
3838
assertThat(context).hasSingleBean(SchedulerClient.class);
@@ -45,7 +45,7 @@ void shouldCreateBeanInstance() {
4545
@ParameterizedTest
4646
@ValueSource(strings = {"", "0x0"})
4747
void shouldFailedAndRaisedExceptionWhenPoolAddressIsInvalid(String poolAddress) {
48-
runner.withPropertyValues("core.protocol=http", "core.host=localhost", "core.port=13000", "core.poolAddress=" + poolAddress)
48+
runner.withPropertyValues("core.protocol=http", "core.host=localhost", "core.port=13000", "core.pool-address=" + poolAddress)
4949
.withConfiguration(UserConfigurations.of(SchedulerConfiguration.class))
5050
.run(context -> {
5151
assertThatThrownBy(() -> context.getBean(SchedulerConfiguration.class))

0 commit comments

Comments
 (0)