Copyright | (c) Soostone Inc 2020 |
---|---|
License | AllRightsReserved |
Stability | experimental |
Portability | POSIX |
Safe Haskell | None |
Language | Haskell2010 |
Synopsis
- data RedshiftT (m :: Type -> Type) a
- connectRedshift :: forall (m :: Type -> Type). MonadIO m => RedshiftDB -> Int -> NominalDiffTime -> Int -> RedshiftT m (Pool Connection)
- runRedshift :: MonadIO m => RedshiftState -> RedshiftT m a -> m a
- defRS :: Configuration -> RedshiftState
- redNick :: String -> IO RedshiftDB
- withRedshift :: String -> Int -> NominalDiffTime -> Int -> (BackendConn Redshift -> IO b) -> IO b
- withPostgresString :: String -> (BackendConn Redshift -> IO b) -> IO b
Redshift Re-exports
data RedshiftT (m :: Type -> Type) a #
The Redshift monad transformer that all the redshift API operations run in. This monad ensures that all tunnels get a unique port on localhost.
Instances
MonadTrans RedshiftT | |
Defined in Aws.Redshift.Monad | |
Monad m => Monad (RedshiftT m) | |
Functor m => Functor (RedshiftT m) | |
MonadFix m => MonadFix (RedshiftT m) | |
Defined in Aws.Redshift.Monad | |
MonadFail m => MonadFail (RedshiftT m) | |
Defined in Aws.Redshift.Monad | |
Monad m => Applicative (RedshiftT m) | |
Defined in Aws.Redshift.Monad | |
MonadIO m => MonadIO (RedshiftT m) | |
Defined in Aws.Redshift.Monad | |
MonadThrow m => MonadThrow (RedshiftT m) | |
Defined in Aws.Redshift.Monad | |
MonadCatch m => MonadCatch (RedshiftT m) | |
MonadMask m => MonadMask (RedshiftT m) | |
Defined in Aws.Redshift.Monad mask :: ((forall a. RedshiftT m a -> RedshiftT m a) -> RedshiftT m b) -> RedshiftT m b # uninterruptibleMask :: ((forall a. RedshiftT m a -> RedshiftT m a) -> RedshiftT m b) -> RedshiftT m b # generalBracket :: RedshiftT m a -> (a -> ExitCase b -> RedshiftT m c) -> (a -> RedshiftT m b) -> RedshiftT m (b, c) # | |
MFunctor RedshiftT | |
connectRedshift :: forall (m :: Type -> Type). MonadIO m => RedshiftDB -> Int -> NominalDiffTime -> Int -> RedshiftT m (Pool Connection) #
Establish a postgresql-simple connection to a RedshiftDB.
runRedshift :: MonadIO m => RedshiftState -> RedshiftT m a -> m a #
Runs any DB action in IO.
The only way to unwrap RedshiftT, as we need to carefully manage SSH tunnels and database connections.
defRS :: Configuration -> RedshiftState #
A default RedshiftState that cleans up and is not verbose. If you
store your keys in ~/.aws-keys you can use baseConfiguration
for
the configuration parameter
redNick :: String -> IO RedshiftDB #
Retrieves a RedshiftDB for the specified DB nickname.
withRedshift :: String -> Int -> NominalDiffTime -> Int -> (BackendConn Redshift -> IO b) -> IO b #
withPostgresString :: String -> (BackendConn Redshift -> IO b) -> IO b #