From c3c156515f290ef0f61cede9b73b84741848800f Mon Sep 17 00:00:00 2001 From: Dave Syer Date: Wed, 18 Feb 2015 10:40:47 +0000 Subject: [PATCH] Add extra detail on servlet listeners Fixes gh-2518 --- .../src/main/asciidoc/spring-boot-features.adoc | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc b/spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc index bc8cde26e2..0312f438d8 100644 --- a/spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc +++ b/spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc @@ -1271,7 +1271,8 @@ instance. By default the embedded server will listen for HTTP requests on port ` [[boot-features-embedded-container-servlets-and-filters]] ==== Servlets and Filters -When using an embedded servlet container you can register Servlets and Filters directly as +When using an embedded servlet container you can register Servlets, Filters and all the +listeners from the Servlet spec (e.g. `HttpSessionListener`) directly as Spring beans. This can be particularly convenient if you want to refer to a value from your `application.properties` during configuration. @@ -1280,9 +1281,10 @@ the case of multiple Servlet beans the bean name will be used as a path prefix. will map to `+/*+`. If convention-based mapping is not flexible enough you can use the -`ServletRegistrationBean` and `FilterRegistrationBean` classes for complete control. You -can also register items directly if your bean implements the `ServletContextInitializer` -interface. +`ServletRegistrationBean`, `FilterRegistrationBean` and +`ServletListenerRegistrationBean` classes for complete control. You +can also register items directly if your bean implements the +`ServletContextInitializer` interface.