Interface JGroupsCertificateProvider
- All Superinterfaces:
Provider
- All Known Implementing Classes:
DatabaseJGroupsCertificateProvider
,FileJGroupsCertificateProvider
Provider
for the TLS certificate for JGroups communication.
Implementation notes
If the method isEnabled()
returns true
, then the implementation must also implement
keyManager()
and trustManager()
.
If the method supportRotateAndReload()
returns true
, then the implementation must also implement
rotateCertificate()
, reloadCertificate()
and nextRotation()
.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptiondefault void
close()
default boolean
default KeyManager
Returns a managedKeyManager
.default Duration
Returns when the next certificate rotation is required.default void
Reloads the most recent certificate and apply it to theKeyManager
andTrustManager
.default void
A new certificate must be generated.default boolean
default TrustManager
Returns a managedTrustManager
.
-
Field Details
-
DISABLED
-
-
Method Details
-
rotateCertificate
default void rotateCertificate()A new certificate must be generated.The generated certificate should not be used immediately, but only after
reloadCertificate()
is invoked.This method must be implemented when
supportRotateAndReload()
returnstrue
. -
reloadCertificate
default void reloadCertificate()Reloads the most recent certificate and apply it to theKeyManager
andTrustManager
.This method must be implemented when
supportRotateAndReload()
returnstrue
. -
nextRotation
Returns when the next certificate rotation is required.It is used to automatically rotate certificates periodically.
This method must be implemented when
supportRotateAndReload()
returnstrue
.- Returns:
- The time until the next rotation.
-
keyManager
Returns a managedKeyManager
.If
supportRotateAndReload()
returnstrue
, the instance returned must be updated with the new certificate whenreloadCertificate()
. This method is invoked only once at boot time.This method must be implemented when
isEnabled()
returnstrue
.- Returns:
- The
KeyManager
to use by theSSLContext
.
-
trustManager
Returns a managedTrustManager
.If
supportRotateAndReload()
returnstrue
, the instance returned must be updated with the new certificate whenreloadCertificate()
. This method is invoked only once at boot time.This method must be implemented when
isEnabled()
returnstrue
.- Returns:
- The
TrustManager
to use by theSSLContext
.
-
supportRotateAndReload
default boolean supportRotateAndReload()- Returns:
true
if rotation and reload requests is possible.
-
isEnabled
default boolean isEnabled()- Returns:
true
if TLS is enabled for JGroups communication.
-
close
default void close()
-