Commit Graph

1610 Commits (913b6020d66db509681149912d74db5e09e7a94b)
 

Author SHA1 Message Date
Josh Long a1a62785be Add cloud deployment documentation
Add a "cloud deployment" section to the Spring Boot reference
manual.

See gh-295
11 years ago
Phillip Webb 7a46ed0866 Port "how-to" section to the reference manual
Copy the existing markdown How-to readme content to the user manual,
converting to asciidoc.

See gh-295
11 years ago
Phillip Webb 163509b5e5 Add initial reference manual documentation
See gh-295
11 years ago
Phillip Webb abba0d63fe Add documentation tool-chain
Generate html, pdf and epub documentation using asciidoctor+docbook.

See gh-295
11 years ago
Phillip Webb 22e397cda2 Polish 11 years ago
Dave Syer 7f8316708a Additionally check for null on registring Servlets and Filters
See gh-482
11 years ago
Dave Syer 3d43771136 Register an AuthenticationManager in security autoconfig
This is quite a big step, but I think it helps a lot. Since Spring
Boot always creates an AuthenticationManager if it doesn't find one
already registered, it makes sense to also make it into a @Bean.
Spring Security does not register its AuthenticationManager by
default though, so we have to do that for it if the user has created
one with an @Autowired AuthenticationManagerBuilder, but not registered
it as a @Bean.

Having the @Bean (marked @Primary to prevent issues with @Autowired)
makes it easier to reason about what Spring Boot has done for you, and
easier to default in simple use cases to the boot-created
AuthenticationManager. For example, if I want an OAuth2 Authorization
Server with password grant, it makes total sense for the
AuthenticationManager for users to be the same as the @Primary one.
Now it is easy to set that up (just @Autowire it).
11 years ago
Dave Syer 85a56a79e4 Tidy up implementation of DispatcherServletAutoConfiguration
also adds another test.
11 years ago
Dave Syer 659d7b6df1 Extend DefaultDispatcherServletCondition to check for a registration
...bean with no explicit @Bean DispatcherServlet. We still have to check
by bean name (slightly unfortunate, but we need to avoid instantiating
too early) so there's now another magic
bean name for the registration bean ("dispatcherServletRegistration")
that the user has to replace if he wants the registration without
defining a servlet @Bean

Fixes gh-482
11 years ago
Dave Syer a71c9b5de7 Add escape hatch for ClassLoader.findResource() for invalid path
The source of the exception is in sun.misc (so hard to track down precisely)
but it's clear that the LaunchedJarURLClassLoader needs to be more
defensive and return null from findResource() if it can't find it.

Fixes gh-486
11 years ago
Dave Syer 08aacf72e0 Update Spring Security to 3.2.2 11 years ago
kozazz ba9f92e74f Add validation test to ws sample
Fixes gh-481
11 years ago
Dave Syer d82a728efe Remove redundant managed dependency version 11 years ago
Dave Syer 14d52b6c18 Avoid creating a new EmbeddedServletContainerFactory for websockets
User can now also switch off and customize the websockets customizer by adding
a bean named "websocketContainerCustomizer".

Fixes gh-479
11 years ago
Dave Syer 34efda1890 Remove duplicate dependency declaration in sample
Fixes gh-476
11 years ago
Dave Syer 207d4853ed More defensive testing of tmpdir 11 years ago
Dave Syer 0439b39381 Fix some broken tests in empty new environments 11 years ago
Dave Syer 4c14f6f685 Add support for Apache HttpClient if available 11 years ago
Dave Syer 7a285cf65d Convert all sample tests to @IntegrationTest where appropriate
Makes them a lot more readable IMO, and also enables @Autowiring
from the context into the test case (sweeet). I added @DirtiesContext
to all of them as well to be on the safe side, but possbly that can be
optimized in some way as well.
11 years ago
Dave Syer 123457a588 Add @IntegrationTest annotation for test classes
Allowing use of embededded container in @SpringApplicationConfiguration
tests, e.g.

```
@RunWith(SpringJUnit4ClassRunner.class)
@SpringApplicationConfiguration(classes = Config.class)
@WebAppConfiguration
@IntegrationTest
public class SpringApplicationIntegrationTestTests {

	@Test
	public void nestedConfigClasses() {
		String body = new RestTemplate().getForObject("http://localhost:8080/",
				String.class);
		assertEquals("Hello World", body);
	}

	@Configuration
	@EnableWebMvc
	@RestController
	protected static class Config {

		@Bean
		public DispatcherServlet dispatcherServlet() {
			return new DispatcherServlet();
		}

		@Bean
		public EmbeddedServletContainerFactory embeddedServletContainer() {
			return new TomcatEmbeddedServletContainerFactory();
		}

		@RequestMapping("/")
		public String home() {
			return "Hello World";
		}

	}

}
```

Fixes gh-473
11 years ago
Chris Beams 4f62a7c6c2 Fix typo in ConfigFileAppListener#addProper(=>t)ySources 11 years ago
Chris Beams e10856fd9b Refactor SpringApplication Environment config hooks
Per discussion: fixes gh-467
11 years ago
Dave Syer d4083e46fe Add exlcusion to httpcomponents dependency 11 years ago
Piotr Maj 1b167f630c Support for maxWait, jdbcInterceptors and validationInterval
Fixes gh-470
11 years ago
Dave Syer 4d172ca742 Remove duplicate resources from classpath
We had been making a special case for logback.xml anyway, so
extending that to simply deleting recursively all of
src/main/resources (or equivalent) from target/classes (or
equivalent) seems like it's perfectly justifiable.

Fixes gh-451
11 years ago
Dave Syer 6657e3ef84 More care taken with management.contextPath
The management.contextPath property should now be respected in a
secure application, whether or not the management.port is different.

Added some test cases in the sample to verify.

Fixes gh-469
11 years ago
Andy Wilkinson 44826812db Add templates/** to list of default includes for CLI jars
Boot promotes the use of a templates directory for housing view
templates. Include this directory by default when building a jar file
from a CLI app.

Fixes #455
11 years ago
Piotr Maj cb6739b4a5 Added testWhileIdle etc.
Fixes gh-463
11 years ago
Andy Piper 695b3917b2 fix link to install.txt
Explicitly link to install.txt in source repo to avoid issues on projects.spring.io with a broken relative link
... also fix this for rendered markdown on GH itself :-)
11 years ago
Dave Syer c9efa5ac13 Allow non-string return from health query 11 years ago
Andy Piper 9d4e940f56 fixup yaml codeblock 11 years ago
Andy Piper 7b4fa22b40 Fix typo 11 years ago
Sebastien Deleuze ab6c8dfee3 Use org.springframework.boot groupId in spring-boot-samples
Use org.springframework.boot instead of ${project.groupId}
groupId in order to make it easier to use spring-boot-samples
modules as a starting point for new projects.
11 years ago
Dave Syer c68902260e Change explicit bean type to concrete NamedParameterJdbcTemplate
Fixes gh-447
11 years ago
Josh Long 9453a6324a polishing documentation 11 years ago
Dave Syer da7d543305 Remove assumption in test about /tmp location 11 years ago
Dave Syer 8168e8a327 Special case for root of classpath resource in archive
This turns out to affect JPA, but only because it looks for a URL for the
root of the classpath using ClassLoader.getResource("") which barfs in
an app launched from an executable JAR. It's easy to make a special case
for "" in the class loader, so I went ahead and did that. Possibly need
to think what the implication of getResources("") is as well (not
tested in an app yet).

Fixes gh-420
11 years ago
Dave Syer afac085318 Use java.io.tmpdir instead of /tmp
Fixes gh-441
11 years ago
Dave Syer 77fd127e09 Use redis starter in sample 11 years ago
Dave Syer aebf3c2bef Tweak external config file loading to support additional profiles
Profiles set with Environment.setActiveProfiles() (rather than
spring.profiles.active) *before* any config files are processed, are
treated as "additional" (to the ones supplied in spring.profiles.active
from all sources, files and System properties included).

Fixes gh-429
11 years ago
Dave Syer de9b6a6a22 Switch off debug in secure sample
Fixes gh-438
11 years ago
Dave Syer c53a36717d Consider subtypes in exception error page mapping
Fixes gh-417
11 years ago
Dave Syer a0ba8c90a6 Add MultipartConfig to DispatcherServlet by default
RC4 added a ServletRegistrationBaen for teh DispatcherServlet and we
didn't register a MultipartConfigElement if one was present.

Fixes gh-427
11 years ago
Dave Syer ffe91ca6bf Change exception message for missing Thymeleaf templates
Fixes gh-424
11 years ago
Dave Syer 6b83e0ad5d Change bean name of ContentNegotiatingViewResolver
Fixed gh-428
11 years ago
Dave Syer 15372cb737 Add Maven example for Tomcat 8
Fixes gh-430
11 years ago
Dave Syer f9094143d7 Remove undefined FILE appender from basic log4j config
Fixes gh-433
11 years ago
Dave Syer b56bd0a10c Add ViewResolver docs 11 years ago
Dave Syer 3bc37ddde0 Strip out most of websocket autoconfig
... leaving only the embedded Tomcat enabling feature (registering
the WsSci).

Fixes part of gh-65
11 years ago
Andy Wilkinson 326c12d1f5 Update Spring repository url in Gradle samples 11 years ago