Class StagingRepositoryClient.StagingContext

java.lang.Object
step.client.AbstractRemoteClient
step.client.repository.StagingRepositoryClient.StagingContext
All Implemented Interfaces:
Closeable, AutoCloseable
Enclosing class:
StagingRepositoryClient

public static class StagingRepositoryClient.StagingContext extends AbstractRemoteClient
  • Field Details

    • contextId

      protected String contextId
  • Constructor Details

  • Method Details

    • uploadFile

      public String uploadFile(File file)
      Uploads the local file provided as argument to the StagingRepositoryClient.StagingContext
      Parameters:
      file - the local file to be uploaded
      Returns:
      the handle to the uploaded file
    • upload

      public String upload(InputStream stream, String resourceName)
      Uploads the resource provided as stream to the StagingRepositoryClient.StagingContext
      Parameters:
      stream - the stream of the resource to be uploaded
      resourceName - the name of the resource
      Returns:
      the handle to the uploaded resource
    • uploadPlan

      public void uploadPlan(Plan plan)
      Parameters:
      plan -
    • run

      public PlanRunnerResult run()
      Runs the uploaded plan in an isolated mode. The plan will only be able to access the artefacts uploaded to this context
      Returns:
      the PlanRunnerResult of the execution
    • run

      public PlanRunnerResult run(Map<String,String> executionParameters)
      Runs the uploaded plan in an isolated mode using the provided parameters. The plan will only be able to access the artefacts uploaded to this context
      Parameters:
      executionParameters - a list of key-value parameters. these parameters correspond to the parameters that can be selected in UI when starting an execution
      Returns:
    • close

      public void close()
      Specified by:
      close in interface AutoCloseable
      Specified by:
      close in interface Closeable
      Overrides:
      close in class AbstractRemoteClient