Skip to content

Instantly share code, notes, and snippets.

@spinscale
Created February 5, 2013 10:45
Show Gist options
  • Save spinscale/4713674 to your computer and use it in GitHub Desktop.
Save spinscale/4713674 to your computer and use it in GitHub Desktop.
spark-groovy-jrebel-curl
# curl -v -X POST localhost:4567/login/foo
> POST /login/foo HTTP/1.1
> User-Agent: curl/7.19.7 (universal-apple-darwin10.0) libcurl/7.19.7 OpenSSL/0.9.8r zlib/1.2.3
> Host: localhost:4567
> Accept: */*
>
< HTTP/1.1 204 No Content
< Set-Cookie: JSESSIONID=1pouphqxh5z3l1pusx23ewksw6;Path=/
< Expires: Thu, 01-Jan-1970 00:00:00 GMT
< Server: Jetty(7.3.0.v20110203)
<
# Now use the session id cookie for greeting
# curl -v localhost:4567/greet/foo --header "Cookie: JSESSIONID=1pouphqxh5z3l1pusx23ewksw6"
> GET /greet/foo HTTP/1.1
> User-Agent: curl/7.19.7 (universal-apple-darwin10.0) libcurl/7.19.7 OpenSSL/0.9.8r zlib/1.2.3
> Host: localhost:4567
> Accept: */*
> Cookie: JSESSIONID=1pouphqxh5z3l1pusx23ewksw6
>
< HTTP/1.1 200 OK
< Content-Length: 10
< Server: Jetty(7.3.0.v20110203)
<
Hello foo
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment