• Home
  • Raw
  • Download

Lines Matching refs:ctxNow

193     if (ctxNow.master) {  in FileModeSync()
194 …WRITE_LOG(LOG_DEBUG, "FileModeSync master ctxNow.fileModeSync = %d size = %zu", ctxNow.fileModeSyn… in FileModeSync()
195 ctxNow.dirMode.size()); in FileModeSync()
196 if (ctxNow.dirMode.size() > 0) { in FileModeSync()
197 auto mode = ctxNow.dirMode.back(); in FileModeSync()
201 ctxNow.dirMode.pop_back(); in FileModeSync()
204 string s = SerialStruct::SerializeToString(ctxNow.transferConfig); in FileModeSync()
208 ctxNow.fileModeSync = true; in FileModeSync()
211 SerialStruct::ParseFromString(ctxNow.fileMode, serialString); in FileModeSync()
240 ctxNow.dirModeMap.insert(std::make_pair(dirMode.fullName, dirMode)); in FileModeSync()
254 TransferConfig &stat = ctxNow.transferConfig; in SlaveCheck()
256 ctxNow.fileSize = stat.fileSize; in SlaveCheck()
257 ctxNow.localPath = stat.path; in SlaveCheck()
258 ctxNow.master = false; in SlaveCheck()
259 ctxNow.fsOpenReq.data = &ctxNow; in SlaveCheck()
261 WRITE_LOG(LOG_DEBUG, "HdcFile fileSize got %" PRIu64 "", ctxNow.fileSize); in SlaveCheck()
264 if (!CheckLocalPath(ctxNow.localPath, stat.optionalName, errStr)) { in SlaveCheck()
269 if (!CheckFilename(ctxNow.localPath, stat.optionalName, errStr)) { in SlaveCheck()
274 childRet = SmartSlavePath(stat.clientCwd, ctxNow.localPath, stat.optionalName.c_str()); in SlaveCheck()
275 if (childRet && ctxNow.transferConfig.updateIfNew) { // file exist and option need update in SlaveCheck()
278 uv_fs_stat(nullptr, &fs, ctxNow.localPath.c_str(), nullptr); in SlaveCheck()
280 if ((uint64_t)fs.statbuf.st_mtim.tv_sec >= ctxNow.transferConfig.mtime) { in SlaveCheck()
281 … LogMsg(MSG_FAIL, "Target file is the same date or newer,path: %s", ctxNow.localPath.c_str()); in SlaveCheck()
287 …uv_fs_open(loopTask, &ctxNow.fsOpenReq, ctxNow.localPath.c_str(), UV_FS_O_TRUNC | UV_FS_O_CREAT | … in SlaveCheck()
289 if (ctxNow.transferDirBegin == 0) { in SlaveCheck()
290 ctxNow.transferDirBegin = Base::GetRuntimeMSec(); in SlaveCheck()
292 ctxNow.transferBegin = Base::GetRuntimeMSec(); in SlaveCheck()
304 context->localName.c_str(), context->localPath.c_str(), ctxNow.taskQueue.size()); in TransferNext()
321 ret = BeginTransfer(&ctxNow, s); in CommandDispatch()
322 ctxNow.transferBegin = Base::GetRuntimeMSec(); in CommandDispatch()
336 … WRITE_LOG(LOG_DEBUG, "Dir = %d taskQueue size = %d", ctxNow.isDir, ctxNow.taskQueue.size()); in CommandDispatch()
337 if (ctxNow.isDir && (ctxNow.taskQueue.size() > 0)) { in CommandDispatch()
338 TransferNext(&ctxNow); in CommandDispatch()
340 ctxNow.ioFinish = true; in CommandDispatch()
341 ctxNow.transferDirBegin = 0; in CommandDispatch()
346 TransferSummary(&ctxNow); in CommandDispatch()