Safe Haskell | None |
---|---|
Language | Haskell2010 |
The shard logic
Synopsis
- data Shard = Shard {
- shardID :: Int
- shardCount :: Int
- gateway :: Text
- evtIn :: InChan CalamityEvent
- cmdOut :: OutChan ControlMessage
- shardState :: IORef ShardState
- token :: Text
- newShard :: Members '[LogEff, MetricEff, Embed IO, Final IO, Async] r => Text -> Int -> Int -> Token -> InChan CalamityEvent -> Sem r (InChan ControlMessage, Async (Maybe ()))
Documentation
Shard | |
|
Instances
Generic Shard Source # | |
type Rep Shard Source # | |
Defined in Calamity.Gateway.Types type Rep Shard = D1 ('MetaData "Shard" "Calamity.Gateway.Types" "calamity-0.1.6.1-inplace" 'False) (C1 ('MetaCons "Shard" 'PrefixI 'True) ((S1 ('MetaSel ('Just "shardID") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int) :*: (S1 ('MetaSel ('Just "shardCount") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Int) :*: S1 ('MetaSel ('Just "gateway") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text))) :*: ((S1 ('MetaSel ('Just "evtIn") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (InChan CalamityEvent)) :*: S1 ('MetaSel ('Just "cmdOut") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (OutChan ControlMessage))) :*: (S1 ('MetaSel ('Just "shardState") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 (IORef ShardState)) :*: S1 ('MetaSel ('Just "token") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedLazy) (Rec0 Text))))) |