| Safe Haskell | None |
|---|---|
| Language | Haskell2010 |
Database.PostgreSQL.Simple.Options
Description
A postgresql connection options type and related functions.
Synopsis
- data Options = Options {
- host :: Last String
- hostaddr :: Last String
- port :: Last Int
- user :: Last String
- password :: Last String
- dbname :: Last String
- connectTimeout :: Last Int
- clientEncoding :: Last String
- options :: Last String
- fallbackApplicationName :: Last String
- keepalives :: Last Int
- keepalivesIdle :: Last Int
- keepalivesCount :: Last Int
- sslmode :: Last String
- requiressl :: Last Int
- sslcompression :: Last Int
- sslcert :: Last String
- sslkey :: Last String
- sslrootcert :: Last String
- requirepeer :: Last String
- krbsrvname :: Last String
- gsslib :: Last String
- service :: Last String
- defaultOptions :: Options
- toConnectionString :: Options -> ByteString
- parseConnectionString :: String -> Either String Options
Documentation
A postgresql connection options type.
Constructors
| Options | |
Fields
| |
Instances
defaultOptions :: Options Source #
Default options.
defaultOptions :: Options
defaultOptions = mempty
{ host = pure "localhost"
, port = pure 5432
, user = pure "postgres"
, dbname = pure "postgres"
}
toConnectionString :: Options -> ByteString Source #
Make a key value postgresql option string.