Stream data from the socket.
This function does not automatically close the socket.
Since 0.0.0
:: a typeCtrl KGHC 9.10.3 · lts/ghc-9.10.x · c74966e · 2026-09-27
Moduleconduit-extra-1.3.8Haskell2010
Stream data from the socket.
This function does not automatically close the socket.
Since 0.0.0
Stream data to the socket.
This function does not automatically close the socket.
Since 0.0.0
The data passed to an Application.
HasReadWrite AppDataDefined in streaming-commons-0.2.3.0 · Data.Streaming.NetworkSettings for a TCP server. It takes a port to listen on, and an optional hostname to bind to.
HasAfterBind ServerSettingsDefined in streaming-commons-0.2.3.0 · Data.Streaming.NetworkHasPort ServerSettingsDefined in streaming-commons-0.2.3.0 · Data.Streaming.NetworkHasReadBufferSize ServerSettingsDefined in streaming-commons-0.2.3.0 · Data.Streaming.NetworkSince 0.1.13
Run an Application with the given settings. This function will create a
new listening socket, accept connections on it, and spawn a new thread for
each connection.
Fork a TCP Server
Will fork the runGeneralTCPServer function but will only return from this call when the server is bound to the port and accepting incoming connections. Will return the thread id of the server
Since 1.1.4
Run a general TCP server
Same as runTCPServer, except monad can be any instance of MonadUnliftIO.
Note that any changes to the monadic state performed by individual client handlers will be discarded. If you have mutable state you want to share among multiple handlers, you need to use some kind of mutable variables.
Since 1.1.3
Settings for a TCP client, specifying how to connect to the server.
HasPort ClientSettingsDefined in streaming-commons-0.2.3.0 · Data.Streaming.NetworkHasReadBufferSize ClientSettingsDefined in streaming-commons-0.2.3.0 · Data.Streaming.NetworkSince 0.1.13
Run an Application by connecting to the specified server.
Run a general TCP client
Same as runTCPClient, except monad can be any instance of MonadUnliftIO.
Since 1.1.3
Which host to bind.
Note: The IsString instance recognizes the following special values:
* means HostAny - "any IPv4 or IPv6 hostname"
*4 means HostIPv4 - "any IPv4 or IPv6 hostname, IPv4 preferred"
!4 means HostIPv4Only - "any IPv4 hostname"
*6 means HostIPv6@ - "any IPv4 or IPv6 hostname, IPv6 preferred"
!6 means HostIPv6Only - "any IPv6 hostname"
Note that the permissive * values allow binding to an IPv4 or an
IPv6 hostname, which means you might be able to successfully bind
to a port more times than you expect (eg once on the IPv4 localhost
127.0.0.1 and again on the IPv6 localhost 0:0:0:0:0:0:0:1).
Any other value is treated as a hostname. As an example, to bind to the IPv4 local host only, use "127.0.0.1".
Eq HostPreferenceDefined in streaming-commons-0.2.3.0 · Data.Streaming.Network.InternalOrd HostPreferenceDefined in streaming-commons-0.2.3.0 · Data.Streaming.Network.InternalRead HostPreferenceDefined in streaming-commons-0.2.3.0 · Data.Streaming.Network.InternalShow HostPreferenceDefined in streaming-commons-0.2.3.0 · Data.Streaming.Network.InternalIsString HostPreferenceDefined in streaming-commons-0.2.3.0 · Data.Streaming.Network.Internal