Skip to content

Commit

Permalink
Merge pull request #268 from slacmshankar/issue267
Browse files Browse the repository at this point in the history
#267 Add the "val" field in GetDataAtTimeEngine
  • Loading branch information
jacomago authored Sep 26, 2024
2 parents 75665cb + 36e06e6 commit 41874ba
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
import org.epics.archiverappliance.utils.ui.MetaFields;
import org.epics.archiverappliance.utils.ui.MimeTypeConstants;
import org.json.simple.JSONObject;
import org.json.simple.JSONValue;

import java.io.IOException;
import java.io.PrintWriter;
Expand Down Expand Up @@ -107,6 +108,11 @@ public void execute(HttpServletRequest req, HttpServletResponse resp, ConfigServ
if (potentialEvent != null) {
HashMap<String, Object> evnt = new HashMap<String, Object>();
evnt.put("secs", potentialEvent.getEpochSeconds());
evnt.put(
"val",
JSONValue.parse(potentialEvent
.getSampleValue()
.toJSONString()));
evnt.put("nanos", potentialEvent.getEventTimeStamp().getNano());
evnt.put("severity", potentialEvent.getSeverity());
evnt.put("status", potentialEvent.getStatus());
Expand Down

0 comments on commit 41874ba

Please sign in to comment.