@Override
        public void run() {
            try {
                System.out.println(id + " - about to get something from " + httpget.getUri());
                this.httpClient.execute(httpget, response -> {
                    System.out.println(id + " - get executed");
                    // get the response body as an array of bytes
                    final HttpEntity entity = response.getEntity();
                    if (entity != null) {
                        final byte[] bytes = EntityUtils.toByteArray(entity);
                        System.out.println(id + " - " + bytes.length + " bytes read");
                    }
                    return null;
                });
            } catch (final Exception e) {
                System.out.println(id + " - error: " + e);
            }
        }
Executes the GetMethod and prints some status information.
httpclient5/src/test/java/org/apache/hc/client5/http/examples/ClientMultiThreadedExecution.java