Module: Spree::PaymentMethod::SessionInstrumentation
- Defined in:
- app/models/spree/payment_method/session_instrumentation.rb
Overview
Wraps the provider-implemented payment-session methods in the 'gateway.spree_payments' notification so every caller — controllers, workflows, extensions — gets the gateway span, not just known call sites. Prepended to every subclass from PaymentMethod.inherited: prepending only the base class would sit below a subclass override in the ancestor chain and never run. If an implementation calls super into another prepended copy, the nested (duplicate) span is accepted rather than guarded against — the base implementations raise NotImplementedError, so that chain does not occur in practice.
Constant Summary collapse
- SESSION_METHODS =
%i[ create_payment_session update_payment_session complete_payment_session cancel_payment_session create_payment_setup_session complete_payment_setup_session ].freeze