Class: Foam::Otel::MaskedLogRecordView
- Inherits:
-
SimpleDelegator
- Object
- SimpleDelegator
- Foam::Otel::MaskedLogRecordView
- Defined in:
- lib/foam/otel/pipelines.rb
Overview
The logs twin: on_emit receives the LIVE record, so the view masks attributes and body lazily through the same engine (floor + customer keys), fail-closed — a read that cannot be masked degrades to the mask, never the raw value. Reads happen AFTER foam's earlier processors (export buffer, session stitching) ran, so the tenant misses nothing.
Instance Method Summary collapse
- #attributes ⇒ Object
- #body ⇒ Object
-
#initialize(record, config) ⇒ MaskedLogRecordView
constructor
A new instance of MaskedLogRecordView.
Constructor Details
#initialize(record, config) ⇒ MaskedLogRecordView
Returns a new instance of MaskedLogRecordView.
200 201 202 203 |
# File 'lib/foam/otel/pipelines.rb', line 200 def initialize(record, config) super(record) @config = config end |
Instance Method Details
#attributes ⇒ Object
205 206 207 208 209 210 211 |
# File 'lib/foam/otel/pipelines.rb', line 205 def attributes @attributes ||= begin Foam::Otel::Redaction.mask_attributes(__getobj__.attributes, @config) rescue StandardError, SystemStackError {} # fail closed: never the raw attributes end end |