diff --git a/spring-context/src/main/java/org/springframework/remoting/support/SimpleHttpServerFactoryBean.java b/spring-context/src/main/java/org/springframework/remoting/support/SimpleHttpServerFactoryBean.java index 771826239a..edad259022 100644 --- a/spring-context/src/main/java/org/springframework/remoting/support/SimpleHttpServerFactoryBean.java +++ b/spring-context/src/main/java/org/springframework/remoting/support/SimpleHttpServerFactoryBean.java @@ -33,7 +33,6 @@ import org.apache.commons.logging.LogFactory; import org.springframework.beans.factory.DisposableBean; import org.springframework.beans.factory.FactoryBean; import org.springframework.beans.factory.InitializingBean; -import org.springframework.lang.UsesSunHttpServer; /** * {@link org.springframework.beans.factory.FactoryBean} that creates a simple @@ -51,8 +50,10 @@ import org.springframework.lang.UsesSunHttpServer; * @since 2.5.1 * @see #setPort * @see #setContexts + * @deprecated as of Spring Framework 5.1, in favor of embedded Tomcat/Jetty/Undertow */ -@UsesSunHttpServer +@Deprecated +@org.springframework.lang.UsesSunHttpServer public class SimpleHttpServerFactoryBean implements FactoryBean, InitializingBean, DisposableBean { protected final Log logger = LogFactory.getLog(getClass()); diff --git a/spring-core/src/main/java/org/springframework/lang/UsesSunHttpServer.java b/spring-core/src/main/java/org/springframework/lang/UsesSunHttpServer.java index 06daac43ab..c795c7616d 100644 --- a/spring-core/src/main/java/org/springframework/lang/UsesSunHttpServer.java +++ b/spring-core/src/main/java/org/springframework/lang/UsesSunHttpServer.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2014 the original author or authors. + * Copyright 2002-2018 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. @@ -28,7 +28,9 @@ import java.lang.annotation.Target; * * @author Stephane Nicoll * @since 4.1 + * @deprecated as of 5.1, along with Spring's Sun HTTP Server support classes */ +@Deprecated @Retention(RetentionPolicy.CLASS) @Target({ElementType.METHOD, ElementType.CONSTRUCTOR, ElementType.TYPE}) @Documented diff --git a/spring-web/src/main/java/org/springframework/remoting/caucho/HessianExporter.java b/spring-web/src/main/java/org/springframework/remoting/caucho/HessianExporter.java index 60426ba5d2..5b2ca64863 100644 --- a/spring-web/src/main/java/org/springframework/remoting/caucho/HessianExporter.java +++ b/spring-web/src/main/java/org/springframework/remoting/caucho/HessianExporter.java @@ -53,7 +53,6 @@ import org.springframework.util.CommonsLogWriter; * @since 2.5.1 * @see #invoke(java.io.InputStream, java.io.OutputStream) * @see HessianServiceExporter - * @see SimpleHessianServiceExporter */ public class HessianExporter extends RemoteExporter implements InitializingBean { diff --git a/spring-web/src/main/java/org/springframework/remoting/caucho/HessianServiceExporter.java b/spring-web/src/main/java/org/springframework/remoting/caucho/HessianServiceExporter.java index a3e36cec0c..6bbdab4b0f 100644 --- a/spring-web/src/main/java/org/springframework/remoting/caucho/HessianServiceExporter.java +++ b/spring-web/src/main/java/org/springframework/remoting/caucho/HessianServiceExporter.java @@ -29,9 +29,6 @@ import org.springframework.web.util.NestedServletException; * Servlet-API-based HTTP request handler that exports the specified service bean * as Hessian service endpoint, accessible via a Hessian proxy. * - *

Note: Spring also provides an alternative version of this exporter, - * for Sun's JRE 1.6 HTTP server: {@link SimpleHessianServiceExporter}. - * *

Hessian is a slim, binary RPC protocol. * For information on Hessian, see the * Hessian website. diff --git a/spring-web/src/main/java/org/springframework/remoting/caucho/SimpleHessianServiceExporter.java b/spring-web/src/main/java/org/springframework/remoting/caucho/SimpleHessianServiceExporter.java index 8324e1329d..0f8d099c80 100644 --- a/spring-web/src/main/java/org/springframework/remoting/caucho/SimpleHessianServiceExporter.java +++ b/spring-web/src/main/java/org/springframework/remoting/caucho/SimpleHessianServiceExporter.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2014 the original author or authors. + * Copyright 2002-2018 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 java.io.IOException; import com.sun.net.httpserver.HttpExchange; import com.sun.net.httpserver.HttpHandler; -import org.springframework.lang.UsesSunHttpServer; import org.springframework.util.FileCopyUtils; /** @@ -43,9 +42,10 @@ import org.springframework.util.FileCopyUtils; * @since 2.5.1 * @see org.springframework.remoting.caucho.HessianClientInterceptor * @see org.springframework.remoting.caucho.HessianProxyFactoryBean - * @see org.springframework.remoting.httpinvoker.SimpleHttpInvokerServiceExporter + * @deprecated as of Spring Framework 5.1, in favor of {@link HessianServiceExporter} */ -@UsesSunHttpServer +@Deprecated +@org.springframework.lang.UsesSunHttpServer public class SimpleHessianServiceExporter extends HessianExporter implements HttpHandler { /** diff --git a/spring-web/src/main/java/org/springframework/remoting/httpinvoker/HttpInvokerServiceExporter.java b/spring-web/src/main/java/org/springframework/remoting/httpinvoker/HttpInvokerServiceExporter.java index ad309397e9..d64f2ec224 100644 --- a/spring-web/src/main/java/org/springframework/remoting/httpinvoker/HttpInvokerServiceExporter.java +++ b/spring-web/src/main/java/org/springframework/remoting/httpinvoker/HttpInvokerServiceExporter.java @@ -36,9 +36,6 @@ import org.springframework.web.util.NestedServletException; * Servlet-API-based HTTP request handler that exports the specified service bean * as HTTP invoker service endpoint, accessible via an HTTP invoker proxy. * - *

Note: Spring also provides an alternative version of this exporter, - * for Sun's JRE 1.6 HTTP server: {@link SimpleHttpInvokerServiceExporter}. - * *

Deserializes remote invocation objects and serializes remote invocation * result objects. Uses Java serialization just like RMI, but provides the * same ease of setup as Caucho's HTTP-based Hessian protocol. diff --git a/spring-web/src/main/java/org/springframework/remoting/httpinvoker/SimpleHttpInvokerServiceExporter.java b/spring-web/src/main/java/org/springframework/remoting/httpinvoker/SimpleHttpInvokerServiceExporter.java index 142d8b5ace..5dfa86abb0 100644 --- a/spring-web/src/main/java/org/springframework/remoting/httpinvoker/SimpleHttpInvokerServiceExporter.java +++ b/spring-web/src/main/java/org/springframework/remoting/httpinvoker/SimpleHttpInvokerServiceExporter.java @@ -1,5 +1,5 @@ /* - * Copyright 2002-2017 the original author or authors. + * Copyright 2002-2018 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. @@ -25,7 +25,6 @@ import java.io.OutputStream; import com.sun.net.httpserver.HttpExchange; import com.sun.net.httpserver.HttpHandler; -import org.springframework.lang.UsesSunHttpServer; import org.springframework.remoting.rmi.RemoteInvocationSerializingExporter; import org.springframework.remoting.support.RemoteInvocation; import org.springframework.remoting.support.RemoteInvocationResult; @@ -55,9 +54,10 @@ import org.springframework.remoting.support.RemoteInvocationResult; * @since 2.5.1 * @see org.springframework.remoting.httpinvoker.HttpInvokerClientInterceptor * @see org.springframework.remoting.httpinvoker.HttpInvokerProxyFactoryBean - * @see org.springframework.remoting.caucho.SimpleHessianServiceExporter + * @deprecated as of Spring Framework 5.1, in favor of {@link HttpInvokerServiceExporter} */ -@UsesSunHttpServer +@Deprecated +@org.springframework.lang.UsesSunHttpServer public class SimpleHttpInvokerServiceExporter extends RemoteInvocationSerializingExporter implements HttpHandler { /** diff --git a/spring-web/src/main/java/org/springframework/remoting/jaxws/AbstractJaxWsServiceExporter.java b/spring-web/src/main/java/org/springframework/remoting/jaxws/AbstractJaxWsServiceExporter.java index 346f3a897b..75b22b61c9 100644 --- a/spring-web/src/main/java/org/springframework/remoting/jaxws/AbstractJaxWsServiceExporter.java +++ b/spring-web/src/main/java/org/springframework/remoting/jaxws/AbstractJaxWsServiceExporter.java @@ -48,7 +48,6 @@ import org.springframework.util.Assert; * @see javax.jws.WebService * @see javax.xml.ws.Endpoint * @see SimpleJaxWsServiceExporter - * @see SimpleHttpServerJaxWsServiceExporter */ public abstract class AbstractJaxWsServiceExporter implements BeanFactoryAware, InitializingBean, DisposableBean { diff --git a/spring-web/src/main/java/org/springframework/remoting/jaxws/SimpleHttpServerJaxWsServiceExporter.java b/spring-web/src/main/java/org/springframework/remoting/jaxws/SimpleHttpServerJaxWsServiceExporter.java index 96b25e5840..e294a71e3b 100644 --- a/spring-web/src/main/java/org/springframework/remoting/jaxws/SimpleHttpServerJaxWsServiceExporter.java +++ b/spring-web/src/main/java/org/springframework/remoting/jaxws/SimpleHttpServerJaxWsServiceExporter.java @@ -30,7 +30,6 @@ import org.apache.commons.logging.Log; import org.apache.commons.logging.LogFactory; import org.springframework.lang.Nullable; -import org.springframework.lang.UsesSunHttpServer; import org.springframework.util.Assert; /** @@ -49,8 +48,10 @@ import org.springframework.util.Assert; * @see javax.jws.WebService * @see javax.xml.ws.Endpoint#publish(Object) * @see SimpleJaxWsServiceExporter + * @deprecated as of Spring Framework 5.1, in favor of {@link SimpleJaxWsServiceExporter} */ -@UsesSunHttpServer +@Deprecated +@org.springframework.lang.UsesSunHttpServer public class SimpleHttpServerJaxWsServiceExporter extends AbstractJaxWsServiceExporter { protected final Log logger = LogFactory.getLog(getClass()); diff --git a/spring-web/src/main/java/org/springframework/remoting/jaxws/SimpleJaxWsServiceExporter.java b/spring-web/src/main/java/org/springframework/remoting/jaxws/SimpleJaxWsServiceExporter.java index 6e985de55f..eea0edb867 100644 --- a/spring-web/src/main/java/org/springframework/remoting/jaxws/SimpleJaxWsServiceExporter.java +++ b/spring-web/src/main/java/org/springframework/remoting/jaxws/SimpleJaxWsServiceExporter.java @@ -30,17 +30,12 @@ import javax.xml.ws.WebServiceProvider; * *

Note that this exporter will only work if the JAX-WS runtime actually * supports publishing with an address argument, i.e. if the JAX-WS runtime - * ships an internal HTTP server. This is the case with the JAX-WS runtime - * that's included in Sun's JDK 6 but not with the standalone JAX-WS 2.1 RI. - * - *

For explicit configuration of JAX-WS endpoints with Sun's JDK 6 - * HTTP server, consider using {@link SimpleHttpServerJaxWsServiceExporter}! + * ships an internal HTTP server. * * @author Juergen Hoeller * @since 2.5 * @see javax.jws.WebService * @see javax.xml.ws.Endpoint#publish(String) - * @see SimpleHttpServerJaxWsServiceExporter */ public class SimpleJaxWsServiceExporter extends AbstractJaxWsServiceExporter { diff --git a/src/docs/asciidoc/integration.adoc b/src/docs/asciidoc/integration.adoc index 877fd7362e..a9f1f7d55a 100644 --- a/src/docs/asciidoc/integration.adoc +++ b/src/docs/asciidoc/integration.adoc @@ -442,31 +442,6 @@ servlet name matching the bean name of the target exporter: ---- -If you are running outside of a servlet container and are using Oracle's Java 6, then you -can use the built-in HTTP server implementation. You can configure the -`SimpleHttpServerFactoryBean` together with a `SimpleHttpInvokerServiceExporter` as is -shown in this example: - -[source,xml,indent=0] -[subs="verbatim,quotes"] ----- - - - - - - - - - - - - - ----- - [[remoting-httpinvoker-client]] ==== Linking in the service at the client