File tree 3 files changed +58
-1
lines changed
springdoc-openapi-starter-common/src/main/java/org/springdoc/core/configuration
springdoc-openapi-starter-webmvc-api/src/test
java/test/org/springdoc/api/v31/app129
3 files changed +58
-1
lines changed Original file line number Diff line number Diff line change 34
34
import java .util .Map ;
35
35
import java .util .Optional ;
36
36
import java .util .Set ;
37
+ import java .util .concurrent .Future ;
37
38
38
39
import com .fasterxml .jackson .databind .node .ObjectNode ;
39
40
import com .querydsl .core .types .Predicate ;
@@ -153,7 +154,8 @@ public class SpringDocConfiguration {
153
154
static {
154
155
getConfig ().replaceWithSchema (ObjectNode .class , new ObjectSchema ())
155
156
.replaceWithClass (Charset .class , String .class )
156
- .addResponseWrapperToIgnore (DeferredResult .class );
157
+ .addResponseWrapperToIgnore (DeferredResult .class )
158
+ .addResponseWrapperToIgnore (Future .class );
157
159
}
158
160
159
161
/**
Original file line number Diff line number Diff line change 24
24
25
25
package test .org .springdoc .api .v31 .app129 ;
26
26
27
+ import java .util .concurrent .CompletableFuture ;
28
+
27
29
import io .swagger .v3 .oas .annotations .responses .ApiResponse ;
28
30
import io .swagger .v3 .oas .annotations .responses .ApiResponses ;
29
31
@@ -43,4 +45,11 @@ public DeferredResult<OperationResponse<ActualReturnedEntity>> update(
43
45
@ RequestBody ActualReturnedEntity entity ) throws Exception {
44
46
return null ;
45
47
}
48
+
49
+ @ PostMapping ("/test2" )
50
+ @ ApiResponses ({ @ ApiResponse (responseCode = "200" ) })
51
+ public CompletableFuture <OperationResponse <ActualReturnedEntity >> update2 (
52
+ @ RequestBody ActualReturnedEntity entity ) throws Exception {
53
+ return null ;
54
+ }
46
55
}
Original file line number Diff line number Diff line change 56
56
}
57
57
}
58
58
}
59
+ },
60
+ "/api/test2" : {
61
+ "post" : {
62
+ "tags" : [
63
+ " hello-controller"
64
+ ],
65
+ "operationId" : " update2" ,
66
+ "parameters" : [
67
+ {
68
+ "name" : " userId" ,
69
+ "in" : " header" ,
70
+ "schema" : {
71
+ "type" : " string"
72
+ }
73
+ },
74
+ {
75
+ "name" : " registrationId" ,
76
+ "in" : " header" ,
77
+ "schema" : {
78
+ "type" : " string"
79
+ }
80
+ }
81
+ ],
82
+ "requestBody" : {
83
+ "content" : {
84
+ "application/json" : {
85
+ "schema" : {
86
+ "$ref" : " #/components/schemas/ActualReturnedEntity"
87
+ }
88
+ }
89
+ },
90
+ "required" : true
91
+ },
92
+ "responses" : {
93
+ "200" : {
94
+ "description" : " OK" ,
95
+ "content" : {
96
+ "*/*" : {
97
+ "schema" : {
98
+ "$ref" : " #/components/schemas/OperationResponseActualReturnedEntity"
99
+ }
100
+ }
101
+ }
102
+ }
103
+ }
104
+ }
59
105
}
60
106
},
61
107
"components" : {
You can’t perform that action at this time.
0 commit comments