Interface PluginDescriptor<C extends Configuration>
- All Known Subinterfaces:
AlarmHandlerPluginDescriptor<C>,AuthenticationActionPluginDescriptor<C>,AuthenticatorPluginDescriptor<C>,AuthorizationManagerPluginDescriptor<C>,BackchannelAuthenticatorPluginDescriptor<C>,ClaimsProviderPluginDescriptor<C>,ConsentorPluginDescriptor<C>,DataAccessProviderPluginDescriptor<C>,EmailProviderPluginDescriptor<C>,EventListenerPluginDescriptor<C>,SigningConsentorPluginDescriptor<C>,SmsPluginDescriptor<C>
The server loads plugin descriptors using Java's ServiceLoader mechanism. However, the server
only scans for implementations of specific subtypes of PluginDescriptor, not of PluginDescriptor
itself.
This means that this interface should not be implemented directly.
All subtypes of PluginDescriptor scanned by the server can be found in the package
se.curity.identityserver.sdk.plugin.descriptor.
An implementation of a PluginDescriptor subtype must be a concrete class with a default constructor.
-
Method Summary
Modifier and TypeMethodDescriptiondefault Optional<? extends ManagedObject<C>>createManagedObject(C configuration) Creates a newManagedObjectfor managing the life-cycle of this plugin.Returns the configuration interface used by this plugin.Returns the plugin implementation type.
-
Method Details
-
getPluginImplementationType
String getPluginImplementationType()Returns the plugin implementation type. The plugin instance id is used to map to a plugin implementation type.- Returns:
- The plugin implementation type. Must be unique across all plugins installed in the server.
-
getConfigurationType
Returns the configuration interface used by this plugin.Only interfaces are allowed. Anything else, like a
classorabstract class, will cause the plugin descriptor to be rejected when the server attempts to load it.- Returns:
- the configuration interface used by this plugin.
-
createManagedObject
Creates a newManagedObjectfor managing the life-cycle of this plugin. Called on configuration changes for instances of this plugin.May return an empty
Optional, if life-cycle management isn't required for this plugin.The default implementation of this method returns an empty Optional.
- Parameters:
configuration- the updated configuration for the plugin. This configuration object cannot provide service instances, only primitive configuration data. Trying to get a service from this object will cause an error at runtime.- Returns:
- the optional
ManagedObjecttype for this plugin. This can be used to manage the plugin lifecycle.
-