Skip to content
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

deprecate buildNative gradle task #8325

Merged
merged 1 commit into from
Apr 12, 2020
Merged

Conversation

glefloch
Copy link
Member

@glefloch glefloch commented Apr 1, 2020

this pull request deprecates gradle buildNative task.

close #7104

@boring-cyborg boring-cyborg bot added area/devtools Issues/PR related to maven, gradle, platform and cli tooling/plugins area/documentation area/gradle Gradle labels Apr 1, 2020
@geoand geoand requested a review from gastaldi April 1, 2020 11:34
Copy link
Contributor

@gastaldi gastaldi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Contributor

@gastaldi gastaldi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You need to update the io.quarkus.gradle.QuarkusPluginFunctionalTest too I suppose

@gastaldi
Copy link
Contributor

gastaldi commented Apr 1, 2020

Also make sure the Gradle tests pass in your environment by running gradle test functionalTest in the plugin folder

@glefloch
Copy link
Member Author

glefloch commented Apr 1, 2020

Thank you for the review, I'm checking why the build fails.

@machi1990 machi1990 requested a review from gastaldi April 3, 2020 17:20
@machi1990
Copy link
Member

Thanks for the contribution @glefloch, can we squash the commits into one?

@glefloch
Copy link
Member Author

glefloch commented Apr 3, 2020

Yes, for sure, I squashed commits.

Copy link
Contributor

@gastaldi gastaldi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added some comments below. Can you verify them before we merge it?

testNative.setShouldRunAfter(Collections.singletonList(tasks.findByName(JavaPlugin.TEST_TASK_NAME)));

project.getGradle().getTaskGraph().whenReady(taskGraph -> {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Isn't this already done in configureBuildNativeTask(...)?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

well, yes, you right, I moved out the logger and used task path instead of task reference.

@gastaldi
Copy link
Contributor

gastaldi commented Apr 6, 2020

It seems that the warning shows only after quarkusBuild executes. Is there any way to show that warning BEFORE quarkusBuild kicks in?

@gastaldi
Copy link
Contributor

gastaldi commented Apr 6, 2020

Also, don't forget to update the READMEs generated when a project is created:
https://github.com/quarkusio/quarkus/blob/master/devtools/platform-descriptor-json/src/main/resources/templates/README.gradle.ftl#L27-L31

@glefloch
Copy link
Member Author

glefloch commented Apr 6, 2020

It seems that the warning shows only after quarkusBuild executes. Is there any way to show that warning BEFORE quarkusBuild kicks in?

Well, we could either move the warning in the configureBuildNative method, or instead of making buildNative depends on quarkusBuild, we could set buildNative to be finalized by quarkusBuild. What do you think @gastaldi ?

@gastaldi
Copy link
Contributor

gastaldi commented Apr 6, 2020

I am not sure which is better. I'll let you decide 😉

@glefloch
Copy link
Member Author

glefloch commented Apr 7, 2020

@gastaldi, I updated buildNative task to be finalizedBy by quarkusBuild. The output looks like:

> Task :buildNative
buildNative task has been deprecated in favor of quarkusBuild -Dquarkus.package.type=native

> Task :quarkusBuild
building quarkus runner

BUILD SUCCESSFUL in 1m 20s

WDYT?

@gastaldi gastaldi added this to the 1.4.0 milestone Apr 7, 2020
@gastaldi gastaldi requested a review from geoand April 7, 2020 13:13
@glefloch glefloch force-pushed the fix/7014 branch 2 times, most recently from 7ad072d to b63baf7 Compare April 7, 2020 14:44
@gastaldi gastaldi modified the milestones: 1.4.0, 1.5 Apr 9, 2020
@gastaldi gastaldi requested a review from aloubyansky April 12, 2020 00:43
@aloubyansky aloubyansky merged commit c36d82f into quarkusio:master Apr 12, 2020
@glefloch glefloch deleted the fix/7014 branch August 19, 2021 06:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/devtools Issues/PR related to maven, gradle, platform and cli tooling/plugins area/documentation area/gradle Gradle
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Deprecate QuarkusNative
5 participants