//create the JSON Object to pass to the client
JSONObject object=new JSONObject();
//one instance
object.put("name","something2");
object.put("status", "up");
//second instance
object.put("name", "something2");
object.put("status", "down");
String json = object.toString();
response.getOutputStream().print(json);
System.out.println("JSON Contents: "+json);
必要な出力:{名前:something1、ステータス:up}、{名前:something2、ステータス:down}...など