Skip to content

Commit

Permalink
feat: async reporting
Browse files Browse the repository at this point in the history
  • Loading branch information
grzuy committed Jan 22, 2025
1 parent 6d97eae commit 8cf99d7
Showing 1 changed file with 7 additions and 1 deletion.
8 changes: 7 additions & 1 deletion lib/tower_error_tracker.ex
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,12 @@ defmodule TowerErrorTracker do

@impl true
def report_event(event) do
TowerErrorTracker.Reporter.report_event(event)
value = Process.get(:error_tracker_context, %{})

Tower.async(fn ->

Check warning on line 16 in lib/tower_error_tracker.ex

View workflow job for this annotation

GitHub Actions / main (1.15, 25.3.2.16, error_tracker_0_3)

Tower.async/1 is undefined or private
Process.put(:error_tracker_context, value)

TowerErrorTracker.Reporter.report_event(event)
end)
end
end

0 comments on commit 8cf99d7

Please sign in to comment.