接口 FunctionAuthProvider

所有已知子接口:
KubernetesFunctionAuthProvider
所有已知实现类:
ClearTextFunctionTokenAuthProvider, KubernetesSecretsTokenAuthProvider, KubernetesServiceAccountTokenAuthProvider

public interface FunctionAuthProvider
This is a generic interface that functions can use to cache and distribute appropriate authentication data that is needed to configure the runtime of functions to support appropriate authentication of function instances.
  • 方法详细资料

    • configureAuthenticationConfig

      void configureAuthenticationConfig(AuthenticationConfig authConfig, Optional<FunctionAuthData> functionAuthData)
      Set authentication configs for function instance based on the data in FunctionAuthenticationSpec.
      参数:
      authConfig - authentication configs passed to the function instance
      functionAuthData - function authentication data that is provider specific
    • cacheAuthData

      Optional<FunctionAuthData> cacheAuthData(org.apache.pulsar.functions.proto.Function.FunctionDetails funcDetails, AuthenticationDataSource authenticationDataSource) throws Exception
      Cache auth data in as part of function metadata for function that runtime may need to configure authentication.
      参数:
      funcDetails - the function details
      authenticationDataSource - auth data
      返回:
      抛出:
      Exception
    • updateAuthData

      Optional<FunctionAuthData> updateAuthData(org.apache.pulsar.functions.proto.Function.FunctionDetails funcDetails, Optional<FunctionAuthData> existingFunctionAuthData, AuthenticationDataSource authenticationDataSource) throws Exception
      抛出:
      Exception
    • cleanUpAuthData

      void cleanUpAuthData(org.apache.pulsar.functions.proto.Function.FunctionDetails funcDetails, Optional<FunctionAuthData> functionAuthData) throws Exception
      Clean up operation for auth when function is terminated.
      参数:
      funcDetails - the function details
      functionAuthData - function auth data
      抛出:
      Exception
    • getAuthProvider

      static FunctionAuthProvider getAuthProvider(String className)