Class: OpenC3::TimelineTopic
- Defined in:
- lib/openc3/topics/timeline_topic.rb
Constant Summary collapse
- PRIMARY_KEY =
"__openc3_timelines"
Class Method Summary collapse
-
.write_activity(activity, scope:) ⇒ Object
Write an activity to the topic.
Methods inherited from Topic
clear_topics, get_cnt, method_missing
Class Method Details
.write_activity(activity, scope:) ⇒ Object
Write an activity to the topic
“‘json
"timeline" => "foobar",
"kind" => "created",
"type" => "activity",
"data" => {
"name" => "foobar",
"start" => 1621875570,
"stop" => 1621875585,
"kind" => "cmd",
"data" => {"cmd"=>"INST ABORT"}
"events" => [{"event"=>"created"}]
}
“‘
44 45 46 |
# File 'lib/openc3/topics/timeline_topic.rb', line 44 def self.write_activity(activity, scope:) Topic.write_topic("#{scope}#{PRIMARY_KEY}", activity, '*', 1000) end |