|
|
|
@ -58,6 +58,7 @@ import java.util.Collections; |
|
|
|
import java.util.Comparator; |
|
|
|
import java.util.List; |
|
|
|
import java.util.Optional; |
|
|
|
import java.util.concurrent.ExecutionException; |
|
|
|
import java.util.stream.Collectors; |
|
|
|
|
|
|
|
import static org.thingsboard.server.common.data.CacheConstants.DEVICE_CACHE; |
|
|
|
@ -158,7 +159,7 @@ public class DeviceServiceImpl extends AbstractEntityService implements DeviceSe |
|
|
|
if (entityViews != null && !entityViews.isEmpty()) { |
|
|
|
throw new DataValidationException("Can't delete device that is assigned to entity views!"); |
|
|
|
} |
|
|
|
} catch (Exception e) { |
|
|
|
} catch (ExecutionException | InterruptedException e) { |
|
|
|
log.error("Exception while finding entity views for deviceId [{}]", deviceId, e); |
|
|
|
throw new RuntimeException("Exception while finding entity views for deviceId [" + deviceId + "]", e); |
|
|
|
} |
|
|
|
|