Skip to content

Commit

Permalink
remove remaining references to gun
Browse files Browse the repository at this point in the history
  • Loading branch information
the-mikedavis committed Jun 30, 2021
1 parent e859316 commit 9305175
Show file tree
Hide file tree
Showing 6 changed files with 4 additions and 37 deletions.
2 changes: 0 additions & 2 deletions config/dev.exs
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,3 @@ config :slipstream, Slipstream.TestModeClient,
# N.B. this client will _not_ connect
uri: "ws://localhost:54321/socket/websocket",
test_mode?: true

config :slipstream, :gun_client, :gun
2 changes: 0 additions & 2 deletions config/test.exs
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,3 @@ config :slipstream, Slipstream.TestModeClient,
# N.B. this client will _not_ connect
uri: "ws://localhost:54321/socket/websocket",
test_mode?: true

config :slipstream, :gun_client, :gun
7 changes: 3 additions & 4 deletions guides/implementation.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,9 @@ Slipstream starts two processes to run a websocket connection:
- the client process (modules with `use Slipstream`)
- the connection process

The connection process is spawned and killed upon `Slipstream.connect/2` and
`Slipstream.disconnect/1`, respectively. It directly interfaces with `:gun` in
active mode, meaning that messages from `:gun` connections and requests are
forwarded to the mailbox of the connection process.
The connection process is spawned and killed upon `Slipstream.connect/2`
and `Slipstream.disconnect/1`, respectively. It directly interfaces with
the WebSocket connection via `Mint.WebSocket`.

The client process is simply a GenServer that has `c:GenServer.handle_info/2`
clauses injected to handle slipstream events. The entire purpose of the client
Expand Down
2 changes: 1 addition & 1 deletion lib/slipstream/connection.ex
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ defmodule Slipstream.Connection do
@moduledoc false

# the Connection _is_ the socket client
# Connection interfaces with :gun and any module that implements the
# Connection interfaces with Mint.WebSocket and any module that implements the
# Slipstream behaviour to offer websocket client functionality

use GenServer, restart: :temporary
Expand Down
27 changes: 0 additions & 27 deletions test/support/gun_behaviour.ex

This file was deleted.

1 change: 0 additions & 1 deletion test/support/mocks.ex

This file was deleted.

0 comments on commit 9305175

Please sign in to comment.