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

Don't set stupid defaults. #80

Merged
merged 1 commit into from
Oct 17, 2017
Merged

Conversation

jtnord
Copy link
Member

@jtnord jtnord commented Oct 12, 2017

I doubt any plugin cares about multicast dns discovery so just disable
it rather than giving it a non standard port (which could lead to
announcments on a public wifi network)

Also reuseForks is true by default so do not set it and allow users to
use the standard -DreuseForks=false without having to change the plugin
config.

On the same note concurrency is only ever used in surefires forkCount -
yet another non standard property. So stop that nonsense and use
forkCount directly (which is initialized to concurrency for backwards
compatability)

Tested on a plugin with an updated snapshot parent using
mvn test (check concurrency is one test at once)
mvn test -Dconcurrency=4 (check concurrency if 4 at once - for backwards comparability)
mvn test -DforkCount=4 (check concurrency is 4 at once)

@reviewbybees

I doubt any plugin cares about multicast dns discovery so just disable
it rather than giving it a non standard port (which could lead to
announcments on a public wifi network)

ALso reuseForks is true by default so do not set it and allow users to
use the standard -DreuseForks=false without having to change the plugin
cofnig.

On the same note concurrency is only ever used in surefires forkCount -
yet another non standard property.  So stop that nonsense and use
forkCount (which is initialized to concurrency for backwards
compatability)
@@ -59,7 +59,8 @@
<!-- Change this property if you need your tests to be compiled with a different Java level than the plugin. -->
<!-- Use only if strictly necessary. It may cause problems in your IDE. -->
<java.level.test>${java.level}</java.level.test>
<concurrency>1</concurrency> <!-- may use e.g. 2C for 2 × (number of cores) -->
<concurrency>1</concurrency> <!-- DEPRECATED use forkCount -->
Copy link
Member Author

Choose a reason for hiding this comment

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

not sure we even need this but it here for backwards compatability... happy to remove both this and forkCount (as the default is one...)

@jtnord jtnord requested review from jglick and batmat October 12, 2017 17:31
@ghost
Copy link

ghost commented Oct 12, 2017

This pull request originates from a CloudBees employee. At CloudBees, we require that all pull requests be reviewed by other CloudBees employees before we seek to have the change accepted. If you want to learn more about our process please see this explanation.

@@ -689,11 +690,9 @@
<systemProperties>
<property>
<name>hudson.udp</name>
<value>33849</value>
<value>-1</value>
Copy link
Member Author

Choose a reason for hiding this comment

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

I mean why would we want this... like EVER? (if some esoteric plugin needs it for a test then let them configure it?)

Copy link
Member

Choose a reason for hiding this comment

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

UDP disabling without throwing errors was only added in 1.514: jenkinsci/jenkins@19f34b5

This option is set at least since 1.388: https://github.com/jenkinsci/jenkins/blob/ea06f60c1abe408ccb45c700421c0456ce00ef6d/plugins/pom.xml#L196, probably a lot longer.

Copy link
Member Author

Choose a reason for hiding this comment

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

@daniel-beck that's a novel use of "only" - something that happened more than 4 years ago :-)

do you care about that supporting building plugins for something as old as that?

Copy link
Member

Choose a reason for hiding this comment

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

I'm just answering your comment. This didn't disable, because disabling didn't exist.

Copy link
Member

Choose a reason for hiding this comment

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

Fine, though better to just move the code out of core, as is already filed in a split-plugins-from-core issue.

Copy link
Member

@batmat batmat left a comment

Choose a reason for hiding this comment

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

🐝

Copy link
Member

@jetersen jetersen left a comment

Choose a reason for hiding this comment

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

👍

Copy link
Member

@jglick jglick left a comment

Choose a reason for hiding this comment

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

Sounds OK.

@@ -689,11 +690,9 @@
<systemProperties>
<property>
<name>hudson.udp</name>
<value>33849</value>
<value>-1</value>
Copy link
Member

Choose a reason for hiding this comment

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

Fine, though better to just move the code out of core, as is already filed in a split-plugins-from-core issue.

@batmat batmat merged commit 2c7efde into jenkinsci:master Oct 17, 2017
@batmat
Copy link
Member

batmat commented Oct 17, 2017

Thanks a lot for the reviews @Casz @jglick !

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants