Class ApiProcessingContext<O>

java.lang.Object
com.scaleoutsoftware.modules.abstractions.ApiProcessingContext<O>
Type Parameters:
O - the SOSS object type.

public abstract class ApiProcessingContext<O> extends Object
The api processing context provides access to contextual information during invocation processing.
  • Constructor Details

    • ApiProcessingContext

      public ApiProcessingContext()
      Instantiate a new ApiProcessingContext.
  • Method Details

    • getModuleName

      public abstract String getModuleName()
      Retrieve the module name of the SOSS object.
      Returns:
      the module name.
    • getObjectId

      public abstract String getObjectId()
      Retrieve the unique object ID of the SOSS object.
      Returns:
      the unique object ID.
    • sendUiAlert

      public abstract CompletableFuture<Void> sendUiAlert(AlertSeverity severity, String message)
      Send an alert to the UI.
      Parameters:
      severity - the AlertSeverity.
      message - the message to display.
      Returns:
      a CompletableFuture that will complete either due to success (no exception) or an exception occurred. An exception may occur if the UI is unavailable.
    • getGridConnection

      public abstract com.scaleout.client.GridConnection getGridConnection()
      Retrieve the underlying GridConnection used to access the ScaleOut StateServer store.
      Returns:
      the underlying GridConnection.
    • getCache

      public abstract com.scaleout.client.caching.Cache<String,O> getCache()
      Retrieve the underlying Cache that stores objects for the associated module.
      Returns:
      the underlying Cache.