jooq-modelator icon indicating copy to clipboard operation
jooq-modelator copied to clipboard

Please do not perform property evaluation during configuration phase

Open ysb33r opened this issue 5 years ago • 2 comments

This plugin has a cardinal sin in that it is validating states of the plugin during configration phase. This makes it impossible to implement lazy evalution.

Please move the validation like whether specific paths exist into the TaskAction on the task and don't do it when the plugin is applied.

A case in point is that jooqConfig.xml might not exist when the plugin is applied as the file might be generated by another task later on before generateJooqMetamodel is executed.

ysb33r avatar Jul 28 '20 15:07 ysb33r

Hello ysb33r,

I did not know that. Thanks for the tip.

I'm going to look into that as soon as I find the time. I'm also always open for pull-requests :)

ayedo avatar Jul 31 '20 17:07 ayedo

I checked the code, and it seems that all validation takes places in an project.afterEvaluate { } block. I'm not sure why this is not sufficient?

ayedo avatar Aug 02 '20 12:08 ayedo