public static void addRumHit(HttpServletRequest httpRequest, Counter httpCounter) {
		final String requestName = httpRequest.getParameter("requestName");
		if (requestName == null) {
			return;
		}
		try {
			final long serverTime = Long.parseLong(httpRequest.getParameter("serverTime"));
			final long timeToFirstByte = Long
					.parseLong(httpRequest.getParameter("timeToFirstByte"));
			final long domProcessing = Long.parseLong(httpRequest.getParameter("domProcessing"));
			final long pageRendering = Long.parseLong(httpRequest.getParameter("pageRendering"));
			final long networkTime = Math.max(timeToFirstByte - serverTime, 0);
			httpCounter.addRumHit(requestName, networkTime, domProcessing, pageRendering);
		} catch (final NumberFormatException e) {
			return;
		}

	}
@Test
	public void testAddRumHit() {
		final Counter httpCounter = new Counter(Counter.HTTP_COUNTER_NAME, "dbweb.png");
		// test null requestName
		addRumHit(httpCounter, null, null, null, null, null);

		final String requestName = "test";
		// test non-parseable values
		addRumHit(httpCounter, requestName, null, null, null, null);
		addRumHit(httpCounter, requestName, "a", "b", "c", "d");

		// test valid values without existing request
		addRumHit(httpCounter, requestName, "100", "200", "300", "400");

		// test with existing request and creating rumData
		httpCounter.addRequest(requestName, 100, 10, 10, false, 1);
		addRumHit(httpCounter, requestName, "100", "200", "300", "400");

		// test with existing request and rumData
		addRumHit(httpCounter, requestName, "100", "200", "300", "400");

		// test aberrant values
		addRumHit(httpCounter, requestName, "-100", "200", "300", "400");
		addRumHit(httpCounter, requestName, "300001", "200", "300", "400");
		addRumHit(httpCounter, requestName, "100", "-200", "300", "400");
		addRumHit(httpCounter, requestName, "100", "300101", "300", "400");
		addRumHit(httpCounter, requestName, "100", "200", "-300", "400");
		addRumHit(httpCounter, requestName, "100", "200", "300001", "400");
		addRumHit(httpCounter, requestName, "100", "200", "300", "-400");
		addRumHit(httpCounter, requestName, "100", "200", "300", "300001");
	}