jodd-http/src/main/java/jodd/http/HttpRequest.java
public HttpResponse send() {
		if (!followRedirects) {
			return _send();
		}

		int redirects = this.maxRedirects;

		while (redirects > 0) {
			redirects--;

			final HttpResponse httpResponse = _send();

			final int statusCode = httpResponse.statusCode();

			if (HttpStatus.isRedirect(statusCode)) {
				_reset();
				set(httpResponse.location());
				continue;
			}

			return httpResponse;
		}

		throw new HttpException("Max number of redirects exceeded: " + this.maxRedirects);
	}
public HttpResponse send() {
		if (!followRedirects) {
			return _send();
		}

		int redirects = this.maxRedirects;

		while (redirects > 0) {
			redirects--;

			final HttpResponse httpResponse = _send();

			final int statusCode = httpResponse.statusCode();

			if (HttpStatus.isRedirect(statusCode)) {
				_reset();
				set(httpResponse.location());
				continue;
			}

			return httpResponse;
		}

		throw new HttpException("Max number of redirects exceeded: " + this.maxRedirects);
	}
{@link #open() Opens connection} if not already open, sends request,
reads response and closes the request. If keep-alive mode is enabled
connection will not be closed.