1. 05 Jun, 2014 2 commits
    • Dave Syer's avatar
      Switch to a matches-none filter for security.basic.enabled=false · 0ccfba93
      Dave Syer authored
      There were some residual issues to do with the changes to the implementation
      of security.basic.enabled=false. It was a good idea to have a filetr chain
      triggered by the flag being off because it smooths the way for user-defined
      filter chains to use the Boot AuthenticationManager (as a first step at least),
      but it wasn't a goog idea to add any actual secuity features to that filter.
      E.g. if it has HSTS then even an app like Sagan that has some secure endpoints
      that it manages itself and the rest is unsecured has issues because it can't
      accept connections over HTTP even on unsecure endpoints.
      
      TODO: find a way for security.ssl_enabled=true to apply to only the user-
      defined security filter (maybe not possible or worth the effort, since they
      can inject a SecurityProperties if they need it?).
      
      See gh-928
      0ccfba93
    • Dave Syer's avatar
      Fix docs in ServletInitializer · 0ccbde9c
      Dave Syer authored
      0ccbde9c
  2. 04 Jun, 2014 9 commits
    • Stephane Nicoll's avatar
      Use an embed HornetQ broker by default · 726991c1
      Stephane Nicoll authored
      This commit changes the default behavior of the HornetQ auto
      configuration. Prior to this commit, an embedded broker was only
      started when it was requested explicitly by a configuration option.
      
      This is inconsistent with the ActiveMQ support and boot favors the
      easiest route. If the necessary classes are available, HornetQ is
      embedded in the application by default.
      
      Fixes gh-1029
      726991c1
    • Oliver Gierke's avatar
      Make HypermediaAutoConfiguration more lenient. · d6718025
      Oliver Gierke authored
      HypermediaAutoConfiguration didn't consider an @EnableHypermediaSupport 
      annotation being present in the user configuration which could've caused 
      it to be evaluated twice.
      
      This is especially the case if both the auto-configuration for Spring 
      HATEOAS and Spring Data REST kick in as Spring Data REST actively declares
      @EnableHypermediaSupport. The double evaluation then causes injection
      ambiguities as we now get multiple beans of e.g. LinkDiscoverers deployed.
      d6718025
    • Andy Wilkinson's avatar
      Add explicit dependencies to make Gradle pull in the desired version · ec1ce2dd
      Andy Wilkinson authored
      Due to the lack of dependency management in Gradle a number of the
      starters were pulling in old versions of spring-tx (and in some cases
      spring-context-support as well) as the only dependency was a
      transitive one that pulled in an older version.
      
      This commit adds explicit dependencies on spring-context-support and
      spring-tx where appropriate. These dependencies will specify Boot's
      preferred version of Spring causing Gradle to do the right thing as it
      prefers the latest version of a dependency when there is more than one
      to choose from.
      
      Fixes #1028
      ec1ce2dd
    • Andy Wilkinson's avatar
      Fix numbering of items in list of steps for Openshift deployment · 06fe1554
      Andy Wilkinson authored
      The list continuation character '+' can be used to prevent a blank
      line from ending a list, thereby allowing code blocks to be included
      in a list. See "Complex content in outline lists" [1] for more
      details.
      
      [1] http://asciidoctor.org/docs/asciidoc-syntax-quick-reference/#lists
      
      Fixes #1025
      06fe1554
    • Andy Wilkinson's avatar
      Exclude commons-logging to the extent that even Gradle’s happy · 196f92bd
      Andy Wilkinson authored
      Gradle hasn’t different exclusion semantics to Maven. In Maven you can
      exclude spring-core’s commons-logging dependency once and it’ll be
      honoured even if you have multiple transitive routes to commons-logging
      via spring-core. In Gradle you have to exclude commons-logging from
      everything that has a transitive spring-core dependency. To make matters
      worse this doesn’t only apply to dependencies and exclusions declared in
      build.gradle but also to dependencies and exclusions declared in the pom
      files of the artifacts that a Gradle build depends upon.
      
      In short, to make our starters work as intended with Gradle, this commit
      adds many, many exclusions for commons-logging. It also removes
      commons-logging exclusions from spring-boot-dependencies’
      <dependencyManagement> as they have no effect with Gradle and their
      presence can cause us to miss required exclusions in a starter
      
      Fixes #987
      196f92bd
    • Stephane Nicoll's avatar
      Add documentation for JMS support · 9ad7a22e
      Stephane Nicoll authored
      This commit documents Boot's JMS support, in particular how Boot
      can auto-configure the ConnectionFactory for ActiveMQ and
      HornetQ.
      
      Fixes gh-1026
      9ad7a22e
    • Dave Syer's avatar
      Cross link Actuator and User Guide docs · c41fa08a
      Dave Syer authored
      Not having READMEs in github is a mistake IMO, so here's one
      restored and with a link to the docs. Docs also updated to
      more accurately reflect the location of the actuator features
      in implementation.
      
      See https://github.com/spring-guides/gs-actuator-service/pull/7
      for the Getting started guide change
      
      Fixes gh-1014
      c41fa08a
    • Andy Wilkinson's avatar
      c0c3c78f
    • Dave Syer's avatar
      Revert deferred DDL changes and re-oreder database migrations · 74166e77
      Dave Syer authored
      Schema initialization now happens in @PostConstruct (effectively)
      whether it is via the Hibernate EntityManagerFactory or the
      Boot DataSourceInitialization (in addition or instead). The data.sql
      script if it exists is still executed on an event fired from the
      other places, so those tests are passing.
      
      Flyway and liquibase have bean factory post processors (like
      the one they use to order the audit aspect in Spring Data) that
      enforce a dependency on those components from the EntityManagerFactory.
      So Hibernate validation is still happy (and there are 2 tests to
      prove it now as well).
      
      Fixes gh-1022
      74166e77
  3. 03 Jun, 2014 13 commits
  4. 02 Jun, 2014 4 commits
    • Dave Syer's avatar
      Defensive on startup with Multipart config · 77eaa9b2
      Dave Syer authored
      77eaa9b2
    • Dave Syer's avatar
      Ensure JPA/Security are not fighting with each other on startup · 1f82ef4d
      Dave Syer authored
      This is *really* nasty (and led me to discover a related bug
      https://jira.spring.io/browse/SPR-11844), but fortunately easy to
      hide from users once you have a test case.
      
      The problem is that Spring Security registers a `BeanPostProcessor`
      to handle `GlobalAuthenticationConfigurerAdapters`, and Boot
      registers a `BeanPostProcessor` to handle injecting the packages
      to scan into an `EntityManagerFactory` from `@EntityScan`. The
      clash comes because the `EntityScanBeanPostProcessor` wants to be
      postprocessed by the Security postprocessor, but if the Security
      configuration depends on JPA it won't be ready in time.
      
      The fix (or workaround) depending on how you look at it is to
      prevent the other bean post processors from taking an interest in
      `EntityScanBeanPostProcessor` at all (mark it as synthetic).
      
      Fixes gh-1008
      1f82ef4d
    • Dave Syer's avatar
      Defer SQL initialization to fit with JPA better · 49a09c80
      Dave Syer authored
      Added 2 new spring.datasource.* properties ("data" like
      "schema", and "deferDdl" like the "spring.jpa.hibernate.*"
      flag). The SQL scripts are then run separately and the "data"
      ones are triggered by a new DataSourceInitializedEvent,
      which is also published by the Hibernate DDL schema export.
      
      Fixes gh-1006
      49a09c80
    • Dave Syer's avatar
      Remove some compiler warnings · efcbb327
      Dave Syer authored
      efcbb327
  5. 01 Jun, 2014 12 commits