aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoraozeritsky <aozeritsky@ydb.tech>2023-11-15 21:10:36 +0300
committeraozeritsky <aozeritsky@ydb.tech>2023-11-15 22:05:47 +0300
commit8e70c7251e94222a2475b7d9b2025b5c33cfd6c1 (patch)
treea595a62611988a2f9b520decbd7d45870ca41482
parent7434cc06afd2ef8e9297f65c03d1fee169119949 (diff)
downloadydb-8e70c7251e94222a2475b7d9b2025b5c33cfd6c1.tar.gz
Filecache per nodeId
-rw-r--r--ydb/library/yql/tools/dq/worker_node/main.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/ydb/library/yql/tools/dq/worker_node/main.cpp b/ydb/library/yql/tools/dq/worker_node/main.cpp
index ed1cfc53fc..691308da80 100644
--- a/ydb/library/yql/tools/dq/worker_node/main.cpp
+++ b/ydb/library/yql/tools/dq/worker_node/main.cpp
@@ -265,9 +265,6 @@ int main(int argc, char** argv) {
backendConfig.SetToken(coordinatorConfig.GetToken());
backendConfig.SetClusterName(coordinatorConfig.GetClusterName());
- TString fileCacheDir = "./file_cache123";
- IFileCache::TPtr fileCache = new TFileCache(fileCacheDir, 16000000000L);
-
Cerr << host + ":" + ToString(ip) << Endl;
TMaybe<ui32> maybeNodeId;
@@ -283,6 +280,9 @@ int main(int argc, char** argv) {
);
Cerr << "My nodeId: " << nodeId << Endl;
+ TString fileCacheDir = "./file_cache/" + ToString(nodeId);
+ IFileCache::TPtr fileCache = new TFileCache(fileCacheDir, 16000000000L);
+
TString udfsDir = res.GetOrElse("udfs", "");
@@ -313,8 +313,8 @@ int main(int argc, char** argv) {
for (auto& m : functionRegistry->GetAllModuleNames()) {
auto path = *functionRegistry->FindUdfPath(m);
- Cout << m << '\t' << path << Endl;
TString objectId = MD5::Calc(path); // Production env uses MD5::File as an Id. For testing purpose we use fast version.
+ Cout << m << '\t' << path << "\t" << objectId << Endl;
if (!fileCache->Contains(objectId)) {
TString newPath = fileCacheDir + "/" + objectId;
NFs::Copy(path, newPath);