Skip to content

Commit eae8120

Browse files
committed
Use gradle 5.6.4 instead of 6.0.1
1 parent f2bb4e0 commit eae8120

File tree

3 files changed

+119
-116
lines changed

3 files changed

+119
-116
lines changed

gradle.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,4 @@ LIB_JACKSON_VER = 2.10.0
1515
SOURCE_COMPATIBILITY = 1.8
1616
TARGET_COMPATIBILITY = 1.8
1717

18-
GRADLE_WRAPPER_VER = 6.0.1
18+
GRADLE_WRAPPER_VER = 5.6.4

gradle/wrapper/gradle-wrapper.properties

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
#Thu Nov 14 18:53:34 CET 2019
2-
distributionUrl=https\://services.gradle.org/distributions/gradle-6.0.1-all.zip
2+
distributionUrl=https\://services.gradle.org/distributions/gradle-5.6.4-all.zip
33
distributionBase=GRADLE_USER_HOME
44
distributionPath=wrapper/dists
55
zipStorePath=wrapper/dists
Lines changed: 117 additions & 114 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,11 @@
11
package graphql.servlet;
22

3-
import graphql.schema.GraphQLSchema;
43
import graphql.kickstart.execution.GraphQLObjectMapper;
54
import graphql.kickstart.execution.GraphQLQueryInvoker;
6-
import graphql.kickstart.execution.config.GraphQLSchemaProvider;
5+
import graphql.schema.GraphQLSchema;
76
import graphql.servlet.config.GraphQLSchemaServletProvider;
87
import graphql.servlet.core.GraphQLServletListener;
98
import graphql.servlet.input.GraphQLInvocationInputFactory;
10-
119
import java.util.ArrayList;
1210
import java.util.List;
1311
import java.util.Objects;
@@ -17,128 +15,133 @@
1715
*/
1816
public class SimpleGraphQLHttpServlet extends AbstractGraphQLHttpServlet {
1917

20-
private GraphQLConfiguration configuration;
21-
22-
public SimpleGraphQLHttpServlet() {
23-
}
24-
25-
/**
26-
* @deprecated use {@link GraphQLHttpServlet} instead
27-
*/
28-
@Deprecated
29-
public SimpleGraphQLHttpServlet(GraphQLInvocationInputFactory invocationInputFactory, GraphQLQueryInvoker queryInvoker, GraphQLObjectMapper graphQLObjectMapper, List<GraphQLServletListener> listeners, boolean asyncServletMode) {
30-
super(listeners);
31-
this.configuration = GraphQLConfiguration.with(invocationInputFactory)
32-
.with(queryInvoker)
33-
.with(graphQLObjectMapper)
34-
.with(listeners != null ? listeners : new ArrayList<>())
35-
.with(asyncServletMode)
36-
.build();
37-
}
38-
39-
/**
40-
* @deprecated use {@link GraphQLHttpServlet} instead
41-
*/
42-
@Deprecated
43-
public SimpleGraphQLHttpServlet(GraphQLInvocationInputFactory invocationInputFactory, GraphQLQueryInvoker queryInvoker, GraphQLObjectMapper graphQLObjectMapper, List<GraphQLServletListener> listeners, boolean asyncServletMode, long subscriptionTimeout) {
44-
super(listeners);
45-
this.configuration = GraphQLConfiguration.with(invocationInputFactory)
46-
.with(queryInvoker)
47-
.with(graphQLObjectMapper)
48-
.with(listeners != null ? listeners : new ArrayList<>())
49-
.with(asyncServletMode)
50-
.with(subscriptionTimeout)
51-
.build();
18+
private GraphQLConfiguration configuration;
19+
20+
public SimpleGraphQLHttpServlet() {
21+
}
22+
23+
/**
24+
* @deprecated use {@link GraphQLHttpServlet} instead
25+
*/
26+
@Deprecated
27+
public SimpleGraphQLHttpServlet(GraphQLInvocationInputFactory invocationInputFactory,
28+
GraphQLQueryInvoker queryInvoker, GraphQLObjectMapper graphQLObjectMapper, List<GraphQLServletListener> listeners,
29+
boolean asyncServletMode) {
30+
super(listeners);
31+
this.configuration = GraphQLConfiguration.with(invocationInputFactory)
32+
.with(queryInvoker)
33+
.with(graphQLObjectMapper)
34+
.with(listeners != null ? listeners : new ArrayList<>())
35+
.with(asyncServletMode)
36+
.build();
37+
}
38+
39+
/**
40+
* @deprecated use {@link GraphQLHttpServlet} instead
41+
*/
42+
@Deprecated
43+
public SimpleGraphQLHttpServlet(GraphQLInvocationInputFactory invocationInputFactory,
44+
GraphQLQueryInvoker queryInvoker, GraphQLObjectMapper graphQLObjectMapper, List<GraphQLServletListener> listeners,
45+
boolean asyncServletMode, long subscriptionTimeout) {
46+
super(listeners);
47+
this.configuration = GraphQLConfiguration.with(invocationInputFactory)
48+
.with(queryInvoker)
49+
.with(graphQLObjectMapper)
50+
.with(listeners != null ? listeners : new ArrayList<>())
51+
.with(asyncServletMode)
52+
.with(subscriptionTimeout)
53+
.build();
54+
}
55+
56+
private SimpleGraphQLHttpServlet(GraphQLConfiguration configuration) {
57+
this.configuration = Objects.requireNonNull(configuration, "configuration is required");
58+
}
59+
60+
public static Builder newBuilder(GraphQLSchema schema) {
61+
return new Builder(GraphQLInvocationInputFactory.newBuilder(schema).build());
62+
}
63+
64+
public static Builder newBuilder(GraphQLSchemaServletProvider schemaProvider) {
65+
return new Builder(GraphQLInvocationInputFactory.newBuilder(schemaProvider).build());
66+
}
67+
68+
public static Builder newBuilder(GraphQLInvocationInputFactory invocationInputFactory) {
69+
return new Builder(invocationInputFactory);
70+
}
71+
72+
@Override
73+
protected GraphQLConfiguration getConfiguration() {
74+
return configuration;
75+
}
76+
77+
@Override
78+
protected GraphQLQueryInvoker getQueryInvoker() {
79+
return configuration.getQueryInvoker();
80+
}
81+
82+
@Override
83+
protected GraphQLInvocationInputFactory getInvocationInputFactory() {
84+
return configuration.getInvocationInputFactory();
85+
}
86+
87+
@Override
88+
protected GraphQLObjectMapper getGraphQLObjectMapper() {
89+
return configuration.getObjectMapper();
90+
}
91+
92+
@Override
93+
protected boolean isAsyncServletMode() {
94+
return configuration.isAsyncServletModeEnabled();
95+
}
96+
97+
public static class Builder {
98+
99+
private final GraphQLInvocationInputFactory invocationInputFactory;
100+
private GraphQLQueryInvoker queryInvoker = GraphQLQueryInvoker.newBuilder().build();
101+
private GraphQLObjectMapper graphQLObjectMapper = GraphQLObjectMapper.newBuilder().build();
102+
private List<GraphQLServletListener> listeners;
103+
private boolean asyncServletMode;
104+
private long subscriptionTimeout;
105+
106+
Builder(GraphQLInvocationInputFactory invocationInputFactory) {
107+
this.invocationInputFactory = invocationInputFactory;
52108
}
53109

54-
private SimpleGraphQLHttpServlet(GraphQLConfiguration configuration) {
55-
this.configuration = Objects.requireNonNull(configuration, "configuration is required");
110+
public Builder withQueryInvoker(GraphQLQueryInvoker queryInvoker) {
111+
this.queryInvoker = queryInvoker;
112+
return this;
56113
}
57114

58-
@Override
59-
protected GraphQLConfiguration getConfiguration() {
60-
return configuration;
115+
public Builder withObjectMapper(GraphQLObjectMapper objectMapper) {
116+
this.graphQLObjectMapper = objectMapper;
117+
return this;
61118
}
62119

63-
@Override
64-
protected GraphQLQueryInvoker getQueryInvoker() {
65-
return configuration.getQueryInvoker();
120+
public Builder withAsyncServletMode(boolean asyncServletMode) {
121+
this.asyncServletMode = asyncServletMode;
122+
return this;
66123
}
67124

68-
@Override
69-
protected GraphQLInvocationInputFactory getInvocationInputFactory() {
70-
return configuration.getInvocationInputFactory();
125+
public Builder withListeners(List<GraphQLServletListener> listeners) {
126+
this.listeners = listeners;
127+
return this;
71128
}
72129

73-
@Override
74-
protected GraphQLObjectMapper getGraphQLObjectMapper() {
75-
return configuration.getObjectMapper();
130+
public Builder withSubscriptionTimeout(long subscriptionTimeout) {
131+
this.subscriptionTimeout = subscriptionTimeout;
132+
return this;
76133
}
77134

78-
@Override
79-
protected boolean isAsyncServletMode() {
80-
return configuration.isAsyncServletModeEnabled();
81-
}
82-
83-
public static Builder newBuilder(GraphQLSchema schema) {
84-
return new Builder(GraphQLInvocationInputFactory.newBuilder(schema).build());
85-
}
86-
87-
public static Builder newBuilder(GraphQLSchemaServletProvider schemaProvider) {
88-
return new Builder(GraphQLInvocationInputFactory.newBuilder(schemaProvider).build());
89-
}
90-
91-
public static Builder newBuilder(GraphQLInvocationInputFactory invocationInputFactory) {
92-
return new Builder(invocationInputFactory);
93-
}
94-
95-
public static class Builder {
96-
private final GraphQLInvocationInputFactory invocationInputFactory;
97-
private GraphQLQueryInvoker queryInvoker = GraphQLQueryInvoker.newBuilder().build();
98-
private GraphQLObjectMapper graphQLObjectMapper = GraphQLObjectMapper.newBuilder().build();
99-
private List<GraphQLServletListener> listeners;
100-
private boolean asyncServletMode;
101-
private long subscriptionTimeout;
102-
103-
Builder(GraphQLInvocationInputFactory invocationInputFactory) {
104-
this.invocationInputFactory = invocationInputFactory;
105-
}
106-
107-
public Builder withQueryInvoker(GraphQLQueryInvoker queryInvoker) {
108-
this.queryInvoker = queryInvoker;
109-
return this;
110-
}
111-
112-
public Builder withObjectMapper(GraphQLObjectMapper objectMapper) {
113-
this.graphQLObjectMapper = objectMapper;
114-
return this;
115-
}
116-
117-
public Builder withAsyncServletMode(boolean asyncServletMode) {
118-
this.asyncServletMode = asyncServletMode;
119-
return this;
120-
}
121-
122-
public Builder withListeners(List<GraphQLServletListener> listeners) {
123-
this.listeners = listeners;
124-
return this;
125-
}
126-
127-
public Builder withSubscriptionTimeout(long subscriptionTimeout) {
128-
this.subscriptionTimeout = subscriptionTimeout;
129-
return this;
130-
}
131-
132-
@Deprecated
133-
public SimpleGraphQLHttpServlet build() {
134-
GraphQLConfiguration configuration = GraphQLConfiguration.with(invocationInputFactory)
135-
.with(queryInvoker)
136-
.with(graphQLObjectMapper)
137-
.with(listeners != null ? listeners : new ArrayList<>())
138-
.with(asyncServletMode)
139-
.with(subscriptionTimeout)
140-
.build();
141-
return new SimpleGraphQLHttpServlet(configuration);
142-
}
135+
@Deprecated
136+
public SimpleGraphQLHttpServlet build() {
137+
GraphQLConfiguration configuration = GraphQLConfiguration.with(invocationInputFactory)
138+
.with(queryInvoker)
139+
.with(graphQLObjectMapper)
140+
.with(listeners != null ? listeners : new ArrayList<>())
141+
.with(asyncServletMode)
142+
.with(subscriptionTimeout)
143+
.build();
144+
return new SimpleGraphQLHttpServlet(configuration);
143145
}
146+
}
144147
}

0 commit comments

Comments
 (0)