You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@ignite.apache.org by "Pochatkin (via GitHub)" <gi...@apache.org> on 2025/09/30 11:38:46 UTC
[PR] IGNITE-26418 Fix potential netty buffers leak [ignite-3]
Pochatkin opened a new pull request, #6674:
URL: https://github.com/apache/ignite-3/pull/6674
Thank you for submitting the pull request.
To streamline the review process of the patch and ensure better code quality
we ask both an author and a reviewer to verify the following:
### The Review Checklist
- [ ] **Formal criteria:** TC status, codestyle, mandatory documentation. Also make sure to complete the following:
\- There is a single JIRA ticket related to the pull request.
\- The web-link to the pull request is attached to the JIRA ticket.
\- The JIRA ticket has the Patch Available state.
\- The description of the JIRA ticket explains WHAT was made, WHY and HOW.
\- The pull request title is treated as the final commit message. The following pattern must be used: IGNITE-XXXX Change summary where XXXX - number of JIRA issue.
- [ ] **Design:** new code conforms with the design principles of the components it is added to.
- [ ] **Patch quality:** patch cannot be split into smaller pieces, its size must be reasonable.
- [ ] **Code quality:** code is clean and readable, necessary developer documentation is added if needed.
- [ ] **Tests code quality:** test set covers positive/negative scenarios, happy/edge cases. Tests are effective in terms of execution time and resources.
### Notes
- [Apache Ignite Coding Guidelines](https://cwiki.apache.org/confluence/display/IGNITE/Java+Code+Style+Guide)
--
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: notifications-unsubscribe@ignite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] IGNITE-26418 Fix potential netty buffers leak [ignite-3]
Posted by "valepakh (via GitHub)" <gi...@apache.org>.
valepakh commented on PR #6674:
URL: https://github.com/apache/ignite-3/pull/6674#issuecomment-3359937774
Introduction of the temp storage looks good, but apparently this didn't solve the netty leak problem.
I'd say we should investigate this more thoroughly, maybe wrap the file uploads and log the close calls?
--
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: notifications-unsubscribe@ignite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] IGNITE-26418 Fix potential netty buffers leak [ignite-3]
Posted by "Pochatkin (via GitHub)" <gi...@apache.org>.
Pochatkin merged PR #6674:
URL: https://github.com/apache/ignite-3/pull/6674
--
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: notifications-unsubscribe@ignite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] IGNITE-26418 Fix potential netty buffers leak [ignite-3]
Posted by "ptupitsyn (via GitHub)" <gi...@apache.org>.
ptupitsyn commented on PR #6674:
URL: https://github.com/apache/ignite-3/pull/6674#issuecomment-3351774314
Please don't forget to remove `// TODO IGNITE-26418 Netty buffer leaks in REST API` from `DeploymentUtils`.
--
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: notifications-unsubscribe@ignite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
Re: [PR] IGNITE-26418 Fix potential netty buffers leak [ignite-3]
Posted by "valepakh (via GitHub)" <gi...@apache.org>.
valepakh commented on code in PR #6674:
URL: https://github.com/apache/ignite-3/pull/6674#discussion_r2410445948
##########
modules/code-deployment/src/main/java/org/apache/ignite/internal/deployunit/tempstorage/TempStorage.java:
##########
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.ignite.internal.deployunit.tempstorage;
+
+import java.io.InputStream;
+import java.nio.file.Path;
+import java.util.concurrent.CompletableFuture;
+
+/**
+ * Temporary storage for deployment unit files.
+ */
+public interface TempStorage {
+ /**
+ * Stores the given input stream as a file with the given name in the temporary storage.
+ *
+ * @param fileName the name of the file to store.
+ * @param is the input stream to store.
+ */
+ CompletableFuture<Path> store(String fileName, InputStream is);
+
+ /**
+ * Rollbacks the temporary storage, deleting all stored files.
Review Comment:
It seems from the implementation that this method simply cancels the process of storing but not deleting anything?
##########
modules/code-deployment/src/main/java/org/apache/ignite/internal/deployunit/FileDeployerService.java:
##########
@@ -43,25 +49,31 @@ public class FileDeployerService {
private static final int DEPLOYMENT_EXECUTOR_SIZE = 4;
+ private final TempStorageProviderImpl tempStorageProvider;
+
/**
* Folder for units.
*/
private Path unitsFolder;
private final ExecutorService executor;
- private final DeploymentUnitProcessor<Path> deployProcessor = new DeployerProcessor();
+ private final DeploymentUnitProcessor<DeployArg, Boolean> deployProcessor;
/** Constructor. */
public FileDeployerService(String nodeName) {
- executor = Executors.newFixedThreadPool(
+ this.executor = Executors.newFixedThreadPool(
Review Comment:
```suggestion
executor = Executors.newFixedThreadPool(
```
--
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: notifications-unsubscribe@ignite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org