Commit Graph

1368 Commits

Author SHA1 Message Date
Phillip Webb
0ac5a7595b Polish eclipse settings 2014-01-21 16:28:26 -08:00
Phillip Webb
ac54d7fe3c Final polish before 1.0.0.RC1 2014-01-21 16:28:17 -08:00
Phillip Webb
853b0a8027 Fix some maven warnings 2014-01-21 10:56:09 -08:00
Phillip Webb
cdda330acd Update copyright header for files changed in 2014 2014-01-21 10:27:10 -08:00
Phillip Webb
b12d728c06 Update ant example to 1.0.0.BUILD-SNAPSHOT 2014-01-21 10:22:42 -08:00
Phillip Webb
72dc09cb56 Strip trailing whitespace 2014-01-21 10:22:00 -08:00
Dave Syer
433d049544 Make some dependencies optional 2014-01-21 17:41:27 +00:00
Dave Syer
ea3b82091b Tweak javadocs in SprinApplicationBuilder 2014-01-21 14:29:19 +00:00
Dave Syer
7e4ee4f720 Special case for YAML ParseException caused by bad document boundary
YAML documents can be text literals, so some common typos can be misleading
and not generate the expected exception (Boot fails to cast the
document to a Map, rather than reporting the underlying exception).

Fixes gh-235
2014-01-21 13:58:16 +00:00
Dave Syer
2dc4c291ff Add some clarifications to maven plugin README
Fixes gh-246
2014-01-21 12:18:13 +00:00
Dave Syer
02f6814d93 Revert direct dependency on Jasper pending changes in Tomcat 2014-01-21 12:18:13 +00:00
Dave Syer
8f4059147c Revert "Upgrade to Tomcat 7.0.50"
This reverts commit 3d60696b9b.
2014-01-21 12:18:12 +00:00
Phillip Webb
7bb6bf6a54 Polish 2014-01-21 00:44:02 -08:00
Phillip Webb
68293f34af Upgrade version to 1.0.0.BUILD-SNAPSHOT
Fixes fg-243
2014-01-21 00:43:54 -08:00
Phillip Webb
3d60696b9b Upgrade to Tomcat 7.0.50
Upgrade to Tomcat 7.0.50, working around the potential
NullPointerException by also adding dependencies to
tomcat-embedded-jasper (which is now also required for Hibernate
Validator 5.0, see commit 377953babd)

Fixes gh-245
2014-01-20 23:45:27 -08:00
Phillip Webb
377953babd Upgrade to Hibernate Validator 5.0.2
Update Hibernate Validator dependency to 5.0.2 and also include
Tomcat Jasper dependency. Jasper is required as it provides the
default ExpressionFactory implementation class
(org.apache.el.ExpressionFactoryImpl) which is indirectly
instantiated by Hibernate Validator.

Fixes gh-173
2014-01-20 22:59:42 -08:00
Phillip Webb
618bfc65ac Upgrade to Groovy 2.2.1
Fixes gh-126
2014-01-20 22:28:24 -08:00
Phillip Webb
e38f10d7a6 Upgrade CRaSH shell to 1.3.0-beta14 2014-01-20 22:18:28 -08:00
Phillip Webb
e33eae5b54 Upgrade various 3rd-party dependencies 2014-01-20 22:17:51 -08:00
Rob Winch
6c5701bacd Use @Autowired AuthenticationManagerBuilder
Update documentation to use @Autowired AuthenticationManagerBuilder.

Fixes gh-244
2014-01-20 20:19:59 -08:00
Phillip Webb
18cecd077d Move CLI integration tests into spring-boot-cli
Use `maven-failsafe-plugin` to run CLI integration tests as part of
the `spring-boot-cli` project, removing the need for
`spring-boot-cli-integration-tests`.
2014-01-20 12:12:10 -08:00
Andy Wilkinson
f418a07ba7 Add basic integration tests for the CLI
Add integration tests for the CLI that invoke it as a user would, i.e.
via the shell script in the package's bin directory.
2014-01-20 11:19:33 +00:00
Dave Syer
015d92b8e8 Add docs for @EntityScan and JPA repository packages
Fixes gh-200
2014-01-20 08:29:35 +00:00
Dave Syer
c1bbd4fc4e Fix typo in howto 2014-01-20 08:11:49 +00:00
Phillip Webb
56364ecd46 Allow custom PersistenceUnitManager with JPA
Allow JPA auto-configuration to use an optional custom
PersistenceUnitManager defined as a bean.

Fixed gh-238
2014-01-19 21:59:06 -08:00
Phillip Webb
096ace6896 Add @EntityScan annotation
Add an @EntityScan annotation that can be used to configure the
`packagesToScan` attribute on `LocalContainerEntityManagerFactoryBean`.

Fixed gh-239
2014-01-19 21:42:04 -08:00
Dave Syer
8db1d0e044 Fix some TODOs 2014-01-19 16:00:10 +00:00
Dave Syer
07da034571 Allow @EnableTransactionManagement to be supplied by user 2014-01-19 14:11:04 +00:00
Dave Syer
e7675a0630 Add unit tests for YAML parsing errors
Test for gh-235
2014-01-19 14:11:04 +00:00
Phillip Webb
0a6074be6f Fix failing test due to cache timeout property
Related to gh-232
2014-01-18 11:51:14 -08:00
Christopher Smith
25cc68cafe Add spring.resources.cachePeriod to MvcAutoConfiguration
Fixes gh-232
2014-01-17 18:48:32 +00:00
Dave Syer
5627caa724 Move spring-boot tests utilities to main spring-boot.jar
Fixes gh-233
2014-01-17 18:31:08 +00:00
Dave Syer
d53a52cf1a Fix test 2014-01-17 17:40:01 +00:00
Dave Syer
d01bc59d7e Update to bootstrap 3.0.3 2014-01-17 10:15:16 +00:00
Dave Syer
aded7435b5 Swicth to webjars for static sample 2014-01-17 09:59:13 +00:00
Dave Syer
559f907b54 Use explicit test dependencies in samples 2014-01-17 09:08:18 +00:00
Phillip Webb
f103a976f8 Don't use @ComponentScan for default packages
Update the 'default' package used for @Entity and Repository scanning
to be the package of the class annotated with @EnableAutoConfiguration
rather than using @ComponentScan.

This allows JPA and Spring Data to be used without requiring component
scanning and also removes the confusion that could arise from reusing
the @ComponentScan annotation, which already has well defined semantics.

Fixes gh-200
2014-01-16 22:57:07 -08:00
Phillip Webb
6c255e5785 Reduce logging in Travis 2014-01-16 13:37:19 -08:00
Phillip Webb
b85f984349 Refine auto-configuration report log levels
Refine the `AutoConfigurationReportLoggingInitializer` log level to
only display the information about enabling debug if the debug level
if not on.

Fixes gh-199
2014-01-16 13:07:48 -08:00
Phillip Webb
53f1488f70 Don't automatically log auto-configuration report
Update the `AutoConfigurationReportLoggingInitializer` to only output
the report at debug level. A crash report now triggers an info output
suggesting the user runs again with '--debug' to display the report.

Fixes gh-199
2014-01-16 12:57:13 -08:00
Phillip Webb
c41a3fd5db Fail builds if multiple main classes are found
Update the maven and gradle plugins to fail the build if a single
unique main class cannot be found. Additionally plugins will warn
if the search is taking too long.

Fixes gh-210
2014-01-16 12:33:16 -08:00
Phillip Webb
312535bcd5 Add SpringNamingStrategy to improve FK names
Add a new `SpringNamingStrategy` hibernate `NamingStrategy` that
extends `ImprovedNamingStrategy` to improve the name of foreign
key columns.

Fixes gh-213
2014-01-16 10:38:56 -08:00
Phillip Webb
28a92d22dc Prevent CTRL-D from causing NPE in shell
Update the integrated shell to deal with a null line which can be
triggered with CTRL-D.

Fixes gh-229
2014-01-16 09:31:54 -08:00
Dave Syer
796816e8c3 Remove CleanCommand
Fixes gh-230
2014-01-16 17:29:52 +00:00
Phillip Webb
c8a1d8830c Refactor CLI internals for REPL shell
Numerous updates to the Spring CLI, primarily for better embedded REPL
shell support:

* Refactor the CLI application to help separate concerts between the
  main CLI and the embedded shell. Both the CLI and embedded shell now
  delegate to a new `CommandRunner` to handle running commands. The
  runner can be configured differently depending depending on need.
  For example, the embedded shell adds the 'prompt' and 'clear'
  commands.

* Most `Command` implementations have been moved to sub-packages so that
  they can be co-located with the classes that they use.

* Option commands are now only used in the CLI, the embedded shell
  does not user them and details have been removed from the Command
  interface.

* The REPL shell has been significantly refactored to:
    - Support CTRL-C to cancel the running process. This is supported
      when running external commands and most internal commands.
    - Fork a new JVM when running commands (primarily for CTRL-C support
      but also for potential memory and classpath issues)
    - Change the "continue" trigger from `<<` to `\`
    - Support command completion of files
    - Add ANSI color output
    - Provide 'help' support for internal commands (such as 'clear')
    - Remove the now redundant `stop` command

Fixes gh-227
2014-01-15 14:03:18 -08:00
Phillip Webb
cad9fbfdf0 Fix CLI help formatting issue with '-cp'
Ensure that '--cp' is replaced with a same length string to prevent
odd help text formatting.
2014-01-15 13:29:32 -08:00
Phillip Webb
4fc9dfc2d5 Revert "Add launcher.count as useful performance testing aid"
This reverts commit e1605b4691.
2014-01-15 10:31:08 -08:00
Phillip Webb
3b259bc865 Polish 2014-01-15 10:31:08 -08:00
Dave Syer
5592023f16 Add support for reloading resources in Gradle plugin
Usage:

$ gradle bootRun
...

Edit files in src/main/resources and see the changes live in a web app
(e.g. static resources in /static).

The old functionality of bootRun has been replaced (since it didn't add
a lot of value and also didn't expose any JMV argument setters of anything).
This new feature set is backed by any existing "run" task configuration.

In addition autodetects a main class if there is one in the project
sources, so no need for mainClassName = '...' in build.gradle.

Applies the 'application' plugin (so no need to declare that either).

Fixes gh-225
2014-01-15 11:26:33 +00:00
Andy Wilkinson
5fb42c3c33 Support @Grab when app has multiple groovy scripts
The AST transformation that processes @Grab annotations is driven once
per source file. Previously, this meant that if an app consisted of
multiple source files then multiple, discrete dependency resolutions
would be performed.

This commit updates AetherGrapeEngine to cache a previous resolution's
outcome and use its dependency to influence the outcome of subsequent
resolutions. For example if a one resolution results in spring-core
4.0.0.RELEASE being added to the classpath, subsequent resolutions
that depend upon spring-core will always get the 4.0.0.RELEASE
version. This is achieved by using the dependencies found by earlier
resolutions as dependency management configuration of the current
resolution. This removes the possibility of multiple versions of the
same dependency ending up on the classpath.

In addition to using the results of earlier resolutions to provide
dependency management configuration, default dependency management
configuration is also provided. This configuration is specified by
the springcli.properties file and ensures that, where Boot prescribes
certain versions of a dependency, that is the version that will be
resolved. For example, this ensures that spring-data-redis, which
depends upon Spring 3.1.4, pulls in the version of Spring that Boot
requires instead.

Fixes #224
2014-01-15 10:51:42 +00:00