-
-
Notifications
You must be signed in to change notification settings - Fork 84
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
use Worker API #138
Comments
This is a good idea but I cannot implement it yet as we still need to support Gradle versions older than 4.10.3 (that should be the minimum version for the worker API). I'll pin this issue for the time being and get back to this at a later point in time. |
@michel-kraemer out of curiosity, why support such an old version? |
@ZacSweers You're right. I just deprecated Gradle 2.x up to 4.x as well as Java 7. This will allow me to do some cleanup in gradle-download-task 5.0.0. 👍 |
@michel-kraemer how about dropping 5.x too, then support only 6.x and 7.x. FYI, latest 5.x or 5.6.4 was releases on Nov 01, 2019, also we need 5.4.1 to support Worker API. |
Hey @michel-kraemer are there some updates on this front? |
@cortinico Sorry, there are no updates on this at the moment. Do you have any specific need for this feature? |
Yup we use I'm wondering what was the plan here. If you're planning on working on Worker API support, you're welcoming external contributions or should we create our own wrapper |
OK. Sounds good. I will reprioritise my efforts then!
The long-term plan was to deprecate support for Gradle versions 2.x-4.x and then eventually implement support for the worker API (besides other improvements, which would then become possible) after a reasonable period of time. I just checked the commit log and this thread here and noticed that 2.x-4.x have been deprecated in July 2020 already! 😳 So, I think it's really time to move on now. I will start refactoring as soon as possible. You can expect the first commits in the next few days. I'll keep you informed about the progress. |
@cortinico I've just published a snapshot of the upcoming gradle-download-task 5.0.0 with support for the worker API and parallel downloads. If you want, you can try it out as follows: buildscript {
repositories {
maven {
url 'https://oss.sonatype.org/content/groups/public'
}
}
dependencies {
classpath 'de.undercouch:gradle-download-task:5.0.0-SNAPSHOT'
}
}
apply plugin: 'de.undercouch.download' The actual usage of the plugin has not changed. Your build script should automatically download files in parallel with this version. The plugin requires Gradle 5.x and Java 8 now. I'll make some more adjustments and improvements and release 5.0.0 in the next few weeks. I'll keep this issue open until then for feedback and further discussion. |
Thanks @michel-kraemer. React Native uses Gradle 7.x and JDK 11, so it would be ok. |
Version 5.0.0 has just been released. I'm closing this issue now. Please let me know if you have any more ideas or feedback! |
Thank you very much for doing it 🙏 |
Summary: This enables concurrent task exection and parallel downloads See also michel-kraemer/gradle-download-task#138 ## Changelog [General] [Changed] - Update gradle-download-task to 5.0.1 to support concurrent downloads Pull Request resolved: #32995 Test Plan: Build runs successfully. Reviewed By: ShikaSD Differential Revision: D33892817 Pulled By: cortinico fbshipit-source-id: 515443573e17a5c2b16a1cf3cea4bf3c5c2d96a7
Summary: This enables concurrent task exection and parallel downloads See also michel-kraemer/gradle-download-task#138 ## Changelog [General] [Changed] - Update gradle-download-task to 5.0.1 to support concurrent downloads Pull Request resolved: facebook#32995 Test Plan: Build runs successfully. Reviewed By: ShikaSD Differential Revision: D33892817 Pulled By: cortinico fbshipit-source-id: 515443573e17a5c2b16a1cf3cea4bf3c5c2d96a7
Worker API introduced in Gradle 5.4.1 allows to execute work concurrently and asynchronously, and I think it might be useful to download files concurrently. It might be best to add support for it release 4.x version, since most users still use 3.x and it won't be a breaking change.
https://guides.gradle.org/using-the-worker-api/
Thank you
The text was updated successfully, but these errors were encountered: