úÎ!@4=b%      !"#$Safe"#_K%&'()*+,;Distribute messages from one producer to several consumers.None"#_ * postgres-websocketsTOpens a thread that relays messages from the producer thread to the channels forever postgres-websocketsjReads the messages from the producer and relays them to the active listeners in their respective channels. postgres-websocketsÿ_Adds a listener to a certain multiplexer's channel. The listener must be a function that takes a 'TChan Message' and perform any IO action. All listeners run in their own thread. The first listener will open the channel, when a listener dies it will check if there acquire any others and close the channel when that's the case.   <Parse and validate JWT to open postgres-websockets channels.None"#_À-postgres-websockets0Possible situations encountered with client JWTspostgres-websockets Given a secret, a token and a timestamp it validates the claims and returns either an error message or a triple containing channel, mode and claims hashmap..postgres-websocketsRReceives the JWT secret (from config) and a JWT and returns a map of JWT claims./postgres-websocketsNInternal helper used to turn JWT ClaimSet into something easier to work with0postgres-websocketsžInternal helper to generate HMAC-SHA256. When the jwt key in the config file is a simple string rather than a JWK object, we'll apply this function to it.1Manages PostgresWebsockets configuration options.None"#_! postgres-websockets#Config file settings for the serverpostgres-websocketsUser friendly version numberpostgres-websocketsˆLoad all postgres-websockets config from Environment variables. This can be used to use just the middleware or to feed into warpSettings postgres-websockets^Given a shutdown handler and an AppConfig builds a Warp Settings to start a stand-alone server1postgres-websockets7Function to read and parse options from the environment   +Build a Hasql.Notifications based producer .None"#_4ä!postgres-websocketsØReturns a multiplexer from a connection URI, keeps trying to connect in case there is any error. This function also spawns a thread that keeps relaying the messages from the database to the multiplexer's listeners"postgres-websocketsÈReturns a multiplexer from a connection URI or an error message on the left case This function also spawns a thread that keeps relaying the messages from the database to the multiplexer's listeners2postgres-websocketsReturns a multiplexer from a channel and an IO Connection, listen for different database notifications on the provided channel using the connection produced.tThis function also spawns a thread that keeps relaying the messages from the database to the multiplexer's listenersTo listen on channels *chat* ± import Protolude import PostgresWebsockets.HasqlBroadcast import PostgresWebsockets.Broadcast import Hasql.Connection main = do conOrError <- H.acquire "postgres:/ localhostÌtest_database" let con = either (panic . show) id conOrError :: Connection multi <- newHasqlBroadcaster con onMessage multi "chat" (ch -> forever $ fmap print (atomically $ readTChan ch)  !"!" LPostgresWebsockets WAI middleware, add functionality to any WAI application.None"#7_8Ò#postgres-websocketsxGiven a secret, a function to fetch the system time, a Hasql Pool and a Multiplexer this will give you a WAI middleware.#@Functions to start a full stand-alone PostgresWebsockets server.None"#_<9$postgres-websocketsmStart a stand-alone warp server using the parameters from AppConfig and a opening a database connection pool.$*PostgresWebsockets main library interface.None"#_=>#$$#3    !!"#$%&'()*+,-./0123456789:;<=>?2postgres-websockets-0.8.0.1-LbZYohOXk3hLMS8cqR6h7s!PostgresWebsockets.HasqlBroadcastPostgresWebsockets.BroadcastPostgresWebsockets.ClaimsPostgresWebsockets.ConfigPostgresWebsocketsPaths_postgres_websocketsPostgresWebsockets.MiddlewarePostgresWebsockets.Server$hasql-1.4.4.2-LQttfpddlfiIF3C5FtgV4EHasql.Private.Connectionacquire stm-2.5.0.0Control.Concurrent.STM.TQueue readTQueue writeTQueueControl.Concurrent.STM.TChan readTChan MultiplexersrcMessagechannelpayloadrelayMessagesForever relayMessagesnewMultiplexer onMessage$fShowMultiplexer $fEqMessage $fShowMessageConnectionInfovalidateClaims$fEqJWTAttempt AppConfigconfigDatabase configPath configHost configPortconfigListenChannelconfigJwtSecretconfigJwtSecretIsBase64 configPool prettyVersion loadConfig warpSettingsnewHasqlBroadcasternewHasqlBroadcasterOrErrorpostgresWsMiddlewareserveversion getBinDir getLibDir getDynLibDir getDataDir getLibexecDir getSysconfDirgetDataFileName JWTAttempt jwtClaims claims2maphs256jwk readOptionsnewHasqlBroadcasterForChannel