Separate out web.server from http.server.reactive

This change separates out lower-level HTTP adapter code from the more
(framework-specific) HTTP processing into a separate package under
org.springframework.web.server (not under org.springframework.http).
This commit is contained in:
Rossen Stoyanchev
2016-01-07 21:44:40 -05:00
parent 94be412327
commit 54e4e012b2
13 changed files with 51 additions and 20 deletions
@@ -22,9 +22,6 @@ import reactor.Mono;
* Contract for handling HTTP requests in a non-blocking way.
*
* @author Arjen Poutsma
* @author Rossen Stoyanchev
* @author Sebastien Deleuze
* @see HttpFilter
*/
public interface HttpHandler {
@@ -17,7 +17,7 @@ package org.springframework.web.reactive;
import reactor.Mono;
import org.springframework.http.server.reactive.HttpExceptionHandler;
import org.springframework.web.server.HttpExceptionHandler;
import org.springframework.http.server.reactive.ServerHttpRequest;
import org.springframework.http.server.reactive.ServerHttpResponse;
import org.springframework.web.ResponseStatusException;
@@ -13,13 +13,16 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.http.server.reactive;
package org.springframework.web.server;
import java.util.Arrays;
import java.util.List;
import reactor.Mono;
import org.springframework.http.server.reactive.HttpHandler;
import org.springframework.http.server.reactive.ServerHttpRequest;
import org.springframework.http.server.reactive.ServerHttpResponse;
import org.springframework.util.Assert;
/**
@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.http.server.reactive;
package org.springframework.web.server;
import java.util.Arrays;
import java.util.Collections;
@@ -21,6 +21,10 @@ import java.util.List;
import reactor.Mono;
import org.springframework.http.server.reactive.HttpHandler;
import org.springframework.http.server.reactive.ServerHttpRequest;
import org.springframework.http.server.reactive.ServerHttpResponse;
/**
* {@link HttpHandler} that delegates to a chain of {@link HttpFilter}s followed
* by a target {@link HttpHandler}.
@@ -13,10 +13,14 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.http.server.reactive;
package org.springframework.web.server;
import reactor.Mono;
import org.springframework.http.server.reactive.HttpHandler;
import org.springframework.http.server.reactive.ServerHttpRequest;
import org.springframework.http.server.reactive.ServerHttpResponse;
/**
* A contract for resolving exceptions from HTTP request handling.
*
@@ -14,11 +14,14 @@
* limitations under the License.
*/
package org.springframework.http.server.reactive;
package org.springframework.web.server;
import org.reactivestreams.Publisher;
import reactor.Mono;
import org.springframework.http.server.reactive.HttpHandler;
import org.springframework.http.server.reactive.ServerHttpRequest;
import org.springframework.http.server.reactive.ServerHttpResponse;
/**
* Contract for interception-style, chained processing of HTTP requests.
*
@@ -13,10 +13,13 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.http.server.reactive;
package org.springframework.web.server;
import reactor.Mono;
import org.springframework.http.server.reactive.ServerHttpRequest;
import org.springframework.http.server.reactive.ServerHttpResponse;
/**
* Represents a chain of {@link HttpFilter}s allowing each {@link HttpFilter} to
* delegate to the next in the chain.
@@ -13,10 +13,13 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.http.server.reactive;
package org.springframework.web.server;
import reactor.Mono;
import org.springframework.http.server.reactive.HttpHandler;
import org.springframework.http.server.reactive.ServerHttpRequest;
import org.springframework.http.server.reactive.ServerHttpResponse;
import org.springframework.util.Assert;
/**
@@ -13,11 +13,13 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.http.server.reactive;
package org.springframework.web.server;
import reactor.Mono;
import org.springframework.http.HttpStatus;
import org.springframework.http.server.reactive.ServerHttpRequest;
import org.springframework.http.server.reactive.ServerHttpResponse;
/**
* Handle any exception by setting the response status to 500.