public class ElasticsearchHttpClient extends Object
| Constructor and Description |
|---|
ElasticsearchHttpClient()
The default constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close() |
protected void |
copyRequestHeaders(javax.servlet.http.HttpServletRequest request,
org.apache.http.HttpRequest proxyRequest,
String uri)
Copy request headers from the servlet client to the proxy request.
|
org.apache.http.HttpResponse |
process(javax.servlet.http.HttpServletRequest request)
This method processes the supplied HTTP request.
|
protected String |
rewriteUrlFromRequest(javax.servlet.http.HttpServletRequest request)
Reads the request URI from
servletRequest and rewrites it, considering #targetUri. |
public ElasticsearchHttpClient()
public org.apache.http.HttpResponse process(javax.servlet.http.HttpServletRequest request)
throws Exception
request - The requestException - Failed to process the requestpublic void close()
protected void copyRequestHeaders(javax.servlet.http.HttpServletRequest request,
org.apache.http.HttpRequest proxyRequest,
String uri)
throws Exception
request - The client requestproxyRequest - The request being sent to the target serviceuri - The target service URIException - Failed to copy headersprotected String rewriteUrlFromRequest(javax.servlet.http.HttpServletRequest request)
servletRequest and rewrites it, considering #targetUri. It's used to make the new request.Copyright © 2015 Red Hat, Inc.. All rights reserved.