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

Make conflict resolution strategies configurable #63

Open
snikolayev opened this issue Mar 14, 2017 · 3 comments
Open

Make conflict resolution strategies configurable #63

snikolayev opened this issue Mar 14, 2017 · 3 comments

Comments

@snikolayev
Copy link
Member

snikolayev commented Mar 14, 2017

Currently, conflict resolution strategy in NRules is fixed. Rules with higher priorities are fired first. Rules with the same priority are fired in a FIFO order.
Need ability to control conflict resolution at a more granular level.

@snikolayev snikolayev changed the title Placeholder Make conflict resolution strategies configurable Mar 14, 2017
@linanqiu
Copy link
Contributor

linanqiu commented Jan 3, 2019

Possible strategies;

  • Alphabetical (as default)
  • Analyze expressions and find dependency in types (e.g. if Rule A forward chains Type1 and Rule B consumes Type1, and RuleA's priority is the same as RuleB's, then always prefer RuleA)

This allows users to define fewer explicit rule groups.

@snikolayev
Copy link
Member Author

FYI, if priorities are the same, the default firing order is not alphabetical, it preserves activation order.

@linanqiu
Copy link
Contributor

linanqiu commented Jan 9, 2019

My bad -- that should be the default yes.

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

No branches or pull requests

2 participants