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

Tool to generate functions.go based on rules descriptor #58

Closed
rameshpolishetti opened this issue Jun 4, 2019 · 4 comments
Closed

Tool to generate functions.go based on rules descriptor #58

rameshpolishetti opened this issue Jun 4, 2019 · 4 comments
Assignees
Labels
enhancement New feature or request

Comments

@rameshpolishetti
Copy link
Contributor

Current behavior:
User has to write down functions.go with condition evaluators and action functions as defined in the rules descriptor json.

Expected behavior:
Add a cli tool or flogo cli plugin to generate functions.go boilerplate code based on supplied rules descriptor json.

What is the motivation / use case for changing the behavior?

  • Improves turn around time to create and run a new rule application.
  • Eliminates human errors caused due to mismatch function names (usually spelling mistakes) between descriptor json and functions.go

Additional information you deem important (e.g. I need this tomorrow):

@tibmatt
Copy link
Contributor

tibmatt commented Jun 5, 2019

Hmmm - I guess? Honestly I'd prefer this to be done:

  1. Conditions utilize the flogo expression language with bindings to the Tuple store
  2. Action functions - same thing (or wrap it in an activity if used within a flogo flow)

Doing a code generator isn't really moving the needle.

@balamg
Copy link
Collaborator

balamg commented Jun 7, 2019

I think all this is asking is for stubs to be generated and save some typing/and errors. (unlike the elaborate codegen in BE) So it would be a good little nifty utility to have.. "(2) that Matt mentioned above would be really cool.. When a rule fires, execute a Flogo-flow.. That would be a nice ER. And of course (1) above, which was done but broke when Flogo-core changed their APIs. That needs to be redone.

@rameshpolishetti
Copy link
Contributor Author

I echo @balamg, points 1 & 2 mentioned by @tibmatt are really cool !!
Not sure about the complexity involved in point 1 & 2 realization, until then this kind of tool saves some time/errors.

@rameshpolishetti
Copy link
Contributor Author

Closing this issue as this kind of tool may not be required as issues #22 & #69 effectively handles the problem statement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

4 participants