Class PersistenceInit$


  • public class PersistenceInit$
    extends java.lang.Object
    Test utility to initialize persistence plugins. Useful when initialization order or coordination is needed. For example to avoid creating tables concurrently.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static PersistenceInit$ MODULE$
      Static reference to the singleton instance of this Scala object.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.util.concurrent.CompletionStage<Done> initializeDefaultPlugins​(ClassicActorSystemProvider system, java.time.Duration timeout)
      Initialize the default journal and snapshot plugins.
      java.util.concurrent.CompletionStage<Done> initializePlugins​(ClassicActorSystemProvider system, java.lang.String journalPluginId, java.lang.String snapshotPluginId, java.time.Duration timeout)
      Initialize the given journal and snapshot plugins.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • MODULE$

        public static final PersistenceInit$ MODULE$
        Static reference to the singleton instance of this Scala object.
    • Constructor Detail

      • PersistenceInit$

        public PersistenceInit$()
    • Method Detail

      • initializeDefaultPlugins

        public java.util.concurrent.CompletionStage<Done> initializeDefaultPlugins​(ClassicActorSystemProvider system,
                                                                                   java.time.Duration timeout)
        Initialize the default journal and snapshot plugins.

        Returns:
        a CompletionStage that is completed when the initialization has completed
      • initializePlugins

        public java.util.concurrent.CompletionStage<Done> initializePlugins​(ClassicActorSystemProvider system,
                                                                            java.lang.String journalPluginId,
                                                                            java.lang.String snapshotPluginId,
                                                                            java.time.Duration timeout)
        Initialize the given journal and snapshot plugins.

        The snapshotPluginId can be empty ("") if snapshot plugin isn't used.

        Returns:
        a CompletionStage that is completed when the initialization has completed