File tree Expand file tree Collapse file tree
python/lib/sift_py/rule_evaluation Expand file tree Collapse file tree Original file line number Diff line number Diff line change 3434class RuleEvaluationService :
3535 """
3636 A service for evaluating rules. Provides methods to evaluate rules and perform dry-run evaluations.
37+
38+ Args:
39+ enable_caching: Enable caching during rule evaluation. This is enabled by default.
40+ This service is typically short lived in a workflows so assets, channels, and
41+ users are unlikely to change during its lifetime to invalidate caches.
3742 """
3843
3944 _channel : SiftChannel
4045 _rule_evaluation_stub : RuleEvaluationServiceStub
4146 _rule_service : RuleService
4247
43- def __init__ (self , channel : SiftChannel ):
48+ def __init__ (self , channel : SiftChannel , enable_caching : bool = True ):
4449 self ._channel = channel
4550 self ._rule_evaluation_stub = RuleEvaluationServiceStub (channel )
46-
47- # Enable caching during rule evaluation. This service is typically
48- # short lived in a workflow so assets, channels, and users are unlikely
49- # to change during its lifetime to invalidate caches.
50- self ._rule_service = RuleService (channel , enable_caching = True )
51+ self ._rule_service = RuleService (channel , enable_caching = enable_caching )
5152
5253 def evaluate_against_run (
5354 self ,
You can’t perform that action at this time.
0 commit comments