sensu / sensu-go

Simple. Scalable. Multi-cloud monitoring.
https://sensu.io
MIT License
1.02k stars 175 forks source link

Discuss: adhoc event entity #91

Closed portertech closed 6 years ago

portertech commented 7 years ago

If a backend receives an event from an agent containing an unknown/unregistered (or new) entity, should it create the entity? RBAC could be used to dictate behaviour, if the agent's user is allowed to manage entities beyond its own etc.

portertech commented 7 years ago

This requires some discussion about RBAC first: https://github.com/sensu/sensu-go/issues/84

portertech commented 7 years ago

Should an event with entity details that differ than the stored entity be altered? Should it update the stored entity?

portertech commented 7 years ago

Proposal:

Allow an event with an unknown entity to store the entity (if the agent RBAC user has permission to do so)

Future events with the same entity ID are considered to be a reference to the stored entity, the entity in etcd is considered to be the source of truth, replacing the entity in the event.

Implementation wise, this means eventd would always have to check if entity exists, if not create it, if so override the entity in the event with the stored version.

portertech commented 7 years ago

Related https://github.com/sensu/sensu-go/issues/90

portertech commented 7 years ago

Begin the user stories.

portertech commented 7 years ago

A web application sends an Event to an Agent interface, containing an Entity that represents the web application instance.

portertech commented 7 years ago

An Agent executes a check against a network switch, the resulting Event contains an Entity that represents the network switch. (ala Sensu proxy checks)

palourde commented 6 years ago

I'm closing this since proxy entities are now fully supported in Sensu 2.