Skip to content

Commit 3644bbd

Browse files
committed
fix javadocs problem and add check
1 parent 7d30386 commit 3644bbd

File tree

15 files changed

+72
-38
lines changed

15 files changed

+72
-38
lines changed

.github/workflows/javadoc.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
#
2+
# Licensed to the Apache Software Foundation (ASF) under one
3+
# or more contributor license agreements. See the NOTICE file
4+
# distributed with this work for additional information
5+
# regarding copyright ownership. The ASF licenses this file
6+
# to you under the Apache License, Version 2.0 (the
7+
# "License"); you may not use this file except in compliance
8+
# with the License. You may obtain a copy of the License at
9+
#
10+
# http://www.apache.org/licenses/LICENSE-2.0
11+
#
12+
# Unless required by applicable law or agreed to in writing,
13+
# software distributed under the License is distributed on an
14+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15+
# KIND, either express or implied. See the License for the
16+
# specific language governing permissions and limitations
17+
# under the License.
18+
#
19+
20+
name: javadoc
21+
on:
22+
pull_request:
23+
branches:
24+
- master
25+
26+
jobs:
27+
javadoc:
28+
timeout-minutes: 60
29+
runs-on: ubuntu-latest
30+
steps:
31+
- uses: actions/checkout@v4
32+
- name: Set up jdk
33+
uses: actions/setup-java@v4
34+
with:
35+
java-version: '17'
36+
distribution: 'temurin'
37+
- name: javadoc
38+
run: mvn javadoc:javadoc -Prelease

clients/service-center-client/src/main/java/org/apache/servicecomb/service/center/client/ServiceCenterOperation.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,6 @@ boolean updateMicroserviceInstanceStatus(String serviceId, String instanceId,
160160
* Batch send heartbeats to service-center
161161
*
162162
* @param heartbeatsRequest
163-
* @return
164163
* @throws OperationException
165164
*/
166165
void sendHeartBeats(HeartbeatsRequest heartbeatsRequest);

common/common-rest/src/main/java/org/apache/servicecomb/common/rest/codec/query/QueryCodecMulti.java

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -25,9 +25,6 @@
2525

2626
import jakarta.servlet.http.HttpServletRequest;
2727

28-
/**
29-
* ?query=x1&query=x2
30-
*/
3128
@SuppressWarnings("unchecked")
3229
public class QueryCodecMulti extends AbstractQueryCodec {
3330
public static final String CODEC_NAME = "form:1";

core/src/main/java/org/apache/servicecomb/core/invocation/endpoint/EndpointUtils.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ public static Endpoint parse(String uriEndpoint) {
8888
}
8989

9090
/**
91-
* <pre>
91+
* {@code
9292
* http://xxx -> rest://xxx
9393
* https://xxx -> rest://xxx?sslEnabled=true
9494
*
@@ -98,7 +98,7 @@ public static Endpoint parse(String uriEndpoint) {
9898
* xxx -> rest://xxx:port?protocol=http2
9999
* xxx?a=a1 -> rest://xxx:port?a=a1&protocol=http2
100100
* other://xxx -> other://xxx
101-
* </pre>
101+
* }
102102
*
103103
* This method provided for convenience of handling user input endpoints, and do not have a strict meaning. Make sure all unit test cases
104104
* work before change.

foundations/foundation-common/src/main/java/org/apache/servicecomb/foundation/common/utils/GenericsUtils.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@ public final class GenericsUtils {
2424
/**
2525
* check if XXX.class is generic type. see TestGenericsUtils for details meaning.
2626
* This method is provided for API compatibility for RestTemplate. Following code:
27-
*
28-
* <code>
27+
* <p>
28+
*{@code
2929
* List<GenericObjectParam<List<RecursiveObjectParam>>> response = consumers.getSCBRestTemplate()
3030
* postForObject("/testListObjectParam", request, List.class);
31-
* </code>
31+
* }
3232
*
3333
* should work for versions of 1.*. This is because java-chassis can read type info from swaggers.
34-
*
34+
* <p>
3535
* Start from 2.x, the best practise to write this code is to use ParameterizedTypeReference provided by RestTemplate
3636
* exchange method.
3737
*/

foundations/foundation-registry/src/main/java/org/apache/servicecomb/registry/api/Registration.java

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -22,42 +22,42 @@
2222

2323

2424
/**
25-
* This is the core service registration interface. <br/>
25+
* This is the core service registration interface.
2626
*/
2727
public interface Registration<R extends RegistrationInstance> extends SPIEnabled, SPIOrder, LifeCycle {
2828
String name();
2929

3030
/**
31-
* get MicroserviceInstance </br>
32-
*
31+
* get MicroserviceInstance
32+
* <p>
3333
* Life Cycle:This method is called anytime after <code>run</code>.
3434
*/
3535
R getMicroserviceInstance();
3636

3737
/**
38-
* update MicroserviceInstance status </br>
39-
*
38+
* update MicroserviceInstance status
39+
* <p>
4040
* Life Cycle:This method is called anytime after <code>run</code>.
4141
*/
4242
boolean updateMicroserviceInstanceStatus(MicroserviceInstanceStatus status);
4343

4444
/**
45-
* adding schemas to Microservice </br>
46-
*
45+
* adding schemas to Microservice
46+
* <p>
4747
* Life Cycle:This method is called after <code>init</code> and before <code>run</code>.
4848
*/
4949
void addSchema(String schemaId, String content);
5050

5151
/**
52-
* adding endpoints to MicroserviceInstance </br>
53-
*
52+
* adding endpoints to MicroserviceInstance
53+
* <p>
5454
* Life Cycle:This method is called after <code>init</code> and before <code>run</code>.
5555
*/
5656
void addEndpoint(String endpoint);
5757

5858
/**
59-
* adding property to MicroserviceInstance </br>
60-
*
59+
* adding property to MicroserviceInstance
60+
* <p>
6161
* Life Cycle:This method is called after <code>init</code> and before <code>run</code>.
6262
*/
6363
void addProperty(String key, String value);

governance/src/main/java/org/apache/servicecomb/governance/marker/operator/CompareOperator.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public String name() {
3838
}
3939

4040
/**
41-
* 支持 > < = >= <= ! 后面加数字
41+
* 支持 {@code > < = >= <= !} 后面加数字
4242
*
4343
* @param targetStr
4444
* @param patternStr

governance/src/main/java/org/apache/servicecomb/router/distribute/RouterDistributor.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,8 @@
2323
import org.apache.servicecomb.router.model.PolicyRuleItem;
2424

2525
/**
26-
* @Author GuoYl123
27-
* @Date 2019/10/17
26+
* @author GuoYl123
27+
* @since 2019/10/17
2828
**/
2929
public interface RouterDistributor<INSTANCE> {
3030

governance/src/main/java/org/apache/servicecomb/router/exception/RouterIllegalParamException.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@
1717
package org.apache.servicecomb.router.exception;
1818

1919
/**
20-
* @Author GuoYl123
21-
* @Date 2019/11/4
20+
* @author GuoYl123
21+
* @since 2019/11/4
2222
**/
2323
public class RouterIllegalParamException extends RuntimeException {
2424

governance/src/main/java/org/apache/servicecomb/router/model/HeaderRule.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,8 +21,8 @@
2121
import org.slf4j.LoggerFactory;
2222

2323
/**
24-
* @Author GuoYl123
25-
* @Date 2019/10/17
24+
* @author GuoYl123
25+
* @since 2019/10/17
2626
**/
2727
public class HeaderRule {
2828

0 commit comments

Comments
 (0)