1 |
package dk.daoas.daoadresseservice.admin; |
package dk.daoas.daoadresseservice.admin; |
2 |
|
|
3 |
|
import dk.thoerup.circuitbreaker.config.BreakerConfig; |
4 |
import dk.thoerup.webconfig.ConfigVariable; |
import dk.thoerup.webconfig.ConfigVariable; |
5 |
|
|
6 |
|
|
7 |
|
|
8 |
public class ServiceConfig { |
public class ServiceConfig implements BreakerConfig { |
9 |
|
|
10 |
@ConfigVariable |
@ConfigVariable |
11 |
public boolean useGoogle; |
public boolean useGoogle; |
13 |
@ConfigVariable |
@ConfigVariable |
14 |
public boolean useOpenStreetMaps; |
public boolean useOpenStreetMaps; |
15 |
|
|
16 |
|
@ConfigVariable |
17 |
|
public int osmTimeout; |
18 |
|
|
19 |
|
@ConfigVariable(mandatory=false, readonly=true) |
20 |
|
public String googleApiUser; |
21 |
|
|
22 |
|
@ConfigVariable(mandatory=false, hideValue=true) |
23 |
|
public String googleApiKey; |
24 |
|
|
25 |
|
@Override |
26 |
|
public int getTimeout() { |
27 |
|
return 60000; |
28 |
|
} |
29 |
|
|
30 |
|
@Override |
31 |
|
public int getTreshold() { |
32 |
|
return 5; |
33 |
|
} |
34 |
|
|
35 |
} |
} |