Skip to content

Commit 92f257e

Browse files
committed
Fix code style/format
1 parent 7e93c1e commit 92f257e

22 files changed

+64
-41
lines changed

spring-core/src/main/java/org/springframework/core/retry/BackOffPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry;
1718

1819
import java.time.Duration;
@@ -32,4 +33,4 @@ public interface BackOffPolicy {
3233
*/
3334
Duration backOff();
3435

35-
}
36+
}

spring-core/src/main/java/org/springframework/core/retry/RetryListener.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry;
1718

1819
import org.springframework.core.retry.support.listener.CompositeRetryListener;
@@ -57,4 +58,4 @@ default void onFailure(Exception exception) {
5758
default void onMaxAttempts(Exception exception) {
5859
}
5960

60-
}
61+
}

spring-core/src/main/java/org/springframework/core/retry/RetryOperations.java

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry;
1718

1819
import java.util.concurrent.Callable;
@@ -41,3 +42,4 @@ public interface RetryOperations {
4142
<R> @Nullable R execute(Callable<R> retryCallback) throws Exception;
4243

4344
}
45+

spring-core/src/main/java/org/springframework/core/retry/RetryPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry;
1718

1819
/**
@@ -30,4 +31,4 @@ public interface RetryPolicy {
3031
*/
3132
int getMaxAttempts();
3233

33-
}
34+
}

spring-core/src/main/java/org/springframework/core/retry/RetryTemplate.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry;
1718

1819
import java.time.Duration;

spring-core/src/main/java/org/springframework/core/retry/support/AlwaysRetryPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support;
1718

1819
import org.springframework.core.retry.RetryPolicy;
@@ -30,4 +31,4 @@ public int getMaxAttempts() {
3031
return Integer.MAX_VALUE;
3132
}
3233

33-
}
34+
}

spring-core/src/main/java/org/springframework/core/retry/support/MaxAttemptsRetryPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support;
1718

1819
import org.springframework.core.retry.RetryPolicy;
@@ -42,4 +43,4 @@ public int getMaxAttempts() {
4243
return this.maxAttempts;
4344
}
4445

45-
}
46+
}

spring-core/src/main/java/org/springframework/core/retry/support/NeverRetryPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support;
1718

1819
import org.springframework.core.retry.RetryPolicy;
@@ -30,4 +31,4 @@ public int getMaxAttempts() {
3031
return 0;
3132
}
3233

33-
}
34+
}

spring-core/src/main/java/org/springframework/core/retry/support/backoff/ExponentialBackOffPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support.backoff;
1718

1819
import java.time.Duration;
@@ -35,4 +36,4 @@ public Duration backOff() {
3536
return this.duration;
3637
}
3738

38-
}
39+
}

spring-core/src/main/java/org/springframework/core/retry/support/backoff/FixedBackOffPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support.backoff;
1718

1819
import java.time.Duration;
@@ -42,4 +43,4 @@ public Duration backOff() {
4243
return this.duration;
4344
}
4445

45-
}
46+
}

spring-core/src/main/java/org/springframework/core/retry/support/backoff/ImmediateBackOffPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support.backoff;
1718

1819
import java.time.Duration;
@@ -32,4 +33,4 @@ public Duration backOff() {
3233
return Duration.ZERO;
3334
}
3435

35-
}
36+
}

spring-core/src/main/java/org/springframework/core/retry/support/backoff/LinearBackOffPolicy.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support.backoff;
1718

1819
import java.time.Duration;
@@ -35,4 +36,4 @@ public Duration backOff() {
3536
return this.duration;
3637
}
3738

38-
}
39+
}

spring-core/src/main/java/org/springframework/core/retry/support/listener/CompositeRetryListener.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support.listener;
1718

1819
import java.util.LinkedList;

spring-core/src/test/java/org/springframework/core/retry/RetryTemplateTests.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry;
1718

1819
import java.time.Duration;
@@ -76,4 +77,4 @@ void testRetryWithFailure() {
7677
// then
7778
assertThatThrownBy(throwingCallable).hasMessage("Error while invoking service");
7879
}
79-
}
80+
}

spring-core/src/test/java/org/springframework/core/retry/support/AlwaysRetryPolicyTests.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support;
1718

1819
import org.junit.jupiter.api.Test;
@@ -32,4 +33,4 @@ void testGetMaxAttempts() {
3233

3334
assertThat(retryPolicy.getMaxAttempts()).isEqualTo(Integer.MAX_VALUE);
3435
}
35-
}
36+
}

spring-core/src/test/java/org/springframework/core/retry/support/MaxAttemptsRetryPolicyTests.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support;
1718

1819
import org.junit.jupiter.api.Test;
@@ -40,4 +41,4 @@ void testInvalidGetMaxAttempts() {
4041
assertThatThrownBy(() -> new MaxAttemptsRetryPolicy(0))
4142
.hasMessage("Max attempts must be greater than zero");
4243
}
43-
}
44+
}

spring-core/src/test/java/org/springframework/core/retry/support/NeverRetryPolicyTests.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support;
1718

1819
import org.junit.jupiter.api.Test;
@@ -32,4 +33,4 @@ void testGetMaxAttempts() {
3233

3334
assertThat(retryPolicy.getMaxAttempts()).isEqualTo(0);
3435
}
35-
}
36+
}

spring-core/src/test/java/org/springframework/core/retry/support/backoff/ExponentialBackOffPolicyTests.java

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2025 the original author or authors.
2+
* Copyright 2002-2025 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -13,6 +13,7 @@
1313
* See the License for the specific language governing permissions and
1414
* limitations under the License.
1515
*/
16+
1617
package org.springframework.core.retry.support.backoff;
1718

1819
import java.time.Duration;
@@ -38,4 +39,4 @@ void testExponentialBackOff() {
3839
assertThat(backOffPolicy.backOff()).isEqualTo(Duration.ofSeconds(16));
3940
assertThat(backOffPolicy.backOff()).isEqualTo(Duration.ofSeconds(32));
4041
}
41-
}
42+
}

0 commit comments

Comments
 (0)