Skip to content

Commit faec79f

Browse files
greenc-FNALmksahakyan
authored andcommitted
pool: Improve logging for hot file replication
Motivation: To facilitate debug of user reports regarding hot file replication. Modification: - Add enablement information to mover request debug messages. - Add new debug messages to `MigrationModule.reportFileRequests()` on: - NOP due to failure to exceed replication threshold. - Discovery of an existing hot file replication job for the same `PnfsId`. Result: Improved logging for diagnostic purposes when addressing user reports of hot file replication issues. Target: master Request: 11.2 Patch: https://rb.dcache.org/r/14655/diff/raw Closes: Requires-notes: yes Requires-book: no Acked-by: Dmitry Litvintsev
1 parent 4c74631 commit faec79f

2 files changed

Lines changed: 6 additions & 2 deletions

File tree

modules/dcache/src/main/java/org/dcache/pool/classic/PoolV4.java

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -752,8 +752,9 @@ private int queueIoRequest(CellMessage envelope, PoolIoFileMessage message)
752752
private void ioFile(CellMessage envelope, PoolIoFileMessage message) {
753753
try {
754754
message.setMoverId(queueIoRequest(envelope, message));
755-
LOGGER.debug("moverId {} received request for pnfsId {}", message.getMoverId(),
756-
message.getPnfsId());
755+
LOGGER.debug("moverId {} received request for pnfsId {}, hotfile replication is {}",
756+
message.getMoverId(), message.getPnfsId(), _hotFileReplicationEnabled
757+
? "enabled" : "disabled");
757758
if (_hotFileReplicationEnabled) {
758759
_fileRequestMonitor.reportFileRequest(message.getPnfsId(),
759760
_ioQueue.numberOfRequestsFor(message.getPnfsId()),

modules/dcache/src/main/java/org/dcache/pool/migration/MigrationModule.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1252,12 +1252,15 @@ public Object messageArrived(CellMessage envelope, PoolMigrationJobCancelMessage
12521252
public synchronized void reportFileRequest(PnfsId pnfsId, long numberOfRequests,
12531253
ProtocolInfo protocolInfo) {
12541254
if (numberOfRequests < hotFileThreshold) {
1255+
LOGGER.debug("hotfile replication : conditions not satisfied numberOfRequests {} < hotFileThreshold {}",
1256+
numberOfRequests, hotFileThreshold);
12551257
return;
12561258
}
12571259
String jobId = "hotfile-" + pnfsId;
12581260
try {
12591261
Job job = _jobs.get(jobId);
12601262
if (job != null) {
1263+
LOGGER.debug("hotfile replication : found job with jobid {} in state {}", jobId, job.getState());
12611264
switch (job.getState()) {
12621265
case FINISHED:
12631266
case CANCELLED:

0 commit comments

Comments
 (0)