Coder Social home page Coder Social logo

How can i write dynamic rules to execute rather than writing in java program .like rules defined in JSON or Yaml? about rulebook HOT 4 OPEN

evasanthan avatar evasanthan commented on June 8, 2024
How can i write dynamic rules to execute rather than writing in java program .like rules defined in JSON or Yaml?

from rulebook.

Comments (4)

awattez avatar awattez commented on June 8, 2024

I do not think that this library is planned to use JSON / YAML files to configure the rules.
I also do not know if there is a RoadMap referenced somewhere, maybe this request can be registered there.
This library can probably help you https://github.com/j-easy/easy-rules

from rulebook.

lospejos avatar lospejos commented on June 8, 2024

I'm not sure that library mentioned above (easy-rules) has something that this library doesn't. Both libraries has examples of dynamically created rules in runtime. Since you can create rules in runtime, you can parse rules from XML, JSON, YAML, database tables or whatever you want and create rules accordingly. The main challenge is to create a flexible rules description format (especially when you plan to create complex rules combined from conditions set joining them using AND, OR, NOT etc), and to create a error-prone parser of this format.

All written above is just my opinion, of course )))

from rulebook.

Clayton7510 avatar Clayton7510 commented on June 8, 2024

JSON, XML or YAML support is not on the roadmap. I agree that if that's specifically what you are looking for, then something like easy-rules might be worth a look.

I don't really like how that was supported in other frameworks - feels like a move away from simplicity. With that being said, there always were plans to have rules loaded at runtime that could be stored somewhere else, but rules that are in an intuitive DSL, like something that could be provided by Groovy or maybe Kotlin. Not a simple task, tho.

from rulebook.

Clayton7510 avatar Clayton7510 commented on June 8, 2024

This thread is scheduled to be deleted on 10/22/2020. Further discussion on externalized rules can be handled in issue #9

from rulebook.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.