Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit d6c72bf

Browse files
committed
Merge branch 'ligasgr-feature/webflux'
Polished. resolves springfox#1773
2 parents bd4d703 + e805689 commit d6c72bf

192 files changed

Lines changed: 5394 additions & 935 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

buildSrc/src/main/groovy/springfox/gradlebuild/utils/ProjectDefinitions.groovy

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ import org.gradle.api.Project
2727
class ProjectDefinitions {
2828
static publishables(Project project) {
2929
return project.subprojects.findAll {
30-
!['swagger-contract-tests', 'buildSrc', 'springfox-spring-config'].contains(it.name)
30+
!['swagger-contract-tests', 'swagger-contract-tests-webflux', 'buildSrc', 'springfox-spring-config'].contains(it.name)
3131
}
3232
}
3333
static publishable(Project project) {
34-
!['swagger-contract-tests', 'buildSrc', 'springfox-spring-config'].contains(project.name)
34+
!['swagger-contract-tests', 'swagger-contract-tests-webflux', 'buildSrc', 'springfox-spring-config'].contains(project.name)
3535
}
3636
}

codecov.yml

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,17 @@ parsers:
3131
macro: no
3232

3333
comment:
34-
layout: "header, diff"
34+
layout: "reach, diff, flags, files"
3535
behavior: default
36-
require_changes: no
36+
require_changes: false # if true: only post the comment if coverage changes
37+
require_base: no # [yes :: must have a base report to post]
38+
require_head: yes # [yes :: must have a head report to post]
39+
branches: null
3740

3841
ignore:
3942
- "springfox-petstore" # ignore petstore project as its a sample
43+
- "springfox-petstore-webflux" # ignore petstore project as its a sample
4044
- "springfox-spring-config" # ignore project used for documentation
4145
- "swagger-contract-tests" # ignore contract tests as its purely for testing
46+
- "swagger-contract-tests-webflux" # ignore contract tests as its purely for testing
4247

gradle/dependencies.gradle

Lines changed: 70 additions & 41 deletions
Original file line numberDiff line numberDiff line change
@@ -30,46 +30,75 @@ ext {
3030

3131
libs = [
3232

33-
test : [
34-
"org.springframework:spring-test:${spring}",
35-
"cglib:cglib-nodep:$cglib",
36-
"org.objenesis:objenesis:$objenesis",
37-
"org.mockito:mockito-core:${mockito}",
38-
"com.jayway.jsonpath:json-path:${jsonPath}",
39-
"org.slf4j:slf4j-simple:${slf4j}",
40-
"org.yaml:snakeyaml:${snakeyaml}",
41-
"org.spockframework:spock-spring:${spock}",
42-
"org.spockframework:spock-core:${spock}",
43-
"org.codehaus.groovy:groovy-all:${groovy}",
44-
"org.springframework.hateoas:spring-hateoas:${springHateoas}",
45-
"nl.jqno.equalsverifier:equalsverifier:${equalsverifierVersion}"
46-
],
47-
swagger2Core : [
48-
"io.swagger:swagger-annotations:${swagger2Core}",
49-
"io.swagger:swagger-models:${swagger2Core}"
50-
],
51-
spring : [
52-
"org.springframework.plugin:spring-plugin-core:${springPluginVersion}",
53-
"org.springframework.plugin:spring-plugin-metadata:${springPluginVersion}",
54-
],
55-
springProvided: [
56-
"org.springframework:spring-core:$spring",
57-
"org.springframework:spring-web:$spring",
58-
"org.springframework:spring-webmvc:$spring",
59-
"org.springframework:spring-context:$spring",
60-
],
61-
springBootProvided: [
62-
"org.springframework.boot:spring-boot-autoconfigure:$springBoot"
63-
],
64-
clientProvided: [
65-
"javax.servlet:javax.servlet-api:$servlet",
66-
"com.fasterxml.jackson.core:jackson-core:${jackson}",
67-
"com.fasterxml.jackson.core:jackson-databind:${jackson}",
68-
"joda-time:joda-time:$joda"
69-
],
70-
core : [
71-
"com.fasterxml:classmate:${classmate}",
72-
"org.slf4j:slf4j-api:${slf4j}",
73-
]
33+
test : [
34+
"org.springframework:spring-test:${spring}",
35+
"cglib:cglib-nodep:$cglib",
36+
"org.objenesis:objenesis:$objenesis",
37+
"org.mockito:mockito-core:${mockito}",
38+
"com.jayway.jsonpath:json-path:${jsonPath}",
39+
"org.slf4j:slf4j-simple:${slf4j}",
40+
"org.yaml:snakeyaml:${snakeyaml}",
41+
"org.spockframework:spock-spring:${spock}",
42+
"org.spockframework:spock-core:${spock}",
43+
"org.codehaus.groovy:groovy-all:${groovy}",
44+
"org.springframework.hateoas:spring-hateoas:${springHateoas}",
45+
"nl.jqno.equalsverifier:equalsverifier:${equalsverifierVersion}"
46+
],
47+
testNoHateoas : [
48+
"org.springframework:spring-test:${spring}",
49+
"cglib:cglib-nodep:$cglib",
50+
"org.objenesis:objenesis:$objenesis",
51+
"org.mockito:mockito-core:${mockito}",
52+
"com.jayway.jsonpath:json-path:${jsonPath}",
53+
"org.slf4j:slf4j-simple:${slf4j}",
54+
"org.yaml:snakeyaml:${snakeyaml}",
55+
"org.spockframework:spock-spring:${spock}",
56+
"org.spockframework:spock-core:${spock}",
57+
"org.codehaus.groovy:groovy-all:${groovy}",
58+
"nl.jqno.equalsverifier:equalsverifier:${equalsverifierVersion}"
59+
],
60+
swagger2Core : [
61+
"io.swagger:swagger-annotations:${swagger2Core}",
62+
"io.swagger:swagger-models:${swagger2Core}"
63+
],
64+
spring : [
65+
"org.springframework.plugin:spring-plugin-core:${springPluginVersion}",
66+
"org.springframework.plugin:spring-plugin-metadata:${springPluginVersion}",
67+
],
68+
springProvided : [
69+
"org.springframework:spring-core:$spring",
70+
"org.springframework:spring-web:$spring",
71+
"org.springframework:spring-context:$spring",
72+
],
73+
springProvidedWithMvc : [
74+
"org.springframework:spring-core:$spring",
75+
"org.springframework:spring-web:$spring",
76+
"org.springframework:spring-webmvc:$spring",
77+
"org.springframework:spring-context:$spring",
78+
],
79+
springProvidedWithFlux: [
80+
"org.springframework:spring-core:$spring",
81+
"org.springframework:spring-web:$spring",
82+
"org.springframework:spring-webflux:$spring",
83+
"org.springframework:spring-context:$spring",
84+
],
85+
springBootProvided : [
86+
"org.springframework.boot:spring-boot-autoconfigure:$springBoot"
87+
],
88+
clientProvided : [
89+
"com.fasterxml.jackson.core:jackson-core:${jackson}",
90+
"com.fasterxml.jackson.core:jackson-databind:${jackson}",
91+
"joda-time:joda-time:$joda"
92+
],
93+
clientProvidedServlet : [
94+
"com.fasterxml.jackson.core:jackson-core:${jackson}",
95+
"com.fasterxml.jackson.core:jackson-databind:${jackson}",
96+
"joda-time:joda-time:$joda",
97+
"javax.servlet:javax.servlet-api:$servlet",
98+
],
99+
core : [
100+
"com.fasterxml:classmate:${classmate}",
101+
"org.slf4j:slf4j-api:${slf4j}",
102+
]
74103
]
75104
}

settings.gradle

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,14 +3,18 @@ include 'springfox-core'
33
include 'springfox-spi'
44
include 'springfox-schema'
55
include 'springfox-spring-web'
6+
include 'springfox-spring-webmvc'
7+
include 'springfox-spring-webflux'
68
include 'springfox-swagger-common'
79
include 'springfox-swagger1'
810
include 'springfox-swagger2'
911
include 'springfox-bean-validators'
1012
include 'springfox-data-rest'
1113
include 'springfox-swagger-ui'
1214
include 'springfox-petstore'
15+
include 'springfox-petstore-webflux'
1316

1417
// Auxiliary projects that are not published
1518
include 'springfox-spring-config'
1619
include 'swagger-contract-tests'
20+
include 'swagger-contract-tests-webflux'

springfox-core/build.gradle

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,5 @@ dependencies {
1818
provided libs.clientProvided
1919

2020
testCompile libs.test
21+
testCompile libs.clientProvidedServlet
2122
}

springfox-core/src/main/java/springfox/documentation/PathProvider.java

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -21,12 +21,6 @@
2121

2222
public interface PathProvider {
2323

24-
/**
25-
* Gets the application base path
26-
* @return application base path
27-
*/
28-
String getApplicationBasePath();
29-
3024
/**
3125
* Gets the sanitized and prepended with a "/" operation path
3226
* @param operationPath - raw operation path

springfox-core/src/main/java/springfox/documentation/RequestHandler.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,12 +23,14 @@
2323
import org.springframework.http.MediaType;
2424
import org.springframework.web.bind.annotation.RequestMethod;
2525
import org.springframework.web.method.HandlerMethod;
26-
import org.springframework.web.servlet.mvc.condition.NameValueExpression;
27-
import org.springframework.web.servlet.mvc.condition.PatternsRequestCondition;
28-
import org.springframework.web.servlet.mvc.method.RequestMappingInfo;
26+
2927
import springfox.documentation.annotations.Incubating;
3028
import springfox.documentation.service.ResolvedMethodParameter;
3129

30+
import springfox.documentation.spring.wrapper.NameValueExpression;
31+
import springfox.documentation.spring.wrapper.PatternsRequestCondition;
32+
import springfox.documentation.spring.wrapper.RequestMappingInfo;
33+
3234
import java.lang.annotation.Annotation;
3335
import java.util.Comparator;
3436
import java.util.List;
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
/*
2+
*
3+
* Copyright 2015 the original author or authors.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License");
6+
* you may not use this file except in compliance with the License.
7+
* You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*
17+
*
18+
*/
19+
20+
package springfox.documentation.spring.wrapper;
21+
22+
public interface NameValueExpression<T> {
23+
24+
String getName();
25+
26+
T getValue();
27+
28+
boolean isNegated();
29+
30+
}
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
/*
2+
*
3+
* Copyright 2015 the original author or authors.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License");
6+
* you may not use this file except in compliance with the License.
7+
* You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*
17+
*
18+
*/
19+
20+
package springfox.documentation.spring.wrapper;
21+
22+
import java.util.Set;
23+
24+
public interface PatternsRequestCondition<T> {
25+
PatternsRequestCondition combine(PatternsRequestCondition<T> other);
26+
27+
Set<String> getPatterns();
28+
}
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
/*
2+
*
3+
* Copyright 2015 the original author or authors.
4+
*
5+
* Licensed under the Apache License, Version 2.0 (the "License");
6+
* you may not use this file except in compliance with the License.
7+
* You may obtain a copy of the License at
8+
*
9+
* http://www.apache.org/licenses/LICENSE-2.0
10+
*
11+
* Unless required by applicable law or agreed to in writing, software
12+
* distributed under the License is distributed on an "AS IS" BASIS,
13+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
* See the License for the specific language governing permissions and
15+
* limitations under the License.
16+
*
17+
*
18+
*/
19+
20+
package springfox.documentation.spring.wrapper;
21+
22+
public interface RequestMappingInfo<T> {
23+
T getOriginalInfo();
24+
}

0 commit comments

Comments
 (0)