Skip to content
This repository has been archived by the owner on Jul 28, 2024. It is now read-only.

Please do not perform property evaluation during configuration phase #18

Open
ysb33r opened this issue Jul 28, 2020 · 2 comments
Open

Comments

@ysb33r
Copy link

ysb33r commented Jul 28, 2020

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.

@ayedo
Copy link
Owner

ayedo commented Jul 31, 2020

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
Copy link
Owner

ayedo commented Aug 2, 2020

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?

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

No branches or pull requests

2 participants