You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pinot.apache.org by je...@apache.org on 2019/01/31 18:20:43 UTC
[incubator-pinot] branch master updated: Remove unnecessary init
from crypter (#3770)
This is an automated email from the ASF dual-hosted git repository.
jenniferdai pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-pinot.git
The following commit(s) were added to refs/heads/master by this push:
new ec6a6e0 Remove unnecessary init from crypter (#3770)
ec6a6e0 is described below
commit ec6a6e05c41bc62f45dd69ddfa9945c6b0519bb3
Author: Jennifer Dai <je...@users.noreply.github.com>
AuthorDate: Thu Jan 31 10:20:39 2019 -0800
Remove unnecessary init from crypter (#3770)
* Crypter is initialized in controller/server starter, so we do not need to init it here. The problem with initing here is that there can be a possible race condition where we are trying to decrypt another segment but the keys will have disappeared since we have now introduced concurrent segment downloads
---
.../org/apache/pinot/server/starter/helix/SegmentFetcherAndLoader.java | 2 --
1 file changed, 2 deletions(-)
diff --git a/pinot-server/src/main/java/org/apache/pinot/server/starter/helix/SegmentFetcherAndLoader.java b/pinot-server/src/main/java/org/apache/pinot/server/starter/helix/SegmentFetcherAndLoader.java
index a2f5b8d..5126525 100644
--- a/pinot-server/src/main/java/org/apache/pinot/server/starter/helix/SegmentFetcherAndLoader.java
+++ b/pinot-server/src/main/java/org/apache/pinot/server/starter/helix/SegmentFetcherAndLoader.java
@@ -202,8 +202,6 @@ public class SegmentFetcherAndLoader {
try {
SegmentFetcherFactory.getInstance().getSegmentFetcherBasedOnURI(uri).fetchSegmentToLocal(uri, tempDownloadFile);
if (crypter != null) {
- // TODO: We should not need to initialize crypter each time, instead Factory should have an initialized version ready.
- crypter.init(_crypterConfig);
crypter.decrypt(tempDownloadFile, tempTarFile);
} else {
tempTarFile = tempDownloadFile;
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@pinot.apache.org
For additional commands, e-mail: commits-help@pinot.apache.org