Skip to content

Commit a710b89

Browse files
Make stylechecker and javadoc generator happy
1 parent ff6bd12 commit a710b89

File tree

5 files changed

+36
-8
lines changed

5 files changed

+36
-8
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<!--
3+
~ Copyright © 2024 Apple Inc. and the ServiceTalk project authors
4+
~
5+
~ Licensed under the Apache License, Version 2.0 (the "License");
6+
~ you may not use this file except in compliance with the License.
7+
~ You may obtain a copy of the License at
8+
~
9+
~ http://www.apache.org/licenses/LICENSE-2.0
10+
~
11+
~ Unless required by applicable law or agreed to in writing, software
12+
~ distributed under the License is distributed on an "AS IS" BASIS,
13+
~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14+
~ See the License for the specific language governing permissions and
15+
~ limitations under the License.
16+
-->
17+
<!DOCTYPE suppressions PUBLIC
18+
"-//Checkstyle//DTD SuppressionFilter Configuration 1.2//EN"
19+
"https://checkstyle.org/dtds/suppressions_1_2.dtd">
20+
21+
<suppressions>
22+
<suppress checks="LineLength"
23+
files="io[\\/]servicetalk[\\/]loadbalancer[\\/]OutlierDetectorConfig.java"/>
24+
</suppressions>

servicetalk-loadbalancer-experimental/src/main/java/io/servicetalk/loadbalancer/LoadBalancingPolicy.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -21,11 +21,12 @@
2121

2222
/**
2323
* Definition of the selector mechanism used for load balancing.
24+
* @param <ResolvedAddress> the type of the resolved address
25+
* @param <C> the type of the load balanced connection
2426
*/
2527
public interface LoadBalancingPolicy<ResolvedAddress, C extends LoadBalancedConnection> {
2628
/**
27-
* The name of the load balancing policy
28-
*
29+
* The name of the load balancing policy.
2930
* @return the name of the load balancing policy
3031
*/
3132
String name();
@@ -35,6 +36,7 @@ public interface LoadBalancingPolicy<ResolvedAddress, C extends LoadBalancedConn
3536
* @param hosts the set of {@link Host}s to select from.
3637
* @param targetResource the name of the target resource, useful for debugging purposes.
3738
* @return a {@link HostSelector}
39+
* @param <T> the refined type of the connections over which to load balance
3840
*/
3941
<T extends C> HostSelector<ResolvedAddress, T> buildSelector(
4042
List<Host<ResolvedAddress, T>> hosts, String targetResource);

servicetalk-loadbalancer-experimental/src/main/java/io/servicetalk/loadbalancer/OutlierDetectorConfig.java

+2-3
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,8 @@
2525
/**
2626
* XDS outlier detector configuration.
2727
* <p>
28-
* See the <a href="https://www.envoyproxy.io/docs/envoy/v1.29.0/api-v3/config/cluster/v3/
29-
outlier_detection.proto#envoy-v3-api-msg-config-cluster-v3-outlierdetection"> Envoy docs</a> for the official
30-
* OutlierDetector configuration definition.
28+
* See the <a href="https://www.envoyproxy.io/docs/envoy/v1.29.0/api-v3/config/cluster/v3/outlier_detection.proto#envoy-v3-api-msg-config-cluster-v3-outlierdetection">Envoy docs</a>
29+
* for the official OutlierDetector configuration definition.
3130
*/
3231
public final class OutlierDetectorConfig {
3332

servicetalk-loadbalancer-experimental/src/main/java/io/servicetalk/loadbalancer/P2CLoadBalancingPolicy.java

+4-2
Original file line numberDiff line numberDiff line change
@@ -29,13 +29,15 @@
2929
* <p>
3030
* This {@link LoadBalancer} selection algorithm is based on work by Michael David Mitzenmacher in The Power of Two
3131
* Choices in Randomized Load Balancing.
32-
* @see <a href="https://www.eecs.harvard.edu/~michaelm/postscripts/tpds2001.pdf">Mitzenmacher (2001) The Power of Two
33-
* Choices in Randomized Load Balancing</a>
3432
* <p>
3533
* This load balancing policy is characterized by the algorithm:
3634
* - select two hosts randomly: hosta, and hostb.
3735
* - if neither host is healthy, repeat selection process until max-effort.
3836
* - pick the 'best' host of the two options.
37+
* @param <ResolvedAddress> the type of the resolved address.
38+
* @param <C> the type of the load balanced connection.
39+
* @see <a href="https://www.eecs.harvard.edu/~michaelm/postscripts/tpds2001.pdf">Mitzenmacher (2001) The Power of Two
40+
* * Choices in Randomized Load Balancing</a>
3941
*/
4042
public final class P2CLoadBalancingPolicy<ResolvedAddress, C extends LoadBalancedConnection>
4143
implements LoadBalancingPolicy<ResolvedAddress, C> {

servicetalk-loadbalancer-experimental/src/main/java/io/servicetalk/loadbalancer/RoundRobinLoadBalancingPolicy.java

+2-1
Original file line numberDiff line numberDiff line change
@@ -21,10 +21,11 @@
2121

2222
/**
2323
* A round-robin load balancing policy.
24-
*
2524
* This load balancing algorithm is the well known policy of selecting hosts sequentially
2625
* from an ordered set. If a host is considered unhealthy it is skipped the next host
2726
* is selected until a healthy host is found or the entire host set has been exhausted.
27+
* @param <ResolvedAddress> the type of the resolved address
28+
* @param <C> the type of the load balanced connection
2829
*/
2930
public final class RoundRobinLoadBalancingPolicy<ResolvedAddress, C extends LoadBalancedConnection>
3031
implements LoadBalancingPolicy<ResolvedAddress, C> {

0 commit comments

Comments
 (0)