src/main/java/sk/filo/plantdiary/service/UserService.java
@Async("pdTaskExecutor")
    public void deleteUserAsync(String username) {
        User user = userRepository.getOne(username);
        userRepository.delete(user);
    }
// Async to avoid log wait when cascade delete running for lot of rows
Async to avoid log wait when cascade delete running for lot of rows
Async to avoid log wait when cascade delete running for lot of rows
@Async("pdTaskExecutor")
    public void deleteUserAsync(String username) {
        User user = userRepository.getOne(username);
        userRepository.delete(user);
    }
@ Async ( "pdTaskExecutor" ) public void deleteUserAsync ( String username ) { User user = userRepository . getOne ( username ) ; userRepository . delete ( user ) ; }
Async to avoid log wait when cascade delete running for lot of rows
Async to avoid log wait when cascade delete running for lot of rows