Commit Graph

23481 Commits

Author SHA1 Message Date
Dave Syer
1be040170c Fix bug with ordering of property sources
Profile-specific property sources were being added last,
*after* the global values, which means they did not
override in the way that users would expect.

Fixed by storing the global property sources in an
intermediate list and applying them after the profile
specific ones.
2013-10-07 09:11:05 -04:00
Dave Syer
a082f2bed5 Investigating 2013-10-07 08:15:58 -04:00
Dave Syer
dfb660aa87 Add schema.sql,data.sql to default SQL initializers
...for compatibility with Spring JDBC. Users can still
optionally specify spring.database.schema, but the default
location is schema-${spring.database.platform}.sql, schema.sql,
data.sql.

[Fixes #58332710]
2013-10-07 08:14:14 -04:00
ggerard
182328697d Spelling error: "everypone" 2013-10-03 17:26:30 -04:00
Eberhard Wolff
0760a4ad87 Added Spring Boot Guides from spring.io 2013-10-03 17:22:47 -04:00
Dave Syer
5fe9ef69c7 Add SpringApplicationContextLoader 2013-10-02 15:07:04 -04:00
Dave Syer
eabb1e70a4 Refine SpringApplicationBuilder and add a test for profiles 2013-10-02 08:35:17 -04:00
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?
2013-10-02 07:06:12 -04:00
Dave Syer
3879afccfb Important: restrict PPC scanning to current context 2013-10-02 06:41:29 -04:00
Dave Syer
0df4156b57 Lazy initialization of management server properties 2013-10-02 06:41:21 -04:00
Dave Syer
5b1503d07d Extract DispatcherServletAutoConfiguration so it can be used independently 2013-10-02 06:39:28 -04:00
dave noel
a1517de6db Add gradle runJar 2013-10-01 14:57:56 -04:00
Dave Syer
f7fa63bcb4 Add status and error messages to /trace
[Fixes #57949108] [bs-323] Make sure /trace shows error responses
2013-10-01 14:48:07 -04:00
Phillip Webb
1bdb2ce1c2 Polish 2013-09-30 09:50:38 -07:00
Dave Syer
be1c279be6 Add connector to service before calling customizers 2013-09-27 11:13:02 -04:00
Dave Syer
52e0193d95 Refactor Rabbit and JMS to avoid bean name clash 2013-09-27 10:17:21 -04:00
Dave Syer
923f286ae2 Add spring.view.{prefix,suffix} properties
Fixes #62
2013-09-27 09:34:10 -04:00
Dave Syer
c661a74c75 Add TomcatConnectorCustomizer
... and ServerProperties.Tomcat.maxThreads to conveniently
limit the thread pool size in the Connector.
2013-09-26 19:19:15 -04:00
Dave Syer
c7dc95692c Fix typo in pom sample 2013-09-26 13:14:22 -04:00
Dave Syer
9bb6e0f497 Fix test 2013-09-26 12:14:24 -04:00
Greg Turnquist
941d163709 Add support for Spring Rabbit (via Spring AMQP) to Boot
- If RabbitTemplate is on the classpath, turn on autodetection.
- Create a RabbitTemplate, a Rabbit ConnectionFactory, and a RabbitAdmin is spring.rabbitmq.dynamic:true
- Enable some **spring.rabbitmq** properties like host, port, username, password, and dynamic
- Add tests to verify functionality
- Add Groovy CLI functionality. Base it on @EnableRabbitMessaging. Add spring-amqp to the path.
- Create rabbit.groovy test to prove it all works.
- Make Queue and TopicExchange top-level Spring beans in rabbit.groovy test script
2013-09-26 12:14:06 -04:00
Greg Turnquist
fa6e6fde6c Add JMS autoconfig support
* application.properties support for spring.jms and spring.activemq

* more tests to verify ActiveMQConnectionFactory pooling

* Groovy support and simple sample with activemq

* Groovy detection mechanism is @EnableJmsMessaging annotation
2013-09-26 11:53:06 -04:00
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.
2013-09-25 20:58:27 -07:00
Phillip Webb
26303a9767 Ensure DataSource can load database driver
Update DataSource conditional to ensure that the driver class
can actually be loaded by the DataSource. This fixes an issue when
deploying a classic WAR where `org.apache.tomcat.jdbc.pool.DataSource`
is found the parent classloader but the database driver cannot be loaded
because is included as a local `/lib` dependency.
2013-09-25 19:49:58 -07:00
Phillip Webb
c544921eaa Polish whitespace 2013-09-24 15:42:45 -07:00
Phillip Webb
15bc25dc29 Further re-organization of launcher code 2013-09-24 15:31:24 -07:00
Dave Syer
0e0eb7d3fa Add loader.system (flag to copy properties to System) 2013-09-24 09:23:44 +01:00
Dave Syer
a3af83cf96 Add internal property replacement
E.g. in application.properties (for launcher)

foo: Application
loader.main: my.${foo}
loader.path: etc
2013-09-24 09:15:30 +01:00
Dave Syer
a70d293c87 Re-organize the Launcher code a bit 2013-09-24 08:52:04 +01:00
Phillip Webb
e9fd7c96b8 Loader changes 2013-09-24 08:52:04 +01:00
Dave Syer
053c072155 Add some tests for PropertiesLauncher 2013-09-24 08:52:04 +01:00
Dave Syer
f83fd47184 Add PropertiesLauncher 2013-09-24 08:52:03 +01:00
Oliver Gierke
604b9069b1 #58 - Upgraded Spring Data JPA dependencies to Babbage release train.
Adapted to changes in the API in Spring Data Commons which requires to pass in the current Environment into the AnnotationRepositoryConfigurationSource.
2013-09-24 08:45:05 +01:00
Phillip Webb
fd9e258d12 Replace 'springsource.org' with 'spring.io'
Replace all references to 'springsource.org' with the new 'spring.io'
domain.
2013-09-23 14:44:59 -07:00
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.
2013-09-20 18:16:03 +01:00
Christian Dupuis
a1631d581b Add license and legal information on third party open source software that is part of the CLI distribution 2013-09-20 16:40:02 +01:00
Dave Syer
3c4f1a7a6f Fixes #54: stop servlet container if context fails to start 2013-09-20 16:38:26 +01:00
Greg Turnquist
97af88a8d8 Switch activemq to version 5.4.0 to avoid slf4j issue 2013-09-20 15:38:59 +01:00
Dave Syer
04ba4d064e Investigating failing tests 2013-09-20 15:38:49 +01:00
Dave Syer
5925e153b4 Make sure JMS is on classpath as well 2013-09-20 10:27:42 +01:00
Greg Turnquist
2e5fc2b36f Ignore IntelliJ build stuff 2013-09-19 09:49:56 +01:00
Phillip Webb
9a529b41c1 Polish 2013-09-18 12:50:47 -07:00
Phillip Webb
b857a9001d Cleanup trailing whitespace 2013-09-18 12:17:56 -07:00
Phillip Webb
6e071d6017 Fix TravisCI build status link following rename
Correct the TravisCI link used for the build status image following the
GitHub organization rename from SpringSource to spring-projects.
2013-09-18 12:11:43 -07:00
Greg Turnquist
5801e422cf [BS-48] Add autoconfigured JMS support
* Add ability to detect spring-jms on the path and create a JmsTemplate with
  ActiveMQConnectionFactory
* Create tests showing autoconfigured JmsTemplate with ActiveMQ, but prove it
  backs off if a separate ConnectionFactory exists.
* Add support to spring-boot-cli to that it detects JmsTemplate, DefaultMessageListenerContainer,
  or SimpleMessageListenerContainer, and turns on autoconfiguration as well as
  add proper @Grab's and import statements.
* Write a jms.groovy test showing proper CLI support

Simplify ActiveMQ configuration

Update ActiveMQ to 5.7.0
2013-09-18 17:52:14 +01:00
Dave Syer
ecc4676fb3 Tweak security example 2013-09-18 16:43:38 +01:00
lecaros
cf4f549b06 change credentials order in authentication manager example
username/password pairs were incorrect. The authentication manager has "user" and "password", so those credentials should be allowed to get the actual message.
2013-09-18 16:43:38 +01:00
Dave Syer
4bb99e80d0 Upgrade to reactor M3 2013-09-15 12:37:07 -07:00
Dave Syer
ef79d63544 Fix #40: extra catch block in BeanDefinitionLoader 2013-09-14 11:23:44 -07:00
Dave Syer
f76662a6ec Add spring-jdbc as well if necessary 2013-09-14 11:01:55 -07:00