Interface IntentSynchronizationService

  • All Known Implementing Classes:
    IntentSynchronizer

    public interface IntentSynchronizationService
    Submits and withdraws intents to the IntentService from a single point in the cluster at any one time. The provided intents will be synchronized with the IntentService on leadership change.

    This is a sample utility and not part of the core ONOS API. This means it is subject to change or to be removed. It is recommended to consider using one of the built-in ONOS distributed primitives such as the WorkQueue instead of using this.

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void removeIntentsByAppId​(org.onosproject.core.ApplicationId applicationId)
      Withdraws intents by app Id.
      void submit​(org.onosproject.net.intent.Intent intent)
      Submits and intent to the synchronizer.
      void withdraw​(org.onosproject.net.intent.Intent intent)
      Withdraws an intent from the synchronizer.
    • Method Detail

      • submit

        void submit​(org.onosproject.net.intent.Intent intent)
        Submits and intent to the synchronizer.

        The intent will be submitted directly to the IntentService if this node is the leader, otherwise it will be stored in the synchronizer for synchronization if this node becomes the leader.

        Parameters:
        intent - intent to submit
      • withdraw

        void withdraw​(org.onosproject.net.intent.Intent intent)
        Withdraws an intent from the synchronizer.

        The intent will be withdrawn directly from the IntentService if this node is the leader. The intent will be removed from the synchronizer's in-memory storage.

        Parameters:
        intent - intent to withdraw
      • removeIntentsByAppId

        void removeIntentsByAppId​(org.onosproject.core.ApplicationId applicationId)
        Withdraws intents by app Id.
        Parameters:
        applicationId - the Id of the application that created the intents to be removed