@Override
	public void channelRead(ChannelHandlerContext context, Object message)
			throws Exception {
		if (message instanceof HttpRequest
				&& ((HttpRequest) message).getUri().toLowerCase()
						.startsWith("/redirect?")) {
			HttpRequest request = (HttpRequest) message;

			QueryStringDecoder decoder = new QueryStringDecoder(
					request.getUri());
			Map<String, List<String>> requestParameters = decoder.parameters();
			String destinationUrl = "";
			if (requestParameters != null
					&& requestParameters.containsKey(uri)) {
				if (requestParameters.get(uri) != null
						&& !requestParameters.get(uri).isEmpty()) {
					destinationUrl = requestParameters.get(uri).get(0);
					if (!destinationUrl.startsWith("http:")
							&& !destinationUrl.startsWith("https:")) {
						destinationUrl = "//".concat(destinationUrl);
					}
					ServerReport.incrementRedirectQuantity(destinationUrl);
				}
			}
			FullHttpResponse response = new DefaultFullHttpResponse(HTTP_1_1,
					FOUND);
			response.headers().set(LOCATION, destinationUrl);
			context.writeAndFlush(response).addListener(
					ChannelFutureListener.CLOSE);
		} else {
			context.fireChannelRead(message);
		}
	}