Sourcery
Sourcery copied to clipboard
Launch multiple configurations in parallel
Currently we have 150+ modules with 300+ targets in project, each module has same assembly+injection code which is auto-generated by Sourcery. To make generation faster, we're preparing list of ymls (1 per module) and launch sourcer(y)-ies in parallel for each module=yml. Codebase (source files and output files) doesn't intersect, so it works well.
Im looking how we can improve performance of this approach.
One of found 'issues' - each sourcery is separated instance, so some unified values each time are loading, e.g. templates.
Much better to have one Sourcery instance, also it already supports having one yml with multiple configations. So I can combine all 150 ymls in one and launch Sourcery one time
BUT as I see in the code, in such case Sourcery launches these sub-configurations in serial, not parallel.
Does it some special limitation or maybe It's just not implemented yet.
To understand better, pls look around let keepAlive = try configurations.flatMap