From 120980100bbe2e815afe71069eaaca861602ccbc Mon Sep 17 00:00:00 2001 From: Zlatin Balevsky Date: Mon, 24 Jun 2019 18:11:55 +0100 Subject: [PATCH] log mesh creation --- core/src/main/groovy/com/muwire/core/mesh/MeshManager.groovy | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/core/src/main/groovy/com/muwire/core/mesh/MeshManager.groovy b/core/src/main/groovy/com/muwire/core/mesh/MeshManager.groovy index 5eb1d3ad..5dddcd51 100644 --- a/core/src/main/groovy/com/muwire/core/mesh/MeshManager.groovy +++ b/core/src/main/groovy/com/muwire/core/mesh/MeshManager.groovy @@ -1,5 +1,6 @@ package com.muwire.core.mesh +import java.util.logging.Level import java.util.stream.Collectors import com.muwire.core.Constants @@ -12,8 +13,10 @@ import com.muwire.core.util.DataUtil import groovy.json.JsonOutput import groovy.json.JsonSlurper +import groovy.util.logging.Log import net.i2p.data.Base64 +@Log class MeshManager { private static final int EXPIRATION = 60 * 60 * 1000 @@ -36,6 +39,7 @@ class MeshManager { synchronized(meshes) { if (meshes.containsKey(infoHash)) return meshes.get(infoHash) + log.log(Level.INFO,"creating mesh with pieces:$nPieces", new Exception()) Pieces pieces = new Pieces(nPieces, Constants.DOWNLOAD_SEQUENTIAL_RATIO) if (fileManager.rootToFiles.containsKey(infoHash)) { for (int i = 0; i < nPieces; i++)