Commit Graph

996 Commits (04d6b21dfbbd24aec57241619b9e3d2d8d48a1df)

Author SHA1 Message Date
Stephane Nicoll b405f8ecf2 Introduce PushRegistry abstraction
This commit introduces a separate layer between PushRegistry and
StepRegistry-based implementations.

See gh-17699
5 years ago
dreis2211 8d2f2b75bd Upgrade to AssertJ 3.13.1
See gh-17690
5 years ago
Phillip Webb 3b28b1cade Don't use static final security matcher
Using static final matchers breaks the build because they have state
that's not reset across tests.

See gh-17525
5 years ago
Phillip Webb 6675f49334 Switch to multi-line security configuration
Now that we have lambda style security configuration we can further
improve readability by switching to one statement per line.

See gh-17525
5 years ago
Madhura Bhave 39a7b9da38 Switch to lambda style security configuration
Closes gh-17525
5 years ago
Phillip Webb 8bc780762a Merge branch '2.1.x' 5 years ago
Phillip Webb fb1dd8fe93 Merge branch '2.0.x' into 2.1.x 5 years ago
Phillip Webb 913e831f4e Merge '1.5.x' into 2.0.x 5 years ago
Stephane Nicoll 94c35ae1de Polish "Make Actuator dedicated ConversionService configurable"
See gh-16449
5 years ago
chao.chang 2aea437536 Make Actuator dedicated ConversionService configurable
See gh-16449
5 years ago
Andy Wilkinson 741d8735d2 Merge branch '2.1.x'
Closes gh-17576
5 years ago
dreis2211 43833c7bf0 Remove unused java-statsd-client dependencies
See gh-17508
5 years ago
Stephane Nicoll be988d7072 Polish "Add HealthIndicator for Hazelcast"
See gh-17499
5 years ago
Dmytro Nosan fca5a2b824 Add HealthIndicator for Hazelcast
See gh-17499
5 years ago
Andy Wilkinson 3bf5cf1124 Merge branch '2.1.x'
Closes gh-17562
5 years ago
Andy Wilkinson b725c60177 Deprecate DeploymentInfo customization with reactive Undertow
Fixes gh-17555
5 years ago
Phillip Webb d567261790 Polish 5 years ago
Phillip Webb eff1147ccc Rename classpath runner package
Remove `runner` since we're no longer tied to JUnit 4.

See gh-17491
5 years ago
Phillip Webb 1117fdb2b3 Make ModifiedClassPathExtension package private
Meta-annotate `ClassPathExclusions` and `ClassPathOverrides` with
so that the `ModifiedClassPathExtension` no longer needs to be
used directly.

See gh-17491
5 years ago
dreis2211 0f0278e69b Migrate ModifiedClassPath tests to JUnit 5
Migrate the remaining JUnit 4 tests to JUnit 5, making use of the
new `ModifiedClassPathExtension`.

See gh-17491
5 years ago
Phillip Webb 0cb6a7f47d Polish 5 years ago
Phillip Webb 01933f9b06 Merge previously split strings
Merge some string lines that were previously split because of the
90 chars wide formatting.
5 years ago
Phillip Webb c3816bfe7b Polish output capture names 5 years ago
Madhura Bhave d590c3ed10 Merge branch '2.1.x'
Closes gh-17486
5 years ago
Madhura Bhave 773dda3d55 Log file location should be evaluated just once
Using a random value for the logfile name caused
the logfile endpoint to return a 404 as the name
was resolved from the environment on every request.
This commit registers a bean for LogFile which is then
used by the logfile endpoint.

Fixes gh-17434
5 years ago
dreis2211 25586a2e23 Use Assertions.contentOf() where possible
See gh-17444
5 years ago
Andy Wilkinson 2816635418 Polish 5 years ago
dreis2211 7c6fd31d06 Use Spring 5 module of Jersey
See gh-17412
5 years ago
Madhura Bhave 39b15af5d6 Polish "Provide links / when using a separate management port"
See gh-17418
5 years ago
HaiTao Zhang c108629311 Provide links for actuators at / when using a separate management port
See gh-17418
5 years ago
Andy Wilkinson c5cae28261 Add support for plain text thread dumps to the threaddump endpoint
When a request that accepts text/plain is received, the threaddump
endpoint will now return a thread dump in plain text. The format of
this text is modelled after the output produced by JVisualVM when
connecting to a remote process over JMX. Note that this output does
not include all of the information in, for example, JStack's output
as it is not available via Java 8's ThreadInfo API.

Rather than the custom formatting logic, using ThreadInfo's toString()
method was considered but its output is documented as being undefined
and implementation specific. The implementation used while developing
this feature produced output that did not match that of JStack or
JVisualVM and truncated stack traces quite considerably.

At the time of writing the format produced by the endpoint could be
consumed by both Thread Dump Analyzer [1] and https://fastthread.io.

Closes gh-2339

[1] https://github.com/irockel/tda
5 years ago
Phillip Webb a66c4d3096 Unify method visibility of private classes
Apply checkstyle rule to ensure that private and package private
classes do not have unnecessary public methods. Test classes have
also been unified as much as possible to use default scoped
inner-classes.

Closes gh-7316
5 years ago
Andy Wilkinson 0b8247bd62 Merge branch '2.1.x'
Closes gh-17408
5 years ago
Andy Wilkinson e57579461a Prevent endpoint's shutdown() method from being a destroy method
Closes gh-17407
5 years ago
Andy Wilkinson 4ab4198168 Switch to Infinispan's Spring 5 integration
Closes gh-17333
5 years ago
Phillip Webb fcbcc9d309 Merge branch '2.1.x'
Closes gh-17387
5 years ago
Phillip Webb a81f37dd68 Escape '{reference}' elements in asciidoc files
Escape lines that look like variable references but should actually be
included verbatim.

Closes gh-17386
5 years ago
Phillip Webb 605599138e Merge branch '2.1.x' 5 years ago
Phillip Webb 92bff3c328 Merge branch '2.0.x' into 2.1.x 5 years ago
Phillip Webb cfeb0239b7 Merge branch '1.5.x' into 2.0.x 5 years ago
Phillip Webb c62b6b4ccd Merge branch '2.1.x' 5 years ago
Phillip Webb de35efd1ef Merge branch '2.0.x' into 2.1.x 5 years ago
Phillip Webb bb34846630 Merge branch '1.5.x' into 2.0.x 5 years ago
Madhura Bhave 7e22901bb2 Fail build on unresolved documentation links
Closes gh-12005
5 years ago
Stephane Nicoll e560b7f6ba Remove public modifier on JUnit5 lifecycle methods
See gh-17292
5 years ago
Stephane Nicoll 403d868611 Polish "Use constants for HTTP headers"
See gh-17199
5 years ago
Johnny Lim a57df0f595 Use constants for HTTP headers
See gh-17199
5 years ago
Stephane Nicoll 9eb2650c0f Merge branch '2.1.x' 5 years ago
Stephane Nicoll 86ace26049 Fix broken link to Spring Integration reference guide
Closes gh-17279
5 years ago
Stephane Nicoll 45d2f1d7d1 Merge branch '2.1.x'
Closes gh-17269
5 years ago
Stephane Nicoll 7e5ca6d280 Merge branch '2.0.x' into 2.1.x
Closes gh-17268
5 years ago
Stephane Nicoll 11dee3c0d8 Merge branch '1.5.x' into 2.0.x 5 years ago
Andy Wilkinson cffc870fd6 Fix test failures on Windows
Since the move to JUnit 5, a number of tests were failing on Windows.
The majority were failing due to open file handles preventing the
clean up of the tests' temporary directory. This commit addresses
these failures by updating the tests to close JarFiles, InputStreams,
OutputStreams etc.

A change has also been made to CachingOperationInvokerTests to make
a flakey test more robust. Due to System.currentTimeMillis() being
less precise on Windows than it is on *nix platforms, the test could
fail as it would not sleep for long enough for the TTL period to have
expired.
6 years ago
Stephane Nicoll 46c2da4a19 Polish "Use existing properties field"
See gh-17129
6 years ago
Ingyu Hwang 725cbd9bc8 Use existing properties field
See gh-17129
6 years ago
Phillip Webb 266d6334b2 Fix checkstyle RedundantModifier test violations 6 years ago
Andy Wilkinson b18fffaf14 Move tests to JUnit 5 wherever possible 6 years ago
Andy Wilkinson aef92b9295 Merge branch '2.1.x'
Closes gh-17079
6 years ago
Andy Wilkinson 24925c3dae Merge branch '2.0.x' into 2.1.x
Closes gh-17078
6 years ago
Andy Wilkinson c6c139d980 Merge branch '1.5.x' into 2.0.x 6 years ago
Phillip Webb d306b31ce9 Merge branch '2.1.x' 6 years ago
Phillip Webb ccfbd03482 Merge branch '2.0.x' into 2.1.x 6 years ago
Phillip Webb b442d3b906 Merge branch '1.5.x' into 2.0.x 6 years ago
Phillip Webb 14349518c9 Polish "Avoid using deprecated NCSARequestLog"
See gh-16987
6 years ago
dreis2211 4af3badbea Avoid using deprecated NCSARequestLog
See gh-16987
6 years ago
Andy Wilkinson 0644a79401 Repackage output capture and always use extension declaratively
Closes gh-17029
6 years ago
Phillip Webb d11d5ceb29 Split up JUnit 5 OutputCapture class
Split the JUnit 5 `OutputCapture` class into separate `OutputExtension`
and `CapturedOutput` classes. The JUnit 5 callback methods are now
contained only in the `OutputExtension` class so no longer pollute the
public API that users will interact with.

The `CapturedOutput` class has also been updated to capture System.err
and System.out separately to allow distinct assertions if required.

Closes gh-17029
6 years ago
Phillip Webb 68a3fbd7a0 Extract AutoTimer interface for metrics
Refactor `Autotime` from a properties object to an interface and
change the existing metric recording implementations. The `AutoTimer`
interface is a general purpose callback that can be applied to a
`Timer.Builder` to configure it. Autotime properties are now located
in `spring-boot-actuator-autoconfigure` and have become an
implementation of the interface.

Closes gh-17026
6 years ago
Phillip Webb 68aec8b6ee Polish 6 years ago
Andy Wilkinson b603cd5d4b Disable Tomcat's MBean Registry by default
Closes gh-16498
6 years ago
Andy Wilkinson 080a2f5c3b Align with Framework’s removal of charset attribute from application/json
Closes gh-16979
6 years ago
Andy Wilkinson 23f803c6b6 Upgrade to Hamcrest 2.1, switch to hamcrest artifact from -core and -library
Closes gh-15555
6 years ago
dreis2211 27ca7e17d9 Fix deprecated StandardAnnotationMetadata usages
Closes gh-16930
6 years ago
Stephane Nicoll 26df55761d Merge enablement and exposure conditions for Actuator endpoints
This commit merges the conditions for determining if an endpoint is
available in a single condition, deprecating
`ConditionalOnEnabledEndpoint` in the process.

Closes gh-16169
6 years ago
Johnny Lim 4900117c71 Restore HttpTraceAutoConfigurationTests.configuresServletFilter()
Closes gh-16885
6 years ago
Phillip Webb 3a9ca5fa30 Update copyright header of changed files 6 years ago
Phillip Webb 79e05c770f Merge branch '2.1.x' 6 years ago
Phillip Webb ed998ef0d3 Update copyright header of changed files 6 years ago
Stephane Nicoll 4d8df3cc47 Polish "Allow configuration of auto-timed metrics"
This commit makes sure the "auto-time-requests" property is still
available in a deprecated fashion.

See gh-15988
6 years ago
Madhura Bhave 1db1c8b03c Validate our own tests work with JUnit5 and the vintage engine
Closes gh-14737

Co-authored-by: Stephane Nicoll <snicoll@pivotal.io>
6 years ago
Madhura Bhave 07d6eb6397 Disable auditing infrastructure by default
Prior to this commit, the audit auto-configuration provided
an `InMemoryAuditEventRepository` bean. This commit changes the auto-config
so that an `AuditEventRepository` is not provided and instead the auto-config
is conditional on the presence of a `AuditEventRepository` bean. This is done
to encourage the use of a custom implementation of `AuditEventRepository`
since the in-memory one is quite limited and not suitable for production.
A flag is available if the auto-configuration needs to be turned off even
in the presence of a bean.

Closes gh-16110
6 years ago
Madhura Bhave e2b15c3f2a Fix tests
See gh-15039
6 years ago
Madhura Bhave de128fed20 Disable HttpTrace infrastructure by default
Prior to this commit, the http trace auto-configuration provided
an `InMemoryHttpTraceRepository` bean. This commit changes the auto-config
so that an `HttpTraceRepository` is not provided and instead the auto-config
is conditional on the presence of a `HttpTraceRepository` bean. This is done
to encourage the use of a custom implementation of `HttpTraceRepository`
since the in-memory one is quite limited and not suitable for production.
A flag is available if the auto-configuration needs to be turned off even
in the presence of a bean.

Closes gh-15039
6 years ago
Madhura Bhave cc99b13ecb Merge branch '2.1.x' 6 years ago
Madhura Bhave c9752f165f Fix javadoc 6 years ago
Stephane Nicoll 8045bf1f50 Polish "Allow configuration of auto-timed metrics"
Closes gh-15988
6 years ago
Tadaya Tsuyukubo 4df6f5dee0 Allow configuration of auto-timed metrics
When `management.metrics.web.server.auto-time-requests` is enabled
(default=true), Spring Boot collects metrics on controller methods even
when they are not annotated with `@Timed`.

When this happens, created metrics are based on the default
`@Timed` configuration and there is no way to customize the
configuration of those auto-timed controller metrics.

This commit adds default configurations to auto-timed requests on both
client and server sides.

See gh-15988
6 years ago
Phillip Webb 17aaf26590 Use consistent javadoc style for annotation links
Closes gh-13920
6 years ago
Phillip Webb 1e44aba772 Fix compiler warnings and polish
Fix various compiler warnings and apply a little polish.
6 years ago
Andy Wilkinson 4754386361 Merge branch '2.1.x'
Closes gh-16644
6 years ago
Andy Wilkinson 6b20d13b3d Polish "Prevent double update of metrics when CompositeMeterRegistry exists"
See gh-16221
6 years ago
Johnny Lim cc285d92dd Prevent double update of metrics when CompositeMeterRegistry exists
See gh-16221
6 years ago
Phillip Webb b879972d0d Migrate to MergedAnnotations API
Migrate away from `AnnotationUtils` and `AnnotatedElementUtils`
when possible to the new `MergedAnnotations` API.

Closes gh-16551
6 years ago
Phillip Webb 2dfd916c96 Polish 6 years ago
Vedran Pavic bbaa98175f Upgrade to Hazelcast 3.12
Closes gh-16503
6 years ago
Stephane Nicoll f42b6199ae Polish 6 years ago
Stephane Nicoll a828072132 Migrate tests to use withBean
See gh-16011
6 years ago
Stephane Nicoll 84735f58f3 Fix build failure 6 years ago
Madhura Bhave ce0282406f Skip lazy init for beans that explicitly set lazy to false
This commit also adds tests to ensure that the child
management context works when lazy initialization is
enabled. Also, it adds a BeanFactoryPostProcessor to
the child context so that the server is created and
listening for requests but other beans in the child
context are not created until requested.

See gh-16184
6 years ago
Andy Wilkinson ff1e5076dc Merge branch '2.1.x'
Closes gh-16473
6 years ago
Andy Wilkinson c0a91478f1 Only start management server once main server is initialized
Closes gh-15378
6 years ago
Stephane Nicoll c432288ed1 Migrate ApplicationContext to common hierarchy
This commit migrates `AnnotationConfigReactiveWebApplicationContext`
parent to the `GenericApplicationContext` abstraction. Any use of
`AnnotationConfigWebApplicationContext` is also removed as it also
inherits from the `AbstractRefreshableApplicationContext` outdated
hierarchy.

A new `AnnotationConfigServletWebApplicationContext` context is
introduced instead, extending from `GenericApplicationContext` and
providing the counter part of the reactive context for the Servlet-based
web app tests.

See gh-16096
6 years ago
Phillip Webb ad7eebee9e Merge branch '2.1.x' 6 years ago
Phillip Webb f12ab1ff90 Update copyright header of changed files 6 years ago
Phillip Webb 34fee1adfa Polish 6 years ago
Andy Wilkinson c5c53849ce Merge branch '2.1.x' 6 years ago
Andy Wilkinson ca0119950f Align with new fail-fast behaviour in Micrometer 1.1.4
Closes gh-16425
6 years ago
Phillip Webb 2376f973f4 Merge branch '2.1.x' 6 years ago
Phillip Webb 47c6bf741d Merge branch '2.0.x' into 2.1.x 6 years ago
Phillip Webb 07c000c5b7 Merge branch '1.5.x' into 2.0.x 6 years ago
Stephane Nicoll 8c8a088c20 Fix zip structure of Actuator documentation
Closes gh-16326
6 years ago
Andy Wilkinson e1a6726d76 Polish "Update CORS handling according to Framework changes"
See gh-16410
6 years ago
Sebastien Deleuze 2f9db7eec6 Update CORS handling according to Framework changes
This commit updates CORS handling according to Framework changes
introduced via [1]. It also fixes tests according to the new behavior.

See gh-16410

[1] d27b5d0ab6.
6 years ago
Stephane Nicoll f4c4b1d3f0 Polish "Permit use of https for configuring Prometheus push gateway"
Closes gh-16084
6 years ago
Dmytro Nosan eed4e9ea56 Permit use of https for configuring Prometheus push gateway
See gh-16084
6 years ago
Stephane Nicoll 1bc47b7e74 Polish "Add Spring-specific styling to Actuator's API documentation"
Closes gh-16326
6 years ago
simionAndrei 26cfbe04b2 Add Spring-specific styling to Actuator's API documentation
This commit replaces the default Asciidoctor styling with
Spring specific styling.

First, we need to unzip the contents of the Spring Asciidoctor
documentation resources provided by the
`io.spring.docsresources:spring-docs-resources` distribution zip. This
is done in a `/target/refdocs` folder. We then copy all files from
`src/main/asciidoc` to the same location, and then launch the generation
process.

See gh-16326
6 years ago
Spring Operator fb242c27d2 Use HTTPS for external links wherever possible
See gh-16276
6 years ago
Andy Wilkinson 878a635bfb Merge branch '2.1.x' 6 years ago
Spring Operator 9fc3ac7d49 Use HTTPS for external links wherever possible
See gh-16320
6 years ago
Andy Wilkinson 864942ad4f Merge branch '2.0.x' into 2.1.x 6 years ago
Spring Operator 1a4c6f2dac Use HTTPS for external links wherever possible
See gh-16319
6 years ago
Andy Wilkinson ba4671f0ab Merge branch '1.5.x' into 2.0.x 6 years ago
Stephane Nicoll b055410ab4 Fix outdated tests
Closes gh-16298
6 years ago
Valery_Yalauchuk c880e10c41 Fix LogFile conditions to check for exposure as well
Closes gh-16298
6 years ago
Stephane Nicoll 76ca467d92 Merge branch '2.1.x' 6 years ago
Stephane Nicoll bd2cc6f48b Add missing condition on LogFile endpoint
See gh-16298
6 years ago
Andy Wilkinson 36c1c051b8 Merge branch '2.1.x' 6 years ago
Andy Wilkinson e23f72c8b0 Merge branch '2.0.x' into 2.1.x 6 years ago
Andy Wilkinson 9fbd38ab3c Merge branch '1.5.x' into 2.0.x 6 years ago
Andy Wilkinson b828b398b5 Merge branch '2.1.x' 6 years ago
Andy Wilkinson a36aa67b52 Merge branch '2.0.x' into 2.1.x 6 years ago
Spring Operator 3e2b6ac8ed Update build and setup configuration to use HTTPS
See gh-16246
6 years ago
Madhura Bhave 3d0219c315 Merge branch '2.1.x' 6 years ago
Johnny Lim c5b5f752ed Polish
Closes gh-16219
6 years ago
Stephane Nicoll c115ee1550 Fix build failure 6 years ago
Stephane Nicoll 0e0ea7f00a Fix checkstyle violation 6 years ago
Stephane Nicoll fcdc414646 Remove use of `@Autowired` for configuration properties bean
See gh-8762
6 years ago
Madhura Bhave 223f2be7d2 Inject InfoContributors instead of exposing them on InfoEndpoint
Closes gh-13586
6 years ago
Stephane Nicoll 81def1f21d Polish 6 years ago
Madhura Bhave e8cb75bba8 Enable git remote linking automatically on CF
Closes gh-13586
6 years ago
Andy Wilkinson 68bfb020aa Reduce need for bean method proxying and disable where not needed
Closes gh-9068
6 years ago
Andy Wilkinson 4b98fa7d94 Alias proxyBeanMethods on annotations meta-annotated with @Configuration
Closes gh-16201
6 years ago
Phillip Webb 64a2e8d67f Update copyright year for changed files 6 years ago
Phillip Webb dd3e8154d9 Merge branch '2.1.x' 6 years ago
Phillip Webb fc3aa43cc2 Update copyright year for changed files 6 years ago
Phillip Webb f02887b6c6 Merge branch '2.0.x' into 2.1.x 6 years ago
Phillip Webb 9c3af103e0 Fix ScheduledTasksEndpointAutoConfigurationTests
Update the `CustomEndpointConfiguration` class in
`ScheduledTasksEndpointAutoConfigurationTests` to be package private
so that it can be enhanced by cglib.

Prior to merge commit 361437f4 the class was a lite configuration so
it didn't matter that it was a private class.
6 years ago
Andy Wilkinson aa2008bc5a Merge branch '2.1.x' 6 years ago
Andy Wilkinson 8c3cec8f13 Merge branch '2.0.x' into 2.1.x 6 years ago