Skip to content

Instantly share code, notes, and snippets.

@devmop
devmop / example.md
Created April 10, 2015 08:35
HATEOAS

The general gist is to have a bunch of links with "method" names describing the operations you can perform on it. Supposedly this gets you the advantage of not hardcoding urls into your clients.

Example from Wikipedia:

    <account>
       <account_number>12345</account_number>
       <balance currency="usd">100.00</balance>
       <link rel="deposit" href="/account/12345/deposit" />
  
@devmop
devmop / gist:0f7b9d092a2ca9d7ffcb
Last active August 29, 2015 14:04
Books I need rid of.
Sword of Truth - Terry Goodkind
Age of Misrule - Mark Chadbourn
Kingdom of the Serpent - Mark Chadbourn
Farseer Trilogy - Robin Hobb
Liveship Traders - Robin Hobb
Tawny Man Trilogy - Robin Hobb
Soldier Son Trilogy - Robin Hobb
@devmop
devmop / Dockerfile
Created June 13, 2014 15:46
Drone docker
from ubuntu:12.04
run apt-get install -y wget
run wget http://downloads.drone.io/latest/drone.deb
run dpkg -i drone.deb
expose 8080
CMD droned
@devmop
devmop / Junit test
Last active December 27, 2015 15:59
Feign bug
import javax.inject.Named;
import org.junit.Test;
import static org.hamcrest.Matchers.is;
import static org.junit.Assert.assertThat;
import com.google.mockwebserver.MockResponse;
import com.google.mockwebserver.MockWebServer;
import com.google.mockwebserver.RecordedRequest;