Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Add maven wrapper to scala project. #13702

Merged
merged 1 commit into from
Feb 6, 2019
Merged

Conversation

frankfliu
Copy link
Contributor

Add maven wrapper to scala project, this removed maven dependency from host machine.
And this will also eliminate build script compatibility issue with different maven version.

Checklist

Essentials

Please feel free to remove inapplicable items for your PR.

  • Changes are complete (i.e. I finished coding on this PR)
  • All changes have test coverage:
  • Unit tests are added for small changes to verify correctness (e.g. adding a new operator)
  • Nightly tests are added for complicated/long-running ones (e.g. changing distributed kvstore)
  • Build tests will be added for build configuration changes (e.g. adding a new build option with NCCL)
  • Code is well-documented:
  • For user-facing API changes, API doc string has been updated.
  • For new C++ functions in header files, their functionalities and arguments are documented.
  • For new examples, README.md is added to explain the what the example does, the source of the dataset, expected performance on test set and reference to the original paper if applicable
  • Check the API doc at http://mxnet-ci-doc.s3-accelerate.dualstack.amazonaws.com/PR-$PR_ID/$BUILD_ID/index.html
  • To the my best knowledge, examples are either not affected by this change, or have been fixed to be compatible with this change

Copy link
Contributor

@marcoabreu marcoabreu left a comment

Choose a reason for hiding this comment

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

As per previous discussion (sorry on mobile, don't have link on hand), we are not allowed to published binaries (the jar file). Basically Apache forbids that action for all of it's projects

@lebeg
Copy link
Contributor

lebeg commented Dec 21, 2018

As per previous discussion...

@marcoabreu Please provide the link.

I would consider reading answers in LEGAL-427 carefully as well.

@marcoabreu
Copy link
Contributor

I don't understand how that link is relevant. The Apache release guidelines forbid binaries in source releases

@Roshrini
Copy link
Member

@nswamy Can you please take a look?
@mxnet-label-bot Add [pr-awaiting-review, Scala]

@marcoabreu marcoabreu added pr-awaiting-review PR is waiting for code review Scala labels Dec 21, 2018
@sandeep-krishnamurthy
Copy link
Contributor

@frankfliu you have any comments on the concerns from @marcoabreu ?

@frankfliu
Copy link
Contributor Author

@marcoabreu
checkin maven wrapper or gradle wrapper is very common practice in most of modern java projects.
check in binary files are bad in general, which is not able diff while updating, and will increase git repo size rapidly. But It should be OK for tools since they are not part of source code and won't be updated frequently. And maven wrapper and gradle wrapper jar files are tiny.

You can find many apache project with maven wrapper checked in github:
Here is a link to apache log4j project: https://github.com/apache/logging-log4j2/tree/master/.mvn/wrapper

@anirudhacharya
Copy link
Member

@marcoabreu ping for a relook at this PR.

}
}

private static void downloadFileFromURL(String urlString, File destination) throws Exception {
Copy link
Member

Choose a reason for hiding this comment

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

Please add some retries in here to reduce the failure

Copy link
Contributor

Choose a reason for hiding this comment

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

I don't think it is needed. It's code coming in from Maven Wrapper package.

@lanking520
Copy link
Member

@frankfliu Please raise a discussion on dev@ to discuss about uploading the binary

@marcoabreu
Copy link
Contributor

Thanks @lanking520 , that's a great idea. We have been advised by out mentors in the past to specifically remove the maven wrapper binary, but it might be good to bring it up again.

@mjwall
Copy link
Member

mjwall commented Jan 25, 2019 via email

@marcoabreu
Copy link
Contributor

@marcoabreu
Copy link
Contributor

Open LEGAL ticket: https://issues.apache.org/jira/browse/LEGAL-288

@mjwall
Copy link
Member

mjwall commented Jan 25, 2019 via email

@marcoabreu
Copy link
Contributor

marcoabreu commented Jan 25, 2019

We had it in the past and were asked to remove it by mentors. I've linked both threads

If there is an alternative to a binary file - which is the case according to your link - I'm also in favour to not have them checked in at all as otherwise users will have to manually download them and we have to manually remove them.

@frankfliu
Copy link
Contributor Author

@marcoabreu I removed jar file. The maven wrapper can compile MavenWrapperDownloader.java and download the .jar file on the fly.

Copy link
Contributor

@marcoabreu marcoabreu left a comment

Choose a reason for hiding this comment

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

Awesome, thank you! :)

@lanking520
Copy link
Member

@frankfliu Since we are good with this PR, please add the final changes on the

  • Jenkins file
  • Publish Jenkinsfile
  • Makefile
  • Docs on website

In order to coordinate this change. Thanks

@vandanavk
Copy link
Contributor

@mxnet-label-bot update [Scala, pr-awaiting-merge]

@marcoabreu marcoabreu added pr-awaiting-merge Review and CI is complete. Ready to Merge and removed pr-awaiting-review PR is waiting for code review labels Feb 6, 2019
@lanking520 lanking520 merged commit 9e14f14 into apache:master Feb 6, 2019
@lanking520
Copy link
Member

@frankfliu please add the remaining items in JIRA as a backlog item

@frankfliu frankfliu deleted the mvnw branch February 11, 2019 00:34
stephenrawls pushed a commit to stephenrawls/incubator-mxnet that referenced this pull request Feb 16, 2019
vdantu pushed a commit to vdantu/incubator-mxnet that referenced this pull request Mar 31, 2019
haohuanw pushed a commit to haohuanw/incubator-mxnet that referenced this pull request Jun 23, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
pr-awaiting-merge Review and CI is complete. Ready to Merge Scala
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants