language stringclasses 1
value | owner stringlengths 2 15 | repo stringlengths 2 21 | sha stringlengths 45 45 | message stringlengths 7 36.3k | path stringlengths 1 199 | patch stringlengths 15 102k | is_multipart bool 2
classes |
|---|---|---|---|---|---|---|---|
Other | spring-projects | spring-framework | 1fb0b0b78609e5d201d90062149697e68722612a.json | Expose remoteAddress from ServerHttpRequest
Issue: SPR-15200 | spring-web/src/main/java/org/springframework/http/server/reactive/UndertowServerHttpRequest.java | @@ -17,9 +17,11 @@
package org.springframework.http.server.reactive;
import java.io.IOException;
+import java.net.InetSocketAddress;
import java.net.URI;
import java.net.URISyntaxException;
import java.nio.ByteBuffer;
+import java.util.Optional;
import io.undertow.connector.ByteBufferPool;
import io.undertow... | true |
Other | spring-projects | spring-framework | 1fb0b0b78609e5d201d90062149697e68722612a.json | Expose remoteAddress from ServerHttpRequest
Issue: SPR-15200 | spring-web/src/test/java/org/springframework/http/server/reactive/ServerHttpRequestIntegrationTests.java | @@ -48,10 +48,11 @@ public static class CheckRequestHandler implements HttpHandler {
@Override
public Mono<Void> handle(ServerHttpRequest request, ServerHttpResponse response) {
URI uri = request.getURI();
- assertNotNull("Request URI host must not be null", uri.getHost());
- assertNotEquals("Request URI ... | true |
Other | spring-projects | spring-framework | 1fb0b0b78609e5d201d90062149697e68722612a.json | Expose remoteAddress from ServerHttpRequest
Issue: SPR-15200 | spring-web/src/test/java/org/springframework/mock/http/server/reactive/test/MockServerHttpRequest.java | @@ -15,12 +15,14 @@
*/
package org.springframework.mock.http.server.reactive.test;
+import java.net.InetSocketAddress;
import java.net.URI;
import java.nio.ByteBuffer;
import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
import java.util.Arrays;
import java.util.List;
+import java.util.... | true |
Other | spring-projects | spring-framework | 9142427c4d898db174aa895494269ff6d2372556.json | Add committed flag to ReactiveHttpOutputMessage
Issue: SPR-15135 | spring-web/src/main/java/org/springframework/http/ReactiveHttpOutputMessage.java | @@ -27,8 +27,8 @@
/**
* A "reactive" HTTP output message that accepts output as a {@link Publisher}.
*
- * <p>Typically implemented by an HTTP request on the client-side or a response
- * on the server-side.
+ * <p>Typically implemented by an HTTP request on the client-side or an
+ * HTTP response on the server-si... | true |
Other | spring-projects | spring-framework | 9142427c4d898db174aa895494269ff6d2372556.json | Add committed flag to ReactiveHttpOutputMessage
Issue: SPR-15135 | spring-web/src/main/java/org/springframework/http/client/reactive/AbstractClientHttpRequest.java | @@ -86,12 +86,23 @@ public MultiValueMap<String, HttpCookie> getCookies() {
return this.cookies;
}
+ @Override
+ public void beforeCommit(Supplier<? extends Mono<Void>> action) {
+ Assert.notNull(action, "Action must not be null");
+ this.commitActions.add(action);
+ }
+
+ @Override
+ public boolean isCommitte... | true |
Other | spring-projects | spring-framework | 9142427c4d898db174aa895494269ff6d2372556.json | Add committed flag to ReactiveHttpOutputMessage
Issue: SPR-15135 | spring-web/src/main/java/org/springframework/http/server/reactive/AbstractServerHttpResponse.java | @@ -54,7 +54,7 @@ public abstract class AbstractServerHttpResponse implements ServerHttpResponse {
* response during which time pre-commit actions can still make changes to
* the response status and headers.
*/
- private enum State {NEW, COMMITTING, COMMITTED};
+ private enum State {NEW, COMMITTING, COMMITTED}... | true |
Other | spring-projects | spring-framework | 9142427c4d898db174aa895494269ff6d2372556.json | Add committed flag to ReactiveHttpOutputMessage
Issue: SPR-15135 | spring-web/src/main/java/org/springframework/http/server/reactive/ServerHttpResponseDecorator.java | @@ -94,6 +94,11 @@ public void beforeCommit(Supplier<? extends Mono<Void>> action) {
getDelegate().beforeCommit(action);
}
+ @Override
+ public boolean isCommitted() {
+ return getDelegate().isCommitted();
+ }
+
@Override
public Mono<Void> writeWith(Publisher<? extends DataBuffer> body) {
return getDeleg... | true |
Other | spring-projects | spring-framework | f2fa74055ea3a81246c94d4d60b28f1b6d41f216.json | Fix missing uriVariables | spring-web-reactive/src/main/java/org/springframework/web/reactive/function/client/DefaultWebClientOperations.java | @@ -129,7 +129,7 @@ public HeaderSpec uri(URI uri) {
@Override
public HeaderSpec uri(String uriTemplate, Object... uriVariables) {
- return uri(getUriBuilderFactory().expand(uriTemplate));
+ return uri(getUriBuilderFactory().expand(uriTemplate, uriVariables));
}
@Override | false |
Other | spring-projects | spring-framework | cd476832cc23e9b52b7d3d7d194ff9e33b734224.json | Add check for Long.MAX_VALUE
Issue: SPR-15203 | spring-web/src/main/java/org/springframework/http/server/reactive/AbstractListenerReadPublisher.java | @@ -116,10 +116,13 @@ public final void onError(Throwable t) {
* @return {@code true} if there is more demand; {@code false} otherwise
*/
private boolean readAndPublish() throws IOException {
- while (hasDemand()) {
+ long r;
+ while ((r = demand) > 0) {
T data = read();
if (data != null) {
- Oper... | false |
Other | spring-projects | spring-framework | 69c16f3821354c9b0732687825cb902375649c5a.json | Add headers in InterceptingClientHttpRequest
This commit *adds* the "intercepted" headers to the ClientHttpRequest,
as opposed to replacing them, which is what happened before this commit.
Issue: SPR-15166 | spring-core/src/main/java/org/springframework/util/CollectionUtils.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -406,14 +406,16 @@ public MultiValueMapAdapt... | true |
Other | spring-projects | spring-framework | 69c16f3821354c9b0732687825cb902375649c5a.json | Add headers in InterceptingClientHttpRequest
This commit *adds* the "intercepted" headers to the ClientHttpRequest,
as opposed to replacing them, which is what happened before this commit.
Issue: SPR-15166 | spring-core/src/main/java/org/springframework/util/LinkedMultiValueMap.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -75,14 +75,16 @@ public LinkedMultiValueMap(... | true |
Other | spring-projects | spring-framework | 69c16f3821354c9b0732687825cb902375649c5a.json | Add headers in InterceptingClientHttpRequest
This commit *adds* the "intercepted" headers to the ClientHttpRequest,
as opposed to replacing them, which is what happened before this commit.
Issue: SPR-15166 | spring-core/src/main/java/org/springframework/util/MultiValueMap.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2012 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -41,6 +41,13 @@
*/
void add(K key, V va... | true |
Other | spring-projects | spring-framework | 69c16f3821354c9b0732687825cb902375649c5a.json | Add headers in InterceptingClientHttpRequest
This commit *adds* the "intercepted" headers to the ClientHttpRequest,
as opposed to replacing them, which is what happened before this commit.
Issue: SPR-15166 | spring-core/src/test/java/org/springframework/util/LinkedMultiValueMapTests.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -17,6 +17,7 @@
package org.springframework.... | true |
Other | spring-projects | spring-framework | 69c16f3821354c9b0732687825cb902375649c5a.json | Add headers in InterceptingClientHttpRequest
This commit *adds* the "intercepted" headers to the ClientHttpRequest,
as opposed to replacing them, which is what happened before this commit.
Issue: SPR-15166 | spring-messaging/src/main/java/org/springframework/messaging/simp/stomp/StompHeaders.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -397,14 +397,16 @@ public String getFirst(St... | true |
Other | spring-projects | spring-framework | 69c16f3821354c9b0732687825cb902375649c5a.json | Add headers in InterceptingClientHttpRequest
This commit *adds* the "intercepted" headers to the ClientHttpRequest,
as opposed to replacing them, which is what happened before this commit.
Issue: SPR-15166 | spring-web/src/main/java/org/springframework/http/HttpHeaders.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -1333,14 +1333,17 @@ public String getFirst(... | true |
Other | spring-projects | spring-framework | 69c16f3821354c9b0732687825cb902375649c5a.json | Add headers in InterceptingClientHttpRequest
This commit *adds* the "intercepted" headers to the ClientHttpRequest,
as opposed to replacing them, which is what happened before this commit.
Issue: SPR-15166 | spring-web/src/main/java/org/springframework/http/client/InterceptingClientHttpRequest.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2015 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -20,6 +20,7 @@
import java.net.URI;
import... | true |
Other | spring-projects | spring-framework | b487ed6748a0cdf68dc0e20ee5733d56a1f711f2.json | Fix trailing slash issue
Issue: SPR-15201 | spring-web/src/main/java/org/springframework/web/util/DefaultUriBuilderFactory.java | @@ -48,6 +48,8 @@ public enum EncodingMode {URI_COMPONENT, VALUES_ONLY, NONE };
private EncodingMode encodingMode = EncodingMode.URI_COMPONENT;
+ private boolean parsePath = true;
+
/**
* Default constructor without a base URI.
@@ -126,6 +128,28 @@ public EncodingMode getEncodingMode() {
return this.enc... | true |
Other | spring-projects | spring-framework | b487ed6748a0cdf68dc0e20ee5733d56a1f711f2.json | Fix trailing slash issue
Issue: SPR-15201 | spring-web/src/test/java/org/springframework/web/client/RestTemplateTests.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -153,6 +153,21 @@ public void mapNullTemplat... | true |
Other | spring-projects | spring-framework | b487ed6748a0cdf68dc0e20ee5733d56a1f711f2.json | Fix trailing slash issue
Issue: SPR-15201 | spring-web/src/test/java/org/springframework/web/util/DefaultUriBuilderFactoryTests.java | @@ -127,10 +127,32 @@ public void encodingNone() throws Exception {
}
@Test
- public void initialPathSplitIntoPathSegments() throws Exception {
+ public void parsePathWithDefaultSettings() throws Exception {
DefaultUriBuilderFactory factory = new DefaultUriBuilderFactory("/foo/{bar}");
URI uri = factory.uri... | true |
Other | spring-projects | spring-framework | 7b67b5bc2a3443026e92af28275d176648353110.json | Introduce UriBuilderFactory and UriBuilder
Issue: SPR-15124 | spring-web/src/main/java/org/springframework/web/util/DefaultUriBuilderFactory.java | @@ -0,0 +1,299 @@
+/*
+ * Copyright 2002-2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+... | true |
Other | spring-projects | spring-framework | 7b67b5bc2a3443026e92af28275d176648353110.json | Introduce UriBuilderFactory and UriBuilder
Issue: SPR-15124 | spring-web/src/main/java/org/springframework/web/util/HierarchicalUriComponents.java | @@ -446,14 +446,27 @@ public URI toUri() {
@Override
protected void copyToUriComponentsBuilder(UriComponentsBuilder builder) {
- builder.scheme(getScheme());
- builder.userInfo(getUserInfo());
- builder.host(getHost());
- builder.port(getPort());
- builder.replacePath("");
- this.path.copyToUriComponentsBui... | true |
Other | spring-projects | spring-framework | 7b67b5bc2a3443026e92af28275d176648353110.json | Introduce UriBuilderFactory and UriBuilder
Issue: SPR-15124 | spring-web/src/main/java/org/springframework/web/util/OpaqueUriComponents.java | @@ -137,9 +137,15 @@ public URI toUri() {
@Override
protected void copyToUriComponentsBuilder(UriComponentsBuilder builder) {
- builder.scheme(getScheme());
- builder.schemeSpecificPart(getSchemeSpecificPart());
- builder.fragment(getFragment());
+ if (getScheme() != null) {
+ builder.scheme(getScheme());
+... | true |
Other | spring-projects | spring-framework | 7b67b5bc2a3443026e92af28275d176648353110.json | Introduce UriBuilderFactory and UriBuilder
Issue: SPR-15124 | spring-web/src/main/java/org/springframework/web/util/UriBuilder.java | @@ -0,0 +1,171 @@
+/*
+ * Copyright 2002-2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+... | true |
Other | spring-projects | spring-framework | 7b67b5bc2a3443026e92af28275d176648353110.json | Introduce UriBuilderFactory and UriBuilder
Issue: SPR-15124 | spring-web/src/main/java/org/springframework/web/util/UriBuilderFactory.java | @@ -0,0 +1,43 @@
+/*
+ * Copyright 2002-2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ ... | true |
Other | spring-projects | spring-framework | 7b67b5bc2a3443026e92af28275d176648353110.json | Introduce UriBuilderFactory and UriBuilder
Issue: SPR-15124 | spring-web/src/main/java/org/springframework/web/util/UriComponentsBuilder.java | @@ -57,7 +57,7 @@
* @see #fromPath(String)
* @see #fromUri(URI)
*/
-public class UriComponentsBuilder implements Cloneable {
+public class UriComponentsBuilder implements UriBuilder, Cloneable {
private static final Pattern QUERY_PARAM_PATTERN = Pattern.compile("([^&=]+)(=?)([^&]+)?");
@@ -360,6 +360,30 @@ ... | true |
Other | spring-projects | spring-framework | 7b67b5bc2a3443026e92af28275d176648353110.json | Introduce UriBuilderFactory and UriBuilder
Issue: SPR-15124 | spring-web/src/test/java/org/springframework/web/util/DefaultUriBuilderFactoryTests.java | @@ -0,0 +1,114 @@
+/*
+ * Copyright 2002-2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+... | true |
Other | spring-projects | spring-framework | 944d17f23773d179b1d788507e8d27ad26777d71.json | Harmonize Tomcat dependencies
Use `tomcat-embed-core` instead of `tomcat-catalina`
for tomcat internal classes. | build.gradle | @@ -748,7 +748,7 @@ project("spring-web") {
optional("io.reactivex:rxjava:${rxjavaVersion}")
optional "io.reactivex.rxjava2:rxjava:${rxjava2Version}"
optional("io.reactivex:rxjava-reactive-streams:${rxjavaAdapterVersion}")
- optional("org.apache.tomcat:tomcat-catalina:${tomcatVersion}")
+ optional("org.apach... | false |
Other | spring-projects | spring-framework | 383375c35f12ff4aec67560b77e00f332b54a36c.json | Use separate reactive HttpHandler for Tomcat/Jetty
Introduce separate adapters TomcatHttpHandlerAdapter/JettyHttpHandlerAdapter
so that each adapter can use the Tomcat/Jetty APIs for reading/writing
with ByteBuffer. | build.gradle | @@ -779,6 +779,7 @@ project("spring-web") {
optional("javax.xml.ws:jaxws-api:${jaxwsVersion}")
optional("javax.mail:javax.mail-api:${javamailVersion}")
optional("org.jetbrains.kotlin:kotlin-stdlib:${kotlinVersion}")
+ optional("org.apache.tomcat:tomcat-catalina:${tomcatVersion}")
testCompile(project(":spri... | true |
Other | spring-projects | spring-framework | 383375c35f12ff4aec67560b77e00f332b54a36c.json | Use separate reactive HttpHandler for Tomcat/Jetty
Introduce separate adapters TomcatHttpHandlerAdapter/JettyHttpHandlerAdapter
so that each adapter can use the Tomcat/Jetty APIs for reading/writing
with ByteBuffer. | spring-web/src/main/java/org/springframework/http/server/reactive/JettyHttpHandlerAdapter.java | @@ -0,0 +1,80 @@
+/*
+ * Copyright 2002-2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ ... | true |
Other | spring-projects | spring-framework | 383375c35f12ff4aec67560b77e00f332b54a36c.json | Use separate reactive HttpHandler for Tomcat/Jetty
Introduce separate adapters TomcatHttpHandlerAdapter/JettyHttpHandlerAdapter
so that each adapter can use the Tomcat/Jetty APIs for reading/writing
with ByteBuffer. | spring-web/src/main/java/org/springframework/http/server/reactive/ServletHttpHandlerAdapter.java | @@ -98,16 +98,28 @@ public void service(ServletRequest request, ServletResponse response) throws IOE
// Start async before Read/WriteListener registration
AsyncContext asyncContext = request.startAsync();
- ServerHttpRequest httpRequest = new ServletServerHttpRequest(
- ((HttpServletRequest) request), async... | true |
Other | spring-projects | spring-framework | 383375c35f12ff4aec67560b77e00f332b54a36c.json | Use separate reactive HttpHandler for Tomcat/Jetty
Introduce separate adapters TomcatHttpHandlerAdapter/JettyHttpHandlerAdapter
so that each adapter can use the Tomcat/Jetty APIs for reading/writing
with ByteBuffer. | spring-web/src/main/java/org/springframework/http/server/reactive/ServletServerHttpRequest.java | @@ -32,6 +32,8 @@
import reactor.core.publisher.Flux;
+import org.apache.commons.logging.Log;
+import org.apache.commons.logging.LogFactory;
import org.springframework.core.io.buffer.DataBuffer;
import org.springframework.core.io.buffer.DataBufferFactory;
import org.springframework.http.HttpCookie;
@@ -58,6 +60... | true |
Other | spring-projects | spring-framework | 383375c35f12ff4aec67560b77e00f332b54a36c.json | Use separate reactive HttpHandler for Tomcat/Jetty
Introduce separate adapters TomcatHttpHandlerAdapter/JettyHttpHandlerAdapter
so that each adapter can use the Tomcat/Jetty APIs for reading/writing
with ByteBuffer. | spring-web/src/main/java/org/springframework/http/server/reactive/ServletServerHttpResponse.java | @@ -132,6 +132,19 @@ protected Processor<? super Publisher<? extends DataBuffer>, Void> createBodyFlu
return processor;
}
+ protected int writeDataBuffer(DataBuffer dataBuffer) throws IOException {
+ ServletOutputStream outputStream = response.getOutputStream();
+ InputStream input = dataBuffer.asInputStream()... | true |
Other | spring-projects | spring-framework | 383375c35f12ff4aec67560b77e00f332b54a36c.json | Use separate reactive HttpHandler for Tomcat/Jetty
Introduce separate adapters TomcatHttpHandlerAdapter/JettyHttpHandlerAdapter
so that each adapter can use the Tomcat/Jetty APIs for reading/writing
with ByteBuffer. | spring-web/src/main/java/org/springframework/http/server/reactive/TomcatHttpHandlerAdapter.java | @@ -0,0 +1,117 @@
+/*
+ * Copyright 2002-2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+... | true |
Other | spring-projects | spring-framework | 383375c35f12ff4aec67560b77e00f332b54a36c.json | Use separate reactive HttpHandler for Tomcat/Jetty
Introduce separate adapters TomcatHttpHandlerAdapter/JettyHttpHandlerAdapter
so that each adapter can use the Tomcat/Jetty APIs for reading/writing
with ByteBuffer. | spring-web/src/test/java/org/springframework/http/server/reactive/bootstrap/JettyHttpServer.java | @@ -22,6 +22,7 @@
import org.eclipse.jetty.servlet.ServletHolder;
import org.springframework.beans.factory.InitializingBean;
+import org.springframework.http.server.reactive.JettyHttpHandlerAdapter;
import org.springframework.http.server.reactive.ServletHttpHandlerAdapter;
import org.springframework.util.Assert;
... | true |
Other | spring-projects | spring-framework | 383375c35f12ff4aec67560b77e00f332b54a36c.json | Use separate reactive HttpHandler for Tomcat/Jetty
Introduce separate adapters TomcatHttpHandlerAdapter/JettyHttpHandlerAdapter
so that each adapter can use the Tomcat/Jetty APIs for reading/writing
with ByteBuffer. | spring-web/src/test/java/org/springframework/http/server/reactive/bootstrap/TomcatHttpServer.java | @@ -24,6 +24,7 @@
import org.springframework.beans.factory.InitializingBean;
import org.springframework.http.server.reactive.ServletHttpHandlerAdapter;
+import org.springframework.http.server.reactive.TomcatHttpHandlerAdapter;
import org.springframework.util.Assert;
/**
@@ -75,11 +76,11 @@ public void afterProp... | true |
Other | spring-projects | spring-framework | eabd8a2964e84eba7bff9d6a50269d15a1f87d1f.json | Support Servlet Part in Spring MVC Test
Issue: SPR-14253 | spring-test/src/main/java/org/springframework/test/web/servlet/request/MockMultipartHttpServletRequestBuilder.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -18,14 +18,20 @@
import java.net.URI;
im... | true |
Other | spring-projects | spring-framework | eabd8a2964e84eba7bff9d6a50269d15a1f87d1f.json | Support Servlet Part in Spring MVC Test
Issue: SPR-14253 | spring-test/src/main/java/org/springframework/test/web/servlet/request/MockMvcRequestBuilders.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -208,7 +208,28 @@ public static MockHttpServ... | true |
Other | spring-projects | spring-framework | eabd8a2964e84eba7bff9d6a50269d15a1f87d1f.json | Support Servlet Part in Spring MVC Test
Issue: SPR-14253 | spring-test/src/test/java/org/springframework/test/web/servlet/samples/standalone/MultipartControllerTests.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -16,6 +16,7 @@
package org.springframewor... | true |
Other | spring-projects | spring-framework | eabd8a2964e84eba7bff9d6a50269d15a1f87d1f.json | Support Servlet Part in Spring MVC Test
Issue: SPR-14253 | src/asciidoc/testing.adoc | @@ -3986,7 +3986,7 @@ request but rather you have to set it up:
[source,java,indent=0]
[subs="verbatim,quotes"]
----
- mockMvc.perform(fileUpload("/doc").file("a1", "ABC".getBytes("UTF-8")));
+ mockMvc.perform(multipart("/doc").file("a1", "ABC".getBytes("UTF-8")));
----
You can specify query parameters in URI te... | true |
Other | spring-projects | spring-framework | c8f98ecd8d36b6d270852f0fd5b6b491108c696c.json | Add MockPart to spring-test
Issue: SPR-14252 | spring-test/src/main/java/org/springframework/mock/web/MockPart.java | @@ -0,0 +1,133 @@
+/*
+ * Copyright 2002-2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+... | true |
Other | spring-projects | spring-framework | c8f98ecd8d36b6d270852f0fd5b6b491108c696c.json | Add MockPart to spring-test
Issue: SPR-14252 | spring-web/src/test/java/org/springframework/mock/web/test/MockPart.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2012 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -20,72 +20,55 @@
import java.io.IOException... | true |
Other | spring-projects | spring-framework | 4e65c10272a97e063389fa8b171b80d3f873ff56.json | Fix broken test in SpringJUnit4ConcurrencyTests
Prior to this commit, SpringJUnit4ConcurrencyTests was broken due to
recent additions of test methods in SampleTests.
This commit fixes the broken test by removing hard coded constants and
replacing them with dynamic lookups for JUnit 4 @Test methods. | spring-test/src/test/java/org/springframework/test/context/junit4/concurrency/SpringJUnit4ConcurrencyTests.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -16,6 +16,14 @@
package org.springframewo... | false |
Other | spring-projects | spring-framework | febed19bf477321c4546f6c2c251eba73605727d.json | Use PathPatternParser in function.server
Use new PathPatternParser instead of PathMatcher in
web.reactive.function.server. | spring-webflux/src/main/java/org/springframework/web/reactive/function/server/DefaultHandlerStrategiesBuilder.java | @@ -112,6 +112,7 @@ public void applicationContext(ApplicationContext applicationContext) {
applicationContext.getBeansOfType(HttpMessageReader.class).values().forEach(this::messageReader);
applicationContext.getBeansOfType(HttpMessageWriter.class).values().forEach(this::messageWriter);
applicationContext.getB... | true |
Other | spring-projects | spring-framework | febed19bf477321c4546f6c2c251eba73605727d.json | Use PathPatternParser in function.server
Use new PathPatternParser instead of PathMatcher in
web.reactive.function.server. | spring-webflux/src/main/java/org/springframework/web/reactive/function/server/RequestPredicates.java | @@ -23,6 +23,7 @@
import java.util.Map;
import java.util.Optional;
import java.util.Set;
+import java.util.function.Function;
import java.util.function.Predicate;
import reactor.core.publisher.Flux;
@@ -32,11 +33,11 @@
import org.springframework.http.MediaType;
import org.springframework.http.server.reactive.S... | true |
Other | spring-projects | spring-framework | febed19bf477321c4546f6c2c251eba73605727d.json | Use PathPatternParser in function.server
Use new PathPatternParser instead of PathMatcher in
web.reactive.function.server. | spring-webflux/src/test/java/org/springframework/web/reactive/function/server/RequestPredicatesTests.java | @@ -18,11 +18,13 @@
import java.net.URI;
import java.util.Collections;
+import java.util.function.Function;
import org.junit.Test;
import org.springframework.http.HttpMethod;
import org.springframework.http.MediaType;
+import org.springframework.web.util.patterns.PathPatternParser;
import static org.junit... | true |
Other | spring-projects | spring-framework | a31429be2b8c5b890040f0fee3cccbe97e5d8d48.json | Add json, html, and xml RequestPredicates
Added RequestPredicate for JSON, HTML, and XML requests. All three tests
for their respective mime type in the Accept header, as well as checking
for a file extension. | spring-webflux/src/main/java/org/springframework/web/reactive/function/server/RequestPredicates.java | @@ -36,6 +36,7 @@
import org.springframework.web.reactive.function.BodyExtractor;
import org.springframework.web.server.WebSession;
import org.springframework.web.util.ParsingPathMatcher;
+import org.springframework.web.util.UriUtils;
/**
* Implementations of {@link RequestPredicate} that implement various usef... | true |
Other | spring-projects | spring-framework | a31429be2b8c5b890040f0fee3cccbe97e5d8d48.json | Add json, html, and xml RequestPredicates
Added RequestPredicate for JSON, HTML, and XML requests. All three tests
for their respective mime type in the Accept header, as well as checking
for a file extension. | spring-webflux/src/test/java/org/springframework/web/reactive/function/server/RequestPredicatesTests.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -130,4 +130,96 @@ public void accept() throw... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-test/src/test/java/org/springframework/test/web/reactive/server/WiretapConnectorTests.java | @@ -13,6 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
package org.springframework.test.web.reactive.server;
import java.net.URI;
@@ -54,7 +55,7 @@ public void listener() throws Exception {
wiretapConnector.addListener(infoRef::set);
... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ClientRequest.java | @@ -36,12 +36,11 @@
* <p>Note that applications are more likely to perform requests through
* {@link WebClient} rather than using this directly.
*
- * @param <T> the type of the body that this request contains
* @author Brian Clozel
* @author Arjen Poutsma
* @since 5.0
*/
-public interface ClientRequest<T... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/DefaultClientRequestBuilder.java | @@ -53,6 +53,8 @@ class DefaultClientRequestBuilder implements ClientRequest.Builder {
private final MultiValueMap<String, String> cookies = new LinkedMultiValueMap<>();
+ private BodyInserter<?, ? super ClientHttpRequest> inserter = BodyInserters.empty();
+
public DefaultClientRequestBuilder(HttpMethod metho... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/DefaultWebClient.java | @@ -262,19 +262,19 @@ public DefaultHeaderSpec ifNoneMatch(String... ifNoneMatches) {
@Override
public Mono<ClientResponse> exchange() {
- ClientRequest<Void> request = initRequestBuilder().build();
+ ClientRequest request = this.initRequestBuilder().build();
return getExchangeFunction().exchange(reques... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeFilterFunction.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -41,7 +41,7 @@ public interface ExchangeFilt... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeFilterFunctions.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -47,9 +47,9 @@ public static ExchangeFilterF... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeFunction.java | @@ -45,7 +45,7 @@ public interface ExchangeFunction {
* @param request the request to exchange
* @return the delayed response
*/
- Mono<ClientResponse> exchange(ClientRequest<?> request);
+ Mono<ClientResponse> exchange(ClientRequest request);
/**
* Filters this exchange function with the given {@code E... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/ExchangeFunctions.java | @@ -72,7 +72,7 @@ public DefaultExchangeFunction(
}
@Override
- public Mono<ClientResponse> exchange(ClientRequest<?> request) {
+ public Mono<ClientResponse> exchange(ClientRequest request) {
Assert.notNull(request, "'request' must not be null");
return this.connector | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/test/java/org/springframework/web/reactive/function/client/DefaultClientRequestBuilderTests.java | @@ -37,7 +37,6 @@
import static java.nio.charset.StandardCharsets.UTF_8;
import static org.junit.Assert.assertEquals;
import static org.junit.Assert.assertNotNull;
-import static org.junit.Assert.assertNull;
import static org.mockito.Mockito.mock;
import static org.mockito.Mockito.when;
import static org.springfr... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/test/java/org/springframework/web/reactive/function/client/DefaultWebClientTests.java | @@ -13,6 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
+
package org.springframework.web.reactive.function.client;
import java.util.Collections;
@@ -42,7 +43,7 @@ public class DefaultWebClientTests {
private ExchangeFunction exchangeFuncti... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/test/java/org/springframework/web/reactive/function/client/ExchangeFilterFunctionsTests.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -22,7 +22,6 @@
import reactor.core.publishe... | true |
Other | spring-projects | spring-framework | 45770d73ede714533741f97275996ea7a04a381a.json | Remove parameterisation from ClientRequest
This commit removes the parameterisation from ClientRequest, similarly
to ServerResponse. Dropping the parameterisation facilitates a
ClientRequest.from method that also copies the body of the target
request.
SPR-15234 Work in Progress | spring-webflux/src/test/java/org/springframework/web/reactive/function/client/WebClientIntegrationTests.java | @@ -252,7 +252,7 @@ public void buildFilter() throws Exception {
WebClient filteredClient = this.webClient.filter(
(request, next) -> {
- ClientRequest<?> filteredRequest = ClientRequest.from(request).header("foo", "bar").build();
+ ClientRequest filteredRequest = ClientRequest.from(request).header("f... | true |
Other | spring-projects | spring-framework | 1901cc65fddc3f2650354def45f6705af681c338.json | Use ParsingPathMatcher by default in WebFlux
Issue: | spring-web/src/main/java/org/springframework/web/cors/reactive/UrlBasedCorsConfigurationSource.java | @@ -20,12 +20,12 @@
import java.util.LinkedHashMap;
import java.util.Map;
-import org.springframework.util.AntPathMatcher;
import org.springframework.util.Assert;
import org.springframework.util.PathMatcher;
import org.springframework.web.cors.CorsConfiguration;
import org.springframework.web.server.ServerWebEx... | true |
Other | spring-projects | spring-framework | 1901cc65fddc3f2650354def45f6705af681c338.json | Use ParsingPathMatcher by default in WebFlux
Issue: | spring-webflux/src/main/java/org/springframework/web/reactive/config/PathMatchConfigurer.java | @@ -82,7 +82,7 @@ public PathMatchConfigurer setPathHelper(HttpRequestPathHelper pathHelper) {
/**
* Set the PathMatcher for matching URL paths against registered URL patterns.
- * <p>Default is {@link org.springframework.util.AntPathMatcher AntPathMatcher}.
+ * <p>Default is {@link org.springframework.web.uti... | true |
Other | spring-projects | spring-framework | 1901cc65fddc3f2650354def45f6705af681c338.json | Use ParsingPathMatcher by default in WebFlux
Issue: | spring-webflux/src/main/java/org/springframework/web/reactive/config/ResourceHandlerRegistry.java | @@ -90,7 +90,7 @@ public ResourceHandlerRegistry(ApplicationContext applicationContext,
* that matches to one of the specified path patterns.
*
* <p>Patterns like {@code "/static/**"} or {@code "/css/{filename:\\w+\\.css}"}
- * are allowed. See {@link org.springframework.util.AntPathMatcher} for more
+ * are... | true |
Other | spring-projects | spring-framework | 1901cc65fddc3f2650354def45f6705af681c338.json | Use ParsingPathMatcher by default in WebFlux
Issue: | spring-webflux/src/main/java/org/springframework/web/reactive/handler/AbstractHandlerMapping.java | @@ -104,7 +104,7 @@ public HttpRequestPathHelper getPathHelper() {
/**
* Set the PathMatcher implementation to use for matching URL paths
* against registered URL patterns. Default is AntPathMatcher.
- * @see org.springframework.util.AntPathMatcher
+ * @see org.springframework.web.util.ParsingPathMatcher
*... | true |
Other | spring-projects | spring-framework | 1901cc65fddc3f2650354def45f6705af681c338.json | Use ParsingPathMatcher by default in WebFlux
Issue: | spring-webflux/src/main/java/org/springframework/web/reactive/handler/AbstractUrlHandlerMapping.java | @@ -37,7 +37,7 @@
* various Ant-style pattern matches, e.g. a registered "/t*" pattern matches
* both "/test" and "/team", "/test/*" matches all paths under "/test",
* "/test/**" matches all paths below "/test". For details, see the
- * {@link org.springframework.util.AntPathMatcher AntPathMatcher} javadoc.
+ * {... | true |
Other | spring-projects | spring-framework | 1901cc65fddc3f2650354def45f6705af681c338.json | Use ParsingPathMatcher by default in WebFlux
Issue: | spring-webflux/src/main/java/org/springframework/web/reactive/handler/SimpleUrlHandlerMapping.java | @@ -46,7 +46,7 @@
* various Ant-style pattern matches, e.g. a registered "/t*" pattern matches
* both "/test" and "/team", "/test/*" matches all paths under "/test",
* "/test/**" matches all paths below "/test". For details, see the
- * {@link org.springframework.util.AntPathMatcher AntPathMatcher} javadoc.
+ * {... | true |
Other | spring-projects | spring-framework | c0f4d78ef9b9e03836baa31ac3ada0b4c48197e7.json | Use Map.getOrDefault in getSqlType implementation
Issue: SPR-15238 | spring-jdbc/src/main/java/org/springframework/jdbc/core/namedparam/AbstractSqlParameterSource.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -64,11 +64,7 @@ public void registerTypeName... | false |
Other | spring-projects | spring-framework | e4be7131ca74c23275837684ce63d839469a0dda.json | Implement reactive HiddenHttpMethodFilter
Provides the ability to embed an HTTP verb inside a hidden form field
(like Thymeleaf's th:method operator).
Issue: SPR-15206 | spring-web/src/main/java/org/springframework/web/filter/reactive/HiddenHttpMethodFilter.java | @@ -0,0 +1,97 @@
+/*
+ * Copyright 2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ *... | true |
Other | spring-projects | spring-framework | e4be7131ca74c23275837684ce63d839469a0dda.json | Implement reactive HiddenHttpMethodFilter
Provides the ability to embed an HTTP verb inside a hidden form field
(like Thymeleaf's th:method operator).
Issue: SPR-15206 | spring-web/src/test/java/org/springframework/web/filter/reactive/HiddenHttpMethodFilterTests.java | @@ -0,0 +1,119 @@
+/*
+ * Copyright 2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ ... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-web/src/main/java/org/springframework/web/cors/reactive/UrlBasedCorsConfigurationSource.java | @@ -18,6 +18,7 @@
import java.util.Collections;
import java.util.LinkedHashMap;
+import java.util.List;
import java.util.Map;
import java.util.SortedSet;
@@ -71,12 +72,14 @@ public void setHttpRequestPathHelper(HttpRequestPathHelper pathHelper) {
/**
* Set CORS configuration based on URL patterns.
*/
- ... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-web/src/main/java/org/springframework/web/util/patterns/PathPatternRegistry.java | @@ -17,7 +17,6 @@
package org.springframework.web.util.patterns;
import java.util.ArrayList;
-import java.util.Collection;
import java.util.Collections;
import java.util.Comparator;
import java.util.HashSet;
@@ -63,6 +62,11 @@ public PathPatternRegistry() {
this.patterns = new HashSet<>();
}
+ public Path... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-web/src/test/java/org/springframework/web/util/patterns/PathPatternRegistryTests.java | @@ -146,8 +146,8 @@ public void registerPatternsWithSameSpecificity() {
PathPattern fooTwo = this.registry.parsePattern("/f?o");
assertThat(fooOne.compareTo(fooTwo), is(0));
- this.registry.add(fooOne);
- this.registry.add(fooTwo);
+ this.registry.register("/fo?");
+ this.registry.register("/f?o");
Set<P... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/main/java/org/springframework/web/reactive/resource/ResourceUrlProvider.java | @@ -84,12 +84,16 @@ public HttpRequestPathHelper getUrlPathHelper() {
* from the Spring {@code ApplicationContext}. However if this property is
* used, the auto-detection is turned off.
*/
- public void setHandlerMap(Map<PathPattern, ResourceWebHandler> handlerMap) {
+ public void setHandlerMap(Map<String, Res... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/main/java/org/springframework/web/reactive/result/condition/PatternsRequestCondition.java | @@ -133,8 +133,7 @@ public PatternsRequestCondition getMatchingCondition(ServerWebExchange exchange)
SortedSet<PathPattern> matches = getMatchingPatterns(lookupPath);
if(!matches.isEmpty()) {
- PathPatternRegistry registry = new PathPatternRegistry();
- registry.addAll(matches);
+ PathPatternRegistry regi... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/main/java/org/springframework/web/reactive/result/method/AbstractHandlerMethodMapping.java | @@ -93,7 +93,7 @@
private final MultiValueMap<PathPattern, T> mappingLookup = new LinkedMultiValueMap<>();
private final ReentrantReadWriteLock readWriteLock = new ReentrantReadWriteLock();
-
+
private final MappingRegistry mappingRegistry = new MappingRegistry();
@@ -129,10 +129,10 @@ MappingRegistry getM... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/main/java/org/springframework/web/reactive/result/method/RequestMappingInfoHandlerMapping.java | @@ -74,8 +74,10 @@ public abstract class RequestMappingInfoHandlerMapping extends AbstractHandlerMe
* Get the URL path patterns associated with this {@link RequestMappingInfo}.
*/
@Override
- protected Set<PathPattern> getMappingPathPatterns(RequestMappingInfo info) {
- return info.getPatternsCondition().getPa... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/test/java/org/springframework/web/reactive/resource/AppCacheManifestTransformerTests.java | @@ -34,7 +34,6 @@
import org.springframework.util.FileCopyUtils;
import org.springframework.web.server.ServerWebExchange;
import org.springframework.web.server.adapter.DefaultServerWebExchange;
-import org.springframework.web.util.patterns.PathPatternParser;
import static org.junit.Assert.assertEquals;
import st... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/test/java/org/springframework/web/reactive/resource/CssLinkResourceTransformerTests.java | @@ -59,8 +59,7 @@ public void setUp() {
ResourceWebHandler resourceHandler = new ResourceWebHandler();
ResourceUrlProvider resourceUrlProvider = new ResourceUrlProvider();
- PathPatternParser parser = new PathPatternParser();
- resourceUrlProvider.setHandlerMap(Collections.singletonMap(parser.parse("/static/*... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/test/java/org/springframework/web/reactive/resource/ResourceTransformerSupportTests.java | @@ -30,7 +30,6 @@
import org.springframework.mock.http.server.reactive.test.MockServerHttpResponse;
import org.springframework.web.server.ServerWebExchange;
import org.springframework.web.server.adapter.DefaultServerWebExchange;
-import org.springframework.web.util.patterns.PathPatternParser;
import static org.ju... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/test/java/org/springframework/web/reactive/resource/ResourceUrlProviderTests.java | @@ -36,9 +36,6 @@
import org.springframework.web.reactive.handler.SimpleUrlHandlerMapping;
import org.springframework.web.server.ServerWebExchange;
import org.springframework.web.server.adapter.DefaultServerWebExchange;
-import org.springframework.web.server.session.DefaultWebSessionManager;
-import org.springframew... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/test/java/org/springframework/web/reactive/result/method/HandlerMethodMappingTests.java | @@ -18,7 +18,9 @@
import java.lang.reflect.Method;
import java.net.URISyntaxException;
+import java.util.Collections;
import java.util.Comparator;
+import java.util.Set;
import java.util.SortedSet;
import java.util.TreeSet;
@@ -39,6 +41,7 @@
import org.springframework.web.server.session.MockWebSessionManager;... | true |
Other | spring-projects | spring-framework | 8d43f45515d0261e6e0255a12c282a503902a97a.json | Reduce API Surface in PathPatternRegistry
This commit reduces the exposition of `PathPattern` instances throughout
the `HandlerMapping` API and removes some methods from its public API.
Issue: SPR-14544 | spring-webflux/src/test/java/org/springframework/web/reactive/result/method/RequestMappingInfoHandlerMappingTests.java | @@ -24,9 +24,7 @@
import java.util.Map;
import java.util.Optional;
import java.util.Set;
-import java.util.SortedSet;
import java.util.function.Consumer;
-import java.util.stream.Collectors;
import org.hamcrest.Matchers;
import org.junit.Before;
@@ -98,11 +96,10 @@ public void setUp() throws Exception {
publi... | true |
Other | spring-projects | spring-framework | 75b18d7b7bf46a9cd8a5f9fb4c58adffec2a2cd4.json | Update copyright header | spring-test/src/main/java/org/springframework/test/web/servlet/result/ContentResultMatchers.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2015 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. | false |
Other | spring-projects | spring-framework | 6aa300d733b696628f0c80d3ede10f1676527c1a.json | Fix Javadoc in ContentResultMatchers
Closes gh-1322 | spring-test/src/main/java/org/springframework/test/web/servlet/result/ContentResultMatchers.java | @@ -127,7 +127,7 @@ public void match(MvcResult result) {
* Assert the response body content with a Hamcrest {@link Matcher}.
* <pre class="code">
* mockMvc.perform(get("/path"))
- * .andExpect(content(containsString("text")));
+ * .andExpect(content().string(containsString("text")));
* </pre>
*/
... | false |
Other | spring-projects | spring-framework | 5cfa7e71bb878cde25b03b79cd5b9c58f12a12df.json | Use Class.getTypeName() where appropriate
Issue: SPR-15237 | spring-core/src/main/java/org/springframework/util/ClassUtils.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -480,28 +480,7 @@ public static String getPa... | true |
Other | spring-projects | spring-framework | 5cfa7e71bb878cde25b03b79cd5b9c58f12a12df.json | Use Class.getTypeName() where appropriate
Issue: SPR-15237 | spring-expression/src/main/java/org/springframework/expression/spel/ast/FormatHelper.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2014 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -62,23 +62,7 @@ public static String formatC... | true |
Other | spring-projects | spring-framework | 5cfa7e71bb878cde25b03b79cd5b9c58f12a12df.json | Use Class.getTypeName() where appropriate
Issue: SPR-15237 | spring-expression/src/test/java/org/springframework/expression/spel/support/ReflectionHelperTests.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -48,6 +48,7 @@ public class ReflectionHelper... | true |
Other | spring-projects | spring-framework | d41d28f8cef5355e0cc36e51049577fb113f3b6f.json | Fix compilation of SpEL elvis/ternary expressions
Without this fix the compiled version of elvis
actual behaved differently to the interpreted version
if the value being queried was an empty string. This
is now fixed. It also now correctly handles the
query value being a primitive and addresses the
findings of SPR-151... | spring-expression/src/main/java/org/springframework/expression/spel/ast/Elvis.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2014 the original author or authors.
+ * Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -49,6 +49,7 @@ public Elvis(int pos, SpelNod... | true |
Other | spring-projects | spring-framework | d41d28f8cef5355e0cc36e51049577fb113f3b6f.json | Fix compilation of SpEL elvis/ternary expressions
Without this fix the compiled version of elvis
actual behaved differently to the interpreted version
if the value being queried was an empty string. This
is now fixed. It also now correctly handles the
query value being a primitive and addresses the
findings of SPR-151... | spring-expression/src/main/java/org/springframework/expression/spel/ast/Ternary.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2014 the original author or authors.
+ * Copyright 2002-2016 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -71,12 +71,6 @@ private void computeExitType... | true |
Other | spring-projects | spring-framework | d41d28f8cef5355e0cc36e51049577fb113f3b6f.json | Fix compilation of SpEL elvis/ternary expressions
Without this fix the compiled version of elvis
actual behaved differently to the interpreted version
if the value being queried was an empty string. This
is now fixed. It also now correctly handles the
query value being a primitive and addresses the
findings of SPR-151... | spring-expression/src/test/java/org/springframework/expression/spel/SpelCompilationCoverageTests.java | @@ -17,8 +17,10 @@
package org.springframework.expression.spel;
import java.io.IOException;
+import java.lang.reflect.Field;
import java.lang.reflect.Method;
import java.util.ArrayList;
+import java.util.Collections;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@@ -4626,6 +4628,188 @@... | true |
Other | spring-projects | spring-framework | 6b9b0230c4de394348c42b6f5964fc66eb659dd3.json | Introduce JSON streaming support
This commit introduces JSON streaming support which
consists of serializing HTTP request with
application/stream+json media type as line delimited JSON.
It also optimize Flux serialization for application/json by
using flux.collectList() and a single Jackson invocation
instead of one ... | spring-web/src/main/java/org/springframework/http/MediaType.java | @@ -137,6 +137,18 @@ public class MediaType extends MimeType implements Serializable {
*/
public final static String APPLICATION_RSS_XML_VALUE = "application/rss+xml";
+ /**
+ * Public constant media type for {@code application/stream+json}.
+ * @since 5.0
+ */
+ public final static MediaType APPLICATION_STRE... | true |
Other | spring-projects | spring-framework | 6b9b0230c4de394348c42b6f5964fc66eb659dd3.json | Introduce JSON streaming support
This commit introduces JSON streaming support which
consists of serializing HTTP request with
application/stream+json media type as line delimited JSON.
It also optimize Flux serialization for application/json by
using flux.collectList() and a single Jackson invocation
instead of one ... | spring-web/src/main/java/org/springframework/http/codec/json/Jackson2JsonEncoder.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -18,7 +18,6 @@
import java.io.IOException... | true |
Other | spring-projects | spring-framework | 6b9b0230c4de394348c42b6f5964fc66eb659dd3.json | Introduce JSON streaming support
This commit introduces JSON streaming support which
consists of serializing HTTP request with
application/stream+json media type as line delimited JSON.
It also optimize Flux serialization for application/json by
using flux.collectList() and a single Jackson invocation
instead of one ... | spring-web/src/test/java/org/springframework/http/codec/json/Jackson2JsonEncoderTests.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2016 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -23,6 +23,7 @@
import com.fasterxml.jackson... | true |
Other | spring-projects | spring-framework | 6b9b0230c4de394348c42b6f5964fc66eb659dd3.json | Introduce JSON streaming support
This commit introduces JSON streaming support which
consists of serializing HTTP request with
application/stream+json media type as line delimited JSON.
It also optimize Flux serialization for application/json by
using flux.collectList() and a single Jackson invocation
instead of one ... | spring-webflux/src/test/java/org/springframework/web/reactive/result/method/annotation/JsonStreamingIntegrationTests.java | @@ -0,0 +1,148 @@
+/*
+ * Copyright 2002-2017 the original author or authors.
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+... | true |
Other | spring-projects | spring-framework | 48e834dfd1f5158913c44fcc40081f0d0d9cb370.json | Update copyright header | spring-web/src/main/java/org/springframework/web/context/request/AsyncWebRequestInterceptor.java | @@ -1,5 +1,5 @@
/*
- * Copyright 2002-2012 the original author or authors.
+ * Copyright 2002-2017 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License. | false |
Other | spring-projects | spring-framework | 654e14a86a5035d5cc061fb8f6bb44cdc3b41e7c.json | Fix Javadoc in UriComponentsBuilder | spring-web/src/main/java/org/springframework/web/util/UriComponentsBuilder.java | @@ -239,8 +239,8 @@ public static UriComponentsBuilder fromUriString(String uri) {
* be parsed unambiguously. Such values should be substituted for URI
* variables to enable correct parsing:
* <pre class="code">
- * String uriString = "/hotels/42?filter={value}";
- * UriComponentsBuilder.fromUriStr... | false |
Other | spring-projects | spring-framework | 82a34f4b246537429a8b236f0d1790b1ae924091.json | Update WebClient builder
Leave only one static, no-arg build() method for access to a Builder.
URI-related preferences are now exposed on the builder itself.
Improve Javadoc with base URI examples. | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/DefaultWebClient.java | @@ -22,6 +22,7 @@
import java.time.ZonedDateTime;
import java.time.format.DateTimeFormatter;
import java.util.Arrays;
+import java.util.Map;
import java.util.function.Function;
import org.jetbrains.annotations.NotNull;
@@ -143,6 +144,11 @@ public HeaderSpec uri(String uriTemplate, Object... uriVariables) {
r... | true |
Other | spring-projects | spring-framework | 82a34f4b246537429a8b236f0d1790b1ae924091.json | Update WebClient builder
Leave only one static, no-arg build() method for access to a Builder.
URI-related preferences are now exposed on the builder itself.
Improve Javadoc with base URI examples. | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/DefaultWebClientBuilder.java | @@ -17,6 +17,7 @@
package org.springframework.web.reactive.function.client;
import java.util.Arrays;
+import java.util.Map;
import org.springframework.http.HttpHeaders;
import org.springframework.http.client.reactive.ClientHttpConnector;
@@ -35,49 +36,38 @@
*/
class DefaultWebClientBuilder implements WebClie... | true |
Other | spring-projects | spring-framework | 82a34f4b246537429a8b236f0d1790b1ae924091.json | Update WebClient builder
Leave only one static, no-arg build() method for access to a Builder.
URI-related preferences are now exposed on the builder itself.
Improve Javadoc with base URI examples. | spring-webflux/src/main/java/org/springframework/web/reactive/function/client/WebClient.java | @@ -19,6 +19,7 @@
import java.net.URI;
import java.nio.charset.Charset;
import java.time.ZonedDateTime;
+import java.util.Map;
import java.util.function.Function;
import org.reactivestreams.Publisher;
@@ -30,28 +31,20 @@
import org.springframework.http.client.reactive.ClientHttpRequest;
import org.springframew... | true |
Other | spring-projects | spring-framework | 82a34f4b246537429a8b236f0d1790b1ae924091.json | Update WebClient builder
Leave only one static, no-arg build() method for access to a Builder.
URI-related preferences are now exposed on the builder itself.
Improve Javadoc with base URI examples. | spring-webflux/src/test/java/org/springframework/web/reactive/function/client/DefaultWebClientTests.java | @@ -99,7 +99,7 @@ public void defaultHeaderAndCookieOverrides() throws Exception {
private WebClient.Builder builder() {
- return WebClient.builder("/base").exchangeFunction(this.exchangeFunction);
+ return WebClient.builder().baseUrl("/base").exchangeFunction(this.exchangeFunction);
}
private ClientReque... | true |
Other | spring-projects | spring-framework | 825449a3d2aa2b70ed7967ee2c266da5e26aaf9e.json | Introduce a link to go back to refdoc index | src/docs/asciidoc/appendix.adoc | @@ -5,6 +5,7 @@
:wiki-spring-framework: https://github.com/spring-projects/spring-framework/wiki
:toc: left
:toclevels: 2
+:docinfo1:
[[spring-whats-new]]
== What's New in the Spring Framework | true |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.