Issue #5044 - implement is secure on DelegatedJettyClientUpgradeRequest

Signed-off-by: Lachlan Roberts <lachlan@webtide.com>
This commit is contained in:
Lachlan Roberts 2020-07-29 22:22:14 +10:00
parent 47d0c35b0b
commit 5ff0ce4142
1 changed files with 3 additions and 3 deletions

View File

@ -27,6 +27,7 @@ import java.util.List;
import java.util.Map; import java.util.Map;
import java.util.stream.Collectors; import java.util.stream.Collectors;
import org.eclipse.jetty.client.HttpClient;
import org.eclipse.jetty.http.HttpField; import org.eclipse.jetty.http.HttpField;
import org.eclipse.jetty.http.HttpHeader; import org.eclipse.jetty.http.HttpHeader;
import org.eclipse.jetty.io.EndPoint; import org.eclipse.jetty.io.EndPoint;
@ -163,8 +164,7 @@ public class DelegatedJettyClientUpgradeRequest implements UpgradeRequest
@Override @Override
public boolean isSecure() public boolean isSecure()
{ {
// TODO: figure out how to obtain from HttpClient's HttpRequest return HttpClient.isSchemeSecure(delegate.getScheme());
return false;
} }
@Override @Override
@ -204,7 +204,7 @@ public class DelegatedJettyClientUpgradeRequest implements UpgradeRequest
if (rawExtensions == null || rawExtensions.isEmpty()) if (rawExtensions == null || rawExtensions.isEmpty())
return Collections.emptyList(); return Collections.emptyList();
return rawExtensions.stream().map((parameterizedName) -> ExtensionConfig.parse(parameterizedName)).collect(Collectors.toList()); return rawExtensions.stream().map(ExtensionConfig::parse).collect(Collectors.toList());
} }
@Override @Override