Rather than creating a `CacheManager` ourselves, we now rely on JCache
to provide a `CacheManager` that we'll augment with the caches that
initializr needs.
If Initializr is embedded in another app and that app uses JCache, then
its cache manager will be transparently upgraded to define the caches
that initializr needs. If not, such caches will have to be created as
part of the custom config.
Also, caching only kicks in if required at the service level.
This commit also switches the cache implementation to EhCache 3.
See gh-389
This commit provides a complete entry for Spring Cloud task and clarify
that no more customization is required as of 1.4. Previously, the entry
did not have any groupId/artifactId pair, leading to a default (wrong)
groupId/artifactId to be generated.
Closes gh-341
This commit removes the auto-configuration that export metrics
automatically to Redis. This feature has been superseded by the stats
feature and can be restored at any time in a custom service.
Closes gh-373
This commit fixes several issues with the initial java migration.
On MacOS, the name of the temp directory can be `T` and the new tgz API
requires a parent folder whose name has at least 3 characters.
The Selenium tests require a more precise element to show the advanced
section.
The integration tests were generation the docs snippet on the wrong
accept header.
There is an issue with Kafka in the M1 release (the app generated
here would blow up because of a mismatch between the client and
server). Snapshots are best for now, until we hit RC1.
link → links
Links seems to be the correct key name according to the code and
semantically for a list, so all instances of `link:` have been replaced
by `links:`. Additionally, the Actuator reference link was pointing to
the wrong section in the documentation and has been fixed.
ref → rel
The application failed on startup due to `rel` being required.
Closes gh-360
The additional bom fixes the version of spring cloud task
(which is different than the one in the main cloud BOM).
Fixes gh-342 some more.
Closes gh-344
Turbine AMQP was deprecated and is not available with any of the current
Spring Boot versions, so this removes it from the dependencies list.
Closes gh-320
This commit configures a resource chain with
`resources.chain.strategy.content.enabled`, enabling cache busting for
static resources based on the hash of their content.
A template helper (here a Groovy Closure) is added to the model given to
the view for appending hashes to static links such as:
"/css/spring.css" -> "/css/spring-d35c4193cd32e7e44cda5737205c0c0e.css"
Fixes#321
This commit removes the reactor extension as it is no longer necessary
given all the customizations have been added in Spring Boot now.
Instead, Java8 is now forced for any use of Spring Boot 2.0 and later.
Arguably, this should have been the case since the beginning.
start.spring.io exposes an annotation processor (Lombok) that's quite
popular but is exposed as a compile/transitive dependency. This commit
introduces a `compileOnly` scope that maps to Gradle's `compileOnly`
scope and Maven's `optional` flag.
There is a case to support optional dependencies in general but
unfortunately, Gradle doesn't have support for such feature.
Closes gh-128
This commit improves massively class loading performance by caching all
templates used by the generator. GroovyTemplate is now a bean rather than
a private utility.
Templates are cached by default and the cache is disabled automatically
if Devtools is in use (via a check of spring.groovy.template.cache).
Closes gh-288
This commit adds support for the experimental reactive starter. When
that starter is selected, the version of Spring Framework and Reactor are
automatically overridden and the java version is forced to 1.8
This starter includes an additional BOM that provides dependency
management for reactive-related dependencies (typically netty).
This commit upgrades to Spring Boot 1.4.0.RELEASE and bumps to Java8. It
also migrate the cache library from Guava to Caffeeine.
The git and build information are now exposed via the `info` endpoint.
Closes gh-251
This commit makes sure that the generated initializr-service app does
not contain a version number. That way, it is easier to reuse the same
command to push the app, regardless of the current version.
This commit improves the dependency mapping infrastructure to include the
groupId and artifactId attributes alongside the existing version. For
consistency, the attribute has been renamed from `versions` to
`mappings`.
This allows to better support the `redis` use case: the starter was
renamed from `spring-boot-starter-redis` to
`spring-boot-starter-data-redis` and previously we had two entries
excluding each other using version ranges.
Closes gh-219
This commit splits the feature of Spring Initializr in several modules:
* `initializr-generator` is a standalone library that is responsible for
generating projects based on a `File` directory. It has a minimal set of
dependencies and is not web-related
* `initializr-web` provides the web integration (project generation,
meta-data, etc)
* `initializr-actuator` is an optional module that can be added to
support project-generation-specific statistics
Closes gh-214
If an elastic instance is available, publish a document to a
configurable index every time a `ProjectRequest` is handled by the
service.
In practice, this means that every attempt to generate a project leads to
a new document in the index. The document gathers the settings of the
required project, including invalid ones if any. If an exception is
thrown, the message of the cause is made available.
CloudFlare is explicitely supported and the IP and country of the request
is added to the document. If that information is not available and the
request contains a `X-Forwarded-For` header, the value is also associated
with the document. If an IPv4 is detected, it is set in a separate
`requestIpv4` property.
If for some reason the document could not be indexed, we attempt to retry
a configurable amount of times.
Closes gh-185
`1.3.2.RELEASE` is available now so there is no need to have a version
range on the snapshot. We don't need to copy/paste the version of the
bom in the actual dependency (that's the whole business of the bom
definition (including versions mapping according to the Spring Boot
version).
We want the `cloud-bom` to be automatically added when the data flow bom
is required so it is referenced as "additional BOM" as well.
Closes gh-189
Previously, Spring Initializr was refering to
`spring-cloud-starter-parent` as the BOM source for any cloud-related
dependencies.
This pom actually inherits from a specific version of Spring Boot and
brings all its dependency management. If the chosen boot version and the
one that the cloud bom brings do not match, inconsistent versions can
appear in the project.
The underlying issue was fixed by providing a new BOM that only provides
dependency management for the cloud-related bits.
Closes gh-116
As of Spring Boot 1.4, lombok is managed and we should no longer provide
a version for it. This commit makes sure to remove the version as of
Spring Boot 1.4
Closes gh-182
Spring Boot 1.4 has renamed the `spring-boot-starter-redis` to
`spring-boot-starter-redis`. This commit adds support for the former up
to 1.4 (exclusive) and the later as from 1.4
Closes gh-174
Spring Initializr does not support the provided scope properly with
Gradle as it relies on the `providedRuntime` configuration added by the
war plugin.
Lombok should be added with an optional flag anyway so until the
service properly supports it, lombok is defined again with the default
(compile) scope.
Closes gh-171
Update controllers to add an ETag information so that meta-data is cached
on the client.
Also enables the compression for json, css and html resources.
Closes gh-165
Remove the cloud dependency until Spring Boot itself provides a
dependency management for it. Also fix the scope so that lombok does
not leak in other projects.
Closes gh-154
Previously, all dependencies were considered equal and enough to compile
and start the simple auto-generated boot application. There are some
corner cases such as the JDBC drivers and the new Ratpack integration.
This commit adds an extra flag on a dependency that determines if it is
a starter or not (the default is true). When no starter dependency has
been selected for the project, the root starter (`spring-boot-starter`)
is automatically added.
Closes gh-159
This commit add two additional attributes to a dependency: weight
and keywords.
Weight is a numeric value (default to 0) that allows to order
dependencies search result in a sensible manner. This is a UI feature
only and is not exposed in the meta-data.
Keywords provides a list of words that are added to the source of terms
that the UI use to discover dependencies. It's not exposed either.
Both are exposed by the UI specific controller (`/ui/dependencies`).
See gh-145
* update keyboard shortcuts
* update dependencies descriptions
* add a second button down the page, after the dependencies
* when autocompleting a dependency that's already selected, unselect it
* synchronize packageName with groupId
* synchronize artifact name with artifactId
* fix tabindex order for form fields
See gh-145