final AsyncSchemeRegistry reg = new AsyncSchemeRegistry();
reg.register(new AsyncScheme("http", 80, null));
if ("https".equals(url.getScheme())) {
try {
final SSLContext sslcontext = getSSLContext();
reg.register(new AsyncScheme("https", 443, new SSLLayeringStrategy(sslcontext) {
@Override
protected void initializeEngine(SSLEngine engine) {
initializeSSLEngine(sslcontext, engine);
}
@Override