   [reservation
    {:keys [cars flights rooms]}
    {:keys [n-queries]}
-   workers]
+   secondary-workers]
   "Process a reservation: find a car, flight, and room for the reservation and
   update the data structures."
   (dosync
     (log "start tx for reservation" (:id @reservation))
-    (send (rand-nth workers) :car    cars    reservation n-queries)
-    (send (rand-nth workers) :flight flights reservation n-queries)
-    (send (rand-nth workers) :room   rooms   reservation n-queries)
+    (send (rand-nth secondary-workers) :car    cars    reservation n-queries)
+    (send (rand-nth secondary-workers) :flight flights reservation n-queries)
+    (send (rand-nth secondary-workers) :room   rooms   reservation n-queries)
     (let [pnr (generate-pnr reservation)]
       (alter reservation assoc
         :status :in-process

    (when print-help?
      (println usage-info))
    ; overwrite "log" function if debugging is enabled
    (when (:debug options)
      (def log log-debug))
    (if proceed?
      (let [options {:n-workers           (:workers options)
                     :n-secondary-workers (:secondary-workers options)
                     :n-reservations      (:reservations options)
                     :n-relations         (:relations options)
                     :n-queries           (:queries options)}]
        (log "options: " options)
        (when (not= (rem (:n-reservations options) (:n-workers options)) 0)
          (println "WARNING: number of reservations is not divisible by number"
            "of workers."))

    ; Note: as opposed to the vacation benchmark, we only support making
    ; reservations, not deleting customers or updating tables.
    (log "start reservation" (:id @reservation) "by worker" worker-id)
    (case (:version options)
      :par
        (process-reservation-par reservation data options secondary-workers)
      ;seq
        (process-reservation-seq reservation data options))
    (send master :done :reservation (:id @reservation))))

(def done? (promise))

(def master-waiting-behavior
  (behavior
    [start-time n]
    [_done _key _id]
    ; _key is one of :reservation, :car, :flight, :room
    (if (= n 1)
      (do
        (println "Total execution time:"
          (/ (- (System/nanoTime) start-time) 1000) "ms")
        (log "done")
        #_(log-data data)
        (deliver done? true))
      (become :same start-time (dec n)))))

(def master-initial-behavior
  (behavior
    [{:keys [version n-workers n-secondary-workers n-reservations] :as options}]
    [_start]
    (let [{:keys [reservations cars flights rooms] :as data}
            (initialize-data options)
