Issue #1741 - Java 9 javadoc failure in build.

Workaround for a Javadoc tool bug in JDK 9.
This commit is contained in:
Simone Bordet 2017-08-15 19:43:57 +02:00
parent 0e2852a5ac
commit 7e5bfedd4e
1 changed files with 19 additions and 10 deletions

View File

@ -139,16 +139,7 @@ public class AsyncMiddleManServlet extends AbstractProxyServlet
protected DeferredContentProvider newProxyContentProvider(final HttpServletRequest clientRequest, HttpServletResponse proxyResponse, Request proxyRequest) throws IOException
{
return new DeferredContentProvider()
{
@Override
public boolean offer(ByteBuffer buffer, Callback callback)
{
if (_log.isDebugEnabled())
_log.debug("{} proxying content to upstream: {} bytes", getRequestId(clientRequest), buffer.remaining());
return super.offer(buffer, callback);
}
};
return new ProxyDeferredContentProvider(clientRequest);
}
protected ReadListener newProxyReadListener(HttpServletRequest clientRequest, HttpServletResponse proxyResponse, Request proxyRequest, DeferredContentProvider provider)
@ -823,4 +814,22 @@ public class AsyncMiddleManServlet extends AbstractProxyServlet
return ByteBuffer.wrap(gzipBytes);
}
}
private class ProxyDeferredContentProvider extends DeferredContentProvider
{
private final HttpServletRequest clientRequest;
public ProxyDeferredContentProvider(HttpServletRequest clientRequest)
{
this.clientRequest = clientRequest;
}
@Override
public boolean offer(ByteBuffer buffer, Callback callback)
{
if (_log.isDebugEnabled())
_log.debug("{} proxying content to upstream: {} bytes", getRequestId(clientRequest), buffer.remaining());
return super.offer(buffer, callback);
}
}
}