Package com.lucimber.dbus.netty
Class DBusHandlerConfiguration
java.lang.Object
com.lucimber.dbus.netty.DBusHandlerConfiguration
Centralized configuration for D-Bus pipeline handlers. This class maintains the definitive order
and creation logic for all handlers, ensuring perfect synchronization between initial setup and
reconnection scenarios.
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
findFirstDbusHandler
(io.netty.channel.ChannelPipeline pipeline) Finds the first existing D-Bus handler in the pipeline to use as an insertion point.static String[]
Gets the ordered list of all handler names in the pipeline.Gets the ordered list of SASL handler names that need to be re-added during reconnection.static void
initializePipeline
(io.netty.channel.ChannelPipeline pipeline, io.netty.util.concurrent.Promise<Void> connectPromise, RealityCheckpoint appLogicHandler) Initializes the complete pipeline in the correct order.
-
Method Details
-
initializePipeline
public static void initializePipeline(io.netty.channel.ChannelPipeline pipeline, io.netty.util.concurrent.Promise<Void> connectPromise, RealityCheckpoint appLogicHandler) Initializes the complete pipeline in the correct order.- Parameters:
pipeline
- the channel pipeline to configureconnectPromise
- the promise to complete when connection is establishedappLogicHandler
- the application logic handler
-
getSaslHandlers
Gets the ordered list of SASL handler names that need to be re-added during reconnection.- Returns:
- ordered map of SASL handler names to their creation suppliers
-
getHandlerOrder
Gets the ordered list of all handler names in the pipeline.- Returns:
- ordered list of handler names
-
findFirstDbusHandler
Finds the first existing D-Bus handler in the pipeline to use as an insertion point.- Parameters:
pipeline
- the channel pipeline to search- Returns:
- the name of the first D-Bus handler found, or null if none found
-