Class SnsHttpDelegate

    • Constructor Detail

      • SnsHttpDelegate

        public SnsHttpDelegate​(com.amazonaws.services.sns.AmazonSNSClient client,
                               PushNotificationServiceConfig config,
                               SnsPushMessageConverter pushMessageConverter,
                               String realm,
                               MessageDispatcher messageDispatcher)
        Generates a new SNS HTTP Delegate, used to communicate over the Internet with the SNS service.
        Parameters:
        client - AmazonSnsClient - used to put messages on the wire.
        config - Necessary to configure this delegate.
        pushMessageConverter - a message converter, to ensure the message sent is of the correct format.
        realm - the realm in which this delegate exists.
        messageDispatcher - the MessageDispatcher used to redirect incoming messages to their caller.
    • Method Detail

      • isRequireNewDelegate

        public boolean isRequireNewDelegate​(PushNotificationServiceConfig newConfig)
        Description copied from interface: PushNotificationDelegate
        Returns whether or not the new config is so different from the old that the existing delegate should be removed from the pool.
        Specified by:
        isRequireNewDelegate in interface PushNotificationDelegate
        Parameters:
        newConfig - The new configuration to check against the old.
        Returns:
        True if the configuration change requires the PushNotificationService to instantiate a new instance of this delegate.
      • updateDelegate

        public void updateDelegate​(PushNotificationServiceConfig newConfig)
        Description copied from interface: PushNotificationDelegate
        Updates the existing delegate's config. Implementors must not alter the connection parameters of the delegate, but may alter extraneous information such as values added to static fields in the delegate's communicated messages.
        Specified by:
        updateDelegate in interface PushNotificationDelegate
        Parameters:
        newConfig - The new config from which to update the existing delegate.
      • getAuthServiceLocation

        public String getAuthServiceLocation()
        Description copied from interface: PushNotificationDelegate
        Returns the (public, relative) authentication service location of this delegate - if appropriate. Otherwise returns null.
        Specified by:
        getAuthServiceLocation in interface PushNotificationDelegate
        Returns:
        The (public, relative) service location of this delegate as exposed to the world, may be relative to the OpenAM server instance ID WebtopNaming.
      • getRegServiceLocation

        public String getRegServiceLocation()
        Description copied from interface: PushNotificationDelegate
        Returns the (public, relative) registration service location of this delegate - if appropriate. Otherwise returns null.
        Specified by:
        getRegServiceLocation in interface PushNotificationDelegate
        Returns:
        The (public, relative) service location of this delegate as exposed to the world, may be relative to the OpenAM server instance ID WebtopNaming.