stats.pingRequestsGWC2.bumpCount();
    public void doV2(HttpServletRequest request,                        HttpServletResponse response)                        throws ServletException, IOException {        PrintWriter out = response.getWriter();        Date now = new Date();        stats.bumpHour(now);        stats.bumpRequests();        try {            RemoteClient remoteParam = remoteFromParams(request);            stats.bumpByClient(remoteParam.getClientVersion());            if (remoteParam.getClientVersion().getClient().equals(ClientVersion.UNKNOWN) ||                remoteParam.getClientVersion().getVersion().equals(ClientVersion.UNKNOWN))                throw new WebCacheException("no anonymous clients allowed");            boolean didOne = false;            String net = request.getParameter("net");            if (net == null)                net = "gnutella";            if (request.getParameter("ping") != null) {                /*                 * Hack for bazooka: it insists on the net appended to                 * the pong response.                 */                if (remoteParam.getClientVersion().getClient().indexOf("Bazooka") != -1)                    out.println("I|pong|jumswebcache/" + getVersion() + "|" + net);                else                    out.println("I|pong|jumswebcache/" + getVersion());                didOne = true;            }            if (request.getParameter("update") != null) {                stats.bumpGWC2Updates();                String remoteIP = request.getRemoteAddr();                RemoteClient remote = new RemoteClient(remoteIP,0,                    remoteParam.getClientVersion());                if (remoteParam.getRemoteIP() != null) {                    stats.IPUpdateRequestsGWC2.bumpCount();                    if (!remoteIP.equals(remoteParam.getRemoteIP()))                        throw new WebCacheException("rejected IP");                    if (Data.getInstance().isRateLimited(remote)) {                        out.println("I|update|WARNING|update denied due to rate limit");                        return;                    }                    checkAddress(remoteParam.getRemoteIP());                    Data.getInstance().addHost(net, remoteParam);                    out.println("I|update|OK");                    didOne = true;                }                String url = request.getParameter("url");                if (url != null) {                    stats.URLUpdateRequestsGWC2.bumpCount();                    try {                        url = URLDecoder.decode(url, "ISO-8859-1");                    } catch (UnsupportedEncodingException ex) {                        throw new WebCacheException("bad encoding");                    }                    RemoteURL remoteURL = new RemoteURL(url, RemoteURL.PROTO_V2, remoteParam.getClientVersion());                    Data.getInstance().addURL(net, remoteURL);                    out.println("I|update|OK");                    didOne = true;                }            }            if (request.getParameter("get") != null) {            	stats.bumpGetRequests();                Iterator it = Data.getInstance().getHosts(net).iterator();                while (it.hasNext()) {                    RemoteClient host = (RemoteClient)it.next();                    Date d = host.getLastUpdated();                    long age = (now.getTime() - d.getTime())/1000;                    out.println("H|" + host.getRemoteIP() + ":" + host.getPort() + "|" + age);                    didOne = true;                }                it = Data.getInstance().getURLs(net, RemoteURL.PROTO_V2).iterator();                while (it.hasNext()) {                    RemoteURL url = (RemoteURL)it.next();                    Date d = url.getLastUpdated();                    long age = (now.getTime() - d.getTime())/1000;                    out.println("U|" + url.getRemoteURL() + "|" + age);                    didOne = true;                }            }            if (!didOne)                out.println("I");        } catch (WebCacheException ex) {            out.println("I|update|WARNING|" + ex.getMessage());            //log("doV2", ex);        }    }