Add cache for SoftwareModule, DistributionSet and Target types (#2784)
Signed-off-by: Avgustin Marinov <Avgustin.Marinov@bosch.com>
This commit is contained in:
@@ -15,12 +15,13 @@ import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityDeletedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.DistributionSetType;
|
||||
import org.eclipse.hawkbit.repository.model.TenantAwareBaseEntity;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event of deleting a {@link DistributionSetType}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class DistributionSetTypeDeletedEvent extends RemoteIdEvent implements EntityDeletedEvent {
|
||||
public class DistributionSetTypeDeletedEvent extends RemoteIdEvent implements EntityDeletedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -15,12 +15,13 @@ import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityDeletedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.SoftwareModuleType;
|
||||
import org.eclipse.hawkbit.repository.model.TenantAwareBaseEntity;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event of deleting a {@link SoftwareModuleType}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class SoftwareModuleTypeDeletedEvent extends RemoteIdEvent implements EntityDeletedEvent {
|
||||
public class SoftwareModuleTypeDeletedEvent extends RemoteIdEvent implements EntityDeletedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -15,12 +15,13 @@ import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityDeletedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.TargetType;
|
||||
import org.eclipse.hawkbit.repository.model.TenantAwareBaseEntity;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event of deleting a {@link TargetType}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class TargetTypeDeletedEvent extends RemoteIdEvent implements EntityDeletedEvent {
|
||||
public class TargetTypeDeletedEvent extends RemoteIdEvent implements EntityDeletedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -14,12 +14,13 @@ import java.io.Serial;
|
||||
import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityCreatedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.DistributionSetType;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event of creating a new {@link DistributionSetType}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class DistributionSetTypeCreatedEvent extends RemoteEntityEvent<DistributionSetType> implements EntityCreatedEvent {
|
||||
public class DistributionSetTypeCreatedEvent extends RemoteEntityEvent<DistributionSetType> implements EntityCreatedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -15,12 +15,13 @@ import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityUpdatedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.DistributionSetType;
|
||||
import org.eclipse.hawkbit.repository.model.SoftwareModuleType;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event for updating a {@link SoftwareModuleType}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class DistributionSetTypeUpdatedEvent extends RemoteEntityEvent<DistributionSetType> implements EntityUpdatedEvent {
|
||||
public class DistributionSetTypeUpdatedEvent extends RemoteEntityEvent<DistributionSetType> implements EntityUpdatedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -14,12 +14,13 @@ import java.io.Serial;
|
||||
import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityUpdatedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.SoftwareModuleType;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event for updating a {@link SoftwareModuleType}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class SoftwareModuleTypeUpdatedEvent extends RemoteEntityEvent<SoftwareModuleType> implements EntityUpdatedEvent {
|
||||
public class SoftwareModuleTypeUpdatedEvent extends RemoteEntityEvent<SoftwareModuleType> implements EntityUpdatedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -14,12 +14,13 @@ import java.io.Serial;
|
||||
import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityUpdatedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.SoftwareModule;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event for updating a {@link SoftwareModule}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class SoftwareModuleUpdatedEvent extends RemoteEntityEvent<SoftwareModule> implements EntityUpdatedEvent {
|
||||
public class SoftwareModuleUpdatedEvent extends RemoteEntityEvent<SoftwareModule> implements EntityUpdatedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -14,12 +14,13 @@ import java.io.Serial;
|
||||
import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityCreatedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.TargetType;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event of creating a new {@link TargetType}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class TargetTypeCreatedEvent extends RemoteEntityEvent<TargetType> implements EntityCreatedEvent {
|
||||
public class TargetTypeCreatedEvent extends RemoteEntityEvent<TargetType> implements EntityCreatedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@@ -14,12 +14,13 @@ import java.io.Serial;
|
||||
import lombok.NoArgsConstructor;
|
||||
import org.eclipse.hawkbit.repository.event.entity.EntityUpdatedEvent;
|
||||
import org.eclipse.hawkbit.repository.model.TargetType;
|
||||
import org.eclipse.hawkbit.tenancy.TenantAwareCacheManager.CacheEvictEvent;
|
||||
|
||||
/**
|
||||
* Defines the remote event for updating a {@link TargetType}.
|
||||
*/
|
||||
@NoArgsConstructor // for serialization libs like jackson
|
||||
public class TargetTypeUpdatedEvent extends RemoteEntityEvent<TargetType> implements EntityUpdatedEvent {
|
||||
public class TargetTypeUpdatedEvent extends RemoteEntityEvent<TargetType> implements EntityUpdatedEvent, CacheEvictEvent {
|
||||
|
||||
@Serial
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
Reference in New Issue
Block a user