[ 
https://issues.apache.org/jira/browse/SAMZA-351?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14072034#comment-14072034
 ] 

Chris Riccomini commented on SAMZA-351:
---------------------------------------

The specific issue that we're seeing this time is that the rat.gradle plugin is 
applying JavaBasePlugin to the root project, which applies a check task. We 
have an internal environment file that messes with the check task as well. Our 
internal code checks to see if "check" already exists, and applies if it 
doesn't. The rat.gradle plugin doesn't. This causes an error because you can't 
define the same task twice, and since rat.gradle goes second, that's what we're 
doing.

The options are:

# Make environment.gradle go last.
# Make rat.gradle only apply JavaBasePlugin if it's required.
# Add an afterEvaluate block to our internal environment script so that we 
force the rat.plugin to go first, and our internal code can skip adding the 
check task since it already exists.

I talked with [~szczepiq], and he recommended (1).

> Re-order environment.gradle apply
> ---------------------------------
>
>                 Key: SAMZA-351
>                 URL: https://issues.apache.org/jira/browse/SAMZA-351
>             Project: Samza
>          Issue Type: Bug
>          Components: build
>    Affects Versions: 0.7.0
>            Reporter: Chris Riccomini
>            Assignee: Chris Riccomini
>             Fix For: 0.8.0
>
>         Attachments: SAMZA-351-0.patch
>
>
> We apply environment.gradle before other plugins in build.gradle. This seems 
> to be in the wrong order, since environment.gradle is meant to provide a way 
> for people to override certain portions of the build.
> We use this internally to tweak certain plugins according to our needs, and 
> we're seeing issues because we need to tweak plugins that are applied after 
> environment.gradle.
> Simply moving the apply to the bottom of the list should fix this issue.



--
This message was sent by Atlassian JIRA
(v6.2#6252)

Reply via email to