comparison src/requests.tp @ 19:5a025e6c6f89

simple parallel requests limit test
author William Morgan <bill@mrgn.org>
date Fri, 09 Aug 2013 13:53:45 -0700
parents a0e66161bde0
children 92db3d1e8809
comparison
equal deleted inserted replaced
18:a0e66161bde0 19:5a025e6c6f89
2 2
3 quote <- :str { 3 quote <- :str {
4 "\"" . str . "\"" 4 "\"" . str . "\""
5 } 5 }
6 6
7 evalRequest <- :_id args { 7 evalRequest <- :id args {
8 #{ 8 #{
9 id <- _id 9 // id <- _id
10 string <- { 10 string <- {
11 // idStr <- id// method not implemented
12 // idStr <- _id//method not implemented
13 // idStr <- "a"//good 11 // idStr <- "a"//good
14 // idStr <- quote("id") . quote(id)//segfault 12 idStr <- quote("id") . quote(id)//segfault
15 // idStr <- "\"id\":\"" . id . "\""// method not implemented 13 // idStr <- "\"id\":\"" . id . "\""// method not implemented
16 // argsStr <- ""//arguments fold: "" with: :acc el {acc . el} 14 // argsStr <- ""//arguments fold: "" with: :acc el {acc . el}
17 argsStr <- "b" 15 argsStr <- "b"
18 "{" . idStr . "," . argsStr . "}" 16 "{" . idStr . "," . argsStr . "}"
19 } 17 }
29 } 27 }
30 } 28 }
31 } 29 }
32 30
33 main <- { 31 main <- {
34 print: ((evalRequest: #[1 2 3]) string) . "\n" 32 print: ((evalRequest: "someId" #[1 2 3]) string) . "\n"
35 print: ((guessRequest: "someId" "someProg") string) . "\n" 33 print: ((guessRequest: "someId" "someProg") string) . "\n"
36 } 34 }
37 } 35 }