Safe Haskell | None |
---|---|
Language | Haskell2010 |
Multiplexed subscription poller threads; see Hasura.GraphQL.Execute.Subscription for details.
Synopsis
- pushResultToCohort :: GQResult ByteString -> Maybe ResponseHash -> SubscriptionMetadata -> CohortSnapshot 'LiveQuery -> IO ([SubscriberExecutionDetails], [SubscriberExecutionDetails])
- pollLiveQuery :: forall b. BackendTransport b => PollerId -> SubscriptionsOptions -> (SourceName, SourceConfig b) -> RoleName -> ParameterizedQueryHash -> MultiplexedQuery b -> CohortMap 'LiveQuery -> SubscriptionPostPollHook -> IO ()
Documentation
:: GQResult ByteString | |
-> Maybe ResponseHash | |
-> SubscriptionMetadata | |
-> CohortSnapshot 'LiveQuery | |
-> IO ([SubscriberExecutionDetails], [SubscriberExecutionDetails]) | subscribers to which data has been pushed, subscribers which already have this data (this information is exposed by metrics reporting) |
pollLiveQuery :: forall b. BackendTransport b => PollerId -> SubscriptionsOptions -> (SourceName, SourceConfig b) -> RoleName -> ParameterizedQueryHash -> MultiplexedQuery b -> CohortMap 'LiveQuery -> SubscriptionPostPollHook -> IO () Source #
Where the magic happens: the top-level action run periodically by each
active Poller
. This needs to be async exception safe.