implemented uwsgi.rpc jvm function [test]

This commit is contained in:
Unbit
2013-03-08 20:59:05 +01:00
parent 57105c1bc7
commit bcb1e623d9
+11
View File
@@ -0,0 +1,11 @@
public class rpc {
public static Object[] application(java.util.HashMap env) {
String rpc_out = uwsgi.rpc("", "reverse", (String) env.get("REQUEST_URI"));
java.util.HashMap<String, Object> headers = new java.util.HashMap<String, Object>();
headers.put("Content-Type", "text/html");
Object[] response = { 200, headers, "<h1>" + rpc_out + "</h1>"};
return response;
}
}