Commit ea3fd92
committed
Add compatibility for MongoConnectionDetails.getSslBundle method
Add reflective check for the getSslBundle method in MongoConnectionDetails interface
to ensure compatibility between Spring Boot 3.4.x and 3.5.x. The method exists in
Spring Boot 3.5 but not in 3.4, and our code needs to work with both versions.
The implementation uses ReflectionUtils to check for the method's existence at runtime
and invokes it only when available (Spring Boot 3.5+), falling back to returning
null when using Spring Boot 3.4.
Signed-off-by: Soby Chacko <[email protected]>1 parent 15a5069 commit ea3fd92
File tree
1 file changed
+20
-1
lines changed- spring-ai-spring-boot-testcontainers/src/main/java/org/springframework/ai/testcontainers/service/connection/mongo
1 file changed
+20
-1
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
2 | | - | |
| 2 | + | |
3 | 3 | | |
4 | 4 | | |
5 | 5 | | |
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
| 20 | + | |
19 | 21 | | |
20 | 22 | | |
21 | 23 | | |
22 | 24 | | |
| 25 | + | |
23 | 26 | | |
24 | 27 | | |
| 28 | + | |
25 | 29 | | |
26 | 30 | | |
27 | 31 | | |
| |||
36 | 40 | | |
37 | 41 | | |
38 | 42 | | |
| 43 | + | |
39 | 44 | | |
40 | 45 | | |
41 | 46 | | |
| |||
44 | 49 | | |
45 | 50 | | |
46 | 51 | | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
47 | 58 | | |
48 | 59 | | |
49 | 60 | | |
| |||
66 | 77 | | |
67 | 78 | | |
68 | 79 | | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
69 | 88 | | |
70 | 89 | | |
71 | 90 | | |
0 commit comments