Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SensedEvents should obscure the dict/json representation of event data underneath #21

Open
KyleBenson opened this issue Mar 21, 2015 · 0 comments

Comments

@KyleBenson
Copy link
Owner

I already added a get_raw_data() function, but I think we need more abstractions for this fairly complex object. It's become fairly clunky and has its logic spread out over a lot of different places that are now requiring checks to validate it's correct state. In particular, I'm looking at how the "condition" part has to be duplicated in the VirtualSensors (once for the logic itself, another time to record how the logic was done). Wouldn't it be great to abstract this into one text representation, configurable via the config files, that is parsed into an actual logical rule and then executed in the VS?

I modified VSs for the whole read_raw_data() vs read() thing to start addressing some of this wonkiness where sometimes we want to work in raw sensor readings and other times in the whole object.

I've also run into issues of the whole TOPIC concept and whether it belongs inside of a SensedEvent or outside as a separate concept (maybe ONLY pertinent to MQTT?). This will also ease omitting unchanged details between sensor readings, compression, etc.

It may be time to bring in some more advanced Python modules that add nice syntax and translations for these operations, such as for database support.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant