Package io.grpc.alts

Class AltsContext

java.lang.Object
io.grpc.alts.AltsContext

@ExperimentalApi("https://github.com/grpc/grpc-java/issues/7864") public final class AltsContext extends Object
AltsContext contains security-related information on the ALTS channel.
  • Field Details

  • Constructor Details

  • Method Details

    • createTestInstance

      public static AltsContext createTestInstance(String peerServiceAccount, String localServiceAccount)
      Creates an AltsContext for testing purposes.
      Parameters:
      peerServiceAccount - the peer service account of the to be created AltsContext
      localServiceAccount - the local service account of the to be created AltsContext
      Returns:
      the created AltsContext
    • getSecurityLevel

      public AltsContext.SecurityLevel getSecurityLevel()
      Get security level.
      Returns:
      the context's security level.
    • getPeerServiceAccount

      public String getPeerServiceAccount()
      Get peer service account.
      Returns:
      the context's peer service account.
    • getLocalServiceAccount

      public String getLocalServiceAccount()
      Get local service account.
      Returns:
      the context's local service account.