btkelly / gnag

A Gradle plugin that helps facilitate GitHub PR checking and automatic commenting of violations.
http://gnag.watch
Apache License 2.0
125 stars 14 forks source link

Run different tools in parallel #208

Open szaboa opened 5 years ago

szaboa commented 5 years ago

Hi, I am wondering if it's possible to run these different static code analyzers in parallel? One use case would be to define distinct jobs for let's say FindBug, PMD, Android Lint etc. and execute them in parallel inside a CI workflow.

Does this make sense? Or it would help? I assume that right know these tools doesn't share any cache or re-use partial result from each other. Am I right?

How could I separate this one gradle task into smaller ones, to be able to run them in parallel?

stkent commented 5 years ago

As a data point, what sort of size project are you running Gnag on, how many build variants does it have, and how long does gnagCheck take to run (approximately)?

In theory, I think you're right; it should be possible to run these checks in parallel and speed things up a bunch.

In practice, I don't believe the current architecture of this plugin makes that possible. Neither @btkelly or I have a lot of time to devote to Gnag at the moment, but we'd definitely be happy to consider a proposal in the form of a PR if you want to take a crack at the necessary changes. Let us know if that's something that interests you and we can support where needed.

szaboa commented 5 years ago

Well this was just a theoretical question, right now I am just experimenting with different CI workflows on Android so I can't say that the current task is slow, but I am pretty sure I will use this this plugin in production apps as well. I will look into this and do a PR if I succeed :)

stkent commented 5 years ago

Awesome, glad to hear it! :)

szaboa commented 5 years ago

Pull request is done, waiting some feedback there :)

stkent commented 5 years ago

Poke @btkelly :)

szaboa commented 5 years ago

@btkelly, @stkent ping :)