Class ServiceAnnouncingChatHandlerProvider

    • Constructor Detail

      • ServiceAnnouncingChatHandlerProvider

        @Inject
        public ServiceAnnouncingChatHandlerProvider​(DruidNode node,
                                                    ServiceAnnouncer serviceAnnouncer)
    • Method Detail

      • register

        public void register​(String service,
                             ChatHandler handler)
        Description copied from interface: ChatHandlerProvider
        Registers a chat handler which provides an API for others to talk to objects in the indexing service. Depending on the implementation, this method may also announce this node so that it can be discovered by other services.
        Specified by:
        register in interface ChatHandlerProvider
        Parameters:
        service - a unique name identifying this service
        handler - instance which implements the API to be exposed
      • register

        public void register​(String service,
                             ChatHandler handler,
                             boolean announce)
        Description copied from interface: ChatHandlerProvider
        Registers a chat handler which provides an API for others to talk to objects in the indexing service. Setting announce to false instructs the implementation to only register the handler to expose the API and skip any discovery announcements that might have been broadcast.
        Specified by:
        register in interface ChatHandlerProvider
        Parameters:
        service - a unique name identifying this service
        handler - instance which implements the API to be exposed
        announce - for implementations that have a service discovery mechanism, whether this node should be announced