class Multiwoven::Integrations::Destination::Slack::Client

def process_records(records, stream)

def process_records(records, stream)
  write_success = 0
  write_failure = 0
  records.each do |record_object|
    process_record(stream, record_object.with_indifferent_access)
    write_success += 1
  rescue StandardError => e
    write_failure += 1
    handle_exception(e, {
                       context: "SLACK:WRITE:EXCEPTION",
                       type: "error",
                       sync_id: @sync_config.sync_id,
                       sync_run_id: @sync_config.sync_run_id
                     })
  end
  tracking_message(write_success, write_failure)
end