           (recur (merge-with merge-results last-result (more-f more))
                  (inc idx)))))))
 
+(defn batch-get-item-request
+  "Implementation detail"
+  [return-cc? raw-req]
+  (doto-cond [g (BatchGetItemRequest.)]
+    :always    (.setRequestItems raw-req)
+    return-cc? (.setReturnConsumedCapacity (utils/enum :total))))
+
 (defn batch-get-item
   "Retrieves a batch of items in a single request.
   Limits apply, Ref. http://goo.gl/Bj9TC.

                  {<attr> <expected-value> ...}
                  {<attr> false ...} ; Attribute must not exist"
  [client-opts table item & [{:keys [return expected return-cc?]
                              :or   {return :none}}]]
  (as-map
   (.putItem (db-client client-opts)
     (doto-cond [g (PutItemRequest.)]
       :always  (.setTableName    (name table))
       :always  (.setItem         (clj-item->db-item item))
       expected (.setExpected     (expected-values g))
       return   (.setReturnValues (utils/enum g))
       return-cc? (.setReturnConsumedCapacity (utils/enum :total))))))

(defn- attribute-updates
  "{<attr> [<action> <value>] ...} -> {<attr> AttributeValueUpdate ...}"

         (throughput-steps [3 3] [27 27])
         (throughput-steps [17 8] [3 22])
         (throughput-steps [1 1] [300 300]))

(defn update-table-request
  "Implementation detail"
  [table throughput]
  (doto (UpdateTableRequest.)
    (.setTableName (name table))
    (.setProvisionedThroughput (provisioned-throughput throughput))))

(defn update-table
  "Updates a table. Allows automatic multi-step adjustments to conform to
