Class CsiAdaptorFactory

java.lang.Object
org.apache.hadoop.yarn.csi.adaptor.CsiAdaptorFactory

public final class CsiAdaptorFactory extends Object
Desired csi-adaptor implementation is configurable, default to CsiAdaptorProtocolService. If user wants to have a different implementation, just to configure a different class for the csi-driver.
  • Method Details

    • getAdaptor

      public static org.apache.hadoop.yarn.api.CsiAdaptorPlugin getAdaptor(String driverName, org.apache.hadoop.conf.Configuration conf) throws org.apache.hadoop.yarn.exceptions.YarnException
      Load csi-driver-adaptor from configuration. If the configuration is not specified, the default implementation for the adaptor is DefaultCsiAdaptorImpl. If the configured class is not a valid variation of CsiAdaptorPlugin or the class cannot be found, this function will throw a RuntimeException.
      Parameters:
      driverName -
      conf -
      Returns:
      CsiAdaptorPlugin
      Throws:
      org.apache.hadoop.yarn.exceptions.YarnException - if unable to create the adaptor class.
      RuntimeException - if given class is not found or not an instance of CsiAdaptorPlugin