   (:gen-class)
   (:use [rosado.processing]
         [clojure.contrib.command-line])
-
+  (:require clojure.contrib.profile)
   (:require [com.twinql.clojure.http :as http])
   (:import  [java.util.concurrent Executors]
             [javax.swing JFrame]

(defn run-request [request url]
  "Runs a single HTTP request"
  (set-request-state request :sent)
  (let [result (http/get url :parameters (http/map->params {:handle-redirects false}))]
      (set-request-state request (:code result))))

(defn initialize-requests [requests concurrency]

; Current state of all requests
(def req-map (ref []))

; Default HTTP Parameters
(def default-http-parameters
  (http/map->params {:handle-redirects false}))
(defn set-request-state [request state]
  "Alters the state of an HTTP request"
  (dosync (alter request assoc 2 state)))
