203 Commits

Author SHA1 Message Date
Gary Russell
8fd79d388d Fix javadoc typo 2020-08-28 10:02:07 -04:00
wojciech.piotrowiak
1bf4669920 test change to show difference before and after fix 2020-07-14 10:15:37 +01:00
wojciech.piotrowiak
dd94c67f12 New unit test that verify resetTimeout behaviour 2020-07-14 10:15:35 +01:00
wojciech.piotrowiak
010a75ce56 Changing it to set the timer only when the circuit first goes open 2020-07-14 10:15:29 +01:00
Dave Syer
39cf01dc19 Fix SubclassClassifier so it recognizes multiple parents
Prior to this fix interfaces with multiple parents were not
recognized.
2020-04-08 11:36:03 +01:00
krolen
b279131e40 Memory leak when @Retryable is used on a @Scope("prorotype") bean. #141
Replaced hashmap with soft reference map
2020-02-01 11:34:03 +00:00
Dave Syer
d1b505c9f4 Revert to snapshots 2019-12-09 10:33:19 +00:00
Dave Syer
5654c828c2 Update to 1.2.5 2019-12-09 10:11:19 +00:00
Chase Diem
ec7a91d276 GH-126: ExpRandomBackOffPolicy: fix maxInterval
Fixes https://github.com/spring-projects/spring-retry/issues/126

The `ExponentialRandomBackOffPolicy` doesn't take into account a `maxInterval` for the next `sleep`
causing a very long sleep problem eventually

* Fallback to `super.getMaxInterval()` when `next` from random is too big
* Fix JavaDocs for ranges
* Add test for `maxInterval`
2019-12-09 10:07:16 +00:00
Dave Syer
f60e17bc1f Allow SubclassClassifier to work with interfaces
Up to now it only traversed superclasses. Now it looks at the
interfaces as well.
2019-06-07 12:18:10 +01:00
Nathanaël Roberts
1f06568928 Fix bug when there are multiple recover methods
...and a potential inheritance with argument types like List.

Fixes #174
2019-05-28 10:32:16 +01:00
Dave Syer
9474abb17e Fix counting errors in args matchers for recovery
There were off-by-one errors in the recovery argument matching,
and also in the copying of arguments from source to target method.

Fixes gh-169
2019-04-04 13:48:09 +01:00
Spring Operator
7429a6994b URL Cleanup
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

# Fixed URLs

## Fixed Success
These URLs were switched to an https URL with a 2xx status. While the status was successful, your review is still recommended.

* [ ] http://contributor-covenant.org with 1 occurrences migrated to:
  https://contributor-covenant.org ([https](https://contributor-covenant.org) result 301).
* [ ] http://contributor-covenant.org/version/1/3/0/ with 1 occurrences migrated to:
  https://contributor-covenant.org/version/1/3/0/ ([https](https://contributor-covenant.org/version/1/3/0/) result 301).
2019-03-27 15:32:24 +00:00
Spring Operator
25f2718d2f URL Cleanup
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

# Fixed URLs

## Fixed Success
These URLs were switched to an https URL with a 2xx status. While the status was successful, your review is still recommended.

* [ ] http://www.apache.org/licenses/ with 1 occurrences migrated to:
  https://www.apache.org/licenses/ ([https](https://www.apache.org/licenses/) result 200).
* [ ] http://www.apache.org/licenses/LICENSE-2.0 with 135 occurrences migrated to:
  https://www.apache.org/licenses/LICENSE-2.0 ([https](https://www.apache.org/licenses/LICENSE-2.0) result 200).
2019-03-26 09:06:02 +00:00
Spring Operator
6673b6214a URL Cleanup
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

# Fixed URLs

## Fixed Success
These URLs were switched to an https URL with a 2xx status. While the status was successful, your review is still recommended.

* http://www.springframework.org/schema/aop/spring-aop-2.0.xsd with 1 occurrences migrated to:
  https://www.springframework.org/schema/aop/spring-aop-2.0.xsd ([https](https://www.springframework.org/schema/aop/spring-aop-2.0.xsd) result 200).
* http://www.springframework.org/schema/beans/spring-beans-2.0.xsd with 1 occurrences migrated to:
  https://www.springframework.org/schema/beans/spring-beans-2.0.xsd ([https](https://www.springframework.org/schema/beans/spring-beans-2.0.xsd) result 200).
* http://www.springframework.org/schema/tx/spring-tx-2.0.xsd with 1 occurrences migrated to:
  https://www.springframework.org/schema/tx/spring-tx-2.0.xsd ([https](https://www.springframework.org/schema/tx/spring-tx-2.0.xsd) result 200).
* http://maven.apache.org/maven-v4_0_0.xsd with 1 occurrences migrated to:
  https://maven.apache.org/maven-v4_0_0.xsd ([https](https://maven.apache.org/maven-v4_0_0.xsd) result 301).

# Ignored
These URLs were intentionally ignored.

* http://maven.apache.org/POM/4.0.0 with 2 occurrences
* http://www.springframework.org/schema/aop with 2 occurrences
* http://www.springframework.org/schema/beans with 2 occurrences
* http://www.springframework.org/schema/p with 1 occurrences
* http://www.springframework.org/schema/tx with 2 occurrences
* http://www.w3.org/2001/XMLSchema-instance with 2 occurrences
2019-03-20 16:51:18 +00:00
Zhang Chao
2f4386d8b7 Align default delay in code to value in document
Fixes gh-146
2019-03-07 10:40:01 +00:00
Neil Brown
8bef15de04 Document @Retryable's additional runtime dependency and advice on how it's best resolved. (Also fix broken link to contributor's agreement) 2019-03-06 02:51:33 -05:00
Kevin Off
328f510ccf Fixed issue for multiple recovery methods creating an ArrayIndexOutOfBoundsException. Fixed #145 2019-03-06 02:30:01 -05:00
Spring Operator
f400fe7fbe URL Cleanup
This commit updates URLs to prefer the https protocol. Redirects are not followed to avoid accidentally expanding intentionally shortened URLs (i.e. if using a URL shortener).

# Fixed URLs

## Fixed Success
These URLs were fixed successfully.

* http://github.com/spring-projects/spring-retry migrated to:
  https://github.com/spring-projects/spring-retry ([https](https://github.com/spring-projects/spring-retry) result 200).
* http://www.apache.org/licenses/LICENSE-2.0 migrated to:
  https://www.apache.org/licenses/LICENSE-2.0 ([https](https://www.apache.org/licenses/LICENSE-2.0) result 200).
* http://www.apache.org/licenses/LICENSE-2.0.txt migrated to:
  https://www.apache.org/licenses/LICENSE-2.0.txt ([https](https://www.apache.org/licenses/LICENSE-2.0.txt) result 200).
* http://www.springsource.com migrated to:
  https://www.springsource.com ([https](https://www.springsource.com) result 301).
* http://www.springsource.org migrated to:
  https://www.springsource.org ([https](https://www.springsource.org) result 301).
* http://www.springsource.com/download/community migrated to:
  https://www.springsource.com/download/community ([https](https://www.springsource.com/download/community) result 302).

# Ignored
These URLs were intentionally ignored.

* http://maven.apache.org/POM/4.0.0
* http://maven.apache.org/maven-v4_0_0.xsd
* http://www.w3.org/2001/XMLSchema-instance
2019-03-06 02:29:27 -05:00
Dave Syer
0753e4ee45 Revert to snapshots 2019-01-16 08:03:15 +00:00
Dave Syer
ff0f33b142 Revert to Spring 4.3
See gh-114
2019-01-16 08:01:55 +00:00
Dave Syer
976abd4d2b Revert to snapshots 2019-01-11 11:52:17 +00:00
Dave Syer
a3593c7e7f Update to 1.2.3 2019-01-11 11:49:14 +00:00
Dave Syer
d12b2035f6 Fix surefire version 2018-12-20 12:47:03 +00:00
Nikhil Kharche
eec9a1c247 Corrected building classified Concurrent Map for retryable Exceptions. 2018-12-16 17:21:41 +00:00
Dave Syer
c5a28f4fa4 Remove unused import 2018-11-08 11:53:30 +00:00
maciekwiso
31586df0a8 If includes is empty and excludes is not, retry not excluded exceptions
Close #108
2018-11-08 07:49:42 +00:00
Yanming Zhou
3080803aa4 Remove unused @Import 2018-11-07 08:20:46 +00:00
Stepan Romankov
3904f9bbea TreeSet not always correctly sorted for "Uncomparable" exceptions 2018-11-07 08:20:04 +00:00
Fabien MIFSUD
243eefec90 Upgrade Spring version to 5.0.7 2018-11-07 08:18:47 +00:00
f.mifsud
8b5a22baae Upgrade Spring to version 5.0.5 2018-11-07 08:18:47 +00:00
wujun8
dba760b3ad remove aspectjrt
Since aspectjrt is included by aspectjweaver, if there's already aspectjweaver then aspectjrt becomes unnecessary.
2018-11-07 08:18:25 +00:00
Piszmog
540787cc99 handle nulls and add a test 2018-11-07 08:16:02 +00:00
Piszmog
f769c6de9a Find the matching @Recover based on the number of parameters and the type of the parameters 2018-11-07 08:16:02 +00:00
Gary Russell
9f23709958 GH-123: Expressions for CircuitBreaker Properties
Resolves https://github.com/spring-projects/spring-retry/issues/123
2018-11-07 08:13:33 +00:00
Gary Russell
c6afa004d6 Add .DS_Store to .gitignore 2018-09-11 11:26:25 -04:00
maciekwiso
ab06d12a77 changed back method name 2018-03-11 09:53:20 +00:00
maciekwiso
68d66033b1 Override retry listeners for each Retryable method 2018-03-11 09:53:20 +00:00
Alex Tawse
b4f076c258 Fix the Backoff.java docs even more 2018-02-20 06:57:29 +00:00
Dave Syer
bdd467c2f8 Typo in README 2017-12-12 00:52:26 -08:00
Kay Bucksch
50b30e446a Update README.md
Add information about usage of `@Recover` annotation. This can help others not loosing time when researching how to use `@Recover` annotation and method its placed on.
2017-12-12 17:51:39 +09:00
Dave Syer
ef2a0e0877 Update to snapshots 2017-12-11 07:08:37 -08:00
Dave Syer
d6a69408b7 Update to 1.2.2 for release 2017-12-11 07:08:37 -08:00
Aldo Sinanaj
e4a806789d Recover method with return parent class 2017-12-12 00:03:18 +09:00
maciekwiso
71a05c622e Info on how to define listeners with annotations 2017-12-06 03:39:59 +09:00
Gary Russell
6c3cfe50e7 Fix @Backoff JavaDocs - maxDelay
Previously stated that the max delay is ignored if less than delay when, in fact,
the default of 30 seconds is applied.

See http://stackoverflow.com/questions/42857807/spring-retrytemplate-fires-too-early-if-no-maxdelay-is-set
2017-12-05 10:37:29 -08:00
Dave Syer
f1121f17ec Move log4j to test scope
Fixes gh-95
2017-12-05 10:34:44 -08:00
Tomas Poch
ea184cb153 Retry annotation detected on implementing class
Fixes gh-88, closes gh-90
2017-12-05 08:19:09 -08:00
Gary Russell
a22ebe7514 Fix @Recover for Prototype Scoped Beans
Previously, if a bean annotated with `@Retryable` and `@Recover` was
scoped "prototype", the `@Recover` method in the first instance was
called instead of the method in the same instance as the failed `@Retryable`
method.

This was because the delegate cache in `AnnotationAwareRetryOperationsInterceptor`
was keyed only on the `Method` object.

Change the cache to cache at the `targetObject.method` level.

Also fixes `backoff` javadocs.

Fixes https://github.com/spring-projects/spring-retry/issues/93
2017-12-05 08:13:39 -08:00
qwazer
236d6206d7 Fix typo: maximimum -> maximum. 2017-12-06 00:29:12 +09:00