Module: PiiSafeSchema::Notify::DataDog

Defined in:
lib/pii_safe_schema/notifiers/data_dog.rb

Constant Summary collapse

KNOWN_CLIENTS =

deprecated

PiiSafeSchema::Configuration::KNOWN_DD_CLIENTS

Class Method Summary collapse

Class Method Details

.deliver(pii_column) ⇒ Object



8
9
10
11
12
13
14
15
16
17
18
# File 'lib/pii_safe_schema/notifiers/data_dog.rb', line 8

def deliver(pii_column)
  return unless %w[staging production development].include?(Rails.env)
  return if datadog_client.nil?

  datadog_client.event(
    'PII Annotation Warning',
    message(pii_column),
    msg_title: 'Unannotated PII Column',
    alert_type: 'warning',
  )
end