Closed pkhamre closed 12 years ago
Try using thin instead of webrick. First make sure you have thin (gem install thin
).
Then run:
bundle exec thin start -R config.ru
Thanks, that helped.
/ respons as I expected, but I get 404 on /version, /available, /counters etc.
Very strange. What type of output are you getting?
/
pkhamre@koda:~ :( GET -USed http://precise:3000/
GET http://precise:3000/
User-Agent: lwp-request/6.03 libwww-perl/6.03
200 OK
Connection: close
Server: thin 1.4.1 codename Chromeo
Content-Length: 832
Content-Type: text/html;charset=utf-8
Client-Date: Thu, 05 Jul 2012 13:50:26 GMT
Client-Peer: 192.168.122.141:3000
Client-Response-Num: 1
Link: </css/jquery-ui.css>; rel="stylesheet"; type="text/css"
Link: </css/datetimepicker.css>; rel="stylesheet"; type="text/css"
Link: </css/public.css>; rel="stylesheet"; type="text/css"
Title: Batsd Dash
X-Frame-Options: sameorigin
X-Meta-Author: http://breakbase.com
X-XSS-Protection: 1; mode=block
/version
pkhamre@koda:~ :) GET -USed http://precise:3000/version
GET http://precise:3000/version
User-Agent: lwp-request/6.03 libwww-perl/6.03
404 Not Found
Connection: close
Server: thin 1.4.1 codename Chromeo
Content-Length: 441
Content-Type: text/html;charset=utf-8
Client-Date: Thu, 05 Jul 2012 13:50:33 GMT
Client-Peer: 192.168.122.141:3000
Client-Response-Num: 1
X-Cascade: pass
X-Frame-Options: sameorigin
X-XSS-Protection: 1; mode=block
/counters
pkhamre@koda:~ :( GET -USed http://precise:3000/counters
GET http://precise:3000/counters
User-Agent: lwp-request/6.03 libwww-perl/6.03
404 Not Found
Connection: close
Server: thin 1.4.1 codename Chromeo
Content-Length: 442
Content-Type: text/html;charset=utf-8
Client-Date: Thu, 05 Jul 2012 13:50:36 GMT
Client-Peer: 192.168.122.141:3000
Client-Response-Num: 1
X-Cascade: pass
X-Frame-Options: sameorigin
X-XSS-Protection: 1; mode=block
pkhamre@koda:~ :(
I should also add that I have no data in batsd yet.
The 404's are because you need to set the Accept header to application/json
for accessing data.
Try hitting /counters#metrics=requests
in your browser and see if you get a response.
Note that, in the next few days when we push our updates, these routes will change somewhat.
Ah, thank you! :)
pkhamre@koda:~ :) GET -H'Accept: application/json' http://precise:3000/version
{"version":"0.2.1"}
Installed the batsd-dash gem, and added a simple config.ru-file and ran rackup. Requests to the server causes 500 internal server error.
A sample request:
Any suggestions?