Class Http2Ext
java.lang.Object
org.apache.pekko.http.impl.engine.http2.Http2Ext
- All Implemented Interfaces:
org.apache.pekko.actor.Extension
INTERNAL API
Internal entry points for Http/2 server
Opentelemetry Java Instrumentation relies on this class so avoid changing it. Besides
Http2Ext.bindAndHandleAsync the agent also reads the system member to obtain a dispatcher for
the response future, so keep that accessor around too.
See https://github.com/apache/pekko-http/issues/1241
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionscala.concurrent.Future<Http.ServerBinding>bindAndHandleAsync(scala.Function1<HttpRequest, scala.concurrent.Future<HttpResponse>> handler, String interface_, int port, ConnectionContext connectionContext, ServerSettings settings, org.apache.pekko.event.LoggingAdapter log, org.apache.pekko.stream.Materializer fm) Opentelemetry Java Instrumentation relies on this method so avoid changing it.http()org.apache.pekko.stream.scaladsl.Flow<org.apache.pekko.util.ByteString,org.apache.pekko.util.ByteString, scala.concurrent.Future<ServerTerminator>> httpsWithAlpn(HttpsConnectionContext httpsContext, org.apache.pekko.stream.scaladsl.Flow<org.apache.pekko.stream.TLSProtocol.SslTlsInbound, org.apache.pekko.stream.TLSProtocol.SslTlsOutbound, ServerTerminator> http1, org.apache.pekko.stream.scaladsl.Flow<org.apache.pekko.stream.TLSProtocol.SslTlsInbound, org.apache.pekko.stream.TLSProtocol.SslTlsOutbound, ServerTerminator> http2) org.apache.pekko.stream.scaladsl.Flow<HttpRequest,HttpResponse, scala.concurrent.Future<Http.OutgoingConnection>> outgoingConnection(String host, int port, HttpsConnectionContext connectionContext, ClientConnectionSettings clientConnectionSettings, org.apache.pekko.event.LoggingAdapter log) org.apache.pekko.stream.scaladsl.Flow<HttpRequest,HttpResponse, scala.concurrent.Future<Http.OutgoingConnection>> outgoingConnectionPriorKnowledge(String host, int port, ClientConnectionSettings clientConnectionSettings, org.apache.pekko.event.LoggingAdapter log) org.apache.pekko.actor.ActorSystemsystem()
-
Constructor Details
-
Http2Ext
public Http2Ext(org.apache.pekko.actor.ActorSystem system)
-
-
Method Details
-
ConnectionUpgradeHeader
-
UpgradeHeader
-
bindAndHandleAsync
public scala.concurrent.Future<Http.ServerBinding> bindAndHandleAsync(scala.Function1<HttpRequest, scala.concurrent.Future<HttpResponse>> handler, String interface_, int port, ConnectionContext connectionContext, ServerSettings settings, org.apache.pekko.event.LoggingAdapter log, org.apache.pekko.stream.Materializer fm) Opentelemetry Java Instrumentation relies on this method so avoid changing it. HTTP/2 bindings do not go through
HttpExt, so this is the only server entry point the agent can hook for HTTP/2. See https://github.com/apache/pekko-http/issues/1241- Parameters:
handler- (undocumented)interface_- (undocumented)port- (undocumented)connectionContext- (undocumented)settings- (undocumented)log- (undocumented)fm- (undocumented)- Returns:
- (undocumented)
-
http
-
httpsWithAlpn
public org.apache.pekko.stream.scaladsl.Flow<org.apache.pekko.util.ByteString,org.apache.pekko.util.ByteString, httpsWithAlpnscala.concurrent.Future<ServerTerminator>> (HttpsConnectionContext httpsContext, org.apache.pekko.stream.scaladsl.Flow<org.apache.pekko.stream.TLSProtocol.SslTlsInbound, org.apache.pekko.stream.TLSProtocol.SslTlsOutbound, ServerTerminator> http1, org.apache.pekko.stream.scaladsl.Flow<org.apache.pekko.stream.TLSProtocol.SslTlsInbound, org.apache.pekko.stream.TLSProtocol.SslTlsOutbound, ServerTerminator> http2) -
outgoingConnection
public org.apache.pekko.stream.scaladsl.Flow<HttpRequest,HttpResponse, outgoingConnectionscala.concurrent.Future<Http.OutgoingConnection>> (String host, int port, HttpsConnectionContext connectionContext, ClientConnectionSettings clientConnectionSettings, org.apache.pekko.event.LoggingAdapter log) -
outgoingConnectionPriorKnowledge
public org.apache.pekko.stream.scaladsl.Flow<HttpRequest,HttpResponse, outgoingConnectionPriorKnowledgescala.concurrent.Future<Http.OutgoingConnection>> (String host, int port, ClientConnectionSettings clientConnectionSettings, org.apache.pekko.event.LoggingAdapter log) -
system
public org.apache.pekko.actor.ActorSystem system() -
telemetry
-