I have the following code:
(defn handle-client [in out]
(binding [
*in* (reader in)
]
(with-connection db
(let [outstream (agent (writer out))]
(loop []
(let [xml (read-input)]
(if xml
(do
(send-answers
(parse outstream (makestr xml)))
(recur))
(info
"disconnected"))))))))
The problem is, that it doesn't work to assign an agent to the
outstream. If I do, the content of the agent (the outstream in this
case) is set to nil after it is passed to send-answers and all send-
answers does is to store the agent in a struct. Why that ? I
Regards
Roger
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
-~----------~----~----~----~------~----~------~--~---