Skip to content

Commit

Permalink
Fixed issue where subscribed telemetry and eventStreams were being ig…
Browse files Browse the repository at this point in the history
…nored
  • Loading branch information
abrighton authored and abrighton committed Mar 6, 2020
1 parent c9c6987 commit 757920d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 3 deletions.
11 changes: 9 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,14 @@
# Change Log
All notable changes to this project will be documented in this file.

## [ICD v1.0.1] -
## [ICD v1.0.2] - 2020-03-06

### Changed

- Fixed issue where subscribed telemetry and eventStreams were being ignored
(Now they are automatically converted to events, since telemetry and eventStreams have been removed in the new JSON schema)

## [ICD v1.0.1] - 2020-03-03

### Changed

Expand All @@ -15,7 +22,7 @@ All notable changes to this project will be documented in this file.

- Updated dependencies to fix issue with PDF generation (DEOPSICDDB-93)

## [ICD v1.0.0] -
## [ICD v1.0.0] - 2020-02-21

### Added

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,14 @@ object SubscribeModelBsonParser {
for (subDoc <- subscribeDoc.getAsOpt[Array[BSONDocument]](name).map(_.toList).getOrElse(Nil))
yield SubscribeInfoBsonParser(subDoc)

// For backward compatibility
val oldEvents = getItems("telemetry") ++ getItems("eventStreams")

SubscribeModel(
subsystem = doc.getAsOpt[String](BaseModelBsonParser.subsystemKey).get,
component = doc.getAsOpt[String](BaseModelBsonParser.componentKey).get,
description = subscribeDoc.getAsOpt[String]("description").map(HtmlMarkup.gfmToHtml).getOrElse(""),
eventList = getItems("events"),
eventList = oldEvents ++ getItems("events"),
observeEventList = getItems("observeEvents"),
currentStateList = getItems("currentStates"),
alarmList = getItems("alarms")
Expand Down

0 comments on commit 757920d

Please sign in to comment.