Commit Graph

81 Commits (1a9ce42da96e8df401d0583eccdc86e692cd6bda)

Author SHA1 Message Date
Phillip Webb 1a9ce42da9 Apply source formatting to samples 11 years ago
Ulrich von Poblotzki f306eda703 Implemented the error handling in case of commucation failures 11 years ago
Ulrich von Poblotzki 386bb73169 Added simple error hangling to 'SnakeTimer#broadcast'
In some cases the websocket communication fails and Snake#sendMessage throws an exception.
In that case the send loop is interrupted and later clients are not update.
11 years ago
Dave Syer 4655eb3a94 Expose SpringApplicationBuilder in SpringBootServletInitializer 11 years ago
Ulrich von Poblotzki 4ddae32de9 Updated Tomcat version updated to 8.0.0-RC3
The RC1 version had some websocket issues, that prevented propper websocket communication.
In some cases the SocketJS communication was downgraded to 'xhr_streaming'.
11 years ago
Dave Syer 3b2abe9c17 Use create_drop JPA as default if in-memory
[Fixes #55277582] [bs-288]
11 years ago
Dave Syer 1a59698f8b Tweak AMQP sample slightly 11 years ago
Eberhard Wolff 1096ed6d1f Added AMQP starter and sample 11 years ago
Dave Syer 5fe9ef69c7 Add SpringApplicationContextLoader 11 years ago
Dave Syer 345c0fc5a4 Add SpringApplicationBuilder
Builder for SpringApplication and ApplicationContext instances with
convenient fluent API and context hierarchy support. Simple example
of a context hierarchy:

   new SpringApplicationBuilder(ParentConfig.class)
               .child(ChildConfig.class).run(args);

Another common use case is setting default arguments, e.g.
active Spring profiles, to set up the environment for an application:

     new SpringApplicationBuilder(Application.class).profiles("server")
 		.defaultArgs("--transport=local").run(args);

If your needs are simpler, consider using the static convenience
methods in SpringApplication instead.

[#49703716] [bs-116] Parent context for some beans maybe?
11 years ago
Dave Syer f7fa63bcb4 Add status and error messages to /trace
[Fixes #57949108] [bs-323] Make sure /trace shows error responses
11 years ago
Phillip Webb 1bdb2ce1c2 Polish 11 years ago
Dave Syer 923f286ae2 Add spring.view.{prefix,suffix} properties
Fixes #62
11 years ago
Phillip Webb e16a0278ae Support single config from ServletInitializer
Update SpringBootServletInitializer with separate getConfigClass() and
getAdditionalConfigClasses() methods. This change makes it easier to
use the SpringBootServletInitializer with the common use case of a
single config class.
11 years ago
Phillip Webb c544921eaa Polish whitespace 11 years ago
Dave Syer abb1420486 Fixes #55: stop() connector to unbind socket
The `Tomcat.start()` has to happen to initialize the `ServletContext`
but we can immediately stop the connector and then restart it when
the context is finished refreshing. Seems to make curl fail quickly
if an app is slow to start.
11 years ago
Phillip Webb 9a529b41c1 Polish 11 years ago
Phillip Webb b857a9001d Cleanup trailing whitespace 11 years ago
Dave Syer 2b5a67ba3c mongo->mongodb sample 11 years ago
Dave Syer 1026e349c4 Prevent Mongo sample tests from failing in CI 11 years ago
Dave Syer 191894a16a Add Mongo auto configuration
Spring Data Mongo is the only dependency so it doesn't
really need a new starter. Added a sample though.
11 years ago
Dave Syer d06d202fd0 Add AopAutoConfiguration (also starter and sample)
A side effect is that spring-boot-starter-data-jpa needs
to include an aspectjweaver depdendency. Hope that doesn't
hurt anything else.

[Fixes #56780004]
11 years ago
Phillip Webb a33425920b Rework POMs to support automated CI release 11 years ago
Phillip Webb 16cf2faa1b Remove sample gradle builds
Remove sample gradle builds since they are not run during the regular
build and would need to be manually updated after a release.
11 years ago
Dave Syer 38e565e920 Back to SNAPSHOT for dev 11 years ago
Dave Syer b634b3bde6 Update to 0.5.0.M2 11 years ago
Dave Syer 5755b07e6c Switch roles of snake and echo
Snake is stateful so it should be one per connection. Echo is the
opposite.
11 years ago
Phillip Webb f7ce153ff0 Fix JSP EL support with Tomcat
Fix TomcatEmbeddedServletContainerFactory to set a MERGED_WEB_XML
attribute when JSPs are used. This is required for EL support with
JSPs since Jasper checks the version number in the web.xml. Without
any web.xml Jasper default to disabling EL.

Issue: #55752948
11 years ago
Phillip Webb a95494fe61 Remove '/resources/**' mapping and default servlet
Remove '/resources/**' mapping since it can cause problems with the
'/**' when the developer defines their own 'resources' sub-folder.

Also remove default servlet config since the resources mapping renders
it redundant.

Issue: #55494446
11 years ago
Dave Syer 1e0e2e7102 Switch off CSRF filter
Might need to revisit later.
11 years ago
Dave Syer 43fc107437 Fix security config
The management endpoints were still all mixed up
with the user endpoints. Fixed that and extracted
user endpoints in to conditional block so not
protected if path explicitly set to empty string.

[#53029715]
11 years ago
Phillip Webb 2b54b6286f Rework database auto-configure
Rework several aspects of database auto-configuration:

- Use RelaxedPropertyResolver to obtain property values
- Extract EmbeddedDatabaseConnection from EmbeddedDatabaseConfiguration
- Rename several configuration classes for consistency

Issue: #53028397
11 years ago
Dave Syer 621116c9b8 ManagementServerConfiguration security
Management endpoints are still secure by default if
Spring Security is present, but now the default
user details have an ADMIN role, and a random password
(which is logged at INFO level if not overridden).

To override you add management.user.password (name, role)
to external properties.

[Fixes #53029715] [bs-203]
11 years ago
Dave Syer 3c44fda782 Switch off ws sample tests 11 years ago
Dave Syer 5ead60a7e1 Comment out websocket sample (fails in CI) 11 years ago
Dave Syer 767aa43e31 Add WebSocketAutoConfiguration
Opinionated defaults for WebSockets:

* If spring-websocket is on the classpath and so is
the Tomcat WSci initializer then it is added to the context
* A DefaultSockJsService is added if none is present
* User has only to define @Beans of type WebSocketHandler with
name starting "/"
* Each one is converted to a SockJsHttpRequestHandler and
mapped to "/<beanName>/**"
11 years ago
Dave Syer 6e8cbbde3b Use reflection hack for error page in Tocmat 8 11 years ago
Biju Kunjummen fa3b593568 Removed spring-boot related version from dependencies of samples 11 years ago
Phillip Webb d4fe320254 Update trace logging to include Hibernate SQL 11 years ago
Dave Syer d205d9404a Add additional ViewResolver configuration
The DispatcherServlet adds a default InternalViewResolver
which was used by some apps, but when the actuator was
available it added an "/error" bean and effectively
switched off the default view resolver. The net fix was
to add an InternalViewResolver at the same time as
adding any other ViewResolvers.

[Fixes #55357516] [bs-290] Actuator UI app cannot serve static index.html
11 years ago
Phillip Webb 878ff13620 Documentation updates 11 years ago
Phillip Webb cf655945aa Polish 11 years ago
Dave Syer 7bea9dd973 Massage MVC test a bit
* Use *Tests as classname
* Fixed broken test in suite where ID is not always "1"
11 years ago
Biju Kunjummen 31af68a915 Added a Spring MVC test for the Sample MessageController 11 years ago
Dave Syer 42bb793155 Add ServletContextListener to embedded web app
* User can add @Bean of type EventListener (e.g.
ServletContextListener)

[Fixes #54112999] [bs-254]
11 years ago
Phillip Webb f5bae04714 Ignore websocket sample for now 11 years ago
Phillip Webb b5e81ff42d Fix broken test dependencies 11 years ago
Phillip Webb eb69732fbb Reinstate integration tests 11 years ago
Dave Syer 521174754e Add default /error view for HTML clients
* Add integration tests for /error view
* Add "error" @Bean as default view for HTML

Users may see side effects because now there will be
a ContentNegotiatingViewResolver by default for the
first time in a vanilla Actuator app. Should be
interesting.

[Fixes #54597932] [bs-273] Circular view reference for /error
11 years ago
Dave Syer f502098065 Fix logging depdendencies in samples 11 years ago