Commit Graph

472 Commits

Author SHA1 Message Date
Artem Bilan
78bd8d22ea GH-476: Assemble Zip for Javadocs
Fixes: https://github.com/spring-projects/spring-retry/issues/476

* Add `maven-assembly-plugin` to Zip Javadocs from the `apidocs` dir into a `*-docs.zip` artifact
* Modify `build-and-deploy-snapshot.yml` and `release.yml` to assign `zip.deployed=false` attribute to Zip artifacts
* Also mark `docs.zip` files as `zip.type=docs`
2024-11-20 11:25:36 -05:00
Artem Bilan
ed9861d18a Next development version (v2.0.11-SNAPSHOT) 2024-10-18 13:04:16 -04:00
Artem Bilan
b74b0db4f6 Upgrade dependencies, Maven plugins; prepare for release 2024-10-18 12:48:30 -04:00
Artem Bilan
9120f9523f Add Revved up by Develocity badge into README.md 2024-10-16 16:42:59 -04:00
Artem Bilan
8f2a5a0ac5 Add Maven -Duser.name=spring-builds+github for Develocity 2024-10-16 16:30:50 -04:00
Artem Bilan
c85f87cd4e Upgrade to io.spring.develocity.conventions:develocity-conventions-maven-extension:0.0.22 2024-10-16 16:11:07 -04:00
Artem Bilan
50e7d82dc6 Add Develocity support to the project 2024-10-16 15:40:09 -04:00
Evgeny Lazarev
76b41e8dac Add AnnotationClassOrMethodPointcut.hashCode() impl
Due to the absence of a `hashCode()` implementation, proxies for the `AnnotationClassOrMethodPointcut` class are regenerated each time, 
which causes them to be stored in the `org.springframework.cglib.core.internal.LoadingCache` (with `RetryConfiguration.AnnotationClassOrMethodPointcut` being part of the composite key for this object).
This results in an excessive accumulation of generated proxies in memory, ultimately leading to metaspace overflow.
2024-09-23 14:15:16 -04:00
Tobias Soloschenko
4886b75d0b feat: setter for Log of RetryTemplate (#471)
GH-470: Add `RetryTemplate.setLogger()` to avoid reflection in other places

Fixes: #470
Issue link: https://github.com/spring-projects/spring-retry/issues/470

Spring Cloud Config does mutation in the `RetryTemplate` for its system loading logger via `RetryTemplateFactory`.

* Expose setter for `logger` property to avoid reflection.
* Add `RetryTemplateBuilder.withLogger()` for convenience
2024-09-19 11:24:41 -04:00
Artem Bilan
a34a62729d Adjust test logging for less noise during build
* Resolve deprecations in the `RetryContextSerializationTests`
2024-09-19 11:01:18 -04:00
Artem Bilan
b98b2a55a0 Next development version (v2.0.10-SNAPSHOT) 2024-09-13 16:17:42 -04:00
Artem Bilan
d0585fd6f7 Update test dependencies; prepare for release 2024-09-13 15:03:33 -04:00
Artem Bilan
dfc95fe42e GH-229: Expose method & methodArgs into ctx from RetryOperationsInterceptor
Fixes: #229
Issue link: https://github.com/spring-projects/spring-retry/issues/229

The logic in the target `RetryPolicy` might be based on the method and its arguments we retry.

* Expose `method` & `methodArgs` `RetryContext` attributes from an internal implementation
of the `MethodInvocationRetryCallback` in the `RetryOperationsInterceptor`
* Document these attributes
2024-09-13 11:07:08 -04:00
Artem Bilan
5493ab7edf GH-148: Test for @Retryable with an XML config
Fixes: #148
Issue link: https://github.com/spring-projects/spring-retry/issues/148
2024-09-12 12:12:26 -04:00
Artem Bilan
74b7ae2cbd Remove @Import(RetryConfiguration.class) from @Recover
Looks like that was a copy/paste artifact.
The `@Recover` is for business method purpose.
The `@Import(RetryConfiguration.class)` is done from the `@EnableRetry`
2024-09-12 11:55:54 -04:00
Artem Bilan
97ca28fc67 GH-188: Expose @CircuitBreaker(recover) attribute
Fixes: #188
Issue link: https://github.com/spring-projects/spring-retry/issues/188

All the logic to determine a recover method is there.
We are just missing the `CircuitBreaker(recover)` attribute with an `@AliasFor(annotation = Retryable.class)`
2024-09-12 10:49:29 -04:00
Artem Bilan
993526c9b8 Add GHA workflow to announce milestone planning in chat 2024-09-12 10:04:41 -04:00
Huijin Hong
42158baa44 GH-467: Support concurrent behavior on MetricsRetryListener
Fixes #467
2024-09-11 09:30:54 -04:00
LokeshAlamuri
c0a49411c2 GH-464: Fix backOff API in UniformRandomBackOffPolicy
Fixes: #464
Issue link: https://github.com/spring-projects/spring-retry/issues/464

When `maxBackOffPeriod` is less than `minBackOffPeriod`, delta is taken
taken as zero in `UniformRandomBackOffPolicy` `backOff()` method.

* Update tests to use `DummySleeper`
* Extract `UniformRandomBackOffPolicy` `backOffSuppliers` into local variables
* Modify `UniformRandomBackOffPolicy` tests
2024-09-09 10:00:03 -04:00
Spring Builds
db47bc66fd Next development version (v2.0.9-SNAPSHOT) 2024-08-16 13:22:40 -04:00
Artem Bilan
81a2cdd434 Downgrade to Micrometer 1.10.13
This is for compatibility with the Spring Framework `6.0.x` version we rely on so far
2024-08-16 12:09:02 -04:00
Stéphane Nicoll
8b8c3887ce Upgrade to Spring Framework 6.0.23
Closes gh-462
2024-08-16 15:25:14 +02:00
Artem Bilan
9d8df3b4d0 GH-458: Introduce MetricsRetryListener
Fixes: #458

* Fix code formatting violations

* * Make `retryContextToSample` as an `IdentityHashMap` and use `RetryContext` as a key
* Change `setCustomTags()` to the `@Nullable Iterable<Tag>` argument
* Use `exception = none` tag for successful executions to avoid time-series conflicts
2024-08-13 12:34:43 -04:00
Vicente Soriano
8e5cafe200 GH-460: Fix required Java version in README
Fixes: #460
2024-08-13 12:06:10 -04:00
Marcin Zajączkowski
9df8d6cc90 Add @Nullable in RetryContext to easier detect possible NPE
* Add @Nullable in RetryContext to easier detect possible NPE

Both getParent() and getLastThrowable() might return null, as mentioned
in javadoc. @Nullable helps an IDE warns developers about potential NPE.

* Rephrase Javadoc for RetryContext.getLastThrowable()

* Review fixes
2024-07-25 17:28:04 -04:00
Artem Bilan
a9b329af55 GH-456: Fix EnableRetryWithBackoffTests.randomExponential() for random
Fixes: #456

The random logic in the `ExponentialRandomBackOffPolicy` may end up with close to the `1`.
And after casting to `long` we got the same `1000`

* Fix test respectively to include that possibility.
2024-07-18 10:57:09 -04:00
Stéphane Nicoll
04f12a7d96 Remove concourse configuration 2024-07-14 10:48:23 +02:00
Stéphane Nicoll
ab1190dbf7 Fix CI badge in README to use GHA 2024-07-14 10:48:06 +02:00
Stéphane Nicoll
caa0d72d16 Fix formatting of Maven Central check url
Closes gh-455
2024-07-13 11:19:06 +02:00
Stéphane Nicoll
d09e100869 Next development version (v2.0.8-SNAPSHOT) 2024-07-13 11:14:43 +02:00
Stéphane Nicoll
98d5e6a633 Upgrade to Maven 3.9.8
Closes gh-454
2024-07-13 10:28:19 +02:00
Stéphane Nicoll
ef14f9342d Upgrade to Maven Surefire Plugin 3.3.0
Closes gh-453
2024-07-13 10:26:11 +02:00
Stéphane Nicoll
1efd8c4017 Upgrade to Maven Javadoc Plugin 3.7.0
Closes gh-452
2024-07-13 10:25:23 +02:00
Stéphane Nicoll
ae71211dbc Upgrade to AssertJ 3.26.2
Closes gh-451
2024-07-13 10:24:10 +02:00
Stéphane Nicoll
7f84572438 Upgrade to JUnit 5.10.3
Closes gh-450
2024-07-13 10:22:36 +02:00
Stéphane Nicoll
11cad72e44 Upgrade to Spring Framework 6.0.22
Closes gh-449
2024-07-13 10:21:23 +02:00
Stéphane Nicoll
ee44dcec66 Release from GitHub Actions
To harmonize the release process, this commit moves it to GHA.

Closes gh-448
2024-07-13 10:19:26 +02:00
Stéphane Nicoll
686dd9d11a Move CI to GitHub actions
This commit moves the regular build and snapshot deployment to GitHub
actions, based on a standard actions that are reusable.

Closes gh-447
2024-07-13 09:55:54 +02:00
Marcin Grzejszczak
0bcc787ad5 Remove repo.spring.io/release reference (#445) 2024-06-27 10:53:19 -04:00
Morulay Planinski
5b69d8059d GH-441: Introduce PredicateRetryPolicy
Fixes: #441

* Replace `Classifier` with more widely used `Predicate` in `RetryTemplateBuilder`
* Introduce `PredicateRetryPolicy` to avoid backward incompatible changes
2024-06-04 13:40:34 -04:00
Spring Builds
8339dfa472 Next development version (v2.0.7-SNAPSHOT) 2024-05-16 13:32:11 +00:00
Stéphane Nicoll
f2ec7212c5 Upgrade to Spring Framework 6.0.20
Closes gh-435
2024-05-16 15:22:40 +02:00
Stéphane Nicoll
22228f8c8e Polish 2024-05-15 18:41:48 +02:00
Stéphane Nicoll
f069b3966e Upgrade to Maven Surefire Plugin 3.2.5
Closes gh-439
2024-05-15 18:41:09 +02:00
Stéphane Nicoll
3bd7e17232 Upgrade to Maven Sources Plugin 3.3.1
Closes gh-438
2024-05-15 18:40:17 +02:00
Stéphane Nicoll
edd221cd7e Upgrade to Maven Compiler Plugin 3.13.0
Closes gh-437
2024-05-15 18:39:16 +02:00
Stéphane Nicoll
09f8c0a2ff Upgrade to spring javaformat 0.0.41
Closes gh-436
2024-05-15 18:38:15 +02:00
Stéphane Nicoll
7d9b887b3a Start building against Spring Framework 6.0.20 snapshots
See gh-435
2024-05-15 18:32:58 +02:00
Stéphane Nicoll
a5788841a9 Upgrade to Mockito 5.11.0
Closes gh-434
2024-05-15 18:31:32 +02:00
Stéphane Nicoll
c87be51012 Upgrade to Log4J 2.23.1
Closes gh-433
2024-05-15 18:30:45 +02:00