cube
cube copied to clipboard
Grammar update: lock expression
Hey folks, not sure if there's any interest, but figured I'd pass this along. Adds the ability to limit an expression by appending a filter expression to the end of a metric or event expression.
This allows us to create an interface to the Cube evaluator and still allow the client to provide the initial expression. Our application just needs to append the lock expression before forwarding to our (well secured) evaluator.
Feedback's awesome, this is one of my very few forays into node.
That seems like a nice addition, but that wouldn't work very well with multiple operations. I like the idea but I'm not sure it's the best way to express constraints, though I have nothing better to offer yet :)
I considered adding additional parameters to the request - so the event and metric getters would then filter based on those parameters. This turned out much cleaner - got some samples of multiple operations that you use that could get my head working through some possibilities?
A meaningless example would be sum(test.gt(i, 42)) + min(test2.lt(i, 24))
but you get the idea.