Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Hasura.Backends.Postgres.Execute.ConnectionTemplate
Synopsis
- data PrimaryTag = PrimaryTag
- data DefaultTag = DefaultTag
- data ReadReplicasTag = ReadReplicasTag
- data ConnectionSetMemberTemplateContext = ConnectionSetMemberTemplateContext {
- _cseType :: ConnectionSetTemplateContextType
- _cseName :: PostgresConnectionSetMemberName
- mkConnectionSetMemberTemplateContext :: PostgresConnectionSetMemberName -> ConnectionSetMemberTemplateContext
- data PostgresResolvedConnectionTemplate
- data RequestContextHeaders = RequestContextHeaders (HashMap Text Text)
- data ConnectionSetTemplateContext
- newtype QueryOperationType = QueryOperationType OperationType
- data QueryContext = QueryContext {}
- data RequestContext = RequestContext {}
- data PostgresConnectionTemplateContext = PostgresConnectionTemplateContext {}
- makeConnectionTemplateContext :: RequestContext -> [PostgresConnectionSetMemberName] -> PostgresConnectionTemplateContext
- runKritiEval :: PostgresConnectionTemplateContext -> KritiTemplate -> Either EvalError Value
- makeRequestContext :: Maybe QueryContext -> [Header] -> SessionVariables -> RequestContext
Documentation
data PrimaryTag Source #
This connection tag represents primary database connection
Constructors
PrimaryTag |
Instances
data DefaultTag Source #
This connection tag represents default behaviour of database connections.
For example, if read replica is set, then it will redirect GQL queries to read replicas and mutations to the primary connection
Constructors
DefaultTag |
Instances
data ReadReplicasTag Source #
This connection tag represents read replica database connection
Constructors
ReadReplicasTag |
Instances
data ConnectionSetMemberTemplateContext Source #
Data type for single member in connection_set for connection template context
Constructors
ConnectionSetMemberTemplateContext | |
Fields
|
Instances
mkConnectionSetMemberTemplateContext :: PostgresConnectionSetMemberName -> ConnectionSetMemberTemplateContext Source #
data PostgresResolvedConnectionTemplate Source #
Outcome of the connection template resolution
Constructors
PCTODefault DefaultTag | |
PCTOPrimary PrimaryTag | |
PCTOReadReplicas ReadReplicasTag | |
PCTOConnectionSet PostgresConnectionSetMemberName |
Instances
data RequestContextHeaders Source #
Headers information for the connection template context
Constructors
RequestContextHeaders (HashMap Text Text) |
Instances
data ConnectionSetTemplateContext Source #
Data type for connection_set for connection template context
Instances
newtype QueryOperationType Source #
Constructors
QueryOperationType OperationType |
Instances
FromJSON QueryOperationType Source # | |
Defined in Hasura.Backends.Postgres.Execute.ConnectionTemplate Methods parseJSON :: Value -> Parser QueryOperationType Source # parseJSONList :: Value -> Parser [QueryOperationType] Source # | |
ToJSON QueryOperationType Source # | |
Defined in Hasura.Backends.Postgres.Execute.ConnectionTemplate Methods toJSON :: QueryOperationType -> Value Source # toEncoding :: QueryOperationType -> Encoding Source # toJSONList :: [QueryOperationType] -> Value Source # toEncodingList :: [QueryOperationType] -> Encoding Source # | |
Show QueryOperationType Source # | |
Defined in Hasura.Backends.Postgres.Execute.ConnectionTemplate Methods showsPrec :: Int -> QueryOperationType -> ShowS # show :: QueryOperationType -> String # showList :: [QueryOperationType] -> ShowS # |
data QueryContext Source #
Query information (operation name and operation type) for connection template context
Constructors
QueryContext | |
Fields |
Instances
data RequestContext Source #
Request information for connection template context
Constructors
RequestContext | |
Fields |
Instances
data PostgresConnectionTemplateContext Source #
The complete connection template context used for resolving connection template
Constructors
PostgresConnectionTemplateContext | |
Instances
makeConnectionTemplateContext :: RequestContext -> [PostgresConnectionSetMemberName] -> PostgresConnectionTemplateContext Source #
Construct template context
runKritiEval :: PostgresConnectionTemplateContext -> KritiTemplate -> Either EvalError Value Source #
We should move this to Data.Aeson.Kriti.Functions
makeRequestContext :: Maybe QueryContext -> [Header] -> SessionVariables -> RequestContext Source #