Skip to content

Commit

Permalink
feat: connect to tenant database via ipv6
Browse files Browse the repository at this point in the history
  • Loading branch information
w3b6x9 committed Aug 30, 2022
1 parent 85e2af4 commit 37d7f36
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
3 changes: 2 additions & 1 deletion lib/extensions/postgres/postgres_replication_poller.ex
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,8 @@ defmodule Extensions.Postgres.ReplicationPoller do
queue_target: @queue_target,
parameters: [
application_name: "realtime_rls"
]
],
socket_options: [:inet6]
)
end

Expand Down
3 changes: 2 additions & 1 deletion lib/realtime/helpers.ex
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,8 @@ defmodule Realtime.Helpers do
queue_target: queue_target,
parameters: [
application_name: "supabase_realtime"
]
],
socket_options: [:inet6]
)
end

Expand Down
2 changes: 1 addition & 1 deletion lib/realtime/repo.ex
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ defmodule Realtime.Repo do

def with_dynamic_repo(credentials, callback) do
default_dynamic_repo = get_dynamic_repo()
start_opts = [name: @name, pool_size: @pool_size] ++ credentials
start_opts = [name: @name, pool_size: @pool_size, socket_options: [:inet6]] ++ credentials
{:ok, repo} = Realtime.Repo.start_link(start_opts)

try do
Expand Down

0 comments on commit 37d7f36

Please sign in to comment.