Class MonitoringStreamsInterceptorConfig

    • Field Detail

      • MONITORING_STREAMS_INTERCEPTOR_ENABLE_CONFIG

        public static String MONITORING_STREAMS_INTERCEPTOR_ENABLE_CONFIG
        monitoring.streams.interceptor.enable
      • MONITORING_INTERCEPTOR_PRODUCER_PREFIX

        public static final String MONITORING_INTERCEPTOR_PRODUCER_PREFIX
        Prefix used to isolate producer configs from other client configs. It is recommended to use producerPrefix(String) to add this prefix to producer properties.
        See Also:
        Constant Field Values
      • MONITORING_INTERCEPTOR_INTERVAL_MS_CONFIG

        public static final String MONITORING_INTERCEPTOR_INTERVAL_MS_CONFIG
        monitoring.streams.interceptor.interval.ms
        See Also:
        Constant Field Values
      • MONITORING_INTERCEPTOR_INTERVAL_MS_DEFAULT

        public static final long MONITORING_INTERCEPTOR_INTERVAL_MS_DEFAULT
        See Also:
        Constant Field Values
      • MONITORING_INTERCEPTOR_TOPIC_CONFIG

        public static final String MONITORING_INTERCEPTOR_TOPIC_CONFIG
        monitoring.streams.interceptor.topic
        See Also:
        Constant Field Values
      • MONITORING_INTERCEPTOR_TOPIC_DEFAULT

        public static final String MONITORING_INTERCEPTOR_TOPIC_DEFAULT
        See Also:
        Constant Field Values
      • MONITORING_INTERCEPTOR_ADVERTISED_SERVER_CONFIG

        public static final String MONITORING_INTERCEPTOR_ADVERTISED_SERVER_CONFIG
        monitoring.streams.interceptor.advertised.server
        See Also:
        Constant Field Values
      • MONITORING_INTERCEPTOR_EXTENSIONS_CONFIG

        public static final String MONITORING_INTERCEPTOR_EXTENSIONS_CONFIG
        monitoring.streams.interceptor.ce.extensions
        See Also:
        Constant Field Values
    • Constructor Detail

    • Method Detail

      • producerPrefix

        public static String producerPrefix​(String producerProp)
        Prefix a property with MONITORING_INTERCEPTOR_PRODUCER_PREFIX. This is used to isolate producer configs.
        Parameters:
        producerProp - the producer property to be masked
        Returns:
        WATCHER_PRODUCER_PREFIX + producerProp
      • getIntervalMs

        public long getIntervalMs()
        Get the period the interceptor should use to send a streams state event (Default is 10 seconds).
        Returns:
        the period in milliseconds.
      • getAdvertisedServer

        public Optional<String> getAdvertisedServer()
        Get the server name that will be included in monitoring events. If not specified, the streams application.server property is used."
        Returns:
        an optional advertised server name.
      • getTopic

        public String getTopic()
        Get the topic on which monitoring event will be sent (Default is _azkarra-streams-monitoring).
        Returns:
        the name of the topic.
      • getProducerConfigs

        public Map<String,​Object> getProducerConfigs​(String clientId)
        Get the configs for the producer. Properties using the prefix MONITORING_INTERCEPTOR_PRODUCER_PREFIX will be used in favor over their non-prefixed versions .
        Parameters:
        clientId - clientId
        Returns:
        Map of the producer configuration.