-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
SOLR-14847: Create Solr Server TGZ #1844
Conversation
Two issues I see currently.
|
I think I have addressed both of the issues I raised. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, correct. Remove excessive lines maybe?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please take a look at the link I provided earlier - it contains a matcher on file name so only one from clause is needed.
from(..., { |
Sorry, forgot to mention this before. I tried that initially and it resulted in all files having the executable bit added.
|
Doing more research on this, I suspect that we should be using the https://docs.gradle.org/current/userguide/distribution_plugin.html built in distribution plugin instead of trying to roll all of this ourselves. I'll spend some time trying to piece this together |
So it turns out that Hopefully this helps in your migration to that plugin Mike. |
@HoustonPutman since I don't have a windows machine, can you check the behaviour of the the distribution plugin for me one more time? |
Most of the changes at this point are indentation, so the PR is much smaller than it appears. |
I am not keen on using the plugin. I like knowing what's going on behind the scenes - a bit of verboseness is good here, actually. |
Could you please revert to using a task instead of the plugin? Including that executable bits block Houston added. |
Perhaps I should clarify my reluctance to use the plugin - these plugins are built-in and ship with gradle. It's a moving target when you upgrade the build system - their behavior changes, your build silently does different things. I've been scalded by this before and I hate it. Versioned plugins are different in that you have some control over their upgrades. |
Give me some time to digest it, @madrob I'll take a look at what the distribution plugin does behind the scenes and how often it changes. |
other distribution tasks.
Ah. Great catch! This is one of the biggest gotchas in gradle - unscoped variables sometimes reach out to unexpected places. Thanks for finding it. |
I've added a file permissions block and verified what the distribution plugin does. I still have mixed feelings about it but I admit I am conservative about using third-party plugins (spent too much time debugging such stuff...). Let it be though. +1 from me. |
I might be using it wrong, but I don't think the distTar task overwrites previously generated tars. I've tried changing the executable bit paths, and the tar that already exists is unnaffected. If this is the case, we might want to switch back to the manual task. Though this seems like I'm doing something wrong, because this surely can't be the default behavior of the plugin. |
I think those bits are not part of the task's inputs so it's not re-run. Try --rerun-tasks or cleanDistTar |
Ahh ok, thank for clearing that up. Whenever I cleaned it up beforehand, the task worked fine. I've also tested changing actual files and the task unsurprisingly works correctly. Since we won't be adding executables in weird places too often, I think this should be good to go. +1 |
I think the timestamps/ execution bits are not part of inputs on purpose
(to allow distributed artifact caches). This is on the border of my gradle
foo knowledge, you'd have to dig in yourself if you want to know more.
Dawid
…On Thu, Sep 10, 2020 at 4:19 PM Houston Putman ***@***.***> wrote:
Ahh ok, thank for clearing that up. Whenever I cleaned it up beforehand,
the task worked fine. I've also tested changing actual files and the task
unsurprisingly works correctly.
Since we won't be adding executables in weird places too often, I think
this should be good to go. +1
—
You are receiving this because your review was requested.
Reply to this email directly, view it on GitHub
<#1844 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AABQWLXKZR3NVGBZ74RLVETSFDN6LANCNFSM4RANVA4A>
.
|
Does this need a CHANGES entry? We haven't been doing that for other gradle build things, but wanted to confirm. |
I don't know. It's on master only and pretty much everything falls under "gradle build" umbrella. Feel free to add it if you like though! |
Create new targets for building solr binary release artifacts: gradlew -p solr/packaging distTar distZip Co-authored-by: Houston Putman <houston@apache.org> Co-authored-by: Dawid Weiss <dawid.weiss@carrotsearch.com> Co-authored-by: Mike Drob <mdrob@apache.org>
Create new targets for building solr binary release artifacts: gradlew -p solr/packaging distTar distZip Co-authored-by: Houston Putman <houston@apache.org> Co-authored-by: Dawid Weiss <dawid.weiss@carrotsearch.com> Co-authored-by: Mike Drob <mdrob@apache.org>
No description provided.