Safe Haskell | Safe-Inferred |
---|---|
Language | Haskell2010 |
Synopsis
- makeGQLContext :: UserInfo -> SchemaCache -> GraphQLQueryType -> GQLContext
- data ResolvedExecutionPlan
- newtype MultiplexedSubscriptionQueryPlan (b :: BackendType) = MultiplexedSubscriptionQueryPlan (SubscriptionQueryPlan b (MultiplexedQuery b))
- newtype SubscriptionQueryPlan = SubscriptionQueryPlan (AnyBackend MultiplexedSubscriptionQueryPlan)
- data SourceSubscription
- data SubscriptionExecution
- buildSubscriptionPlan :: forall m. (MonadError QErr m, MonadQueryTags m, MonadIO m, MonadBaseControl IO m) => UserInfo -> RootFieldMap (QueryRootField UnpreparedValue) -> ParameterizedQueryHash -> [Header] -> Maybe Name -> m (SubscriptionExecution, Maybe (Endo Value))
- checkQueryInAllowlist :: MonadError QErr m => AllowListStatus -> AllowlistMode -> UserInfo -> GQLReqParsed -> SchemaCache -> m ()
- getResolvedExecPlan :: forall m. (MonadError QErr m, MonadMetadataStorage m, MonadIO m, MonadBaseControl IO m, MonadTrace m, MonadGQLExecutionCheck m, MonadQueryTags m, ProvidesNetwork m) => Environment -> Logger Hasura -> PrometheusMetrics -> UserInfo -> SQLGenCtx -> ReadOnlyMode -> SchemaCache -> GraphQLQueryType -> [Header] -> GQLReqUnparsed -> SingleOperation -> Maybe Name -> RequestId -> m (ParameterizedQueryHash, ResolvedExecutionPlan)
Documentation
makeGQLContext :: UserInfo -> SchemaCache -> GraphQLQueryType -> GQLContext Source #
Construct a single step of an execution plan.
data ResolvedExecutionPlan Source #
QueryExecutionPlan ExecutionPlan [QueryRootField UnpreparedValue] DirectiveMap | query execution; remote schemas and introspection possible |
MutationExecutionPlan ExecutionPlan | mutation execution; only __typename introspection supported |
SubscriptionExecutionPlan (SubscriptionExecution, Maybe (Endo Value)) | either action query or live query execution; remote schemas and introspection not supported |
newtype MultiplexedSubscriptionQueryPlan (b :: BackendType) Source #
newtype SubscriptionQueryPlan Source #
data SourceSubscription Source #
data SubscriptionExecution Source #
The comprehensive subscription plan. We only support either 1. Fields with only async action queries with no associated relationships or 2. Source database query fields from same source and also can be mixed with async action query fields whose relationships are defined to tables in the source
buildSubscriptionPlan :: forall m. (MonadError QErr m, MonadQueryTags m, MonadIO m, MonadBaseControl IO m) => UserInfo -> RootFieldMap (QueryRootField UnpreparedValue) -> ParameterizedQueryHash -> [Header] -> Maybe Name -> m (SubscriptionExecution, Maybe (Endo Value)) Source #
checkQueryInAllowlist :: MonadError QErr m => AllowListStatus -> AllowlistMode -> UserInfo -> GQLReqParsed -> SchemaCache -> m () Source #
getResolvedExecPlan :: forall m. (MonadError QErr m, MonadMetadataStorage m, MonadIO m, MonadBaseControl IO m, MonadTrace m, MonadGQLExecutionCheck m, MonadQueryTags m, ProvidesNetwork m) => Environment -> Logger Hasura -> PrometheusMetrics -> UserInfo -> SQLGenCtx -> ReadOnlyMode -> SchemaCache -> GraphQLQueryType -> [Header] -> GQLReqUnparsed -> SingleOperation -> Maybe Name -> RequestId -> m (ParameterizedQueryHash, ResolvedExecutionPlan) Source #
Construct a ResolvedExecutionPlan
from a GQLReqParsed
and a
bunch of metadata.
Labelling it as inlineable fixed a performance regression on GHC 8.10.7.