vidakovic commented on code in PR #4638:
URL: https://github.com/apache/fineract/pull/4638#discussion_r2079332479


##########
fineract-core/src/main/java/org/apache/fineract/infrastructure/event/external/service/ExternalEventConfigurationWritePlatformServiceImpl.java:
##########
@@ -22,31 +22,28 @@
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
-import lombok.AllArgsConstructor;
-import org.apache.fineract.infrastructure.core.api.JsonCommand;
-import org.apache.fineract.infrastructure.core.data.CommandProcessingResult;
-import 
org.apache.fineract.infrastructure.core.data.CommandProcessingResultBuilder;
-import 
org.apache.fineract.infrastructure.event.external.command.ExternalEventConfigurationCommand;
+import lombok.RequiredArgsConstructor;
+import org.apache.fineract.command.core.Command;
+import 
org.apache.fineract.infrastructure.event.external.data.ExternalEventConfigKey;
+import 
org.apache.fineract.infrastructure.event.external.data.ExternalEventConfigurationRequest;
+import 
org.apache.fineract.infrastructure.event.external.data.ExternalEventConfigurationResponse;
 import 
org.apache.fineract.infrastructure.event.external.repository.ExternalEventConfigurationRepository;
 import 
org.apache.fineract.infrastructure.event.external.repository.domain.ExternalEventConfiguration;
-import 
org.apache.fineract.infrastructure.event.external.serialization.ExternalEventConfigurationCommandFromApiJsonDeserializer;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Transactional;
 
 @Service
-@AllArgsConstructor
+@RequiredArgsConstructor
 public class ExternalEventConfigurationWritePlatformServiceImpl implements 
ExternalEventConfigurationWritePlatformService {
 
     private final ExternalEventConfigurationRepository repository;
-    private final ExternalEventConfigurationCommandFromApiJsonDeserializer 
fromApiJsonDeserializer;
 
     @Transactional
     @Override
-    public CommandProcessingResult updateConfigurations(final JsonCommand 
command) {
-        final ExternalEventConfigurationCommand configurationCommand = 
fromApiJsonDeserializer.commandFromApiJson(command.json());
-        final Map<String, Boolean> commandConfigurations = 
configurationCommand.externalEventConfigurations();
-        final Map<String, Object> changes = new HashMap<>();
+    public ExternalEventConfigurationResponse 
updateConfigurations(Command<ExternalEventConfigurationRequest> command) {

Review Comment:
   Let's see if we can standardize validations with Jakarta Validations... I 
understand the "business validation" part, but let's see if we can get this 
under one API... having 2 different validation concepts in place is just hard 
to explain (read: people will start again to do whatever comes to their minds). 
Let me see if I can bulldozer an example.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to