Package io.helidon.grpc.core
Class GrpcSslDescriptor
- java.lang.Object
-
- io.helidon.grpc.core.GrpcSslDescriptor
-
public class GrpcSslDescriptor extends Object
GrpcSslDescriptor contains details about configuring TLS of aChannel.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classGrpcSslDescriptor.BuilderBuilder to build a new instance ofGrpcSslDescriptor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static GrpcSslDescriptor.Builderbuilder()Return a new instance ofGrpcSslDescriptor.Builder.static GrpcSslDescriptor.Builderbuilder(Config config)Return an instance of builder based on the specified external config.static GrpcSslDescriptorcreate(Config config)Create an instance of sslConfig from external configuration source.booleanisEnabled()Check if SSL is enabled.booleanisJdkSSL()Check if JDK SSL has be used.StringtlsCaCert()Get the CA (certificate authority) certificate path.StringtlsCert()Get the tlsCert path.StringtlsKey()Get the client private key path.
-
-
-
Method Detail
-
builder
public static GrpcSslDescriptor.Builder builder()
Return a new instance ofGrpcSslDescriptor.Builder.- Returns:
- a new instance of
GrpcSslDescriptor.Builder
-
builder
public static GrpcSslDescriptor.Builder builder(Config config)
Return an instance of builder based on the specified external config.- Parameters:
config- external config- Returns:
- an instance of builder
-
create
public static GrpcSslDescriptor create(Config config)
Create an instance of sslConfig from external configuration source.- Parameters:
config- external config- Returns:
- an instance of sslconfig
-
isEnabled
public boolean isEnabled()
Check if SSL is enabled. If this is false, then none of the other configuration values are used.- Returns:
- true if ssl is enabled; false otherwise
-
isJdkSSL
public boolean isJdkSSL()
Check if JDK SSL has be used. Only used for TLS enabled server channels.A Ignored by client channel.- Returns:
- true if JDK ssl has to be used; false otherwise
-
tlsCert
public String tlsCert()
Get the tlsCert path. Can be either client or server cert.- Returns:
- the path to tls certificate
-
tlsKey
public String tlsKey()
Get the client private key path. Can be either client or server private key.- Returns:
- the path to tls private key
-
tlsCaCert
public String tlsCaCert()
Get the CA (certificate authority) certificate path.- Returns:
- the path to CA certificate
-
-