What documentation is there for the DSL syntax?
Specific problem, in the rule below I want the rule to trigger when both lines match, effectively AND. I've done a bit of trial and error, so far all error.
rule ProxyStore {
when {
rr : RequestRouter rr.path.substring(0, 7) == "/store/";
r : Route r.map["target"] == "";
}
then {
log.debug("*** Proxy rule triggered ***");
modify(r, function(){this.map["path"] = rr.path.substring(6);});
modify(r, function(){this.map["target"] = "ProxyHandler";});
halt();
}
}
What I'm looking for would maybe be something like:
when {
// grab the objects
rr : RequestRouter;
r : Route;
// do the test
(rr.path.substring(0, 7) == "/store/") && (r.map["target"] == "");
}
Cheers,
Danny.