1 |
package dk.thoerup.traininfoservice; |
package dk.thoerup.traininfoservice; |
2 |
|
|
3 |
import dk.thoerup.circuitbreaker.config.BreakerConfig; |
import dk.thoerup.circuitbreaker.config.BreakerConfig; |
4 |
|
import dk.thoerup.webconfig.ConfigVariable; |
5 |
|
import dk.thoerup.webconfig.ReloadConfig; |
6 |
|
|
7 |
|
|
8 |
public class TraininfoSettings implements BreakerConfig{ |
public class TraininfoSettings implements BreakerConfig{ |
9 |
|
|
10 |
|
@ConfigVariable |
11 |
boolean useazuresite; |
boolean useazuresite; |
12 |
|
|
13 |
|
@ConfigVariable(description = "Circuitbreaker", readonly = true) |
14 |
int banedk_threshold; |
int banedk_threshold; |
15 |
|
|
16 |
|
@ConfigVariable(readonly = true) |
17 |
int banedk_timeout; |
int banedk_timeout; |
18 |
|
|
19 |
|
@ConfigVariable(readonly = true) |
20 |
int cache_timeout; |
int cache_timeout; |
21 |
|
|
22 |
|
@ConfigVariable(readonly = true) |
23 |
int stats_interval; |
int stats_interval; |
24 |
|
|
25 |
|
@ConfigVariable |
26 |
int reply_timeout; |
int reply_timeout; |
27 |
|
|
28 |
|
@ReloadConfig |
29 |
|
public void reloadConfig() { |
30 |
|
System.out.println("Reloading config"); |
31 |
|
|
32 |
|
} |
33 |
|
|
34 |
public boolean getUseAzureSite() { |
public boolean getUseAzureSite() { |
35 |
return useazuresite; |
return useazuresite; |