Module network::logging

source ·
Expand description

This module is to contain all networking logging information.

use diem_config::network_id::NetworkContext;
use diem_logger::info;
use diem_types::{PeerId, network_address::NetworkAddress};
use network::logging::NetworkSchema;

info!(
  NetworkSchema::new(&NetworkContext::mock())
    .remote_peer(&PeerId::random())
    .network_address(&NetworkAddress::mock()),
  field_name = "field",
  "Value is {} message",
  5
);

Structs