You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by "Jukka Zitting (JIRA)" <ji...@apache.org> on 2012/07/12 13:45:38 UTC

[jira] [Created] (JCR-3385) DbClusterTest fails when port is already in use

Jukka Zitting created JCR-3385:
----------------------------------

             Summary: DbClusterTest fails when port is already in use
                 Key: JCR-3385
                 URL: https://issues.apache.org/jira/browse/JCR-3385
             Project: Jackrabbit Content Repository
          Issue Type: Bug
          Components: clustering, jackrabbit-core
    Affects Versions: 2.5
            Reporter: Jukka Zitting
            Priority: Minor


The DbClusterTest and DbClusterTestJCR3162 classes use hard-coded TCP port numbes 9001 and 9002 which make the tests fail whenever there already is some process listening on those ports.

It would be better if the classes automatically looked for unused ports for the tests.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (JCR-3385) DbClusterTest fails when port is already in use

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JCR-3385?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13412813#comment-13412813 ] 

Jukka Zitting commented on JCR-3385:
------------------------------------

> The problem is that the ports are also hardcoded in the repository-h2.xml file. 

My patch uses variable expansion in the config file to get around that problem.

> Alternative patch using an embedded database - a bit less "real world" but results in simpler test cases

Sounds good too, +1.
                
> DbClusterTest fails when port is already in use
> -----------------------------------------------
>
>                 Key: JCR-3385
>                 URL: https://issues.apache.org/jira/browse/JCR-3385
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: clustering, jackrabbit-core
>    Affects Versions: 2.5
>            Reporter: Jukka Zitting
>            Assignee: Thomas Mueller
>            Priority: Minor
>         Attachments: 0001-JCR-3385-DbClusterTest-fails-when-port-is-already-in.patch, JCR-3385-embedded-shared-db.patch
>
>
> The DbClusterTest and DbClusterTestJCR3162 classes use hard-coded TCP port numbes 9001 and 9002 which make the tests fail whenever there already is some process listening on those ports.
> It would be better if the classes automatically looked for unused ports for the tests.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Assigned] (JCR-3385) DbClusterTest fails when port is already in use

Posted by "Thomas Mueller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-3385?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thomas Mueller reassigned JCR-3385:
-----------------------------------

    Assignee: Thomas Mueller
    
> DbClusterTest fails when port is already in use
> -----------------------------------------------
>
>                 Key: JCR-3385
>                 URL: https://issues.apache.org/jira/browse/JCR-3385
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: clustering, jackrabbit-core
>    Affects Versions: 2.5
>            Reporter: Jukka Zitting
>            Assignee: Thomas Mueller
>            Priority: Minor
>
> The DbClusterTest and DbClusterTestJCR3162 classes use hard-coded TCP port numbes 9001 and 9002 which make the tests fail whenever there already is some process listening on those ports.
> It would be better if the classes automatically looked for unused ports for the tests.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (JCR-3385) DbClusterTest fails when port is already in use

Posted by "Alex Parvulescu (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-3385?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Alex Parvulescu updated JCR-3385:
---------------------------------

    Fix Version/s: 2.5.1
    
> DbClusterTest fails when port is already in use
> -----------------------------------------------
>
>                 Key: JCR-3385
>                 URL: https://issues.apache.org/jira/browse/JCR-3385
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: clustering, jackrabbit-core
>    Affects Versions: 2.5
>            Reporter: Jukka Zitting
>            Assignee: Thomas Mueller
>            Priority: Minor
>             Fix For: 2.5.1
>
>         Attachments: 0001-JCR-3385-DbClusterTest-fails-when-port-is-already-in.patch, JCR-3385-embedded-shared-db.patch
>
>
> The DbClusterTest and DbClusterTestJCR3162 classes use hard-coded TCP port numbes 9001 and 9002 which make the tests fail whenever there already is some process listening on those ports.
> It would be better if the classes automatically looked for unused ports for the tests.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (JCR-3385) DbClusterTest fails when port is already in use

Posted by "Thomas Mueller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-3385?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thomas Mueller updated JCR-3385:
--------------------------------

    Attachment: JCR-3385-embedded-shared-db.patch

Alternative patch using an embedded database - a bit less "real world" but results in simpler test cases
                
> DbClusterTest fails when port is already in use
> -----------------------------------------------
>
>                 Key: JCR-3385
>                 URL: https://issues.apache.org/jira/browse/JCR-3385
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: clustering, jackrabbit-core
>    Affects Versions: 2.5
>            Reporter: Jukka Zitting
>            Assignee: Thomas Mueller
>            Priority: Minor
>         Attachments: 0001-JCR-3385-DbClusterTest-fails-when-port-is-already-in.patch, JCR-3385-embedded-shared-db.patch
>
>
> The DbClusterTest and DbClusterTestJCR3162 classes use hard-coded TCP port numbes 9001 and 9002 which make the tests fail whenever there already is some process listening on those ports.
> It would be better if the classes automatically looked for unused ports for the tests.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Resolved] (JCR-3385) DbClusterTest fails when port is already in use

Posted by "Thomas Mueller (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-3385?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thomas Mueller resolved JCR-3385.
---------------------------------

    Resolution: Fixed

I have committed my patch now - not because it's better thank Jukkas patch, but because I hope the tests will be easier to understand and maintain in the future.

Revision 1360692
                
> DbClusterTest fails when port is already in use
> -----------------------------------------------
>
>                 Key: JCR-3385
>                 URL: https://issues.apache.org/jira/browse/JCR-3385
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: clustering, jackrabbit-core
>    Affects Versions: 2.5
>            Reporter: Jukka Zitting
>            Assignee: Thomas Mueller
>            Priority: Minor
>         Attachments: 0001-JCR-3385-DbClusterTest-fails-when-port-is-already-in.patch, JCR-3385-embedded-shared-db.patch
>
>
> The DbClusterTest and DbClusterTestJCR3162 classes use hard-coded TCP port numbes 9001 and 9002 which make the tests fail whenever there already is some process listening on those ports.
> It would be better if the classes automatically looked for unused ports for the tests.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Commented] (JCR-3385) DbClusterTest fails when port is already in use

Posted by "Thomas Mueller (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/JCR-3385?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13412775#comment-13412775 ] 

Thomas Mueller commented on JCR-3385:
-------------------------------------

The problem is that the ports are also hardcoded in the repository-h2.xml file.

The easiest solution is probably to use a non-clustered, embedded database stored in the parent directory if the cluster nodes.
                
> DbClusterTest fails when port is already in use
> -----------------------------------------------
>
>                 Key: JCR-3385
>                 URL: https://issues.apache.org/jira/browse/JCR-3385
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: clustering, jackrabbit-core
>    Affects Versions: 2.5
>            Reporter: Jukka Zitting
>            Assignee: Thomas Mueller
>            Priority: Minor
>         Attachments: 0001-JCR-3385-DbClusterTest-fails-when-port-is-already-in.patch
>
>
> The DbClusterTest and DbClusterTestJCR3162 classes use hard-coded TCP port numbes 9001 and 9002 which make the tests fail whenever there already is some process listening on those ports.
> It would be better if the classes automatically looked for unused ports for the tests.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

[jira] [Updated] (JCR-3385) DbClusterTest fails when port is already in use

Posted by "Jukka Zitting (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/JCR-3385?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Jukka Zitting updated JCR-3385:
-------------------------------

    Attachment: 0001-JCR-3385-DbClusterTest-fails-when-port-is-already-in.patch

The attached patch seems to solve this problem.
                
> DbClusterTest fails when port is already in use
> -----------------------------------------------
>
>                 Key: JCR-3385
>                 URL: https://issues.apache.org/jira/browse/JCR-3385
>             Project: Jackrabbit Content Repository
>          Issue Type: Bug
>          Components: clustering, jackrabbit-core
>    Affects Versions: 2.5
>            Reporter: Jukka Zitting
>            Assignee: Thomas Mueller
>            Priority: Minor
>         Attachments: 0001-JCR-3385-DbClusterTest-fails-when-port-is-already-in.patch
>
>
> The DbClusterTest and DbClusterTestJCR3162 classes use hard-coded TCP port numbes 9001 and 9002 which make the tests fail whenever there already is some process listening on those ports.
> It would be better if the classes automatically looked for unused ports for the tests.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira