[Demonstration 1]

[Buggy Method]
@Override
public void configure() throws Exception {
    restConfiguration().component("jetty").host("0.0.0.0").port("9191").bindingMode(RestBindingMode.json).dataFormatProperty("prettyPrint", "true");
    rest("/blog/").produces("application/json").consumes("application/json").get("/article/search/id/{id}").id("rest-searchbyid").to("direct:searchById").get("/article/search/user/{user}").id("rest-searchbyuser").outTypeList(Blog.class).to("direct:searchByUser").put("/article/{id}").id("rest-put-article").type(Blog.class).to("direct:add").delete("/article/{id}").id("rest-deletearticle").type(Blog.class).to("direct:remove");
}

[Buggy Hunk]
rest("/blog/").produces("application/json").consumes("application/json")

[Patch]
rest("/blog/").id("rest-blog-services").produces("application/json").consumes("application/json")

[Demonstration 2]

[Buggy Method]
static Command getAll(List<String> scmds) throws Exception {
    Command tcmd = new Command();
    get(tcmd, scmds.listIterator());
    mergeIfElses(tcmd);
    Collections.sort(tcmd.children, new Comparator<Command>() {

        public int compare(Command o1, Command o2) {
            return Integer.valueOf(o1.weigth()).compareTo(o2.weigth());
        }
    });
    return tcmd;
}

[Buggy Hunk]
return Integer.valueOf(o1.weigth()).compareTo(o2.weigth());

[Patch]
return Integer.valueOf(o1.weight()).compareTo(o2.weight());

[Demonstration 3]

[Buggy Method]
private Map<String, String> validateURLAndGetQueryMap(HttpExchange he) throws IOException {
    URI uri = he.getRequestURI();
    String path = uri.getPath();
    String context = he.getHttpContext().getPath();
    if (!context.equals(path) && !(context + "/").equals(path)) {
        new RequestHandler().handle(he);
        return null;
    }
    String query = uri.getQuery();
    System.out.println("URI: " + uri);
    System.out.println("Query: " + query);
    return queryToMap(query);
}

[Buggy Hunk]
String query = uri.getQuery();

[Patch]
String query = URLDecoder.decode(uri.getQuery(), "UTF-8");