From f9500134960f85ddd57810a7406fd4177f13aeef Mon Sep 17 00:00:00 2001 From: Ruben Bartelink Date: Thu, 13 Feb 2020 19:53:48 +0000 Subject: [PATCH] Update to FsCodec 2.0.0-rc3 --- equinox-fc/Domain/Allocation.fs | 3 +++ equinox-fc/Domain/Allocator.fs | 3 +++ equinox-fc/Domain/Ticket.fs | 3 +++ equinox-fc/Domain/TicketList.fs | 3 +++ 4 files changed, 12 insertions(+) diff --git a/equinox-fc/Domain/Allocation.fs b/equinox-fc/Domain/Allocation.fs index 1fd7d485a..4bc4a5372 100644 --- a/equinox-fc/Domain/Allocation.fs +++ b/equinox-fc/Domain/Allocation.fs @@ -6,6 +6,9 @@ let streamName allocationId = FsCodec.StreamName.create Category (AllocationId.t // NOTE - these types and the union case names reflect the actual storage formats and hence need to be versioned with care module Events = + let [] CategoryId = "Allocation" + let (|For|) id = FsCodec.StreamName.create CategoryId (AllocationId.toString id) + type Commenced = { ticketIds : TicketId[] } type Tickets = { ticketIds : TicketId[] } type Allocated = { ticketIds : TicketId[]; listId : TicketListId } diff --git a/equinox-fc/Domain/Allocator.fs b/equinox-fc/Domain/Allocator.fs index b83a3b4e5..01d778171 100644 --- a/equinox-fc/Domain/Allocator.fs +++ b/equinox-fc/Domain/Allocator.fs @@ -8,6 +8,9 @@ let streamName allocatorId = FsCodec.StreamName.create Category (AllocatorId.toS // NOTE - these types and the union case names reflect the actual storage formats and hence need to be versioned with care module Events = + let [] CategoryId = "Allocator" + let (|For|) id = FsCodec.StreamName.create CategoryId (AllocatorId.toString id) + type Commenced = { allocationId : AllocationId; cutoff : DateTimeOffset } type Completed = { allocationId : AllocationId; reason : Reason } and [)>] diff --git a/equinox-fc/Domain/Ticket.fs b/equinox-fc/Domain/Ticket.fs index fdd00cc81..0f3a5a0fe 100644 --- a/equinox-fc/Domain/Ticket.fs +++ b/equinox-fc/Domain/Ticket.fs @@ -6,6 +6,9 @@ let streamName ticketId = FsCodec.StreamName.create Category (TicketId.toString // NOTE - these types and the union case names reflect the actual storage formats and hence need to be versioned with care module Events = + let [] CategoryId = "Ticket" + let (|For|) id = FsCodec.StreamName.create CategoryId (TicketId.toString id) + type Reserved = { allocatorId : AllocatorId } type Allocated = { allocatorId : AllocatorId; listId : TicketListId } diff --git a/equinox-fc/Domain/TicketList.fs b/equinox-fc/Domain/TicketList.fs index c452ac24e..167f4930f 100644 --- a/equinox-fc/Domain/TicketList.fs +++ b/equinox-fc/Domain/TicketList.fs @@ -6,6 +6,9 @@ let streamName listId = FsCodec.StreamName.create Category (TicketListId.toStrin // NOTE - these types and the union case names reflect the actual storage formats and hence need to be versioned with care module Events = + let [] CategoryId = "TicketList" + let (|For|) id = FsCodec.StreamName.create CategoryId (TicketListId.toString id) + type Allocated = { allocatorId : AllocatorId; ticketIds : TicketId[] } type Snapshotted = { ticketIds : TicketId[] } type Event =