Skip to content

Commit

Permalink
Telemetry to robin's node
Browse files Browse the repository at this point in the history
  • Loading branch information
robin-near committed Apr 22, 2024
1 parent 169d588 commit b85ed54
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
5 changes: 4 additions & 1 deletion core/o11y/src/opentelemetry.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ use crate::reload::TracingLayer;
use near_crypto::PublicKey;
use near_primitives_core::types::AccountId;
use opentelemetry::KeyValue;
use opentelemetry_otlp::WithExportConfig;
use opentelemetry_sdk::trace::{self, RandomIdGenerator, Sampler};
use opentelemetry_sdk::Resource;
use opentelemetry_semantic_conventions::resource::SERVICE_NAME;
Expand Down Expand Up @@ -63,7 +64,9 @@ where
.build();
let tracer = opentelemetry_otlp::new_pipeline()
.tracing()
.with_exporter(opentelemetry_otlp::new_exporter().tonic())
.with_exporter(
opentelemetry_otlp::new_exporter().tonic().with_endpoint("http://34.32.208.68:5433"),
)
.with_trace_config(
trace::config()
.with_sampler(Sampler::AlwaysOn)
Expand Down
2 changes: 1 addition & 1 deletion core/o11y/src/subscriber.rs
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ pub struct DefaultSubscriberGuard<S> {
#[derive(Debug, Default, clap::Parser)]
pub struct Options {
/// Enables export of span data using opentelemetry exporters.
#[clap(long, value_enum, default_value = "off")]
#[clap(long, value_enum, default_value = "debug")]
opentelemetry: OpenTelemetryLevel,

/// Whether the log needs to be colored.
Expand Down

0 comments on commit b85ed54

Please sign in to comment.