 ; PARSE COMMAND LINE OPTIONS
 
 (def cli-options
-  [["-v" "--version X" "Version (seq, par)"
-    ; TODO: rename "seq", because it's not sequential.
-    ; There are two versions of this program, "seq" works similar to the
-    ; original vacation benchmark, while "par" uses secondary worker actors.
-    :default "seq"
-    :validate [#(contains? #{"seq" "par"} %) "Must be seq or par"]]
+  [["-v" "--version X" "Version (orig, txact)"
+    ; There are two versions of this program, "orig" works similar to the
+    ; original vacation benchmark, while "txact" uses secondary worker actors.
+    :default "orig"
+    :validate [#(contains? #{"orig" "txact"} %) "Must be orig or txact"]]
    ["-w" "--workers N" "Number of workers"
     ; Workers are called clients in vacation, the option is -c there.
     :default 20

      (def log log-debug))
    (if proceed?
      (let [options {:version             (case (:version args)
                                            "par" :par
                                                  :seq)
                     :n-workers           (:workers args)
                     :n-secondary-workers (if (not= (:version args) "par")
                                            0
                                            (:secondary-workers args))
                     :n-reservations      (:reservations args)
                     :n-relations         (:relations args)
                     :n-queries           (:queries args)}]
        (log "options: " options)
        (when (and (= (:version args) :seq)
                   (not= (:secondary-workers args) 20)) ; 20 is the default
          (println "WARNING: did not expect number of secondary workers to be"
            "specified when version is 'seq'."))
        (when (not= (rem (:n-reservations options) (:n-workers options)) 0)
          (println "WARNING: number of reservations is not divisible by number"
            "of workers."))

        :pnr    pnr)))
  (log "finished reservation" (:id @reservation)))

(defn process-reservation-txact
  [reservation
   {:keys [cars flights rooms]}
   {:keys [n-queries]}
   secondary-workers]
  "Process a reservation: find a car, flight, and room for the reservation,
  generate a PNR, and update the data structures.

  This version books the car, flight, and room in a separate actor."
  (dosync
    (log "start tx for reservation" (:id @reservation))
    (send (rand-nth secondary-workers) :car    cars    reservation n-queries)
