Interface ArtifactHandlerConfigurator
- All Superinterfaces:
BambooPluginModule
,InitablePluginModule<ArtifactHandlerModuleDescriptor>
- All Known Implementing Classes:
AbstractArtifactHandlerConfigurator
,AgentLocalArtifactHandlerConfigurator
,BambooRemoteArtifactHandlerConfigurator
,S3ArtifactHandlerConfigurator
,ServerLocalArtifactHandlerConfigurator
@Internal
public interface ArtifactHandlerConfigurator
extends InitablePluginModule<ArtifactHandlerModuleDescriptor>
Configurator for a
ArtifactHandler
.-
Method Summary
Modifier and TypeMethodDescriptionbeforeSave
(Map<String, String> artifactHandlersConfigurationBeforeSave, Map<String, String> existingArtifactHandlersConfiguration) Pre save action handler, allows to gather feedback from configurator before artifact handler configuration saving.void
decorateConfigurationForRuntime
(@NotNull Map<String, String> artifactHandlersConfiguration) Decorate artifact handlers configuration for runtime.getArtifactHandlerConfiguration
(@NotNull Map<String, String> configuration) Filter out the current configuration of the artifact handler from the given map.@NotNull String
getConfigurationKey
(@NotNull String key) For a provided suffix return full configuration key.getEncryptedArtifactHandlerConfiguration
(@NotNull Map<String, String> configuration) Filter out configuration of the artifact handler from the given map and encrypt sensitive field values.getRawArtifactHandlerConfigurationData
(@NotNull Map<String, String> configuration) Filter out all the configuration data of the artifact handler from the given map.boolean
isConfigurationComplete
(@NotNull Map<String, String> artifactHandlersConfiguration) Validate if configuration of the artifact handler is completevoid
populateContextForEdit
(@NotNull Map<String, Object> context) void
postProcessConfiguration
(ActionParametersMap actionParametersMap) Any configuration adjustments that need to happen before configuration is saved should be done here.void
validateConfiguration
(@NotNull Map<String, String> newArtifactHandlersConfiguration, @NotNull Map<String, String> oldArtifactHandlersConfiguration, @NotNull ErrorCollection errorCollection) Validate configuration.Methods inherited from interface com.atlassian.bamboo.plugin.InitablePluginModule
init
-
Method Details
-
populateContextForEdit
-
postProcessConfiguration
Any configuration adjustments that need to happen before configuration is saved should be done here. -
getConfigurationKey
For a provided suffix return full configuration key.- Since:
- 9.1
-
decorateConfigurationForRuntime
void decorateConfigurationForRuntime(@NotNull @NotNull Map<String, String> artifactHandlersConfiguration) Decorate artifact handlers configuration for runtime. Implement this method to append any necessary properties which were not persisted in handler configuration.- Parameters:
artifactHandlersConfiguration
- artifact handlers configuration map
-
validateConfiguration
void validateConfiguration(@NotNull @NotNull Map<String, String> newArtifactHandlersConfiguration, @NotNull @NotNull Map<String, String> oldArtifactHandlersConfiguration, @NotNull @NotNull ErrorCollection errorCollection) Validate configuration.- Parameters:
newArtifactHandlersConfiguration
- new configuration to be validatedoldArtifactHandlersConfiguration
- existing configurationerrorCollection
- error collection to be set on validation failure
-
isConfigurationComplete
Validate if configuration of the artifact handler is complete- Parameters:
artifactHandlersConfiguration
- configuration to be validated- Since:
- 6.2
-
getArtifactHandlerConfiguration
Map<String,String> getArtifactHandlerConfiguration(@NotNull @NotNull Map<String, String> configuration) Filter out the current configuration of the artifact handler from the given map. Don't include data that are not currently used- Parameters:
configuration
- - artifact handlers configuration data- Returns:
- Subset of given configuration that is only relevant to this artifact handler's current configuration
-
getRawArtifactHandlerConfigurationData
default Map<String,String> getRawArtifactHandlerConfigurationData(@NotNull @NotNull Map<String, String> configuration) Filter out all the configuration data of the artifact handler from the given map.- Parameters:
configuration
- - artifact handlers configuration data- Returns:
- Subset of configuration that only relates to this artifact handler, with no additional filtering.
- Since:
- 9.1
-
getEncryptedArtifactHandlerConfiguration
Map<String,String> getEncryptedArtifactHandlerConfiguration(@NotNull @NotNull Map<String, String> configuration) Filter out configuration of the artifact handler from the given map and encrypt sensitive field values.- Parameters:
configuration
- - artifact handlers configuration data- Returns:
- Subset of given configuration that is only relevant to this artifact handler
-
beforeSave
MessageCollection beforeSave(Map<String, String> artifactHandlersConfigurationBeforeSave, Map<String, String> existingArtifactHandlersConfiguration) Pre save action handler, allows to gather feedback from configurator before artifact handler configuration saving.- Parameters:
artifactHandlersConfigurationBeforeSave
- updated configurationexistingArtifactHandlersConfiguration
- existing configuration- Returns:
- collection of messages which should be shown to user after configuration saving
-