haxl-2.1.2.0: A Haskell library for efficient, concurrent, and concise data access.

Safe HaskellNone
LanguageHaskell2010

Haxl.Core.RequestStore

Description

Bucketing requests by DataSource.

When a request is issued by the client via dataFetch, it is placed in the RequestStore. When we are ready to fetch the current batch of requests, the contents operation extracts the fetches, bucketed by DataSource.

This module is provided for access to Haxl internals only; most users should not need to import it.

Synopsis

Documentation

data BlockedFetches u Source #

A batch of BlockedFetch objects for a single DataSource

Constructors

DataSource u r => BlockedFetches [BlockedFetch r] 

data RequestStore u Source #

A container for multiple BlockedFetch objects.

contents :: RequestStore u -> [BlockedFetches u] Source #

Retrieves the whole contents of the RequestStore.

newtype ReqCountMap Source #

Constructors

ReqCountMap (Map Text (Map TypeRep Int)) 
Instances
Show ReqCountMap Source # 
Instance details

Defined in Haxl.Core.RequestStore

addToCountMap :: forall (r :: * -> *). (DataSourceName r, Typeable r) => Proxy r -> Int -> ReqCountMap -> ReqCountMap Source #

subFromCountMap :: forall (r :: * -> *). (DataSourceName r, Typeable r) => Proxy r -> Int -> ReqCountMap -> ReqCountMap Source #