java.lang.Object
es.kukenan.smartfi.microservice.transfer.service.events.UserService

@Service public class UserService extends Object
Service for handler user events.
  • Field Details

    • logAudit

      private static final es.kukenan.smartfi.logger.WalletLogger logAudit
      kukenan logger.
    • appName

      @Value("${spring.application.name}") private String appName
      Spring application name.
    • userRepository

      @Autowired private UserRepository userRepository
      User repository use for database queries.
    • contextManager

      @Autowired private es.kukenan.smartfi.common.context.RequestContextManager contextManager
      kukenan request context manager.
    • kafkaController

      @Autowired private KafkaController kafkaController
      AMQP controller.
    • documentTypeRepository

      @Autowired private DocumentTypeRepository documentTypeRepository
      DocumentTypeRepository.
    • userLanguageRepository

      @Autowired private UserLanguageRepository userLanguageRepository
      UserLanguageRepository.
    • userStateRepository

      @Autowired private UserStateRepository userStateRepository
      UserStateRepository.
    • userTypeRepository

      @Autowired private UserTypeRepository userTypeRepository
      UserTypeRepository.
  • Constructor Details

    • UserService

      public UserService()
  • Method Details

    • handleUserUpdatedEvent

      public void handleUserUpdatedEvent(es.kukenan.smartfi.microservice.clients.events.updated.UserUpdatedEvent userUpdatedEvent)
      Method for handle event for update update information.
      Parameters:
      userUpdatedEvent - UserUpdatedEvent update event.
    • handleUserCreatedEvent

      public void handleUserCreatedEvent(es.kukenan.smartfi.microservice.clients.events.created.UserCreatedEvent userCreatedEvent)
      Method for handle event for user creation.
      Parameters:
      userCreatedEvent - userCreatedEvent user created event.
    • publishUserCreationErrorEvent

      private void publishUserCreationErrorEvent(String userId, String sourceEventId, String errorCode, String errorDescription)
      Publish a user creation error event.
      Parameters:
      userId - the user whose creation has failed.
      sourceEventId - event received that caused the failure.
      errorCode - Error code.
      errorDescription - Error description.