Interface CacheContinuousQueryListener<K,​V>


  • public interface CacheContinuousQueryListener<K,​V>
    Continuous query listener.
    • Method Detail

      • onEntryUpdated

        void onEntryUpdated​(org.apache.ignite.internal.processors.cache.query.continuous.CacheContinuousQueryEvent<K,​V> evt,
                            boolean primary,
                            boolean recordIgniteEvt,
                            @Nullable
                            @Nullable GridDhtAtomicAbstractUpdateFuture fut)
        Entry update callback.
        Parameters:
        evt - Event
        primary - Primary flag.
        recordIgniteEvt - Whether to record event.
        fut - Dht atomic future.
      • onBeforeRegister

        void onBeforeRegister()
      • onAfterRegister

        void onAfterRegister()
      • onUnregister

        void onUnregister()
        Listener unregistered callback.
      • cleanupOnAck

        void cleanupOnAck​(Map<Integer,​Long> updateCntrs)
        Cleans backup queue.
        Parameters:
        updateCntrs - Update indexes map.
      • acknowledgeBackupOnTimeout

        void acknowledgeBackupOnTimeout​(GridKernalContext ctx)
        Parameters:
        ctx - Context.
      • skipUpdateEvent

        void skipUpdateEvent​(org.apache.ignite.internal.processors.cache.query.continuous.CacheContinuousQueryEvent<K,​V> evt,
                             AffinityTopologyVersion topVer,
                             boolean primary)
        Parameters:
        evt - Event
        topVer - Topology version.
        primary - Primary
      • skipUpdateCounter

        @Nullable
        @Nullable CounterSkipContext skipUpdateCounter​(GridCacheContext cctx,
                                                       @Nullable
                                                       @Nullable CounterSkipContext skipCtx,
                                                       int part,
                                                       long cntr,
                                                       AffinityTopologyVersion topVer,
                                                       boolean primary)
        For cache updates in shared cache group need notify others caches CQ listeners that generated counter should be skipped.
        Parameters:
        cctx - Cache context.
        skipCtx - Context.
        part - Partition.
        cntr - Counter to skip.
        topVer - Topology version.
        Returns:
        Context.
      • onPartitionEvicted

        void onPartitionEvicted​(int part)
        Parameters:
        part - Partition.
      • oldValueRequired

        boolean oldValueRequired()
        Returns:
        Whether old value is required.
      • keepBinary

        boolean keepBinary()
        Returns:
        Keep binary flag.
      • notifyExisting

        boolean notifyExisting()
        Returns:
        Whether to notify on existing entries.
      • isPrimaryOnly

        boolean isPrimaryOnly()
        Returns:
        True if this listener should be called on events on primary partitions only.