| Copyright | (c) Moritz Clasmeier 2017 2018 |
|---|---|
| License | BSD3 |
| Maintainer | mtesseract@silverratio.net |
| Stability | experimental |
| Portability | POSIX |
| Safe Haskell | None |
| Language | Haskell2010 |
Network.Nakadi.Types.Service
Description
This module provides the Nakadi Service Types.
Synopsis
- newtype CursorOffset = CursorOffset {}
- newtype EventTypeName = EventTypeName {}
- newtype PartitionName = PartitionName {}
- newtype PartitionCompactionKey = PartitionCompactionKey {}
- newtype CursorToken = CursorToken Text
- data Cursor = Cursor {}
- newtype ApplicationName = ApplicationName {}
- data SubscriptionsListResponse = SubscriptionsListResponse {
- _links :: PaginationLinks
- _items :: [Subscription]
- data SubscriptionCursor = SubscriptionCursor {}
- newtype FlowId = FlowId {}
- data SubscriptionCursorWithoutToken = SubscriptionCursorWithoutToken {}
- newtype SubscriptionCursorCommit = SubscriptionCursorCommit {
- _items :: [SubscriptionCursor]
- newtype CursorCommit = CursorCommit {}
- newtype SubscriptionId = SubscriptionId {}
- newtype StreamId = StreamId {
- unStreamId :: Text
- data SubscriptionEventStream = SubscriptionEventStream {}
- newtype Timestamp = Timestamp {}
- data SubscriptionEventStreamBatch a = SubscriptionEventStreamBatch {
- _cursor :: SubscriptionCursor
- _events :: Maybe (Vector a)
- newtype EventId = EventId {}
- data Partition = Partition {}
- data ShiftedCursor = ShiftedCursor {}
- data CursorDistanceQuery = CursorDistanceQuery {}
- newtype CursorDistanceResult = CursorDistanceResult {}
- data SubscriptionPosition
- data Subscription = Subscription {}
- data SubscriptionRequest = SubscriptionRequest {}
- newtype ConsumerGroup = ConsumerGroup {}
- data PublishingStatus
- data Step
- data BatchItemResponse = BatchItemResponse {}
- newtype StreamKeepAliveLimit = StreamKeepAliveLimit {}
- newtype BatchFlushTimeout = BatchFlushTimeout {}
- data CursorCommitResultType
- data CursorCommitResult = CursorCommitResult {}
- newtype CursorCommitResults = CursorCommitResults {
- _items :: [CursorCommitResult]
- data SchemaType = SchemaTypeJson
- data EventTypeSchema = EventTypeSchema {}
- newtype PaginationLink = PaginationLink {}
- data PaginationLinks = PaginationLinks {}
- data EventTypeSchemasResponse = EventTypeSchemasResponse {}
- newtype SchemaVersion = SchemaVersion {}
- newtype Offset = Offset {}
- newtype Limit = Limit {}
- data PartitionState
- data PartitionStat = PartitionStat {}
- data SubscriptionEventTypeStats = SubscriptionEventTypeStats {}
- newtype SubscriptionStats = SubscriptionStats {}
- data EventTypeCategory
- data PartitionStrategy
- data EnrichmentStrategy = EnrichmentStrategyMetadata
- data CompatibilityMode
- data CleanupPolicy
- newtype PartitionKeyField = PartitionKeyField {}
- data EventType = EventType {
- _name :: EventTypeName
- _owningApplication :: Maybe ApplicationName
- _category :: Maybe EventTypeCategory
- _enrichmentStrategies :: Maybe [EnrichmentStrategy]
- _partitionStrategy :: Maybe PartitionStrategy
- _compatibilityMode :: Maybe CompatibilityMode
- _schema :: EventTypeSchema
- _partitionKeyFields :: Maybe [PartitionKeyField]
- _cleanupPolicy :: Maybe CleanupPolicy
- _defaultStatistic :: Maybe EventTypeStatistics
- _options :: Maybe EventTypeOptions
- data DataChangeEvent a = DataChangeEvent {}
- data DataChangeEventEnriched a = DataChangeEventEnriched {}
- data BusinessEvent a = BusinessEvent {
- _payload :: a
- _metadata :: EventMetadata
- data BusinessEventEnriched a = BusinessEventEnriched {}
- data DataOp
- data EventMetadata = EventMetadata {}
- data EventMetadataEnriched = EventMetadataEnriched {}
- data EventTypeStatistics = EventTypeStatistics {}
- data EventTypeOptions = EventTypeOptions {}
Documentation
newtype CursorOffset Source #
Type for cursor offsets.
Constructors
| CursorOffset | |
Fields
| |
Instances
newtype EventTypeName Source #
Type for event type names.
Constructors
| EventTypeName | |
Fields
| |
Instances
newtype PartitionName Source #
Type for partition names.
Constructors
| PartitionName | |
Fields
| |
Instances
newtype PartitionCompactionKey Source #
Type for partition compaction keys.
Constructors
| PartitionCompactionKey | |
Fields
| |
Instances
newtype CursorToken Source #
Type for cursor tokens.
Constructors
| CursorToken Text |
Instances
Type for cursors.
Constructors
| Cursor | |
Fields | |
Instances
newtype ApplicationName Source #
Type for application names.
Constructors
| ApplicationName | |
Fields | |
Instances
data SubscriptionsListResponse Source #
SubscriptionsListResponse
Constructors
| SubscriptionsListResponse | |
Fields
| |
Instances
data SubscriptionCursor Source #
Type fo rsubscription cursors.
Constructors
| SubscriptionCursor | |
Fields
| |
Instances
A Flow ID.
Instances
| Eq FlowId Source # | |
| Ord FlowId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| Show FlowId Source # | |
| IsString FlowId Source # | |
Defined in Network.Nakadi.Internal.Types.Service Methods fromString :: String -> FlowId # | |
| Generic FlowId Source # | |
| ToJSON FlowId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| FromJSON FlowId Source # | |
| HasNakadiFlowId EventMetadataEnriched (Maybe FlowId) | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiFlowId (Config m) (Maybe FlowId) | |
| type Rep FlowId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
data SubscriptionCursorWithoutToken Source #
Type for subscription cursors without token.
Constructors
| SubscriptionCursorWithoutToken | |
Fields
| |
Instances
newtype SubscriptionCursorCommit Source #
Type for commit object for subscription cursor committing.
Constructors
| SubscriptionCursorCommit | |
Fields
| |
Instances
newtype CursorCommit Source #
Type for commit objects for cursor committing.
Constructors
| CursorCommit | |
Instances
newtype SubscriptionId Source #
Type for subscription IDs.
Constructors
| SubscriptionId | |
Fields
| |
Instances
Type for stream IDs.
Constructors
| StreamId | |
Fields
| |
Instances
| Eq StreamId Source # | |
| Ord StreamId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| Show StreamId Source # | |
| Generic StreamId Source # | |
| ToJSON StreamId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| FromJSON StreamId Source # | |
| HasNakadiStreamId SubscriptionEventStream StreamId | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiId StreamId Text | |
Defined in Network.Nakadi.Internal.Lenses | |
| HasNakadiStreamId PartitionStat (Maybe StreamId) | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| type Rep StreamId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
data SubscriptionEventStream Source #
SubscriptionEventStream
Constructors
| SubscriptionEventStream | |
Fields | |
Instances
| Show SubscriptionEventStream Source # | |
Defined in Network.Nakadi.Internal.Types.Service Methods showsPrec :: Int -> SubscriptionEventStream -> ShowS # show :: SubscriptionEventStream -> String # showList :: [SubscriptionEventStream] -> ShowS # | |
| HasNakadiStreamId SubscriptionEventStream StreamId | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiSubscriptionId SubscriptionEventStream SubscriptionId | |
Defined in Network.Nakadi.Internal.Lenses | |
Type for timestamps.
Constructors
| Timestamp | |
Fields
| |
Instances
| Eq Timestamp Source # | |
| Ord Timestamp Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| Show Timestamp Source # | |
| Generic Timestamp Source # | |
| Hashable Timestamp Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| ToJSON Timestamp Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| FromJSON Timestamp Source # | |
| HasNakadiOccurredAt EventMetadata Timestamp | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiOccurredAt EventMetadataEnriched Timestamp | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiReceivedAt EventMetadataEnriched Timestamp | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiCreatedAt Subscription Timestamp | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiUTCTime Timestamp UTCTime | |
Defined in Network.Nakadi.Internal.Lenses | |
| HasNakadiCreatedAt EventTypeSchema (Maybe Timestamp) | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| type Rep Timestamp Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
data SubscriptionEventStreamBatch a Source #
SubscriptionEventStreamBatch
Constructors
| SubscriptionEventStreamBatch | |
Fields
| |
Instances
ID of an Event
Instances
| Eq EventId Source # | |
| Ord EventId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| Show EventId Source # | |
| Generic EventId Source # | |
| Hashable EventId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| ToJSON EventId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| FromJSON EventId Source # | |
| HasNakadiEid EventMetadata EventId | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiEid EventMetadataEnriched EventId | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiId EventId UUID | |
Defined in Network.Nakadi.Internal.Lenses | |
| HasNakadiParentEids EventMetadata (Maybe [EventId]) | |
Defined in Network.Nakadi.Internal.Lenses Methods parentEids :: Lens' EventMetadata (Maybe [EventId]) | |
| HasNakadiParentEids EventMetadataEnriched (Maybe [EventId]) | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| type Rep EventId Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
Partition Data
Constructors
| Partition | |
Fields
| |
Instances
| Show Partition Source # | |
| ToJSON Partition Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| FromJSON Partition Source # | |
| HasNakadiPartition Partition PartitionName | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiOldestAvailableOffset Partition CursorOffset | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiNewestAvailableOffset Partition CursorOffset | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
| HasNakadiUnconsumedEvents Partition (Maybe Int64) | |
Defined in Network.Nakadi.Internal.Lenses Methods | |
data ShiftedCursor Source #
Type for shift-cursor queries.
Constructors
| ShiftedCursor | |
Fields
| |
Instances
data CursorDistanceQuery Source #
Type for cursor-distance queries. Represents the request to compute the distance between initial cursor and final cursor.
Constructors
| CursorDistanceQuery | |
Fields
| |
Instances
newtype CursorDistanceResult Source #
Type for results of cursor-distance-queries.
Constructors
| CursorDistanceResult | |
Instances
data SubscriptionPosition Source #
Type modelling a subscription position.
Constructors
| SubscriptionPositionBegin | |
| SubscriptionPositionEnd | |
| SubscriptionPositionCursors [SubscriptionCursorWithoutToken] |
Instances
data Subscription Source #
Type for a Subscription which has already been created.
When a subscription object is retrieved from Nakadi the following fields are regarded as mandatory:
id
owning_application
event_types
consumer_group
created_at
read_from
- depending on
read_fromalsocursors.
Constructors
| Subscription | |
Instances
data SubscriptionRequest Source #
Type for a Subscription which is to be created.
When a subscription is to be created the following fields are regarded as mandatory in the subscription object:
owning_application
event_types
The remaining fields are regarded as optional:
consumer_group
read_from
- depending on
read_fromthe fieldcursorsmight have to be present as well.
Constructors
| SubscriptionRequest | |
Instances
newtype ConsumerGroup Source #
This type models the value describing the use case of a subscription. In general this is an additional identifier used to differ subscriptions having the same owning application and event types.
Constructors
| ConsumerGroup | |
Fields | |
Instances
data PublishingStatus Source #
Type for publishing status.
Instances
Step
Instances
| Eq Step Source # | |
| Ord Step Source # | |
| Show Step Source # | |
| Generic Step Source # | |
| Hashable Step Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| ToJSON Step Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| FromJSON Step Source # | |
| type Rep Step Source # | |
Defined in Network.Nakadi.Internal.Types.Service type Rep Step = D1 (MetaData "Step" "Network.Nakadi.Internal.Types.Service" "nakadi-client-0.7.0.0-KOzkX3CyJmv3p5G5yolcIB" False) ((C1 (MetaCons "StepNone" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "StepValidating" PrefixI False) (U1 :: Type -> Type)) :+: (C1 (MetaCons "StepPartitioning" PrefixI False) (U1 :: Type -> Type) :+: (C1 (MetaCons "StepEnriching" PrefixI False) (U1 :: Type -> Type) :+: C1 (MetaCons "StepPublishing" PrefixI False) (U1 :: Type -> Type)))) | |
data BatchItemResponse Source #
In case of failures during batch publishing, Nakadi returns detailed information about which events failed to be published. This per-event information is a batch item response.
Constructors
| BatchItemResponse | |
Instances
newtype StreamKeepAliveLimit Source #
StreamKeepAliveLimit
Constructors
| StreamKeepAliveLimit | |
Fields | |
Instances
newtype BatchFlushTimeout Source #
BatchFlushTimeout
Constructors
| BatchFlushTimeout | |
Fields | |
Instances
data CursorCommitResultType Source #
CursorCommitResultType
Instances
data CursorCommitResult Source #
CursorCommitResult
Constructors
| CursorCommitResult | |
Fields | |
Instances
newtype CursorCommitResults Source #
Constructors
| CursorCommitResults | |
Fields
| |
Instances
data SchemaType Source #
SchemaType
Constructors
| SchemaTypeJson |
Instances
data EventTypeSchema Source #
Type for the schema of an event type.
Constructors
| EventTypeSchema | |
Fields
| |
Instances
newtype PaginationLink Source #
PaginationLink
Constructors
| PaginationLink | |
Instances
data PaginationLinks Source #
PaginationLinks
Constructors
| PaginationLinks | |
Fields | |
Instances
data EventTypeSchemasResponse Source #
EventTypeSchemasResponse
Constructors
| EventTypeSchemasResponse | |
Fields
| |
Instances
newtype SchemaVersion Source #
Type for the version of a schema.
Constructors
| SchemaVersion | |
Fields | |
Instances
Type for offset values.
Type for limit values.
data PartitionState Source #
Type for partition states.
Instances
data PartitionStat Source #
Type for per-partition statistics.
Constructors
| PartitionStat | |
Fields | |
Instances
data SubscriptionEventTypeStats Source #
Nakadi type SubscriptionEventTypeStats.
Constructors
| SubscriptionEventTypeStats | |
Fields | |
Instances
newtype SubscriptionStats Source #
Type modelling per-subscription statistics. Objects of this type are returned by requests to subscriptionsSUBSCRIPTION-ID/stats.
Constructors
| SubscriptionStats | |
Fields | |
Instances
data EventTypeCategory Source #
Instances
data PartitionStrategy Source #
Type for a partitioning strategy.
Constructors
| PartitionStrategyRandom | |
| PartitionStrategyUser | |
| PartitionStrategyHash | |
| PartitionStrategyCustom Text |
Instances
data EnrichmentStrategy Source #
Type for an enrichment stragey.
Constructors
| EnrichmentStrategyMetadata |
Instances
data CompatibilityMode Source #
Type for an event type compatibility mode.
Instances
data CleanupPolicy Source #
Type for cleanup policy.
Constructors
| CleanupPolicyDelete | |
| CleanupPolicyCompact |
Instances
newtype PartitionKeyField Source #
Type for a partitioning key field.
Constructors
| PartitionKeyField | |
Fields | |
Instances
EventType
Constructors
Instances
data DataChangeEvent a Source #
DataChangeEvent
Constructors
| DataChangeEvent | |
Instances
data DataChangeEventEnriched a Source #
A DataChangeEvent enriched by Nakadi
Constructors
| DataChangeEventEnriched | |
Instances
data BusinessEvent a Source #
Type modelling a "Business Event". Their JSON encodings are special since the payload
object is directly enriched with a metadata field. "Data Change Events" on the other side
are JSON-encoded such that the complete event payload is contained in a seperate object field.
On the Haskell API side we split payload from meta data, which requires us to write custom
ToJSON and FromJSON implementations.
Constructors
| BusinessEvent | |
Fields
| |
Instances
data BusinessEventEnriched a Source #
Type modelling a Nakadi-enriched "Business Event". JSON encoding is basically the same as for the non-enriched Business Events.
Constructors
| BusinessEventEnriched | |
Fields
| |
Instances
Type for "data_op" as contained in the DataChangeEvent.
Constructors
| DataOpCreation | |
| DataOpUpdate | |
| DataOpDeletion | |
| DataOpSnapshot |
Instances
| Eq DataOp Source # | |
| Ord DataOp Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| Show DataOp Source # | |
| ToJSON DataOp Source # | |
Defined in Network.Nakadi.Internal.Types.Service | |
| FromJSON DataOp Source # | |
| HasNakadiDataOp (DataChangeEvent a) DataOp | |
Defined in Network.Nakadi.Internal.Lenses Methods dataOp :: Lens' (DataChangeEvent a) DataOp | |
| HasNakadiDataOp (DataChangeEventEnriched a) DataOp | |
Defined in Network.Nakadi.Internal.Lenses Methods dataOp :: Lens' (DataChangeEventEnriched a) DataOp | |
data EventMetadata Source #
Type of published event metadata values.
Constructors
| EventMetadata | |
Fields | |
Instances
data EventMetadataEnriched Source #
Type of event metadata enriched by Nakadi
Constructors
| EventMetadataEnriched | |
Fields | |
Instances
data EventTypeStatistics Source #
Type for event type statistics.
Constructors
| EventTypeStatistics | |
Fields | |
Instances
data EventTypeOptions Source #
Type for event type options.
Constructors
| EventTypeOptions | |
Fields | |