@InterfaceAudience.LimitedPrivate @InterfaceStability.Evolving public interface ProxyExtension extends AutoCloseable
| Modifier and Type | Method and Description |
|---|---|
boolean |
accept(String extension)
Verify if the extension can handle the given extension name.
|
void |
close() |
String |
extensionName()
Returns the unique extension name.
|
void |
initialize(ProxyConfiguration conf)
Initialize the extension when the extension is constructed from reflection.
|
Map<InetSocketAddress,io.netty.channel.ChannelInitializer<io.netty.channel.socket.SocketChannel>> |
newChannelInitializers()
Create the list of channel initializers for the ports that this extension
will listen on.
|
void |
start(ProxyService service)
Start the extension with the provided proxy service.
|
String extensionName()
boolean accept(String extension)
extension - the extension to verifyvoid initialize(ProxyConfiguration conf) throws Exception
The initialize should initialize all the resources required for serving the extension
but don't start those resources until start(ProxyService) is called.
conf - proxy service configurationException - when fail to initialize the extension.void start(ProxyService service)
The proxy service provides the accesses to the Pulsar Proxy components.
service - the broker service to start with.Map<InetSocketAddress,io.netty.channel.ChannelInitializer<io.netty.channel.socket.SocketChannel>> newChannelInitializers()
NOTE: this method is called after start(ProxyService).
void close()
close in interface AutoCloseableCopyright © 2017–2022 Apache Software Foundation. All rights reserved.