private int handleApi(String s, ChannelHandlerContext ctx, HttpRequest req) {
		if (s.indexOf("/") == 0)
			s = s.substring(1);
		else
			return -1;
		int indexOfSlash = s.indexOf("/");
		if (indexOfSlash == -1)
			return -1;
		String apiName = s.substring(0, indexOfSlash);
		if (apiName.equalsIgnoreCase("start")) {
			int ret = handleRunApi(s.substring(indexOfSlash + 1),ctx, req);
			return 0;
		} else if (apiName.equalsIgnoreCase("stop")) {
			int ret = handleStopApi(s.substring(indexOfSlash + 1),ctx, req);
			return 0;
		} else if (apiName.equalsIgnoreCase("migrate")) {
			int ret = handleMigApi(s.substring(indexOfSlash + 1), ctx, req);
		}
		return -1;
	}