text
stringlengths
70
351k
source
stringclasses
4 values
<file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=histogram_metric_f64 roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> histogram_metric_f64!(ENCRYPTION_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> histogram_metric_f64!(ENCRYPTION_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=histogram_metric_f64 roles=use_site,macro_def use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=histogram_metric_f64 roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub mod bg_metrics_collector; pub mod request; pub mod utils; use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(HEALTH_METRIC, GLOBAL_METER); // No. of health API hits counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // API Level Metrics counter_metric!(REQUESTS_RECEIVED, GLOBAL_METER); counter_metric!(REQUEST_STATUS, GLOBAL_METER); histogram_metric_f64!(REQUEST_TIME, GLOBAL_METER); histogram_metric_f64!(EXTERNAL_REQUEST_TIME, GLOBAL_METER); // Operation Level Metrics counter_metric!(PAYMENT_OPS_COUNT, GLOBAL_METER); counter_metric!(PAYMENT_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_PAYMENT, GLOBAL_METER); //TODO: This can be removed, added for payment list debugging histogram_metric_f64!(PAYMENT_LIST_LATENCY, GLOBAL_METER); counter_metric!(REFUND_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_REFUND, GLOBAL_METER); counter_metric!(PAYMENT_CANCEL_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_CANCEL, GLOBAL_METER); counter_metric!(MANDATE_COUNT, GLOBAL_METER); counter_metric!(SUBSEQUENT_MANDATE_PAYMENT, GLOBAL_METER); // Manual retry metrics counter_metric!(MANUAL_RETRY_REQUEST_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_VALIDATION_FAILED, GLOBAL_METER); counter_metric!(STORED_TO_LOCKER, GLOBAL_METER); counter_metric!(GET_FROM_LOCKER, GLOBAL_METER); counter_metric!(DELETE_FROM_LOCKER, GLOBAL_METER); counter_metric!(CREATED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(DELETED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(GET_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(TOKENIZED_DATA_COUNT, GLOBAL_METER); // Tokenized data added counter_metric!(RETRIED_DELETE_DATA_COUNT, GLOBAL_METER); // Tokenized data retried counter_metric!(CUSTOMER_CREATED, GLOBAL_METER); counter_metric!(CUSTOMER_REDACTED, GLOBAL_METER); counter_metric!(API_KEY_CREATED, GLOBAL_METER); counter_metric!(API_KEY_REVOKED, GLOBAL_METER); counter_metric!(MCA_CREATE, GLOBAL_METER); // Flow Specific Metrics histogram_metric_f64!(CONNECTOR_REQUEST_TIME, GLOBAL_METER); counter_metric!(SESSION_TOKEN_CREATED, GLOBAL_METER); counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed counter_metric!(THREE_DS_PAYMENT_COUNT, GLOBAL_METER); counter_metric!(THREE_DS_DOWNGRADE_COUNT, GLOBAL_METER); counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); counter_metric!(CONNECTOR_ERROR_RESPONSE_COUNT, GLOBAL_METER); counter_metric!(REQUEST_TIMEOUT_COUNT, GLOBAL_METER); counter_metric!(EXECUTE_PRETASK_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_PAYMENT_METHOD_TOKENIZATION, GLOBAL_METER); counter_metric!(PREPROCESSING_STEPS_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_CUSTOMER_CREATE, GLOBAL_METER); counter_metric!(REDIRECTION_TRIGGERED, GLOBAL_METER); // Connector Level Metric counter_metric!(REQUEST_BUILD_FAILURE, GLOBAL_METER); // Connector http status code metrics counter_metric!(CONNECTOR_HTTP_STATUS_CODE_1XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_2XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_3XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_4XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_5XX_COUNT, GLOBAL_METER); // Service Level counter_metric!(CARD_LOCKER_FAILURES, GLOBAL_METER); counter_metric!(CARD_LOCKER_SUCCESSFUL_RESPONSE, GLOBAL_METER); counter_metric!(TEMP_LOCKER_FAILURES, GLOBAL_METER); histogram_metric_f64!(CARD_ADD_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_GET_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); // Apple Pay Flow Metrics counter_metric!(APPLE_PAY_MANUAL_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_FAILED_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_FAILED_PAYMENT, GLOBAL_METER); // Metrics for Payment Auto Retries counter_metric!(AUTO_RETRY_CONNECTION_CLOSED, GLOBAL_METER); counter_metric!(AUTO_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYMENT_COUNT, GLOBAL_METER); // Metrics for Payout Auto Retries counter_metric!(AUTO_PAYOUT_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYOUT_COUNT, GLOBAL_METER); // Scheduler / Process Tracker related metrics counter_metric!(TASKS_ADDED_COUNT, GLOBAL_METER); // Tasks added to process tracker counter_metric!(TASK_ADDITION_FAILURES_COUNT, GLOBAL_METER); // Failures in task addition to process tracker counter_metric!(TASKS_RESET_COUNT, GLOBAL_METER); // Tasks reset in process tracker for requeue flow // Access token metrics // // A counter to indicate the number of new access tokens created counter_metric!(ACCESS_TOKEN_CREATION, GLOBAL_METER); // A counter to indicate the access token cache hits counter_metric!(ACCESS_TOKEN_CACHE_HIT, GLOBAL_METER); // A counter to indicate the access token cache miss counter_metric!(ACCESS_TOKEN_CACHE_MISS, GLOBAL_METER); // A counter to indicate the integrity check failures counter_metric!(INTEGRITY_CHECK_FAILED, GLOBAL_METER); // Network Tokenization metrics histogram_metric_f64!(GENERATE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); // A counter to indicate allowed payment method types mismatch counter_metric!(PAYMENT_METHOD_TYPES_MISCONFIGURATION_METRIC, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> pub mod bg_metrics_collector; pub mod request; pub mod utils; use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(HEALTH_METRIC, GLOBAL_METER); // No. of health API hits counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // API Level Metrics counter_metric!(REQUESTS_RECEIVED, GLOBAL_METER); counter_metric!(REQUEST_STATUS, GLOBAL_METER); histogram_metric_f64!(REQUEST_TIME, GLOBAL_METER); histogram_metric_f64!(EXTERNAL_REQUEST_TIME, GLOBAL_METER); // Operation Level Metrics counter_metric!(PAYMENT_OPS_COUNT, GLOBAL_METER); counter_metric!(PAYMENT_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_PAYMENT, GLOBAL_METER); //TODO: This can be removed, added for payment list debugging histogram_metric_f64!(PAYMENT_LIST_LATENCY, GLOBAL_METER); counter_metric!(REFUND_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_REFUND, GLOBAL_METER); counter_metric!(PAYMENT_CANCEL_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_CANCEL, GLOBAL_METER); counter_metric!(MANDATE_COUNT, GLOBAL_METER); counter_metric!(SUBSEQUENT_MANDATE_PAYMENT, GLOBAL_METER); // Manual retry metrics counter_metric!(MANUAL_RETRY_REQUEST_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_VALIDATION_FAILED, GLOBAL_METER); counter_metric!(STORED_TO_LOCKER, GLOBAL_METER); counter_metric!(GET_FROM_LOCKER, GLOBAL_METER); counter_metric!(DELETE_FROM_LOCKER, GLOBAL_METER); counter_metric!(CREATED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(DELETED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(GET_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(TOKENIZED_DATA_COUNT, GLOBAL_METER); // Tokenized data added counter_metric!(RETRIED_DELETE_DATA_COUNT, GLOBAL_METER); // Tokenized data retried counter_metric!(CUSTOMER_CREATED, GLOBAL_METER); counter_metric!(CUSTOMER_REDACTED, GLOBAL_METER); counter_metric!(API_KEY_CREATED, GLOBAL_METER); counter_metric!(API_KEY_REVOKED, GLOBAL_METER); counter_metric!(MCA_CREATE, GLOBAL_METER); // Flow Specific Metrics histogram_metric_f64!(CONNECTOR_REQUEST_TIME, GLOBAL_METER); counter_metric!(SESSION_TOKEN_CREATED, GLOBAL_METER); counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed counter_metric!(THREE_DS_PAYMENT_COUNT, GLOBAL_METER); counter_metric!(THREE_DS_DOWNGRADE_COUNT, GLOBAL_METER); counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); counter_metric!(CONNECTOR_ERROR_RESPONSE_COUNT, GLOBAL_METER); counter_metric!(REQUEST_TIMEOUT_COUNT, GLOBAL_METER); counter_metric!(EXECUTE_PRETASK_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_PAYMENT_METHOD_TOKENIZATION, GLOBAL_METER); counter_metric!(PREPROCESSING_STEPS_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_CUSTOMER_CREATE, GLOBAL_METER); counter_metric!(REDIRECTION_TRIGGERED, GLOBAL_METER); // Connector Level Metric counter_metric!(REQUEST_BUILD_FAILURE, GLOBAL_METER); // Connector http status code metrics counter_metric!(CONNECTOR_HTTP_STATUS_CODE_1XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_2XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_3XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_4XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_5XX_COUNT, GLOBAL_METER); // Service Level counter_metric!(CARD_LOCKER_FAILURES, GLOBAL_METER); counter_metric!(CARD_LOCKER_SUCCESSFUL_RESPONSE, GLOBAL_METER); counter_metric!(TEMP_LOCKER_FAILURES, GLOBAL_METER); histogram_metric_f64!(CARD_ADD_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_GET_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); // Apple Pay Flow Metrics counter_metric!(APPLE_PAY_MANUAL_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_FAILED_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_FAILED_PAYMENT, GLOBAL_METER); // Metrics for Payment Auto Retries counter_metric!(AUTO_RETRY_CONNECTION_CLOSED, GLOBAL_METER); counter_metric!(AUTO_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYMENT_COUNT, GLOBAL_METER); // Metrics for Payout Auto Retries counter_metric!(AUTO_PAYOUT_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYOUT_COUNT, GLOBAL_METER); // Scheduler / Process Tracker related metrics counter_metric!(TASKS_ADDED_COUNT, GLOBAL_METER); // Tasks added to process tracker counter_metric!(TASK_ADDITION_FAILURES_COUNT, GLOBAL_METER); // Failures in task addition to process tracker counter_metric!(TASKS_RESET_COUNT, GLOBAL_METER); // Tasks reset in process tracker for requeue flow // Access token metrics // // A counter to indicate the number of new access tokens created counter_metric!(ACCESS_TOKEN_CREATION, GLOBAL_METER); // A counter to indicate the access token cache hits counter_metric!(ACCESS_TOKEN_CACHE_HIT, GLOBAL_METER); // A counter to indicate the access token cache miss counter_metric!(ACCESS_TOKEN_CACHE_MISS, GLOBAL_METER); // A counter to indicate the integrity check failures counter_metric!(INTEGRITY_CHECK_FAILED, GLOBAL_METER); // Network Tokenization metrics histogram_metric_f64!(GENERATE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); // A counter to indicate allowed payment method types mismatch counter_metric!(PAYMENT_METHOD_TYPES_MISCONFIGURATION_METRIC, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=histogram_metric_f64 roles=macro_def,use_site use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=histogram_metric_f64 roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=histogram_metric_f64 roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub mod bg_metrics_collector; pub mod request; pub mod utils; use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(HEALTH_METRIC, GLOBAL_METER); // No. of health API hits counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // API Level Metrics counter_metric!(REQUESTS_RECEIVED, GLOBAL_METER); counter_metric!(REQUEST_STATUS, GLOBAL_METER); histogram_metric_f64!(REQUEST_TIME, GLOBAL_METER); histogram_metric_f64!(EXTERNAL_REQUEST_TIME, GLOBAL_METER); // Operation Level Metrics counter_metric!(PAYMENT_OPS_COUNT, GLOBAL_METER); counter_metric!(PAYMENT_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_PAYMENT, GLOBAL_METER); //TODO: This can be removed, added for payment list debugging histogram_metric_f64!(PAYMENT_LIST_LATENCY, GLOBAL_METER); counter_metric!(REFUND_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_REFUND, GLOBAL_METER); counter_metric!(PAYMENT_CANCEL_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_CANCEL, GLOBAL_METER); counter_metric!(MANDATE_COUNT, GLOBAL_METER); counter_metric!(SUBSEQUENT_MANDATE_PAYMENT, GLOBAL_METER); // Manual retry metrics counter_metric!(MANUAL_RETRY_REQUEST_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_VALIDATION_FAILED, GLOBAL_METER); counter_metric!(STORED_TO_LOCKER, GLOBAL_METER); counter_metric!(GET_FROM_LOCKER, GLOBAL_METER); counter_metric!(DELETE_FROM_LOCKER, GLOBAL_METER); counter_metric!(CREATED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(DELETED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(GET_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(TOKENIZED_DATA_COUNT, GLOBAL_METER); // Tokenized data added counter_metric!(RETRIED_DELETE_DATA_COUNT, GLOBAL_METER); // Tokenized data retried counter_metric!(CUSTOMER_CREATED, GLOBAL_METER); counter_metric!(CUSTOMER_REDACTED, GLOBAL_METER); counter_metric!(API_KEY_CREATED, GLOBAL_METER); counter_metric!(API_KEY_REVOKED, GLOBAL_METER); counter_metric!(MCA_CREATE, GLOBAL_METER); // Flow Specific Metrics histogram_metric_f64!(CONNECTOR_REQUEST_TIME, GLOBAL_METER); counter_metric!(SESSION_TOKEN_CREATED, GLOBAL_METER); counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed counter_metric!(THREE_DS_PAYMENT_COUNT, GLOBAL_METER); counter_metric!(THREE_DS_DOWNGRADE_COUNT, GLOBAL_METER); counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); counter_metric!(CONNECTOR_ERROR_RESPONSE_COUNT, GLOBAL_METER); counter_metric!(REQUEST_TIMEOUT_COUNT, GLOBAL_METER); counter_metric!(EXECUTE_PRETASK_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_PAYMENT_METHOD_TOKENIZATION, GLOBAL_METER); counter_metric!(PREPROCESSING_STEPS_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_CUSTOMER_CREATE, GLOBAL_METER); counter_metric!(REDIRECTION_TRIGGERED, GLOBAL_METER); // Connector Level Metric counter_metric!(REQUEST_BUILD_FAILURE, GLOBAL_METER); // Connector http status code metrics counter_metric!(CONNECTOR_HTTP_STATUS_CODE_1XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_2XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_3XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_4XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_5XX_COUNT, GLOBAL_METER); // Service Level counter_metric!(CARD_LOCKER_FAILURES, GLOBAL_METER); counter_metric!(CARD_LOCKER_SUCCESSFUL_RESPONSE, GLOBAL_METER); counter_metric!(TEMP_LOCKER_FAILURES, GLOBAL_METER); histogram_metric_f64!(CARD_ADD_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_GET_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); // Apple Pay Flow Metrics counter_metric!(APPLE_PAY_MANUAL_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_FAILED_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_FAILED_PAYMENT, GLOBAL_METER); // Metrics for Payment Auto Retries counter_metric!(AUTO_RETRY_CONNECTION_CLOSED, GLOBAL_METER); counter_metric!(AUTO_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYMENT_COUNT, GLOBAL_METER); // Metrics for Payout Auto Retries counter_metric!(AUTO_PAYOUT_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYOUT_COUNT, GLOBAL_METER); // Scheduler / Process Tracker related metrics counter_metric!(TASKS_ADDED_COUNT, GLOBAL_METER); // Tasks added to process tracker counter_metric!(TASK_ADDITION_FAILURES_COUNT, GLOBAL_METER); // Failures in task addition to process tracker counter_metric!(TASKS_RESET_COUNT, GLOBAL_METER); // Tasks reset in process tracker for requeue flow // Access token metrics // // A counter to indicate the number of new access tokens created counter_metric!(ACCESS_TOKEN_CREATION, GLOBAL_METER); // A counter to indicate the access token cache hits counter_metric!(ACCESS_TOKEN_CACHE_HIT, GLOBAL_METER); // A counter to indicate the access token cache miss counter_metric!(ACCESS_TOKEN_CACHE_MISS, GLOBAL_METER); // A counter to indicate the integrity check failures counter_metric!(INTEGRITY_CHECK_FAILED, GLOBAL_METER); // Network Tokenization metrics histogram_metric_f64!(GENERATE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); // A counter to indicate allowed payment method types mismatch counter_metric!(PAYMENT_METHOD_TYPES_MISCONFIGURATION_METRIC, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> pub mod bg_metrics_collector; pub mod request; pub mod utils; use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(HEALTH_METRIC, GLOBAL_METER); // No. of health API hits counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // API Level Metrics counter_metric!(REQUESTS_RECEIVED, GLOBAL_METER); counter_metric!(REQUEST_STATUS, GLOBAL_METER); histogram_metric_f64!(REQUEST_TIME, GLOBAL_METER); histogram_metric_f64!(EXTERNAL_REQUEST_TIME, GLOBAL_METER); // Operation Level Metrics counter_metric!(PAYMENT_OPS_COUNT, GLOBAL_METER); counter_metric!(PAYMENT_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_PAYMENT, GLOBAL_METER); //TODO: This can be removed, added for payment list debugging histogram_metric_f64!(PAYMENT_LIST_LATENCY, GLOBAL_METER); counter_metric!(REFUND_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_REFUND, GLOBAL_METER); counter_metric!(PAYMENT_CANCEL_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_CANCEL, GLOBAL_METER); counter_metric!(MANDATE_COUNT, GLOBAL_METER); counter_metric!(SUBSEQUENT_MANDATE_PAYMENT, GLOBAL_METER); // Manual retry metrics counter_metric!(MANUAL_RETRY_REQUEST_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_VALIDATION_FAILED, GLOBAL_METER); counter_metric!(STORED_TO_LOCKER, GLOBAL_METER); counter_metric!(GET_FROM_LOCKER, GLOBAL_METER); counter_metric!(DELETE_FROM_LOCKER, GLOBAL_METER); counter_metric!(CREATED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(DELETED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(GET_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(TOKENIZED_DATA_COUNT, GLOBAL_METER); // Tokenized data added counter_metric!(RETRIED_DELETE_DATA_COUNT, GLOBAL_METER); // Tokenized data retried counter_metric!(CUSTOMER_CREATED, GLOBAL_METER); counter_metric!(CUSTOMER_REDACTED, GLOBAL_METER); counter_metric!(API_KEY_CREATED, GLOBAL_METER); counter_metric!(API_KEY_REVOKED, GLOBAL_METER); counter_metric!(MCA_CREATE, GLOBAL_METER); // Flow Specific Metrics histogram_metric_f64!(CONNECTOR_REQUEST_TIME, GLOBAL_METER); counter_metric!(SESSION_TOKEN_CREATED, GLOBAL_METER); counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed counter_metric!(THREE_DS_PAYMENT_COUNT, GLOBAL_METER); counter_metric!(THREE_DS_DOWNGRADE_COUNT, GLOBAL_METER); counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); counter_metric!(CONNECTOR_ERROR_RESPONSE_COUNT, GLOBAL_METER); counter_metric!(REQUEST_TIMEOUT_COUNT, GLOBAL_METER); counter_metric!(EXECUTE_PRETASK_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_PAYMENT_METHOD_TOKENIZATION, GLOBAL_METER); counter_metric!(PREPROCESSING_STEPS_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_CUSTOMER_CREATE, GLOBAL_METER); counter_metric!(REDIRECTION_TRIGGERED, GLOBAL_METER); // Connector Level Metric counter_metric!(REQUEST_BUILD_FAILURE, GLOBAL_METER); // Connector http status code metrics counter_metric!(CONNECTOR_HTTP_STATUS_CODE_1XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_2XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_3XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_4XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_5XX_COUNT, GLOBAL_METER); // Service Level counter_metric!(CARD_LOCKER_FAILURES, GLOBAL_METER); counter_metric!(CARD_LOCKER_SUCCESSFUL_RESPONSE, GLOBAL_METER); counter_metric!(TEMP_LOCKER_FAILURES, GLOBAL_METER); histogram_metric_f64!(CARD_ADD_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_GET_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); // Apple Pay Flow Metrics counter_metric!(APPLE_PAY_MANUAL_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_FAILED_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_FAILED_PAYMENT, GLOBAL_METER); // Metrics for Payment Auto Retries counter_metric!(AUTO_RETRY_CONNECTION_CLOSED, GLOBAL_METER); counter_metric!(AUTO_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYMENT_COUNT, GLOBAL_METER); // Metrics for Payout Auto Retries counter_metric!(AUTO_PAYOUT_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYOUT_COUNT, GLOBAL_METER); // Scheduler / Process Tracker related metrics counter_metric!(TASKS_ADDED_COUNT, GLOBAL_METER); // Tasks added to process tracker counter_metric!(TASK_ADDITION_FAILURES_COUNT, GLOBAL_METER); // Failures in task addition to process tracker counter_metric!(TASKS_RESET_COUNT, GLOBAL_METER); // Tasks reset in process tracker for requeue flow // Access token metrics // // A counter to indicate the number of new access tokens created counter_metric!(ACCESS_TOKEN_CREATION, GLOBAL_METER); // A counter to indicate the access token cache hits counter_metric!(ACCESS_TOKEN_CACHE_HIT, GLOBAL_METER); // A counter to indicate the access token cache miss counter_metric!(ACCESS_TOKEN_CACHE_MISS, GLOBAL_METER); // A counter to indicate the integrity check failures counter_metric!(INTEGRITY_CHECK_FAILED, GLOBAL_METER); // Network Tokenization metrics histogram_metric_f64!(GENERATE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); // A counter to indicate allowed payment method types mismatch counter_metric!(PAYMENT_METHOD_TYPES_MISCONFIGURATION_METRIC, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=histogram_metric_f64 roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub mod bg_metrics_collector; pub mod request; pub mod utils; use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(HEALTH_METRIC, GLOBAL_METER); // No. of health API hits counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // API Level Metrics counter_metric!(REQUESTS_RECEIVED, GLOBAL_METER); counter_metric!(REQUEST_STATUS, GLOBAL_METER); histogram_metric_f64!(REQUEST_TIME, GLOBAL_METER); histogram_metric_f64!(EXTERNAL_REQUEST_TIME, GLOBAL_METER); // Operation Level Metrics counter_metric!(PAYMENT_OPS_COUNT, GLOBAL_METER); counter_metric!(PAYMENT_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_PAYMENT, GLOBAL_METER); //TODO: This can be removed, added for payment list debugging histogram_metric_f64!(PAYMENT_LIST_LATENCY, GLOBAL_METER); counter_metric!(REFUND_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_REFUND, GLOBAL_METER); counter_metric!(PAYMENT_CANCEL_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_CANCEL, GLOBAL_METER); counter_metric!(MANDATE_COUNT, GLOBAL_METER); counter_metric!(SUBSEQUENT_MANDATE_PAYMENT, GLOBAL_METER); // Manual retry metrics counter_metric!(MANUAL_RETRY_REQUEST_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_VALIDATION_FAILED, GLOBAL_METER); counter_metric!(STORED_TO_LOCKER, GLOBAL_METER); counter_metric!(GET_FROM_LOCKER, GLOBAL_METER); counter_metric!(DELETE_FROM_LOCKER, GLOBAL_METER); counter_metric!(CREATED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(DELETED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(GET_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(TOKENIZED_DATA_COUNT, GLOBAL_METER); // Tokenized data added counter_metric!(RETRIED_DELETE_DATA_COUNT, GLOBAL_METER); // Tokenized data retried counter_metric!(CUSTOMER_CREATED, GLOBAL_METER); counter_metric!(CUSTOMER_REDACTED, GLOBAL_METER); counter_metric!(API_KEY_CREATED, GLOBAL_METER); counter_metric!(API_KEY_REVOKED, GLOBAL_METER); counter_metric!(MCA_CREATE, GLOBAL_METER); // Flow Specific Metrics histogram_metric_f64!(CONNECTOR_REQUEST_TIME, GLOBAL_METER); counter_metric!(SESSION_TOKEN_CREATED, GLOBAL_METER); counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed counter_metric!(THREE_DS_PAYMENT_COUNT, GLOBAL_METER); counter_metric!(THREE_DS_DOWNGRADE_COUNT, GLOBAL_METER); counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); counter_metric!(CONNECTOR_ERROR_RESPONSE_COUNT, GLOBAL_METER); counter_metric!(REQUEST_TIMEOUT_COUNT, GLOBAL_METER); counter_metric!(EXECUTE_PRETASK_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_PAYMENT_METHOD_TOKENIZATION, GLOBAL_METER); counter_metric!(PREPROCESSING_STEPS_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_CUSTOMER_CREATE, GLOBAL_METER); counter_metric!(REDIRECTION_TRIGGERED, GLOBAL_METER); // Connector Level Metric counter_metric!(REQUEST_BUILD_FAILURE, GLOBAL_METER); // Connector http status code metrics counter_metric!(CONNECTOR_HTTP_STATUS_CODE_1XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_2XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_3XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_4XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_5XX_COUNT, GLOBAL_METER); // Service Level counter_metric!(CARD_LOCKER_FAILURES, GLOBAL_METER); counter_metric!(CARD_LOCKER_SUCCESSFUL_RESPONSE, GLOBAL_METER); counter_metric!(TEMP_LOCKER_FAILURES, GLOBAL_METER); histogram_metric_f64!(CARD_ADD_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_GET_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); // Apple Pay Flow Metrics counter_metric!(APPLE_PAY_MANUAL_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_FAILED_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_FAILED_PAYMENT, GLOBAL_METER); // Metrics for Payment Auto Retries counter_metric!(AUTO_RETRY_CONNECTION_CLOSED, GLOBAL_METER); counter_metric!(AUTO_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYMENT_COUNT, GLOBAL_METER); // Metrics for Payout Auto Retries counter_metric!(AUTO_PAYOUT_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYOUT_COUNT, GLOBAL_METER); // Scheduler / Process Tracker related metrics counter_metric!(TASKS_ADDED_COUNT, GLOBAL_METER); // Tasks added to process tracker counter_metric!(TASK_ADDITION_FAILURES_COUNT, GLOBAL_METER); // Failures in task addition to process tracker counter_metric!(TASKS_RESET_COUNT, GLOBAL_METER); // Tasks reset in process tracker for requeue flow // Access token metrics // // A counter to indicate the number of new access tokens created counter_metric!(ACCESS_TOKEN_CREATION, GLOBAL_METER); // A counter to indicate the access token cache hits counter_metric!(ACCESS_TOKEN_CACHE_HIT, GLOBAL_METER); // A counter to indicate the access token cache miss counter_metric!(ACCESS_TOKEN_CACHE_MISS, GLOBAL_METER); // A counter to indicate the integrity check failures counter_metric!(INTEGRITY_CHECK_FAILED, GLOBAL_METER); // Network Tokenization metrics histogram_metric_f64!(GENERATE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); // A counter to indicate allowed payment method types mismatch counter_metric!(PAYMENT_METHOD_TYPES_MISCONFIGURATION_METRIC, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> pub mod bg_metrics_collector; pub mod request; pub mod utils; use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(HEALTH_METRIC, GLOBAL_METER); // No. of health API hits counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // API Level Metrics counter_metric!(REQUESTS_RECEIVED, GLOBAL_METER); counter_metric!(REQUEST_STATUS, GLOBAL_METER); histogram_metric_f64!(REQUEST_TIME, GLOBAL_METER); histogram_metric_f64!(EXTERNAL_REQUEST_TIME, GLOBAL_METER); // Operation Level Metrics counter_metric!(PAYMENT_OPS_COUNT, GLOBAL_METER); counter_metric!(PAYMENT_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_PAYMENT, GLOBAL_METER); //TODO: This can be removed, added for payment list debugging histogram_metric_f64!(PAYMENT_LIST_LATENCY, GLOBAL_METER); counter_metric!(REFUND_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_REFUND, GLOBAL_METER); counter_metric!(PAYMENT_CANCEL_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_CANCEL, GLOBAL_METER); counter_metric!(MANDATE_COUNT, GLOBAL_METER); counter_metric!(SUBSEQUENT_MANDATE_PAYMENT, GLOBAL_METER); // Manual retry metrics counter_metric!(MANUAL_RETRY_REQUEST_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_VALIDATION_FAILED, GLOBAL_METER); counter_metric!(STORED_TO_LOCKER, GLOBAL_METER); counter_metric!(GET_FROM_LOCKER, GLOBAL_METER); counter_metric!(DELETE_FROM_LOCKER, GLOBAL_METER); counter_metric!(CREATED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(DELETED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(GET_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(TOKENIZED_DATA_COUNT, GLOBAL_METER); // Tokenized data added counter_metric!(RETRIED_DELETE_DATA_COUNT, GLOBAL_METER); // Tokenized data retried counter_metric!(CUSTOMER_CREATED, GLOBAL_METER); counter_metric!(CUSTOMER_REDACTED, GLOBAL_METER); counter_metric!(API_KEY_CREATED, GLOBAL_METER); counter_metric!(API_KEY_REVOKED, GLOBAL_METER); counter_metric!(MCA_CREATE, GLOBAL_METER); // Flow Specific Metrics histogram_metric_f64!(CONNECTOR_REQUEST_TIME, GLOBAL_METER); counter_metric!(SESSION_TOKEN_CREATED, GLOBAL_METER); counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed counter_metric!(THREE_DS_PAYMENT_COUNT, GLOBAL_METER); counter_metric!(THREE_DS_DOWNGRADE_COUNT, GLOBAL_METER); counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); counter_metric!(CONNECTOR_ERROR_RESPONSE_COUNT, GLOBAL_METER); counter_metric!(REQUEST_TIMEOUT_COUNT, GLOBAL_METER); counter_metric!(EXECUTE_PRETASK_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_PAYMENT_METHOD_TOKENIZATION, GLOBAL_METER); counter_metric!(PREPROCESSING_STEPS_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_CUSTOMER_CREATE, GLOBAL_METER); counter_metric!(REDIRECTION_TRIGGERED, GLOBAL_METER); // Connector Level Metric counter_metric!(REQUEST_BUILD_FAILURE, GLOBAL_METER); // Connector http status code metrics counter_metric!(CONNECTOR_HTTP_STATUS_CODE_1XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_2XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_3XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_4XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_5XX_COUNT, GLOBAL_METER); // Service Level counter_metric!(CARD_LOCKER_FAILURES, GLOBAL_METER); counter_metric!(CARD_LOCKER_SUCCESSFUL_RESPONSE, GLOBAL_METER); counter_metric!(TEMP_LOCKER_FAILURES, GLOBAL_METER); histogram_metric_f64!(CARD_ADD_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_GET_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); // Apple Pay Flow Metrics counter_metric!(APPLE_PAY_MANUAL_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_FAILED_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_FAILED_PAYMENT, GLOBAL_METER); // Metrics for Payment Auto Retries counter_metric!(AUTO_RETRY_CONNECTION_CLOSED, GLOBAL_METER); counter_metric!(AUTO_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYMENT_COUNT, GLOBAL_METER); // Metrics for Payout Auto Retries counter_metric!(AUTO_PAYOUT_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYOUT_COUNT, GLOBAL_METER); // Scheduler / Process Tracker related metrics counter_metric!(TASKS_ADDED_COUNT, GLOBAL_METER); // Tasks added to process tracker counter_metric!(TASK_ADDITION_FAILURES_COUNT, GLOBAL_METER); // Failures in task addition to process tracker counter_metric!(TASKS_RESET_COUNT, GLOBAL_METER); // Tasks reset in process tracker for requeue flow // Access token metrics // // A counter to indicate the number of new access tokens created counter_metric!(ACCESS_TOKEN_CREATION, GLOBAL_METER); // A counter to indicate the access token cache hits counter_metric!(ACCESS_TOKEN_CACHE_HIT, GLOBAL_METER); // A counter to indicate the access token cache miss counter_metric!(ACCESS_TOKEN_CACHE_MISS, GLOBAL_METER); // A counter to indicate the integrity check failures counter_metric!(INTEGRITY_CHECK_FAILED, GLOBAL_METER); // Network Tokenization metrics histogram_metric_f64!(GENERATE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); // A counter to indicate allowed payment method types mismatch counter_metric!(PAYMENT_METHOD_TYPES_MISCONFIGURATION_METRIC, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=histogram_metric_f64 roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=histogram_metric_f64 roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! histogram_metric_f64 { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; ($name:ident, $meter:ident, $description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Histogram<f64>, > = once_cell::sync::Lazy::new(|| { $meter .f64_histogram(stringify!($name)) .with_description($description) .with_boundaries($crate::metrics::f64_histogram_buckets()) .build() }); }; } <file_sep path="hyperswitch/crates/diesel_models/src/lib.rs" crate="diesel_models" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> diesel_models macro=histogram_metric_f64 roles=macro_def,use_site use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/diesel_models/src/lib.rs" crate="diesel_models" role="use_site"> <|fim_prefix|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=counter_metric roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=counter_metric roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=counter_metric roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(INCOMING_DISPUTE_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks counter_metric!( INCOMING_DISPUTE_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which signature verification failed counter_metric!( INCOMING_DISPUTE_WEBHOOK_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which validation failed counter_metric!(INCOMING_DISPUTE_WEBHOOK_NEW_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which new record is created in our db counter_metric!(INCOMING_DISPUTE_WEBHOOK_UPDATE_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which we have updated the details to existing record counter_metric!( INCOMING_DISPUTE_WEBHOOK_MERCHANT_NOTIFIED_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks which are notified to merchant counter_metric!( ACCEPT_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while accepting a dispute counter_metric!( EVIDENCE_SUBMISSION_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while submitting evidence for a dispute //No. of status validation failures while attaching evidence for a dispute counter_metric!( ATTACH_EVIDENCE_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); counter_metric!(INCOMING_PAYOUT_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming payout webhooks counter_metric!( INCOMING_PAYOUT_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming payout webhooks for which signature verification failed counter_metric!(WEBHOOK_INCOMING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_INCOMING_FILTERED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_SOURCE_VERIFIED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_NOT_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_PAYMENT_NOT_FOUND, GLOBAL_METER); counter_metric!( WEBHOOK_EVENT_TYPE_IDENTIFICATION_FAILURE_COUNT, GLOBAL_METER ); counter_metric!(ROUTING_CREATE_REQUEST_RECEIVED, GLOBAL_METER); counter_metric!(ROUTING_CREATE_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_MERCHANT_DICTIONARY_RETRIEVE, GLOBAL_METER); counter_metric!( ROUTING_MERCHANT_DICTIONARY_RETRIEVE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_DEFAULT_CONFIG, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_DEFAULT_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_UPDATE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(DYNAMIC_SUCCESS_BASED_ROUTING, GLOBAL_METER); counter_metric!(DYNAMIC_CONTRACT_BASED_ROUTING, GLOBAL_METER); #[cfg(feature = "partial-auth")] counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(INCOMING_DISPUTE_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks counter_metric!( INCOMING_DISPUTE_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which signature verification failed counter_metric!( INCOMING_DISPUTE_WEBHOOK_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which validation failed counter_metric!(INCOMING_DISPUTE_WEBHOOK_NEW_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which new record is created in our db counter_metric!(INCOMING_DISPUTE_WEBHOOK_UPDATE_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which we have updated the details to existing record counter_metric!( INCOMING_DISPUTE_WEBHOOK_MERCHANT_NOTIFIED_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks which are notified to merchant counter_metric!( ACCEPT_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while accepting a dispute counter_metric!( EVIDENCE_SUBMISSION_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while submitting evidence for a dispute //No. of status validation failures while attaching evidence for a dispute counter_metric!( ATTACH_EVIDENCE_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); counter_metric!(INCOMING_PAYOUT_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming payout webhooks counter_metric!( INCOMING_PAYOUT_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming payout webhooks for which signature verification failed counter_metric!(WEBHOOK_INCOMING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_INCOMING_FILTERED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_SOURCE_VERIFIED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_NOT_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_PAYMENT_NOT_FOUND, GLOBAL_METER); counter_metric!( WEBHOOK_EVENT_TYPE_IDENTIFICATION_FAILURE_COUNT, GLOBAL_METER ); counter_metric!(ROUTING_CREATE_REQUEST_RECEIVED, GLOBAL_METER); counter_metric!(ROUTING_CREATE_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_MERCHANT_DICTIONARY_RETRIEVE, GLOBAL_METER); counter_metric!( ROUTING_MERCHANT_DICTIONARY_RETRIEVE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_DEFAULT_CONFIG, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_DEFAULT_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_UPDATE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(DYNAMIC_SUCCESS_BASED_ROUTING, GLOBAL_METER); counter_metric!(DYNAMIC_CONTRACT_BASED_ROUTING, GLOBAL_METER); #[cfg(feature = "partial-auth")] counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=counter_metric roles=macro_def,use_site use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> counter_metric!(ENCRYPTION_API_FAILURES, GLOBAL_METER); <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> counter_metric!(ENCRYPTION_API_FAILURES, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=counter_metric roles=use_site,macro_def use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=counter_metric roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> counter_metric!(DECRYPTION_API_FAILURES, GLOBAL_METER); <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> counter_metric!(DECRYPTION_API_FAILURES, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=counter_metric roles=use_site,macro_def use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> counter_metric!(APPLICATION_DECRYPTION_COUNT, GLOBAL_METER); <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> counter_metric!(APPLICATION_DECRYPTION_COUNT, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=counter_metric roles=use_site,macro_def use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> counter_metric!(APPLICATION_ENCRYPTION_COUNT, GLOBAL_METER); <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> counter_metric!(APPLICATION_ENCRYPTION_COUNT, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=counter_metric roles=use_site,macro_def use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/diesel_models/src/lib.rs" crate="diesel_models" role="use_site"> counter_metric!(DATABASE_CALLS_COUNT, GLOBAL_METER); <file_sep path="hyperswitch/crates/diesel_models/src/lib.rs" crate="diesel_models" role="use_site"> counter_metric!(DATABASE_CALLS_COUNT, GLOBAL_METER); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> diesel_models macro=counter_metric roles=use_site,macro_def use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=counter_metric roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(INCOMING_DISPUTE_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks counter_metric!( INCOMING_DISPUTE_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which signature verification failed counter_metric!( INCOMING_DISPUTE_WEBHOOK_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which validation failed counter_metric!(INCOMING_DISPUTE_WEBHOOK_NEW_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which new record is created in our db counter_metric!(INCOMING_DISPUTE_WEBHOOK_UPDATE_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which we have updated the details to existing record counter_metric!( INCOMING_DISPUTE_WEBHOOK_MERCHANT_NOTIFIED_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks which are notified to merchant counter_metric!( ACCEPT_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while accepting a dispute counter_metric!( EVIDENCE_SUBMISSION_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while submitting evidence for a dispute //No. of status validation failures while attaching evidence for a dispute counter_metric!( ATTACH_EVIDENCE_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); counter_metric!(INCOMING_PAYOUT_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming payout webhooks counter_metric!( INCOMING_PAYOUT_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming payout webhooks for which signature verification failed counter_metric!(WEBHOOK_INCOMING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_INCOMING_FILTERED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_SOURCE_VERIFIED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_NOT_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_PAYMENT_NOT_FOUND, GLOBAL_METER); counter_metric!( WEBHOOK_EVENT_TYPE_IDENTIFICATION_FAILURE_COUNT, GLOBAL_METER ); counter_metric!(ROUTING_CREATE_REQUEST_RECEIVED, GLOBAL_METER); counter_metric!(ROUTING_CREATE_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_MERCHANT_DICTIONARY_RETRIEVE, GLOBAL_METER); counter_metric!( ROUTING_MERCHANT_DICTIONARY_RETRIEVE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_DEFAULT_CONFIG, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_DEFAULT_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_UPDATE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(DYNAMIC_SUCCESS_BASED_ROUTING, GLOBAL_METER); counter_metric!(DYNAMIC_CONTRACT_BASED_ROUTING, GLOBAL_METER); #[cfg(feature = "partial-auth")] counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(INCOMING_DISPUTE_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks counter_metric!( INCOMING_DISPUTE_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which signature verification failed counter_metric!( INCOMING_DISPUTE_WEBHOOK_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which validation failed counter_metric!(INCOMING_DISPUTE_WEBHOOK_NEW_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which new record is created in our db counter_metric!(INCOMING_DISPUTE_WEBHOOK_UPDATE_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which we have updated the details to existing record counter_metric!( INCOMING_DISPUTE_WEBHOOK_MERCHANT_NOTIFIED_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks which are notified to merchant counter_metric!( ACCEPT_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while accepting a dispute counter_metric!( EVIDENCE_SUBMISSION_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while submitting evidence for a dispute //No. of status validation failures while attaching evidence for a dispute counter_metric!( ATTACH_EVIDENCE_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); counter_metric!(INCOMING_PAYOUT_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming payout webhooks counter_metric!( INCOMING_PAYOUT_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming payout webhooks for which signature verification failed counter_metric!(WEBHOOK_INCOMING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_INCOMING_FILTERED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_SOURCE_VERIFIED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_NOT_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_PAYMENT_NOT_FOUND, GLOBAL_METER); counter_metric!( WEBHOOK_EVENT_TYPE_IDENTIFICATION_FAILURE_COUNT, GLOBAL_METER ); counter_metric!(ROUTING_CREATE_REQUEST_RECEIVED, GLOBAL_METER); counter_metric!(ROUTING_CREATE_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_MERCHANT_DICTIONARY_RETRIEVE, GLOBAL_METER); counter_metric!( ROUTING_MERCHANT_DICTIONARY_RETRIEVE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_DEFAULT_CONFIG, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_DEFAULT_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_UPDATE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(DYNAMIC_SUCCESS_BASED_ROUTING, GLOBAL_METER); counter_metric!(DYNAMIC_CONTRACT_BASED_ROUTING, GLOBAL_METER); #[cfg(feature = "partial-auth")] counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=counter_metric roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(INCOMING_DISPUTE_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks counter_metric!( INCOMING_DISPUTE_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which signature verification failed counter_metric!( INCOMING_DISPUTE_WEBHOOK_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which validation failed counter_metric!(INCOMING_DISPUTE_WEBHOOK_NEW_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which new record is created in our db counter_metric!(INCOMING_DISPUTE_WEBHOOK_UPDATE_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which we have updated the details to existing record counter_metric!( INCOMING_DISPUTE_WEBHOOK_MERCHANT_NOTIFIED_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks which are notified to merchant counter_metric!( ACCEPT_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while accepting a dispute counter_metric!( EVIDENCE_SUBMISSION_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while submitting evidence for a dispute //No. of status validation failures while attaching evidence for a dispute counter_metric!( ATTACH_EVIDENCE_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); counter_metric!(INCOMING_PAYOUT_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming payout webhooks counter_metric!( INCOMING_PAYOUT_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming payout webhooks for which signature verification failed counter_metric!(WEBHOOK_INCOMING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_INCOMING_FILTERED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_SOURCE_VERIFIED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_NOT_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_PAYMENT_NOT_FOUND, GLOBAL_METER); counter_metric!( WEBHOOK_EVENT_TYPE_IDENTIFICATION_FAILURE_COUNT, GLOBAL_METER ); counter_metric!(ROUTING_CREATE_REQUEST_RECEIVED, GLOBAL_METER); counter_metric!(ROUTING_CREATE_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_MERCHANT_DICTIONARY_RETRIEVE, GLOBAL_METER); counter_metric!( ROUTING_MERCHANT_DICTIONARY_RETRIEVE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_DEFAULT_CONFIG, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_DEFAULT_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_UPDATE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(DYNAMIC_SUCCESS_BASED_ROUTING, GLOBAL_METER); counter_metric!(DYNAMIC_CONTRACT_BASED_ROUTING, GLOBAL_METER); #[cfg(feature = "partial-auth")] counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(INCOMING_DISPUTE_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks counter_metric!( INCOMING_DISPUTE_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which signature verification failed counter_metric!( INCOMING_DISPUTE_WEBHOOK_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which validation failed counter_metric!(INCOMING_DISPUTE_WEBHOOK_NEW_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which new record is created in our db counter_metric!(INCOMING_DISPUTE_WEBHOOK_UPDATE_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which we have updated the details to existing record counter_metric!( INCOMING_DISPUTE_WEBHOOK_MERCHANT_NOTIFIED_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks which are notified to merchant counter_metric!( ACCEPT_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while accepting a dispute counter_metric!( EVIDENCE_SUBMISSION_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while submitting evidence for a dispute //No. of status validation failures while attaching evidence for a dispute counter_metric!( ATTACH_EVIDENCE_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); counter_metric!(INCOMING_PAYOUT_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming payout webhooks counter_metric!( INCOMING_PAYOUT_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming payout webhooks for which signature verification failed counter_metric!(WEBHOOK_INCOMING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_INCOMING_FILTERED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_SOURCE_VERIFIED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_NOT_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_PAYMENT_NOT_FOUND, GLOBAL_METER); counter_metric!( WEBHOOK_EVENT_TYPE_IDENTIFICATION_FAILURE_COUNT, GLOBAL_METER ); counter_metric!(ROUTING_CREATE_REQUEST_RECEIVED, GLOBAL_METER); counter_metric!(ROUTING_CREATE_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_MERCHANT_DICTIONARY_RETRIEVE, GLOBAL_METER); counter_metric!( ROUTING_MERCHANT_DICTIONARY_RETRIEVE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_DEFAULT_CONFIG, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_DEFAULT_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_UPDATE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(DYNAMIC_SUCCESS_BASED_ROUTING, GLOBAL_METER); counter_metric!(DYNAMIC_CONTRACT_BASED_ROUTING, GLOBAL_METER); #[cfg(feature = "partial-auth")] counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=counter_metric roles=macro_def,use_site use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! counter_metric { ($name:ident, $meter:ident) => { pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| $meter.u64_counter(stringify!($name)).build()); }; ($name:ident, $meter:ident, description:literal) => { #[doc = $description] pub(crate) static $name: once_cell::sync::Lazy< $crate::opentelemetry::metrics::Counter<u64>, > = once_cell::sync::Lazy::new(|| { $meter .u64_counter(stringify!($name)) .with_description($description) .build() }); }; } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=counter_metric roles=macro_def,use_site use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/hyperswitch_connectors/src/metrics.rs" crate="hyperswitch_connectors" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_connectors macro=global_meter roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Metrics interface use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(CONNECTOR_RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); <file_sep path="hyperswitch/crates/hyperswitch_connectors/src/metrics.rs" crate="hyperswitch_connectors" role="use_site"> <|fim_prefix|> //! Metrics interface use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(CONNECTOR_RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=global_meter roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/diesel_models/src/lib.rs" crate="diesel_models" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> diesel_models macro=global_meter roles=macro_def,use_site use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/diesel_models/src/lib.rs" crate="diesel_models" role="use_site"> <|fim_prefix|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/hyperswitch_connectors/src/metrics.rs" crate="hyperswitch_connectors" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/hyperswitch_connectors/src/metrics.rs" crate="hyperswitch_connectors" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_connectors macro=global_meter roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=global_meter roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub mod bg_metrics_collector; pub mod request; pub mod utils; use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(HEALTH_METRIC, GLOBAL_METER); // No. of health API hits counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // API Level Metrics counter_metric!(REQUESTS_RECEIVED, GLOBAL_METER); counter_metric!(REQUEST_STATUS, GLOBAL_METER); histogram_metric_f64!(REQUEST_TIME, GLOBAL_METER); histogram_metric_f64!(EXTERNAL_REQUEST_TIME, GLOBAL_METER); // Operation Level Metrics counter_metric!(PAYMENT_OPS_COUNT, GLOBAL_METER); counter_metric!(PAYMENT_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_PAYMENT, GLOBAL_METER); //TODO: This can be removed, added for payment list debugging histogram_metric_f64!(PAYMENT_LIST_LATENCY, GLOBAL_METER); counter_metric!(REFUND_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_REFUND, GLOBAL_METER); counter_metric!(PAYMENT_CANCEL_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_CANCEL, GLOBAL_METER); counter_metric!(MANDATE_COUNT, GLOBAL_METER); counter_metric!(SUBSEQUENT_MANDATE_PAYMENT, GLOBAL_METER); // Manual retry metrics counter_metric!(MANUAL_RETRY_REQUEST_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_VALIDATION_FAILED, GLOBAL_METER); counter_metric!(STORED_TO_LOCKER, GLOBAL_METER); counter_metric!(GET_FROM_LOCKER, GLOBAL_METER); counter_metric!(DELETE_FROM_LOCKER, GLOBAL_METER); counter_metric!(CREATED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(DELETED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(GET_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(TOKENIZED_DATA_COUNT, GLOBAL_METER); // Tokenized data added counter_metric!(RETRIED_DELETE_DATA_COUNT, GLOBAL_METER); // Tokenized data retried counter_metric!(CUSTOMER_CREATED, GLOBAL_METER); counter_metric!(CUSTOMER_REDACTED, GLOBAL_METER); counter_metric!(API_KEY_CREATED, GLOBAL_METER); counter_metric!(API_KEY_REVOKED, GLOBAL_METER); counter_metric!(MCA_CREATE, GLOBAL_METER); // Flow Specific Metrics histogram_metric_f64!(CONNECTOR_REQUEST_TIME, GLOBAL_METER); counter_metric!(SESSION_TOKEN_CREATED, GLOBAL_METER); counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed counter_metric!(THREE_DS_PAYMENT_COUNT, GLOBAL_METER); counter_metric!(THREE_DS_DOWNGRADE_COUNT, GLOBAL_METER); counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); counter_metric!(CONNECTOR_ERROR_RESPONSE_COUNT, GLOBAL_METER); counter_metric!(REQUEST_TIMEOUT_COUNT, GLOBAL_METER); counter_metric!(EXECUTE_PRETASK_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_PAYMENT_METHOD_TOKENIZATION, GLOBAL_METER); counter_metric!(PREPROCESSING_STEPS_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_CUSTOMER_CREATE, GLOBAL_METER); counter_metric!(REDIRECTION_TRIGGERED, GLOBAL_METER); // Connector Level Metric counter_metric!(REQUEST_BUILD_FAILURE, GLOBAL_METER); // Connector http status code metrics counter_metric!(CONNECTOR_HTTP_STATUS_CODE_1XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_2XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_3XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_4XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_5XX_COUNT, GLOBAL_METER); // Service Level counter_metric!(CARD_LOCKER_FAILURES, GLOBAL_METER); counter_metric!(CARD_LOCKER_SUCCESSFUL_RESPONSE, GLOBAL_METER); counter_metric!(TEMP_LOCKER_FAILURES, GLOBAL_METER); histogram_metric_f64!(CARD_ADD_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_GET_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); // Apple Pay Flow Metrics counter_metric!(APPLE_PAY_MANUAL_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_FAILED_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_FAILED_PAYMENT, GLOBAL_METER); // Metrics for Payment Auto Retries counter_metric!(AUTO_RETRY_CONNECTION_CLOSED, GLOBAL_METER); counter_metric!(AUTO_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYMENT_COUNT, GLOBAL_METER); // Metrics for Payout Auto Retries counter_metric!(AUTO_PAYOUT_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYOUT_COUNT, GLOBAL_METER); // Scheduler / Process Tracker related metrics counter_metric!(TASKS_ADDED_COUNT, GLOBAL_METER); // Tasks added to process tracker counter_metric!(TASK_ADDITION_FAILURES_COUNT, GLOBAL_METER); // Failures in task addition to process tracker counter_metric!(TASKS_RESET_COUNT, GLOBAL_METER); // Tasks reset in process tracker for requeue flow // Access token metrics // // A counter to indicate the number of new access tokens created counter_metric!(ACCESS_TOKEN_CREATION, GLOBAL_METER); // A counter to indicate the access token cache hits counter_metric!(ACCESS_TOKEN_CACHE_HIT, GLOBAL_METER); // A counter to indicate the access token cache miss counter_metric!(ACCESS_TOKEN_CACHE_MISS, GLOBAL_METER); // A counter to indicate the integrity check failures counter_metric!(INTEGRITY_CHECK_FAILED, GLOBAL_METER); // Network Tokenization metrics histogram_metric_f64!(GENERATE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); // A counter to indicate allowed payment method types mismatch counter_metric!(PAYMENT_METHOD_TYPES_MISCONFIGURATION_METRIC, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/routes/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> pub mod bg_metrics_collector; pub mod request; pub mod utils; use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(HEALTH_METRIC, GLOBAL_METER); // No. of health API hits counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // API Level Metrics counter_metric!(REQUESTS_RECEIVED, GLOBAL_METER); counter_metric!(REQUEST_STATUS, GLOBAL_METER); histogram_metric_f64!(REQUEST_TIME, GLOBAL_METER); histogram_metric_f64!(EXTERNAL_REQUEST_TIME, GLOBAL_METER); // Operation Level Metrics counter_metric!(PAYMENT_OPS_COUNT, GLOBAL_METER); counter_metric!(PAYMENT_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_PAYMENT, GLOBAL_METER); //TODO: This can be removed, added for payment list debugging histogram_metric_f64!(PAYMENT_LIST_LATENCY, GLOBAL_METER); counter_metric!(REFUND_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_REFUND, GLOBAL_METER); counter_metric!(PAYMENT_CANCEL_COUNT, GLOBAL_METER); counter_metric!(SUCCESSFUL_CANCEL, GLOBAL_METER); counter_metric!(MANDATE_COUNT, GLOBAL_METER); counter_metric!(SUBSEQUENT_MANDATE_PAYMENT, GLOBAL_METER); // Manual retry metrics counter_metric!(MANUAL_RETRY_REQUEST_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_COUNT, GLOBAL_METER); counter_metric!(MANUAL_RETRY_VALIDATION_FAILED, GLOBAL_METER); counter_metric!(STORED_TO_LOCKER, GLOBAL_METER); counter_metric!(GET_FROM_LOCKER, GLOBAL_METER); counter_metric!(DELETE_FROM_LOCKER, GLOBAL_METER); counter_metric!(CREATED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(DELETED_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(GET_TOKENIZED_CARD, GLOBAL_METER); counter_metric!(TOKENIZED_DATA_COUNT, GLOBAL_METER); // Tokenized data added counter_metric!(RETRIED_DELETE_DATA_COUNT, GLOBAL_METER); // Tokenized data retried counter_metric!(CUSTOMER_CREATED, GLOBAL_METER); counter_metric!(CUSTOMER_REDACTED, GLOBAL_METER); counter_metric!(API_KEY_CREATED, GLOBAL_METER); counter_metric!(API_KEY_REVOKED, GLOBAL_METER); counter_metric!(MCA_CREATE, GLOBAL_METER); // Flow Specific Metrics histogram_metric_f64!(CONNECTOR_REQUEST_TIME, GLOBAL_METER); counter_metric!(SESSION_TOKEN_CREATED, GLOBAL_METER); counter_metric!(CONNECTOR_CALL_COUNT, GLOBAL_METER); // Attributes needed counter_metric!(THREE_DS_PAYMENT_COUNT, GLOBAL_METER); counter_metric!(THREE_DS_DOWNGRADE_COUNT, GLOBAL_METER); counter_metric!(RESPONSE_DESERIALIZATION_FAILURE, GLOBAL_METER); counter_metric!(CONNECTOR_ERROR_RESPONSE_COUNT, GLOBAL_METER); counter_metric!(REQUEST_TIMEOUT_COUNT, GLOBAL_METER); counter_metric!(EXECUTE_PRETASK_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_PAYMENT_METHOD_TOKENIZATION, GLOBAL_METER); counter_metric!(PREPROCESSING_STEPS_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_CUSTOMER_CREATE, GLOBAL_METER); counter_metric!(REDIRECTION_TRIGGERED, GLOBAL_METER); // Connector Level Metric counter_metric!(REQUEST_BUILD_FAILURE, GLOBAL_METER); // Connector http status code metrics counter_metric!(CONNECTOR_HTTP_STATUS_CODE_1XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_2XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_3XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_4XX_COUNT, GLOBAL_METER); counter_metric!(CONNECTOR_HTTP_STATUS_CODE_5XX_COUNT, GLOBAL_METER); // Service Level counter_metric!(CARD_LOCKER_FAILURES, GLOBAL_METER); counter_metric!(CARD_LOCKER_SUCCESSFUL_RESPONSE, GLOBAL_METER); counter_metric!(TEMP_LOCKER_FAILURES, GLOBAL_METER); histogram_metric_f64!(CARD_ADD_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_GET_TIME, GLOBAL_METER); histogram_metric_f64!(CARD_DELETE_TIME, GLOBAL_METER); // Apple Pay Flow Metrics counter_metric!(APPLE_PAY_MANUAL_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_SUCCESSFUL_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_MANUAL_FLOW_FAILED_PAYMENT, GLOBAL_METER); counter_metric!(APPLE_PAY_SIMPLIFIED_FLOW_FAILED_PAYMENT, GLOBAL_METER); // Metrics for Payment Auto Retries counter_metric!(AUTO_RETRY_CONNECTION_CLOSED, GLOBAL_METER); counter_metric!(AUTO_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYMENT_COUNT, GLOBAL_METER); // Metrics for Payout Auto Retries counter_metric!(AUTO_PAYOUT_RETRY_ELIGIBLE_REQUEST_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MISS_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_FETCH_FAILURE_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_GSM_MATCH_COUNT, GLOBAL_METER); counter_metric!(AUTO_PAYOUT_RETRY_EXHAUSTED_COUNT, GLOBAL_METER); counter_metric!(AUTO_RETRY_PAYOUT_COUNT, GLOBAL_METER); // Scheduler / Process Tracker related metrics counter_metric!(TASKS_ADDED_COUNT, GLOBAL_METER); // Tasks added to process tracker counter_metric!(TASK_ADDITION_FAILURES_COUNT, GLOBAL_METER); // Failures in task addition to process tracker counter_metric!(TASKS_RESET_COUNT, GLOBAL_METER); // Tasks reset in process tracker for requeue flow // Access token metrics // // A counter to indicate the number of new access tokens created counter_metric!(ACCESS_TOKEN_CREATION, GLOBAL_METER); // A counter to indicate the access token cache hits counter_metric!(ACCESS_TOKEN_CACHE_HIT, GLOBAL_METER); // A counter to indicate the access token cache miss counter_metric!(ACCESS_TOKEN_CACHE_MISS, GLOBAL_METER); // A counter to indicate the integrity check failures counter_metric!(INTEGRITY_CHECK_FAILED, GLOBAL_METER); // Network Tokenization metrics histogram_metric_f64!(GENERATE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(FETCH_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(DELETE_NETWORK_TOKEN_TIME, GLOBAL_METER); histogram_metric_f64!(CHECK_NETWORK_TOKEN_STATUS_TIME, GLOBAL_METER); // A counter to indicate allowed payment method types mismatch counter_metric!(PAYMENT_METHOD_TYPES_MISCONFIGURATION_METRIC, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=global_meter roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/storage_impl/src/metrics.rs" crate="storage_impl" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/storage_impl/src/metrics.rs" crate="storage_impl" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> storage_impl macro=global_meter roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/external_services/src/lib.rs" crate="external_services" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> external_services macro=global_meter roles=macro_def,use_site use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub mod metrics { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/external_services/src/lib.rs" crate="external_services" role="use_site"> <|fim_prefix|> pub mod metrics { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=global_meter roles=macro_def,use_site use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> <|fim_prefix|> pub(crate) mod metrics { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> router macro=global_meter roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(INCOMING_DISPUTE_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks counter_metric!( INCOMING_DISPUTE_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which signature verification failed counter_metric!( INCOMING_DISPUTE_WEBHOOK_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which validation failed counter_metric!(INCOMING_DISPUTE_WEBHOOK_NEW_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which new record is created in our db counter_metric!(INCOMING_DISPUTE_WEBHOOK_UPDATE_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which we have updated the details to existing record counter_metric!( INCOMING_DISPUTE_WEBHOOK_MERCHANT_NOTIFIED_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks which are notified to merchant counter_metric!( ACCEPT_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while accepting a dispute counter_metric!( EVIDENCE_SUBMISSION_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while submitting evidence for a dispute //No. of status validation failures while attaching evidence for a dispute counter_metric!( ATTACH_EVIDENCE_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); counter_metric!(INCOMING_PAYOUT_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming payout webhooks counter_metric!( INCOMING_PAYOUT_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming payout webhooks for which signature verification failed counter_metric!(WEBHOOK_INCOMING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_INCOMING_FILTERED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_SOURCE_VERIFIED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_NOT_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_PAYMENT_NOT_FOUND, GLOBAL_METER); counter_metric!( WEBHOOK_EVENT_TYPE_IDENTIFICATION_FAILURE_COUNT, GLOBAL_METER ); counter_metric!(ROUTING_CREATE_REQUEST_RECEIVED, GLOBAL_METER); counter_metric!(ROUTING_CREATE_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_MERCHANT_DICTIONARY_RETRIEVE, GLOBAL_METER); counter_metric!( ROUTING_MERCHANT_DICTIONARY_RETRIEVE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_DEFAULT_CONFIG, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_DEFAULT_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_UPDATE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(DYNAMIC_SUCCESS_BASED_ROUTING, GLOBAL_METER); counter_metric!(DYNAMIC_CONTRACT_BASED_ROUTING, GLOBAL_METER); #[cfg(feature = "partial-auth")] counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER); <file_sep path="hyperswitch/crates/router/src/core/metrics.rs" crate="router" role="use_site"> <|fim_prefix|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(INCOMING_DISPUTE_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks counter_metric!( INCOMING_DISPUTE_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which signature verification failed counter_metric!( INCOMING_DISPUTE_WEBHOOK_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks for which validation failed counter_metric!(INCOMING_DISPUTE_WEBHOOK_NEW_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which new record is created in our db counter_metric!(INCOMING_DISPUTE_WEBHOOK_UPDATE_RECORD_METRIC, GLOBAL_METER); // No. of incoming dispute webhooks for which we have updated the details to existing record counter_metric!( INCOMING_DISPUTE_WEBHOOK_MERCHANT_NOTIFIED_METRIC, GLOBAL_METER ); // No. of incoming dispute webhooks which are notified to merchant counter_metric!( ACCEPT_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while accepting a dispute counter_metric!( EVIDENCE_SUBMISSION_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); //No. of status validation failures while submitting evidence for a dispute //No. of status validation failures while attaching evidence for a dispute counter_metric!( ATTACH_EVIDENCE_DISPUTE_STATUS_VALIDATION_FAILURE_METRIC, GLOBAL_METER ); counter_metric!(INCOMING_PAYOUT_WEBHOOK_METRIC, GLOBAL_METER); // No. of incoming payout webhooks counter_metric!( INCOMING_PAYOUT_WEBHOOK_SIGNATURE_FAILURE_METRIC, GLOBAL_METER ); // No. of incoming payout webhooks for which signature verification failed counter_metric!(WEBHOOK_INCOMING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_INCOMING_FILTERED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_SOURCE_VERIFIED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_OUTGOING_NOT_RECEIVED_COUNT, GLOBAL_METER); counter_metric!(WEBHOOK_PAYMENT_NOT_FOUND, GLOBAL_METER); counter_metric!( WEBHOOK_EVENT_TYPE_IDENTIFICATION_FAILURE_COUNT, GLOBAL_METER ); counter_metric!(ROUTING_CREATE_REQUEST_RECEIVED, GLOBAL_METER); counter_metric!(ROUTING_CREATE_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_MERCHANT_DICTIONARY_RETRIEVE, GLOBAL_METER); counter_metric!( ROUTING_MERCHANT_DICTIONARY_RETRIEVE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_DEFAULT_CONFIG, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_DEFAULT_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_RETRIEVE_LINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UNLINK_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_SUCCESS_RESPONSE, GLOBAL_METER); counter_metric!(ROUTING_UPDATE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_UPDATE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(ROUTING_RETRIEVE_CONFIG_FOR_PROFILE, GLOBAL_METER); counter_metric!( ROUTING_RETRIEVE_CONFIG_FOR_PROFILE_SUCCESS_RESPONSE, GLOBAL_METER ); counter_metric!(DYNAMIC_SUCCESS_BASED_ROUTING, GLOBAL_METER); counter_metric!(DYNAMIC_CONTRACT_BASED_ROUTING, GLOBAL_METER); #[cfg(feature = "partial-auth")] counter_metric!(PARTIAL_AUTH_FAILURE, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_INITIATED, GLOBAL_METER); counter_metric!(API_KEY_REQUEST_COMPLETED, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/storage_impl/src/metrics.rs" crate="storage_impl" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> storage_impl macro=global_meter roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // Metrics for KV counter_metric!(KV_OPERATION_SUCCESSFUL, GLOBAL_METER); counter_metric!(KV_OPERATION_FAILED, GLOBAL_METER); counter_metric!(KV_PUSHED_TO_DRAINER, GLOBAL_METER); counter_metric!(KV_FAILED_TO_PUSH_TO_DRAINER, GLOBAL_METER); counter_metric!(KV_SOFT_KILL_ACTIVE_UPDATE, GLOBAL_METER); // Metrics for In-memory cache gauge_metric!(IN_MEMORY_CACHE_ENTRY_COUNT, GLOBAL_METER); counter_metric!(IN_MEMORY_CACHE_HIT, GLOBAL_METER); counter_metric!(IN_MEMORY_CACHE_MISS, GLOBAL_METER); counter_metric!(IN_MEMORY_CACHE_EVICTION_COUNT, GLOBAL_METER); <file_sep path="hyperswitch/crates/storage_impl/src/metrics.rs" crate="storage_impl" role="use_site"> <|fim_prefix|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(GLOBAL_METER, "ROUTER_API"); counter_metric!(KV_MISS, GLOBAL_METER); // No. of KV misses // Metrics for KV counter_metric!(KV_OPERATION_SUCCESSFUL, GLOBAL_METER); counter_metric!(KV_OPERATION_FAILED, GLOBAL_METER); counter_metric!(KV_PUSHED_TO_DRAINER, GLOBAL_METER); counter_metric!(KV_FAILED_TO_PUSH_TO_DRAINER, GLOBAL_METER); counter_metric!(KV_SOFT_KILL_ACTIVE_UPDATE, GLOBAL_METER); // Metrics for In-memory cache gauge_metric!(IN_MEMORY_CACHE_ENTRY_COUNT, GLOBAL_METER); counter_metric!(IN_MEMORY_CACHE_HIT, GLOBAL_METER); counter_metric!(IN_MEMORY_CACHE_MISS, GLOBAL_METER); counter_metric!(IN_MEMORY_CACHE_EVICTION_COUNT, GLOBAL_METER);
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> macro_rules! global_meter { ($name:ident) => { static $name: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; ($meter:ident, $name:literal) => { static $meter: once_cell::sync::Lazy<$crate::opentelemetry::metrics::Meter> = once_cell::sync::Lazy::new(|| $crate::opentelemetry::global::meter(stringify!($name))); }; } <file_sep path="hyperswitch/crates/scheduler/src/metrics.rs" crate="scheduler" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> scheduler macro=global_meter roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(PT_METER, "PROCESS_TRACKER"); histogram_metric_f64!(CONSUMER_OPS, PT_METER); counter_metric!(PAYMENT_COUNT, PT_METER); // No. of payments created counter_metric!(TASKS_PICKED_COUNT, PT_METER); // Tasks picked by counter_metric!(BATCHES_CREATED, PT_METER); // Batches added to stream counter_metric!(BATCHES_CONSUMED, PT_METER); // Batches consumed by consumer counter_metric!(TASK_CONSUMED, PT_METER); // Tasks consumed by consumer counter_metric!(TASK_PROCESSED, PT_METER); // Tasks completed processing counter_metric!(TASK_FINISHED, PT_METER); // Tasks finished counter_metric!(TASK_RETRIED, PT_METER); // Tasks added for retries <file_sep path="hyperswitch/crates/scheduler/src/metrics.rs" crate="scheduler" role="use_site"> <|fim_prefix|> use router_env::{ <|fim_suffix|> <|fim_middle|> }; global_meter!(PT_METER, "PROCESS_TRACKER"); histogram_metric_f64!(CONSUMER_OPS, PT_METER); counter_metric!(PAYMENT_COUNT, PT_METER); // No. of payments created counter_metric!(TASKS_PICKED_COUNT, PT_METER); // Tasks picked by counter_metric!(BATCHES_CREATED, PT_METER); // Batches added to stream counter_metric!(BATCHES_CONSUMED, PT_METER); // Batches consumed by consumer counter_metric!(TASK_CONSUMED, PT_METER); // Tasks consumed by consumer counter_metric!(TASK_PROCESSED, PT_METER); // Tasks completed processing counter_metric!(TASK_FINISHED, PT_METER); // Tasks finished counter_metric!(TASK_RETRIED, PT_METER); // Tasks added for retries
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/hyperswitch_domain_models/src/type_encryption.rs" crate="hyperswitch_domain_models" role="use_site"> global_meter!(GLOBAL_METER, "ROUTER_API"); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> hyperswitch_domain_models macro=global_meter roles=use_site,macro_def use=invoke item=mod pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/scheduler/src/metrics.rs" crate="scheduler" role="use_site"> global_meter!(PT_METER, "PROCESS_TRACKER"); <file_sep path="hyperswitch/crates/scheduler/src/metrics.rs" crate="scheduler" role="use_site"> global_meter!(PT_METER, "PROCESS_TRACKER"); <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/metrics.rs<|crate|> scheduler macro=global_meter roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/metrics.rs" crate="router_env" role="macro_def"> <|fim_prefix|> //! Utilities to easily create opentelemetry contexts, meters and metrics. /// Create a global [`Meter`][Meter] with the specified name and an optional description. /// /// [Meter]: opentelemetry::metrics::Meter #[macro_export] macro_rules! global_meter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch-card-vault/src/logger/setup.rs" crate="src" role="use_site"> let mut workspace_members = crate::cargo_workspace_members!(); <file_sep path="hyperswitch-card-vault/src/logger/setup.rs" crate="src" role="use_site"> let mut workspace_members = crate::cargo_workspace_members!(); <file_sep path="hyperswitch/crates/router_env/src/cargo_workspace.rs" crate="router_env" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/cargo_workspace.rs<|crate|> src macro=cargo_workspace_members roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> /// Sets the `CARGO_WORKSPACE_MEMBERS` environment variable to include a comma-separated list of /// names of all crates in the current cargo workspace. /// /// This function should be typically called within build scripts, so that the environment variable /// is available to the corresponding crate at compile time. /// /// # Panics /// /// Panics if running the `cargo metadata` command fails. #[allow(clippy::expect_used)] pub fn set_cargo_workspace_members_env() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/cargo_workspace.rs" crate="router_env" role="macro_def"> <|fim_prefix|> /// Sets the `CARGO_WORKSPACE_MEMBERS` environment variable to include a comma-separated list of /// names of all crates in the current cargo workspace. /// /// This function should be typically called within build scripts, so that the environment variable /// is available to the corresponding crate at compile time. /// /// # Panics /// /// Panics if running the `cargo metadata` command fails. #[allow(clippy::expect_used)] pub fn set_cargo_workspace_members_env() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/cargo_workspace.rs" crate="router_env" role="macro_def"> macro_rules! cargo_workspace_members { () => { std::env!("CARGO_WORKSPACE_MEMBERS") .split(',') .collect::<std::collections::HashSet<&'static str>>() }; } <file_sep path="hyperswitch/crates/router_env/src/cargo_workspace.rs" crate="router_env" role="macro_def"> macro_rules! cargo_workspace_members { () => { std::env!("CARGO_WORKSPACE_MEMBERS") .split(',') .collect::<std::collections::HashSet<&'static str>>() }; } <file_sep path="hyperswitch/crates/router_env/src/logger/setup.rs" crate="router_env" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/cargo_workspace.rs<|crate|> router_env macro=cargo_workspace_members roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn get_envfilter( filtering_directive: Option<&String>, default_log_level: config::Level, filter_log_level: config::Level, crates_to_filter: impl AsRef<[&'static str]>, ) -> EnvFilter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router_env/src/logger/setup.rs" crate="router_env" role="use_site"> <|fim_prefix|> fn get_envfilter( filtering_directive: Option<&String>, default_log_level: config::Level, filter_log_level: config::Level, crates_to_filter: impl AsRef<[&'static str]>, ) -> EnvFilter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router_env/src/cargo_workspace.rs" crate="router_env" role="macro_def"> macro_rules! cargo_workspace_members { () => { std::env!("CARGO_WORKSPACE_MEMBERS") .split(',') .collect::<std::collections::HashSet<&'static str>>() }; } <file_sep path="hyperswitch/crates/router_env/src/cargo_workspace.rs" crate="router_env" role="macro_def"> macro_rules! cargo_workspace_members { () => { std::env!("CARGO_WORKSPACE_MEMBERS") .split(',') .collect::<std::collections::HashSet<&'static str>>() }; } <file_sep path="hyperswitch-card-vault/src/logger/setup.rs" crate="src" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router_env/src/cargo_workspace.rs<|crate|> src macro=cargo_workspace_members roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn get_envfilter( filtering_directive: Option<&String>, default_log_level: config::Level, filter_log_level: config::Level, crates_to_filter: impl AsRef<[&'static str]>, ) -> EnvFilter { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch-card-vault/src/logger/setup.rs" crate="src" role="use_site"> <|fim_prefix|> fn get_envfilter( filtering_directive: Option<&String>, default_log_level: config::Level, filter_log_level: config::Level, crates_to_filter: impl AsRef<[&'static str]>, ) -> EnvFilter { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(RealTimePaymentType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(RealTimePaymentType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(UpiType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(UpiType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(CardRedirectType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(CardRedirectType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(BankTransferType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(BankTransferType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(OpenBankingType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(OpenBankingType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(GiftCardType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(GiftCardType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> macro_rules! collect_global_variants { ($parent_enum:ident) => { &mut dir::enums::$parent_enum::iter() .map(dir::DirValue::$parent_enum) .collect::<Vec<_>>() }; } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> <|fim_prefix|> fn global_vec_pmt( enabled_pmt: Vec<dir::DirValue>, builder: &mut cgraph::ConstraintGraphBuilder<dir::DirValue>, ) -> Vec<cgraph::NodeId> { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(VoucherType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(VoucherType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(MobilePaymentType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="use_site"> global_vector.append(collect_global_variants!(MobilePaymentType)); <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/kgraph_utils/src/mca.rs<|crate|> kgraph_utils macro=collect_global_variants roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/kgraph_utils/src/mca.rs" crate="kgraph_utils" role="macro_def"> <|fim_prefix|> use std::str::FromStr; use api_models::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(Card) & PaymentMethod(not Wallet) ->> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(Card) & PaymentMethod(not Wallet) ->> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(in [Card, Wallet]) ->> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(in [Card, Wallet]) ->> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid/src/dssa/analyzer.rs" crate="euclid" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn test_negation_graph_analysis() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid/src/dssa/analyzer.rs" crate="euclid" role="use_site"> <|fim_prefix|> fn test_negation_graph_analysis() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(not in [Card, Wallet]) ->> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(not in [Card, Wallet]) ->> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(not in [Card, Wallet]) ->> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(not in [Card, Wallet]) ->> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(in [Card, Wallet]) -> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(in [Card, Wallet]) -> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(Card) & PaymentMethod(not Wallet) -> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> let graph = knowledge! { PaymentMethod(Card) & PaymentMethod(not Wallet) -> CaptureMethod(Automatic); }; <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> <|fim_prefix|> pub fn knowledge(ts: TokenStream) -> TokenStream { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid_macros/src/lib.rs" crate="euclid_macros" role="macro_def"> pub fn knowledge(ts: TokenStream) -> TokenStream { match inner::knowledge_inner(ts.into()) { Ok(ts) => ts.into(), Err(e) => e.into_compile_error().into(), } } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/euclid_macros/src/lib.rs<|crate|> euclid macro=knowledge roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/euclid/src/dssa/graph.rs" crate="euclid" role="use_site"> <|fim_prefix|> fn test_in_aggregator_failure_trace() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(AuthenticationStatus); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(AuthenticationStatus); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(FraudCheckStatus); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(FraudCheckStatus); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(DisputeStatus); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(DisputeStatus); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(TransactionStatus); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(TransactionStatus); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(DecoupledAuthenticationType); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(DecoupledAuthenticationType); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(DisputeStage); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(DisputeStage); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(AuthenticationConnectors); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> db_type!(AuthenticationConnectors); <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="macro_def"> macro_rules! db_type { ($a: ident, $str: tt) => { impl DbType for $a { fn name() -> &'static str { stringify!($str) } } }; ($a:ident) => { impl DbType for $a { fn name() -> &'static str { stringify!($a) } } }; } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/sqlx.rs<|crate|> analytics macro=db_type roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/sqlx.rs" crate="analytics" role="use_site"> <|fim_prefix|> pub struct SqlxClient { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="macro_def"> macro_rules! impl_to_sql_for_to_string { ($($type:ty),+) => { $( impl<T: AnalyticsDataSource> ToSql<T> for $type { fn to_sql(&self, _table_engine: &TableEngine) -> error_stack::Result<String, ParsingError> { Ok(self.to_string()) } } )+ }; } <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="macro_def"> macro_rules! impl_to_sql_for_to_string { ($($type:ty),+) => { $( impl<T: AnalyticsDataSource> ToSql<T> for $type { fn to_sql(&self, _table_engine: &TableEngine) -> error_stack::Result<String, ParsingError> { Ok(self.to_string()) } } )+ }; } <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/query.rs<|crate|> analytics macro=impl_to_sql_for_to_string roles=macro_def,use_site use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> impl<T> QueryFilter<T> for analytics_api::TimeRange where T: AnalyticsDataSource, time::PrimitiveDateTime: ToSql<T>, AnalyticsCollection: ToSql<T>, Granularity: GroupByClause<T>, { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="use_site"> <|fim_prefix|> impl<T> QueryFilter<T> for analytics_api::TimeRange where T: AnalyticsDataSource, time::PrimitiveDateTime: ToSql<T>, AnalyticsCollection: ToSql<T>, Granularity: GroupByClause<T>, { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="use_site"> impl_to_sql_for_to_string!( String, &str, &PaymentDimensions, &PaymentIntentDimensions, &RefundDimensions, &FrmDimensions, PaymentDimensions, PaymentIntentDimensions, &PaymentDistributions, RefundDimensions, &RefundDistributions, FrmDimensions, PaymentMethod, PaymentMethodType, AuthenticationType, Connector, AttemptStatus, IntentStatus, RefundStatus, FraudCheckStatus, storage_enums::RefundStatus, Currency, RefundType, FrmTransactionType, TransactionStatus, AuthenticationStatus, AuthenticationConnectors, DecoupledAuthenticationType, Flow, &String, &bool, &u64, u64, Order ); <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="use_site"> impl_to_sql_for_to_string!( String, &str, &PaymentDimensions, &PaymentIntentDimensions, &RefundDimensions, &FrmDimensions, PaymentDimensions, PaymentIntentDimensions, &PaymentDistributions, RefundDimensions, &RefundDistributions, FrmDimensions, PaymentMethod, PaymentMethodType, AuthenticationType, Connector, AttemptStatus, IntentStatus, RefundStatus, FraudCheckStatus, storage_enums::RefundStatus, Currency, RefundType, FrmTransactionType, TransactionStatus, AuthenticationStatus, AuthenticationConnectors, DecoupledAuthenticationType, Flow, &String, &bool, &u64, u64, Order ); <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/query.rs<|crate|> analytics macro=impl_to_sql_for_to_string roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="use_site"> impl_to_sql_for_to_string!( &SdkEventDimensions, SdkEventDimensions, SdkEventNames, AuthEventFlows, &ApiEventDimensions, ApiEventDimensions, &DisputeDimensions, DisputeDimensions, DisputeStage, AuthEventDimensions, &AuthEventDimensions ); <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="use_site"> impl_to_sql_for_to_string!( &SdkEventDimensions, SdkEventDimensions, SdkEventNames, AuthEventFlows, &ApiEventDimensions, ApiEventDimensions, &DisputeDimensions, DisputeDimensions, DisputeStage, AuthEventDimensions, &AuthEventDimensions ); <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/analytics/src/query.rs<|crate|> analytics macro=impl_to_sql_for_to_string roles=use_site,macro_def use=invoke item=file pack=proc_macro_neighborhoods lang=rust<|meta_end|> use std::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/analytics/src/query.rs" crate="analytics" role="macro_def"> <|fim_prefix|> use std::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![merchant_id, api_key]: HList![MerchantId, ApiKey] = <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![merchant_id, api_key]: HList![MerchantId, ApiKey] = <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![merchant_id, api_key]: HList![MerchantId, ApiKey] = <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![merchant_id, api_key]: HList![MerchantId, ApiKey] = <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![status]: HList![Status] = <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![status]: HList![Status] = <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![status]: HList![Status] = <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![status]: HList![Status] = <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> macro_rules! hlist_pat { () => { $crate::utils::HNil }; ($head:pat $(, $rest:pat)* $(,)?) => { $crate::utils::HCons { head: $head, tail: hlist_pat!($($rest),*) } }; } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=macro_def,use_site use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> <|fim_prefix|> async fn exceed_refund() { <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![merchant_id, _api_key]: HList![MerchantId, ApiKey] = admin_client <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![merchant_id, _api_key]: HList![MerchantId, ApiKey] = admin_client <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods
<file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![status]: HList![Status] = <file_sep path="hyperswitch/crates/router/tests/integration_demo.rs" crate="router" role="use_site"> let hlist_pat![status]: HList![Status] = <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> <|meta_start|><|file|> hyperswitch/crates/router/tests/utils.rs<|crate|> router macro=hlist_pat roles=use_site,macro_def use=invoke item=fn pack=proc_macro_neighborhoods lang=rust<|meta_end|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> } <file_sep path="hyperswitch/crates/router/tests/utils.rs" crate="router" role="macro_def"> <|fim_prefix|> #![allow( dead_code, clippy::expect_used, clippy::missing_panics_doc, clippy::unwrap_used )] use actix_http::{ <|fim_suffix|> <|fim_middle|> }
proc_macro_neighborhoods