0

I am using PHP and MySQL to run a backend server. Currently I have a "Action" table that contains certain criteria and what action should be taken, the properties are following:

  1. Conditions (contains complex criteria, e.g. [Item.Qty] > 100000 AND [User.Level] < 5 AND [Item.Price] > 100000)
  2. Actions (e.g. SEND EMAIL TO [SUPERVISOR])

I already have the condition parser that will return boolean.

The software will need to validate every user's action to the every rules (e.g. enterprise software). But I have thousands of rules and number of request is high.

Any idea to run this in real-time when user submitting / saving data to the system?

Thanks :)

Notes: Since I have tons of feature to compare, decision table is not a feasible option here

user2936719
  • 165
  • 2
  • 10
  • Parallelization? – bbozo Jun 14 '17 at 14:44
  • @bbozo I have not tried it, considering the high request, retrieving and running thousand of complex rules one by one on PHP, I am afraid it can slow down the process of the API call to user at the front-end. – user2936719 Jun 14 '17 at 14:54

0 Answers0