[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15247166#comment-15247166 ] ASF GitHub Bot commented on IGNITE-2404: Github user asfgit closed the pull request at: https://github.com/apache/ignite/pull/549 > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15247167#comment-15247167 ] Denis Magda commented on IGNITE-2404: - Thanks. I've reviewed and merged your changes into the master. Well done! > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15245463#comment-15245463 ] Ryan Zhao commented on IGNITE-2404: --- Pull request: https://github.com/apache/ignite/pull/549 tests result: pull/549/merge > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15242423#comment-15242423 ] Denis Magda commented on IGNITE-2404: - Hi [~ryanzhaocs], Yes, there can be some tests that fail from time to time and not related to your changes. Please share the link to tests results and the link to current pull-request with me. > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15238753#comment-15238753 ] Ryan Zhao commented on IGNITE-2404: --- Hi, I've run all the tests. And, there are some test fails which seems not caused by my changes. Does it matter? > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15237208#comment-15237208 ] Ryan Zhao commented on IGNITE-2404: --- Hi Denis, I just found that I need manually run tests on teamcity. I will let you know as soon as possible when all test passed. > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15237080#comment-15237080 ] Denis Magda commented on IGNITE-2404: - Hi, [~ryanzhaocs] when do you expect to finish working on this task? Do you need any assistance from community side? > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15208150#comment-15208150 ] Denis Magda commented on IGNITE-2404: - Thanks, please let me know when you're ready for review. Don't forget to check your changes against all the test suites using TeamCity referring to this section https://cwiki.apache.org/confluence/display/IGNITE/How+to+Contribute#HowtoContribute-1.CreateGitHubpull-request The section includes the link to TeamCity at the very end. > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15208136#comment-15208136 ] Ryan Zhao commented on IGNITE-2404: --- [~dmagda] Your proposal is considerably more robust, and I will get it done. > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15206043#comment-15206043 ] Denis Magda commented on IGNITE-2404: - [~ryanzhaocs], I've reviewed your changes and left my comments directly in the pull-request. As per IgniteConfiguration#getTimeServerPortRange and ConnectorConfiguration#getPortRange let's make sure that port range set to '0' will work with them as well. To achieve this you can modify the loops where these ranges are used in a way I recommended to do for TcpDiscoverySpi in the pull-request {noformat} int lastPort = spi.locPortRange == 0 ? spi.locPort : spi.locPort + spi.locPortRange - 1; for (port = spi.locPort; port <= lasPort; port++) {noformat} > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15193099#comment-15193099 ] Denis Magda commented on IGNITE-2404: - Hi, Thanks for the contribution. I'll review your changes in the nearest couple of days and will answer on other questions. > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15193085#comment-15193085 ] Ryan Zhao commented on IGNITE-2404: --- Hi, in the implementation of the change presented above, I have found that many component in Ignite have a portRange parameter, such as IgniteConfiguration#getTimeServerPortRange and ConnectorConfiguration#getPortRange. And in these scenarios portRange equals 0 is considered to be a mistake. So, I think we should keep this consistency, and make the docs more clear. Any thoughts? > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15191072#comment-15191072 ] ASF GitHub Bot commented on IGNITE-2404: GitHub user ryanzz opened a pull request: https://github.com/apache/ignite/pull/549 IGNITE-2404 For TcpDiscoverySpi and TcpCommunicationSpi, if port range value is 0, then implementation will try bind only to the port provided by setLocalPort(int) method and fail if binding to this port did not succeed. You can merge this pull request into a Git repository by running: $ git pull https://github.com/ryanzz/ignite ignite-2404 Alternatively you can review and apply these changes as the patch at: https://github.com/apache/ignite/pull/549.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #549 commit 7c6d33a49f8005d5dc66f10044efe8cfea9ad8be Author: Ryan ZhaoDate: 2016-03-11T14:54:41Z fixed ignite-2404 > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda >Assignee: Ryan Zhao > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15190707#comment-15190707 ] Ryan Zhao commented on IGNITE-2404: --- The doc on TcpCommunicationSpi.setLocalPortRange() saying that "If port range value is 0, then implementation will try bind only to the port provided by setLocalPort(int) method and fail if binding to this port did not succeed." So, I think it would be a right choice to treat localPortRange=0 as localPortRange=1. I will solve it. > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (IGNITE-2404) TcpDiscoverySpi.setLocalPortRange set 0 doesn't work
[ https://issues.apache.org/jira/browse/IGNITE-2404?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15106650#comment-15106650 ] Denis Magda commented on IGNITE-2404: - Refer to this discussion for more details http://apache-ignite-users.70518.x6.nabble.com/TcpDiscoverySpi-setLocalPortRange-value-must-be-0-tp2606.html > TcpDiscoverySpi.setLocalPortRange set 0 doesn't work > - > > Key: IGNITE-2404 > URL: https://issues.apache.org/jira/browse/IGNITE-2404 > Project: Ignite > Issue Type: Bug >Reporter: Denis Magda > Labels: community, newbie > > Local port range set to 0 presently doesn't work at least for > TcpCommunicationSpi and TcpDiscoverySpi. However SPIs support it. > In my understanding the condition has to changed to the following one (from < > to <=). > x = port; x <= port + range -- This message was sent by Atlassian JIRA (v6.3.4#6332)