Browse Source
Merge pull request #15197 from smatvienko-tb/fix/notification-edge-test-recipients-config
Fix NotificationRuleRecipientsConfig serialization with Jackson 2.18.x
pull/15216/head
Viacheslav Klimov
7 months ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
3 additions and
1 deletions
-
common/data/src/main/java/org/thingsboard/server/common/data/notification/rule/NotificationRuleRecipientsConfig.java
|
|
|
@ -17,6 +17,7 @@ package org.thingsboard.server.common.data.notification.rule; |
|
|
|
|
|
|
|
import com.fasterxml.jackson.annotation.JsonIgnore; |
|
|
|
import com.fasterxml.jackson.annotation.JsonIgnoreProperties; |
|
|
|
import com.fasterxml.jackson.annotation.JsonProperty; |
|
|
|
import com.fasterxml.jackson.annotation.JsonSubTypes; |
|
|
|
import com.fasterxml.jackson.annotation.JsonSubTypes.Type; |
|
|
|
import com.fasterxml.jackson.annotation.JsonTypeInfo; |
|
|
|
@ -29,7 +30,7 @@ import java.util.List; |
|
|
|
import java.util.Map; |
|
|
|
import java.util.UUID; |
|
|
|
|
|
|
|
@JsonIgnoreProperties |
|
|
|
@JsonIgnoreProperties(ignoreUnknown = true) |
|
|
|
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, property = "triggerType", visible = true, include = JsonTypeInfo.As.EXISTING_PROPERTY, defaultImpl = DefaultNotificationRuleRecipientsConfig.class) |
|
|
|
@JsonSubTypes({ |
|
|
|
@Type(name = "ALARM", value = EscalatedNotificationRuleRecipientsConfig.class), |
|
|
|
@ -38,6 +39,7 @@ import java.util.UUID; |
|
|
|
public abstract class NotificationRuleRecipientsConfig implements Serializable { |
|
|
|
|
|
|
|
@NotNull |
|
|
|
@JsonProperty("triggerType") |
|
|
|
private NotificationRuleTriggerType triggerType; |
|
|
|
|
|
|
|
@JsonIgnore |
|
|
|
|