Skip to content
Snippets Groups Projects
Commit b314f512 authored by Fabian Seidl's avatar Fabian Seidl
Browse files

added event to app framework, fixed typo, tested and working

parent cc0f61b6
No related branches found
No related tags found
1 merge request!568Resolve "Improve the event system by adding an extra Event for gNMI-Subscribe to replace the currently used Update Event"
Pipeline #164085 passed
......@@ -12,6 +12,8 @@ const (
Update
// Delete is a delete event.
Delete
// Subscribe is a gNMI subscribe event.
Subscribe
)
// String implements the stringer interface for types.
......@@ -23,6 +25,8 @@ func (t Type) String() string {
return "update"
case Delete:
return "delete"
case Subscribe:
return "subscribe"
}
return "unknown"
......@@ -30,9 +34,10 @@ func (t Type) String() string {
var (
typeLookup = map[string]Type{
"add": Add,
"update": Update,
"delete": Delete,
"add": Add,
"update": Update,
"delete": Delete,
"subscribe": Subscribe,
}
)
......
......@@ -20,7 +20,7 @@ const (
// TypeDelete is a delete event.
TypeDelete = "delete"
// TypeSusbcribe is a gNMI subscribe event.
// TypeSubscribe is a gNMI subscribe event.
TypeSubscribe = "subscribe"
)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment