gnodet commented on code in PR #24358:
URL: https://github.com/apache/camel/pull/24358#discussion_r3510691146
##########
tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/UpdateCamelReleasesMojo.java:
##########
@@ -117,6 +117,8 @@ private JsonArray processOldReleases() throws Exception {
return Jsoner.deserialize(json, new JsonArray());
}
+ // HttpClient does not implement AutoCloseable before Java 21; short-lived
and GC'd
+ @SuppressWarnings("java:S2095")
private List<ReleaseModel> processReleases(List<String> urls) throws
Exception {
List<ReleaseModel> answer = new ArrayList<>();
Review Comment:
_Claude Code on behalf of Guillaume Nodet_
Fixed in 32c5573 — updated comments to remove misleading "GC'd" rationale,
added try-with-resources for LineNumberReader, and corrected ShellPanel comment
to reference virtualTerminal ownership.
##########
tooling/maven/camel-package-maven-plugin/src/main/java/org/apache/camel/maven/packaging/UpdateCamelReleasesMojo.java:
##########
@@ -158,6 +160,8 @@ private List<ReleaseModel> processReleases(List<String>
urls) throws Exception {
return answer;
}
+ // HttpClient does not implement AutoCloseable before Java 21; short-lived
and GC'd
+ @SuppressWarnings("java:S2095")
private List<String> fetchCamelReleaseLinks(String gitUrl) throws
Exception {
List<String> answer = new ArrayList<>();
Review Comment:
_Claude Code on behalf of Guillaume Nodet_
Fixed in 32c5573 — updated comments to remove misleading "GC'd" rationale,
added try-with-resources for LineNumberReader, and corrected ShellPanel comment
to reference virtualTerminal ownership.
##########
test-infra/camel-test-infra-qdrant/src/main/java/org/apache/camel/test/infra/qdrant/services/QdrantInfraService.java:
##########
@@ -52,6 +52,8 @@ default String apiKey() {
return "";
}
+ // HttpClient does not implement AutoCloseable before Java 21; short-lived
and GC'd
+ @SuppressWarnings("java:S2095")
default HttpResponse<byte[]> put(String path, Map<Object, Object> body)
throws Exception {
Review Comment:
_Claude Code on behalf of Guillaume Nodet_
Fixed in 32c5573 — updated comments to remove misleading "GC'd" rationale,
added try-with-resources for LineNumberReader, and corrected ShellPanel comment
to reference virtualTerminal ownership.
##########
dsl/camel-jbang/camel-jbang-plugin-tui/src/main/java/org/apache/camel/dsl/jbang/core/commands/tui/ShellPanel.java:
##########
@@ -391,6 +391,8 @@ static Line convertRow(long[] buffer, int offset, int
width) {
private String startError;
+ // DelegateOutputStream and feedbackOutput are owned by the
virtualTerminal; closed in stopShell()
+ @SuppressWarnings("java:S2095")
private void startShell(int width, int height) {
Review Comment:
_Claude Code on behalf of Guillaume Nodet_
Fixed in 32c5573 — updated comments to remove misleading "GC'd" rationale,
added try-with-resources for LineNumberReader, and corrected ShellPanel comment
to reference virtualTerminal ownership.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]