refactoring: used const instead of String

This commit is contained in:
dashevchenko 2023-12-12 12:35:57 +02:00
parent 7957e5cca6
commit 355503bbbc

View File

@ -27,6 +27,8 @@ import org.springframework.stereotype.Service;
import java.util.Objects; import java.util.Objects;
import java.util.Optional; import java.util.Optional;
import static org.thingsboard.server.common.data.CacheConstants.SECURITY_SETTINGS_CACHE;
@RequiredArgsConstructor @RequiredArgsConstructor
@Service @Service
@Profile("install") @Profile("install")
@ -88,7 +90,7 @@ public class DefaultCacheCleanupService implements CacheCleanupService {
break; break;
case "3.6.1": case "3.6.1":
log.info("Clearing cache to upgrade from version 3.6.1 to 3.6.2"); log.info("Clearing cache to upgrade from version 3.6.1 to 3.6.2");
clearCacheByName("securitySettings"); clearCacheByName(SECURITY_SETTINGS_CACHE);
break; break;
default: default:
//Do nothing, since cache cleanup is optional. //Do nothing, since cache cleanup is optional.