File tree Expand file tree Collapse file tree 1 file changed +14
-2
lines changed
spring-boot-project/spring-boot/src/main/java/org/springframework/boot Expand file tree Collapse file tree 1 file changed +14
-2
lines changed Original file line number Diff line number Diff line change 1
1
/*
2
- * Copyright 2012-2024 the original author or authors.
2
+ * Copyright 2012-2025 the original author or authors.
3
3
*
4
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
5
* you may not use this file except in compliance with the License.
19
19
import java .util .HashMap ;
20
20
import java .util .Map ;
21
21
22
+ import org .springframework .boot .origin .Origin ;
23
+ import org .springframework .boot .origin .OriginLookup ;
22
24
import org .springframework .boot .system .ApplicationPid ;
23
25
import org .springframework .core .env .ConfigurableEnvironment ;
24
26
import org .springframework .core .env .MapPropertySource ;
32
34
*
33
35
* @author Moritz Halbritter
34
36
*/
35
- class ApplicationInfoPropertySource extends MapPropertySource {
37
+ class ApplicationInfoPropertySource extends MapPropertySource implements OriginLookup < String > {
36
38
37
39
static final String NAME = "applicationInfo" ;
38
40
@@ -44,6 +46,16 @@ class ApplicationInfoPropertySource extends MapPropertySource {
44
46
super (NAME , getProperties (applicationVersion ));
45
47
}
46
48
49
+ @ Override
50
+ public Origin getOrigin (String key ) {
51
+ return null ;
52
+ }
53
+
54
+ @ Override
55
+ public boolean isImmutable () {
56
+ return true ;
57
+ }
58
+
47
59
private static Map <String , Object > getProperties (String applicationVersion ) {
48
60
Map <String , Object > result = new HashMap <>();
49
61
if (StringUtils .hasText (applicationVersion )) {
You can’t perform that action at this time.
0 commit comments