Commit 5557406f07cf6650a9b768195330d724f6827783

Authored by Volodymyr Babak
1 parent 7d1a8490

Added alarm id for future needs

@@ -58,6 +58,8 @@ public class AlarmMsgConstructor { @@ -58,6 +58,8 @@ public class AlarmMsgConstructor {
58 } 58 }
59 AlarmUpdateMsg.Builder builder = AlarmUpdateMsg.newBuilder() 59 AlarmUpdateMsg.Builder builder = AlarmUpdateMsg.newBuilder()
60 .setMsgType(msgType) 60 .setMsgType(msgType)
  61 + .setIdMSB(alarm.getId().getId().getMostSignificantBits())
  62 + .setIdLSB(alarm.getId().getId().getLeastSignificantBits())
61 .setName(alarm.getName()) 63 .setName(alarm.getName())
62 .setType(alarm.getType()) 64 .setType(alarm.getType())
63 .setOriginatorName(entityName) 65 .setOriginatorName(entityName)
@@ -54,6 +54,7 @@ public class AlarmEdgeProcessor extends BaseEdgeProcessor { @@ -54,6 +54,7 @@ public class AlarmEdgeProcessor extends BaseEdgeProcessor {
54 EntityId originatorId = getAlarmOriginator(tenantId, alarmUpdateMsg.getOriginatorName(), 54 EntityId originatorId = getAlarmOriginator(tenantId, alarmUpdateMsg.getOriginatorName(),
55 EntityType.valueOf(alarmUpdateMsg.getOriginatorType())); 55 EntityType.valueOf(alarmUpdateMsg.getOriginatorType()));
56 if (originatorId == null) { 56 if (originatorId == null) {
  57 + log.warn("Originator not found for the alarm msg {}", alarmUpdateMsg);
57 return Futures.immediateFuture(null); 58 return Futures.immediateFuture(null);
58 } 59 }
59 try { 60 try {
@@ -250,18 +250,20 @@ message EntityViewUpdateMsg { @@ -250,18 +250,20 @@ message EntityViewUpdateMsg {
250 250
251 message AlarmUpdateMsg { 251 message AlarmUpdateMsg {
252 UpdateMsgType msgType = 1; 252 UpdateMsgType msgType = 1;
253 - string name = 2;  
254 - string type = 3;  
255 - string originatorType = 4;  
256 - string originatorName = 5;  
257 - string severity = 6;  
258 - string status = 7;  
259 - int64 startTs = 8;  
260 - int64 endTs = 9;  
261 - int64 ackTs = 10;  
262 - int64 clearTs = 11;  
263 - string details = 12;  
264 - bool propagate = 13; 253 + int64 idMSB = 2;
  254 + int64 idLSB = 3;
  255 + string name = 4;
  256 + string type = 5;
  257 + string originatorType = 6;
  258 + string originatorName = 7;
  259 + string severity = 8;
  260 + string status = 9;
  261 + int64 startTs = 10;
  262 + int64 endTs = 11;
  263 + int64 ackTs = 12;
  264 + int64 clearTs = 13;
  265 + string details = 14;
  266 + bool propagate = 15;
265 } 267 }
266 268
267 message CustomerUpdateMsg { 269 message CustomerUpdateMsg {