Class ApiDecisionLoader

java.lang.Object
io.gorules.zen.loader.ApiDecisionLoader
All Implemented Interfaces:
DecisionLoader

public class ApiDecisionLoader extends Object implements DecisionLoader
Decision loader that fetches decisions from an HTTP API. Supports flexible header configuration, caching, and automatic retries.
  • Constructor Details

    • ApiDecisionLoader

      public ApiDecisionLoader(ApiLoaderConfig config)
      Create a new ApiDecisionLoader with the given configuration.
      Parameters:
      config - API loader configuration
  • Method Details

    • load

      public CompletableFuture<io.gorules.zen_engine.JsonBuffer> load(String key)
      Description copied from interface: DecisionLoader
      Load a decision by its key.
      Specified by:
      load in interface DecisionLoader
      Parameters:
      key - Decision key/filename
      Returns:
      CompletableFuture with decision content as JsonBuffer