Skip to content

Commit 80e6a1c

Browse files
authored
Claude fix all docstring problems & add check to CI (#2822)
1 parent 522d669 commit 80e6a1c

File tree

31 files changed

+121
-106
lines changed

31 files changed

+121
-106
lines changed

.github/workflows/ci.yml

Lines changed: 25 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -191,7 +191,7 @@ jobs:
191191
- name: Set up Java
192192
uses: actions/setup-java@v5
193193
with:
194-
java-version: "11"
194+
java-version: "23"
195195
distribution: "temurin"
196196

197197
- name: Set up Gradle
@@ -200,6 +200,30 @@ jobs:
200200
- name: Run copyright and code format checks
201201
run: ./gradlew --no-daemon spotlessCheck
202202

203+
javadoc:
204+
name: Javadoc
205+
runs-on: ubuntu-latest
206+
timeout-minutes: 20
207+
steps:
208+
- name: Checkout repo
209+
uses: actions/checkout@v5
210+
with:
211+
fetch-depth: 0
212+
submodules: recursive
213+
ref: ${{ github.event.pull_request.head.sha }}
214+
215+
- name: Set up Java
216+
uses: actions/setup-java@v5
217+
with:
218+
java-version: "23"
219+
distribution: "temurin"
220+
221+
- name: Set up Gradle
222+
uses: gradle/actions/setup-gradle@v5
223+
224+
- name: Run javadoc
225+
run: ./gradlew --no-daemon javadoc
226+
203227
build_native_images:
204228
name: Build native test server
205229
uses: ./.github/workflows/build-native-image.yml

.gitignore

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,4 +18,6 @@ src/main/idls/*
1818
.settings
1919
.vscode/
2020
*/bin
21-
/.claude
21+
/.claude
22+
mise.local.toml
23+
**/.factorypath

gradle/java.gradle

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,8 @@ subprojects {
3232

3333
javadoc {
3434
options.encoding = 'UTF-8'
35-
if (JavaVersion.current().isJava8Compatible()) {
36-
options.addStringOption('Xdoclint:none', '-quiet')
37-
}
35+
options.addStringOption('Xdoclint:reference', '-quiet')
36+
options.addBooleanOption('Werror', true)
3837
if (JavaVersion.current().isJava9Compatible()) {
3938
options.addBooleanOption('html5', true)
4039
}

temporal-envconfig/src/main/java/io/temporal/envconfig/ClientConfig.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ public static ClientConfig fromToml(byte[] tomlData, ClientConfigFromTomlOptions
179179
*
180180
* @param config the client config to convert
181181
* @return the TOML data as bytes
182-
* @apiNote The output will not be identical to the input if the config was loaded from a file
182+
* <p>Note: The output will not be identical to the input if the config was loaded from a file
183183
* because comments and formatting are not preserved.
184184
*/
185185
public static byte[] toTomlAsBytes(ClientConfig config) throws IOException {

temporal-remote-data-encoder/src/main/java/io/temporal/payload/codec/AbstractRemoteDataEncoderCodec.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@
1111
/**
1212
* Performs encoding/decoding of the payloads via the Remote Data Encoder (RDE) available over http.
1313
*
14-
* <p>
15-
*
1614
* <h2>Remote Data Encoder Http Server specification</h2>
1715
*
1816
* <p>RDE Server must:

temporal-sdk/src/main/java/io/temporal/activity/ActivityInfo.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,8 @@ public interface ActivityInfo {
126126
/**
127127
* Return the priority of the activity task.
128128
*
129-
* @apiNote If unset or on an older server version, this method will return {@link
130-
* Priority#getDefaultInstance()}.
129+
* <p>Note: If unset or on an older server version, this method will return {@link
130+
* Priority#getDefaultInstance()}.
131131
*/
132132
@Experimental
133133
@Nonnull

temporal-sdk/src/main/java/io/temporal/activity/ActivityInterface.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,6 @@
4242
* When <code>CImpl</code> instance is registered with the {@link io.temporal.worker.Worker} the
4343
* following activities are registered:
4444
*
45-
* <p>
46-
*
4745
* <ul>
4846
* <li>B_a
4947
* <li>B_b

temporal-sdk/src/main/java/io/temporal/client/WorkflowClient.java

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -158,9 +158,8 @@ static WorkflowClient newInstance(WorkflowServiceStubs service, WorkflowClientOp
158158
* @param workflowId Workflow id.
159159
* @param runId Run id of the workflow execution.
160160
* @return Stub that implements workflowInterface and can be used to signal, update, or query it.
161-
* @deprecated Use {@link #newWorkflowStub(Class, WorkflowTargetOptions)} instead.
162-
* @apiNote This method is deprecated because the returned stub does not properly account for the
163-
* runId.
161+
* @deprecated Use {@link #newWorkflowStub(Class, WorkflowTargetOptions)} instead. This method is
162+
* deprecated because the returned stub does not properly account for the runId.
164163
*/
165164
@Deprecated
166165
<T> T newWorkflowStub(Class<T> workflowInterface, String workflowId, Optional<String> runId);
@@ -205,9 +204,8 @@ static WorkflowClient newInstance(WorkflowServiceStubs service, WorkflowClientOp
205204
* workflowId is assumed.
206205
* @param workflowType type of the workflow. Optional as it is used for error reporting only.
207206
* @return Stub that can be used to start workflow and later to signal or query it.
208-
* @deprecated Use {@link #newUntypedWorkflowStub(WorkflowTargetOptions, Optional)} instead.
209-
* @apiNote This method is deprecated because the returned stub does not properly account for the
210-
* runId.
207+
* @deprecated Use {@link #newUntypedWorkflowStub(WorkflowTargetOptions, Optional)} instead. This
208+
* method is deprecated because the returned stub does not properly account for the runId.
211209
*/
212210
@Deprecated
213211
WorkflowStub newUntypedWorkflowStub(
@@ -220,9 +218,8 @@ WorkflowStub newUntypedWorkflowStub(
220218
* @param execution workflow id and optional run id for execution
221219
* @param workflowType type of the workflow. Optional as it is used for error reporting only.
222220
* @return Stub that can be used to start workflow and later to signal or query it.
223-
* @deprecated Use {@link #newUntypedWorkflowStub(WorkflowTargetOptions, Optional)} instead.
224-
* @apiNote This method is deprecated because the returned stub does not properly account for the
225-
* runId.
221+
* @deprecated Use {@link #newUntypedWorkflowStub(WorkflowTargetOptions, Optional)} instead. This
222+
* method is deprecated because the returned stub does not properly account for the runId.
226223
*/
227224
WorkflowStub newUntypedWorkflowStub(WorkflowExecution execution, Optional<String> workflowType);
228225

temporal-sdk/src/main/java/io/temporal/client/WorkflowClientPlugin.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -27,9 +27,9 @@
2727
/**
2828
* Plugin interface for customizing Temporal workflow client configuration.
2929
*
30-
* <p>This interface is separate from {@link
31-
* io.temporal.serviceclient.WorkflowServiceStubs.ServiceStubsPlugin} to allow plugins that only
32-
* need to configure the workflow client without affecting the underlying gRPC connection.
30+
* <p>This interface is separate from {@link io.temporal.serviceclient.WorkflowServiceStubsPlugin}
31+
* to allow plugins that only need to configure the workflow client without affecting the underlying
32+
* gRPC connection.
3333
*
3434
* <p>Plugins that implement both {@code ServiceStubsPlugin} and {@code WorkflowClientPlugin} will
3535
* have their service stubs configuration applied when creating the service stubs, and their client
@@ -54,7 +54,7 @@
5454
* }
5555
* }</pre>
5656
*
57-
* @see io.temporal.serviceclient.WorkflowServiceStubs.ServiceStubsPlugin
57+
* @see io.temporal.serviceclient.WorkflowServiceStubsPlugin
5858
* @see io.temporal.worker.WorkerPlugin
5959
* @see SimplePlugin
6060
*/

temporal-sdk/src/main/java/io/temporal/client/WorkflowExecutionDescription.java

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@ public WorkflowExecutionDescription(
2222
/**
2323
* Get the fixed summary for this workflow execution.
2424
*
25-
* @apiNote Will be decoded on each invocation, so it is recommended to cache the result if it is
26-
* used multiple times.
25+
* <p>Note: Will be decoded on each invocation, so it is recommended to cache the result if it is
26+
* used multiple times.
2727
*/
2828
@Experimental
2929
@Nullable
@@ -45,8 +45,8 @@ public String getStaticSummary() {
4545
/**
4646
* Get the details summary for this workflow execution.
4747
*
48-
* @apiNote Will be decoded on each invocation, so it is recommended to cache the result if it is
49-
* used multiple times.
48+
* <p>Note: Will be decoded on each invocation, so it is recommended to cache the result if it is
49+
* used multiple times.
5050
*/
5151
@Experimental
5252
@Nullable

0 commit comments

Comments
 (0)