|
|
|
@ -22,27 +22,36 @@ public enum EdgeEventType { |
|
|
|
CUSTOMER(true, EntityType.CUSTOMER), |
|
|
|
RELATION(true, null), |
|
|
|
TENANT(true, EntityType.TENANT), |
|
|
|
TENANT_PROFILE(true, EntityType.TENANT_PROFILE), |
|
|
|
WIDGETS_BUNDLE(true, EntityType.WIDGETS_BUNDLE), |
|
|
|
WIDGET_TYPE(true, EntityType.WIDGET_TYPE), |
|
|
|
ADMIN_SETTINGS(true, EntityType.ADMIN_SETTINGS), |
|
|
|
TENANT_PROFILE(true, true, EntityType.TENANT_PROFILE), |
|
|
|
WIDGETS_BUNDLE(true, true, EntityType.WIDGETS_BUNDLE), |
|
|
|
WIDGET_TYPE(true, true, EntityType.WIDGET_TYPE), |
|
|
|
ADMIN_SETTINGS(true, true, EntityType.ADMIN_SETTINGS), |
|
|
|
OTA_PACKAGE(true, EntityType.OTA_PACKAGE), |
|
|
|
QUEUE(true, EntityType.QUEUE), |
|
|
|
NOTIFICATION_RULE(true, EntityType.NOTIFICATION_RULE), |
|
|
|
NOTIFICATION_TARGET(true, EntityType.NOTIFICATION_TARGET), |
|
|
|
NOTIFICATION_TEMPLATE(true, EntityType.NOTIFICATION_TEMPLATE), |
|
|
|
TB_RESOURCE(true, EntityType.TB_RESOURCE), |
|
|
|
OAUTH2_CLIENT(true, EntityType.OAUTH2_CLIENT), |
|
|
|
DOMAIN(true, EntityType.DOMAIN), |
|
|
|
QUEUE(true, true, EntityType.QUEUE), |
|
|
|
NOTIFICATION_RULE(true, true, EntityType.NOTIFICATION_RULE), |
|
|
|
NOTIFICATION_TARGET(true, true, EntityType.NOTIFICATION_TARGET), |
|
|
|
NOTIFICATION_TEMPLATE(true, true, EntityType.NOTIFICATION_TEMPLATE), |
|
|
|
TB_RESOURCE(true, true, EntityType.TB_RESOURCE), |
|
|
|
OAUTH2_CLIENT(true, true, EntityType.OAUTH2_CLIENT), |
|
|
|
DOMAIN(true, true, EntityType.DOMAIN), |
|
|
|
CALCULATED_FIELD(false, EntityType.CALCULATED_FIELD); |
|
|
|
|
|
|
|
private final boolean allEdgesRelated; |
|
|
|
// entity is pushed to all edges of its tenant, otherwise only to edges it's assigned to
|
|
|
|
private final boolean allTenantEdgesRelated; |
|
|
|
|
|
|
|
// entity can be owned by system tenant, so system level events are pushed to all edges
|
|
|
|
private final boolean systemLevelSupported; |
|
|
|
|
|
|
|
private final EntityType entityType; |
|
|
|
|
|
|
|
|
|
|
|
EdgeEventType(boolean allEdgesRelated, EntityType entityType) { |
|
|
|
this.allEdgesRelated = allEdgesRelated; |
|
|
|
EdgeEventType(boolean allTenantEdgesRelated, EntityType entityType) { |
|
|
|
this(allTenantEdgesRelated, false, entityType); |
|
|
|
} |
|
|
|
|
|
|
|
EdgeEventType(boolean allTenantEdgesRelated, boolean systemLevelSupported, EntityType entityType) { |
|
|
|
this.allTenantEdgesRelated = allTenantEdgesRelated; |
|
|
|
this.systemLevelSupported = systemLevelSupported; |
|
|
|
this.entityType = entityType; |
|
|
|
} |
|
|
|
} |
|
|
|
|