File tree Expand file tree Collapse file tree 3 files changed +17
-1
lines changed Expand file tree Collapse file tree 3 files changed +17
-1
lines changed Original file line number Diff line number Diff line change @@ -1530,7 +1530,9 @@ impl EnvelopeProcessor {
15301530
15311531 metric ! (
15321532 counter( RelayCounters :: EventTransactionSource ) += 1 ,
1533- source = & source. to_string( )
1533+ source = & source. to_string( ) ,
1534+ sdk = envelope. meta( ) . client_name( ) . unwrap_or( "proprietary" ) ,
1535+ platform = event. platform. as_str( ) . unwrap_or( "other" ) ,
15341536 ) ;
15351537 }
15361538 }
Original file line number Diff line number Diff line change @@ -204,10 +204,21 @@ pub struct RequestMeta<D = PartialDsn> {
204204
205205impl < D > RequestMeta < D > {
206206 /// Returns the client that sent this event (Sentry SDK identifier).
207+ ///
208+ /// The client is formatted as `"sdk/version"`, for example `"raven-node/2.6.3"`.
207209 pub fn client ( & self ) -> Option < & str > {
208210 self . client . as_deref ( )
209211 }
210212
213+ /// Returns the name of the client that sent the event without version.
214+ ///
215+ /// If the client is not sent in standard format, this method returns `None`.
216+ pub fn client_name ( & self ) -> Option < & str > {
217+ let client = self . client ( ) ?;
218+ let ( name, _version) = client. split_once ( '/' ) ?;
219+ Some ( name)
220+ }
221+
211222 /// Returns the protocol version of the event payload.
212223 pub fn version ( & self ) -> u16 {
213224 self . version
Original file line number Diff line number Diff line change @@ -450,6 +450,9 @@ pub enum RelayCounters {
450450 /// The number of transaction events processed by the source of the transaction name.
451451 ///
452452 /// This metric is tagged with:
453+ /// - `platform`: The event's platform, such as `"javascript"`.
454+ /// - `sdk`: The name of the Sentry SDK sending the transaction. This tag is only set for
455+ /// Sentry's SDKs and defaults to "proprietary".
453456 /// - `source`: The source of the transaction name on the client. See the [transaction source
454457 /// documentation](https://develop.sentry.dev/sdk/event-payloads/properties/transaction_info/)
455458 /// for all valid values.
You can’t perform that action at this time.
0 commit comments