Hello, I’m trying to optimize the artifact upload...
# community-support
u
Hello, I’m trying to optimize the artifact upload process for my Kotlin Multiplatform project, which targets both Android and iOS. Right now, the
publish
task takes 20–30 minutes to upload artifacts to a custom Maven repository. From what I can tell, even though the tasks are executed in parallel, the actual uploads seem to happen sequentially, which slows everything down. The project has 25 modules, and as the number of modules grows, I know this issue will only get worse. For some context: • The
publishToMavenLocal
task runs much faster (1–2 minutes), even without configuration cache reuse. • I’m using a composite build to share common logic between modules (just inline functions). • I asked about this in Kotlin Slack, and they directed me here, mentioning a related issue. I’m still unsure how composite builds could help with this problem. Does anyone know if it’s possible to enable parallel uploads to speed this up? Here are the options I’m currently using:
Copy code
org.gradle.jvmargs=-Xmx4G -Dfile.encoding=UTF-8 -Dkotlin.daemon.jvm.options="-Xmx4G" -XX:+UseParallelGC  
org.gradle.caching=true  
org.gradle.configuration-cache=true  
org.gradle.configuration-cache.problems=warn  
org.gradle.parallel=true  
org.gradle.configureondemand=true
Any insights or suggestions would be greatly appreciated!