|
|
|
@ -33,7 +33,7 @@ import org.springframework.cloud.context.scope.refresh.RefreshScopeConfiguration
@@ -33,7 +33,7 @@ import org.springframework.cloud.context.scope.refresh.RefreshScopeConfiguration
|
|
|
|
|
import org.springframework.context.annotation.AnnotationConfigApplicationContext; |
|
|
|
|
import org.springframework.context.annotation.Bean; |
|
|
|
|
import org.springframework.context.annotation.Configuration; |
|
|
|
|
import org.springframework.web.bind.annotation.RequestMapping; |
|
|
|
|
import org.springframework.web.bind.annotation.GetMapping; |
|
|
|
|
import org.springframework.web.bind.annotation.RestController; |
|
|
|
|
|
|
|
|
|
import static org.assertj.core.api.BDDAssertions.then; |
|
|
|
@ -120,7 +120,7 @@ public class RefreshScopeConfigurationTests {
@@ -120,7 +120,7 @@ public class RefreshScopeConfigurationTests {
|
|
|
|
|
@Value("${message:Hello World!}") |
|
|
|
|
String message; |
|
|
|
|
|
|
|
|
|
@RequestMapping("/") |
|
|
|
|
@GetMapping("/") |
|
|
|
|
public String hello() { |
|
|
|
|
return this.message; |
|
|
|
|
} |
|
|
|
@ -140,7 +140,7 @@ public class RefreshScopeConfigurationTests {
@@ -140,7 +140,7 @@ public class RefreshScopeConfigurationTests {
|
|
|
|
|
SpringApplication.run(Application.class, args); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
@RequestMapping("/") |
|
|
|
|
@GetMapping("/") |
|
|
|
|
public String hello() { |
|
|
|
|
return this.message; |
|
|
|
|
} |
|
|
|
@ -168,7 +168,7 @@ public class RefreshScopeConfigurationTests {
@@ -168,7 +168,7 @@ public class RefreshScopeConfigurationTests {
|
|
|
|
|
@Value("${message:Hello World!}") |
|
|
|
|
String message; |
|
|
|
|
|
|
|
|
|
@RequestMapping("/") |
|
|
|
|
@GetMapping("/") |
|
|
|
|
// Deliberately use package scope
|
|
|
|
|
String hello() { |
|
|
|
|
return this.message; |
|
|
|
|