private static int RequestReservation(int ticketId, int quantity)
        {
            Console.WriteLine($"--- {nameof(RequestReservation)} ---");

            using (var context = new SampleWriteContext())
            {
                var reservation = Reservation.Request(ticketId, quantity);
                var memento     = ((IWithMemento <ReservationMemento>)reservation).CreateMemento();

                context.ReservationMementos.Add(memento);
                context.SaveChanges();

                Console.WriteLine($"\tCreated memento: {JsonConvert.SerializeObject(memento)}");

                return(memento.Id);
            }
        }
        private static void ConfirmReservation(int reservationId)
        {
            Console.WriteLine($"--- {nameof(ConfirmReservation)} ---");

            using (var context = new SampleWriteContext())
            {
                var memento     = context.ReservationMementos.AsNoTracking().FirstOrDefault(x => x.Id == reservationId);
                var reservation = new Reservation(memento);

                reservation.Confirm();

                var updatedMemento = ((IWithMemento <ReservationMemento>)reservation).CreateMemento();
                Console.WriteLine($"\tUpdated memento: {JsonConvert.SerializeObject(updatedMemento)}");

                context.ReservationMementos.Update(updatedMemento);
                context.SaveChanges();
            }
        }