Package energy.eddie.aiida.services
Class ProvisioningService
java.lang.Object
energy.eddie.aiida.services.ProvisioningService
-
Constructor Summary
ConstructorsConstructorDescriptionProvisioningService(InboundAggregator inboundAggregator, PermissionRepository permissionRepository, MqttConfiguration mqttConfiguration, org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder passwordEncoder, InboundDataSourceRepository inboundDataSourceRepository) -
Method Summary
Modifier and TypeMethodDescriptionchangeProvisioningType(UUID permissionId, ProvisioningTypePatchDto patch) Changes the provisioning type of the inbound data source associated with a permission.resetServerModePassword(UUID permissionId)
-
Constructor Details
-
ProvisioningService
public ProvisioningService(InboundAggregator inboundAggregator, PermissionRepository permissionRepository, MqttConfiguration mqttConfiguration, org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder passwordEncoder, InboundDataSourceRepository inboundDataSourceRepository)
-
-
Method Details
-
changeProvisioningType
public MqttProvisioningConnectionDto changeProvisioningType(UUID permissionId, ProvisioningTypePatchDto patch) throws PermissionNotFoundException, InvalidDataSourceTypeException, ProvisioningConfigurationException Changes the provisioning type of the inbound data source associated with a permission. MQTT modes establish a connection and replace the active publisher, while REST modes stop any active publisher and clear the MQTT provisioning configuration.- Parameters:
permissionId- ID of the permission whose inbound data source should be reconfigured.patch- Requested provisioning type and, for MQTT client mode, its connection parameters.- Returns:
- Connection details for MQTT provisioning, or an empty DTO for REST provisioning.
- Throws:
PermissionNotFoundExceptionInvalidDataSourceTypeExceptionProvisioningConfigurationException
-
resetServerModePassword
public MqttProvisioningConnectionDto resetServerModePassword(UUID permissionId) throws PermissionNotFoundException, InvalidDataSourceTypeException, ProvisioningTypeNotConfiguredException, ProvisioningConfigurationException
-