You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tuweni.apache.org by to...@apache.org on 2021/06/08 07:33:39 UTC

[incubator-tuweni] branch main updated: Reduce crawler logging

This is an automated email from the ASF dual-hosted git repository.

toulmean pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/incubator-tuweni.git


The following commit(s) were added to refs/heads/main by this push:
     new 02096f0  Reduce crawler logging
     new 6a54005  Merge pull request #273 from atoulme/reduce_crawler_logging
02096f0 is described below

commit 02096f0cec06fd7bfd2e8c4266ced1f9324b4fce
Author: Antoine Toulme <an...@lunar-ocean.com>
AuthorDate: Mon Jun 7 23:29:34 2021 -0700

    Reduce crawler logging
---
 .../kotlin/org/apache/tuweni/eth/crawler/RelationalPeerRepository.kt | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/eth-crawler/src/main/kotlin/org/apache/tuweni/eth/crawler/RelationalPeerRepository.kt b/eth-crawler/src/main/kotlin/org/apache/tuweni/eth/crawler/RelationalPeerRepository.kt
index 6f23e7f..173c726 100644
--- a/eth-crawler/src/main/kotlin/org/apache/tuweni/eth/crawler/RelationalPeerRepository.kt
+++ b/eth-crawler/src/main/kotlin/org/apache/tuweni/eth/crawler/RelationalPeerRepository.kt
@@ -64,10 +64,9 @@ open class RelationalPeerRepository(
       stmt.setBytes(1, nodeId.bytes().toArrayUnsafe())
       try {
         val rs = stmt.executeQuery()
-        logger.info("Results")
         rs.use {
           if (!rs.next()) {
-            logger.info("Creating new peer with public key ${nodeId.toHexString()}")
+            logger.debug("Creating new peer with public key ${nodeId.toHexString()}")
             val id = UUID.randomUUID().toString()
             val insert = conn.prepareStatement("insert into identity(id, publickey) values(?, ?)")
             insert.setString(1, id)
@@ -83,7 +82,7 @@ open class RelationalPeerRepository(
             }
             return newPeer
           } else {
-            logger.info("Found existing peer with public key ${nodeId.toHexString()}")
+            logger.debug("Found existing peer with public key ${nodeId.toHexString()}")
             val id = rs.getString(1)
             val pubKey = rs.getBytes(2)
             return RepositoryPeer(SECP256K1.PublicKey.fromBytes(Bytes.wrap(pubKey)), id, endpoint, dataSource)

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@tuweni.apache.org
For additional commands, e-mail: commits-help@tuweni.apache.org