You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@cloudstack.apache.org by marcaurele <gi...@git.apache.org> on 2017/04/05 10:27:41 UTC

[GitHub] cloudstack pull request #2027: Activate NioTest following changes in CLOUDST...

GitHub user marcaurele opened a pull request:

    https://github.com/apache/cloudstack/pull/2027

    Activate NioTest following changes in CLOUDSTACK-9348 PR #1549

    The first PR #1493 re-enabled the NioTest but not the new PR #1549.
    
    @rhtyd the test fails locally on my laptop. Is there any special configuration requirements?

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/exoscale/cloudstack niotest

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/cloudstack/pull/2027.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 #2027
    
----
commit 226e79c8ce0686ba3d5690ed90134934e26b635d
Author: Marc-Aur�le Brothier <m...@brothier.org>
Date:   2017-04-05T10:25:17Z

    Activate NioTest following changes in CLOUDSTACK-9348 PR #1549

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack issue #2027: Activate NioTest following changes in CLOUDSTACK-934...

Posted by marcaurele <gi...@git.apache.org>.
Github user marcaurele commented on the issue:

    https://github.com/apache/cloudstack/pull/2027
  
    @rhtyd I found one issue with the test and `NioConnection` class. This kind of intermittent problem are always hard to search for a root cause, but after lots of logging I finally found why. I updated the PR with the change.
    
    If the main thread running the test is stopped there https://github.com/apache/cloudstack/blob/master/utils/src/main/java/com/cloud/utils/nio/NioConnection.java#L102 due to context switching, the flag `_isRunning` isn't switched to True by the time the NioServer connection handler start it's call loop, and it exits on the `while(_isRunning)`
    https://github.com/apache/cloudstack/blob/master/utils/src/main/java/com/cloud/utils/nio/NioConnection.java#L125 directly. Therefore the server isn't listening at all and the connection cannot be made. The flag `_isRunning` must be turned `true` before submitting the task/thread.
    
    I still digging into Nio thread handler as we are experiencing some problem in production when quite a few agents try to connect at the same time to a management server. None of them can connect.



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack issue #2027: Activate NioTest following changes in CLOUDSTACK-934...

Posted by marcaurele <gi...@git.apache.org>.
Github user marcaurele commented on the issue:

    https://github.com/apache/cloudstack/pull/2027
  
    @rhtyd I moved the PR against 4.9 and rebased the changes


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack issue #2027: Activate NioTest following changes in CLOUDSTACK-934...

Posted by rhtyd <gi...@git.apache.org>.
Github user rhtyd commented on the issue:

    https://github.com/apache/cloudstack/pull/2027
  
    Thanks @marcaurele that's a good catch! Can you push -f and see why Travis failed, if your fix works let's reenable this test! Also, can you edit the PR and send it for 4.9?


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack issue #2027: Activate NioTest following changes in CLOUDSTACK-934...

Posted by rhtyd <gi...@git.apache.org>.
Github user rhtyd commented on the issue:

    https://github.com/apache/cloudstack/pull/2027
  
    @marcaurele the test makes use of threads to run various clients and server instances and is known to consume ports for the same, for these reasons it might fail in some test/build environments. If you look at the git history on this test file and on the pom.xml, you'll find that this test had been disabled in the past (before PR 1493) due to these issues. The test is known to fail intermittently in CI environments such as Jenkins and Travis, which is why I added to the ignored list of test with one of the PRs.
    
    On my workstation, I've been consistently able to run and pass it, it is likely an environment issue in your laptop if this is failing inconsistently.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] cloudstack issue #2027: Activate NioTest following changes in CLOUDSTACK-934...

Posted by marcaurele <gi...@git.apache.org>.
Github user marcaurele commented on the issue:

    https://github.com/apache/cloudstack/pull/2027
  
    @rhtyd the `NioTest` result is not consistent on my laptop and fails from time to time.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---