Skip to content

Commit

Permalink
debug
Browse files Browse the repository at this point in the history
  • Loading branch information
leandrocp committed Dec 12, 2024
1 parent 1943905 commit 3f33ab8
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/beacon/proxy_endpoint.ex
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,13 @@ defmodule Beacon.ProxyEndpoint do
plug :proxy

def proxy(conn, opts) do
require Logger

%{host: host} = conn

Logger.debug("@session_options => #{inspect(@session_options)}")
Logger.debug("conn.host => #{host}")

endpoint =
Enum.reduce_while(Beacon.Registry.running_sites(), @__beacon_proxy_fallback__, fn site, default ->
%{endpoint: endpoint} = Beacon.Config.fetch!(site)
Expand All @@ -43,6 +48,8 @@ defmodule Beacon.ProxyEndpoint do
end
end)

Logger.debug("endpoint => #{inspect(endpoint)}")

endpoint.call(conn, endpoint.init(opts))
end
end
Expand Down

0 comments on commit 3f33ab8

Please sign in to comment.