You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@qpid.apache.org by "Cliff Jansen (JIRA)" <qp...@incubator.apache.org> on 2010/02/18 00:31:29 UTC

[jira] Created: (QPID-2410) perftest hang in SSL on Windows with large buffers

perftest hang in SSL on Windows with large buffers
--------------------------------------------------

                 Key: QPID-2410
                 URL: https://issues.apache.org/jira/browse/QPID-2410
             Project: Qpid
          Issue Type: Bug
          Components: C++ Client
    Affects Versions: 0.7
         Environment: Windows client, Linux broker
            Reporter: Cliff Jansen


The following command:

  perftest --count 1 --size 102400 -P ssl --port 5671 --broker linuxhost --username testuser --password secret --mechanism PLAIN

hangs on a Windows client.  Reducing the message body size to 1024 bytes makes the hang go away, as does turning off SSL.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org


[jira] Commented: (QPID-2410) perftest hang in SSL on Windows with large buffers

Posted by "Steve Huston (JIRA)" <qp...@incubator.apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-2410?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12835463#action_12835463 ] 

Steve Huston commented on QPID-2410:
------------------------------------

This is happening because the max frame size negotiated on the AMQP session is 64K but the max segment size reported from SSL is 16K; when the framing layer asks for send buffers, the SSL layer keeps handing back 16K  buffers, and the framing layer keeps throwing them away and asking for another, ad infinitum.

Either the SSL layer needs to break buffers up, or the SSL size needs to be taken into account when negotiating the AMQP max frame size. I suspect the latter, but am open to opinions while I research how the frame size is negotiated.

> perftest hang in SSL on Windows with large buffers
> --------------------------------------------------
>
>                 Key: QPID-2410
>                 URL: https://issues.apache.org/jira/browse/QPID-2410
>             Project: Qpid
>          Issue Type: Bug
>          Components: C++ Client
>    Affects Versions: 0.7
>         Environment: Windows client, Linux broker
>            Reporter: Cliff Jansen
>            Assignee: Steve Huston
>
> The following command:
>   perftest --count 1 --size 102400 -P ssl --port 5671 --broker linuxhost --username testuser --password secret --mechanism PLAIN
> hangs on a Windows client.  Reducing the message body size to 1024 bytes makes the hang go away, as does turning off SSL.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org


[jira] Assigned: (QPID-2410) perftest hang in SSL on Windows with large buffers

Posted by "Steve Huston (JIRA)" <qp...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/QPID-2410?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Steve Huston reassigned QPID-2410:
----------------------------------

    Assignee: Steve Huston

> perftest hang in SSL on Windows with large buffers
> --------------------------------------------------
>
>                 Key: QPID-2410
>                 URL: https://issues.apache.org/jira/browse/QPID-2410
>             Project: Qpid
>          Issue Type: Bug
>          Components: C++ Client
>    Affects Versions: 0.7
>         Environment: Windows client, Linux broker
>            Reporter: Cliff Jansen
>            Assignee: Steve Huston
>
> The following command:
>   perftest --count 1 --size 102400 -P ssl --port 5671 --broker linuxhost --username testuser --password secret --mechanism PLAIN
> hangs on a Windows client.  Reducing the message body size to 1024 bytes makes the hang go away, as does turning off SSL.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org


[jira] Commented: (QPID-2410) perftest hang in SSL on Windows with large buffers

Posted by "Steve Huston (JIRA)" <qp...@incubator.apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-2410?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12836758#action_12836758 ] 

Steve Huston commented on QPID-2410:
------------------------------------

Thanks for checking into this, Andrew.

Qpid can fragment AMQP messages to fit - the 102400 message size works over non-SSL TCP on Windows.

You're right that I could offer 64K buffers to framing and then chop them up on the way out SSL (that's what NSS is doing, effectively, as the Windows SSL code can deal with large buffers coming in). However, it would be better performing if we could take the effective segment size and configure the max AMQP frame size to fit in it. As long as it's not less than 4K, it's valid AMQP to do so. But right now there's no feedback from the transport when negotiating the max frame size in AMQP. However, by the time it's time to tune the AMQP connection, the transport connection is up and the optimal sizes are known, so we could use that feedback.

In a debugger session I forced the AMQP tune max frame size to 16K and things went swimmingly from there.


> perftest hang in SSL on Windows with large buffers
> --------------------------------------------------
>
>                 Key: QPID-2410
>                 URL: https://issues.apache.org/jira/browse/QPID-2410
>             Project: Qpid
>          Issue Type: Bug
>          Components: C++ Client
>    Affects Versions: 0.7
>         Environment: Windows client, Linux broker
>            Reporter: Cliff Jansen
>            Assignee: Steve Huston
>
> The following command:
>   perftest --count 1 --size 102400 -P ssl --port 5671 --broker linuxhost --username testuser --password secret --mechanism PLAIN
> hangs on a Windows client.  Reducing the message body size to 1024 bytes makes the hang go away, as does turning off SSL.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org


[jira] Commented: (QPID-2410) perftest hang in SSL on Windows with large buffers

Posted by "Andrew Stitcher (JIRA)" <qp...@incubator.apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-2410?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12836743#action_12836743 ] 

Andrew Stitcher commented on QPID-2410:
---------------------------------------

I'm puzzled that --size 102400 could even work  as that is larger than the max frame size and there is no code in qpid to fragment/unfragment frames/messages. I guess this must have changed since I last looked.

> perftest hang in SSL on Windows with large buffers
> --------------------------------------------------
>
>                 Key: QPID-2410
>                 URL: https://issues.apache.org/jira/browse/QPID-2410
>             Project: Qpid
>          Issue Type: Bug
>          Components: C++ Client
>    Affects Versions: 0.7
>         Environment: Windows client, Linux broker
>            Reporter: Cliff Jansen
>            Assignee: Steve Huston
>
> The following command:
>   perftest --count 1 --size 102400 -P ssl --port 5671 --broker linuxhost --username testuser --password secret --mechanism PLAIN
> hangs on a Windows client.  Reducing the message body size to 1024 bytes makes the hang go away, as does turning off SSL.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org


[jira] Issue Comment Edited: (QPID-2410) perftest hang in SSL on Windows with large buffers

Posted by "Andrew Stitcher (JIRA)" <qp...@incubator.apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-2410?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12836744#action_12836744 ] 

Andrew Stitcher edited comment on QPID-2410 at 2/22/10 5:41 PM:
----------------------------------------------------------------

I think the SSL layer may need to patch together multiple SSL buffers to get (up to) 64k buffers as otherwise messages larger than 16k can't be sent.

This probably isn't so hard on the send side as you just keep on copying into the SSL buffers (getting new ones as necessary) until you're done.

On the receive side you need to change the logic when buffers are returned with data still in them so that subsequent data gets appended even if greater than 16k.

      was (Author: astitcher):
    I think the SSL layer may need to patch together multiple SSL buffers to get (up to) 64k buffers as otherwise messages larger than 16k can't be sent.
  
> perftest hang in SSL on Windows with large buffers
> --------------------------------------------------
>
>                 Key: QPID-2410
>                 URL: https://issues.apache.org/jira/browse/QPID-2410
>             Project: Qpid
>          Issue Type: Bug
>          Components: C++ Client
>    Affects Versions: 0.7
>         Environment: Windows client, Linux broker
>            Reporter: Cliff Jansen
>            Assignee: Steve Huston
>
> The following command:
>   perftest --count 1 --size 102400 -P ssl --port 5671 --broker linuxhost --username testuser --password secret --mechanism PLAIN
> hangs on a Windows client.  Reducing the message body size to 1024 bytes makes the hang go away, as does turning off SSL.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org


[jira] Commented: (QPID-2410) perftest hang in SSL on Windows with large buffers

Posted by "Andrew Stitcher (JIRA)" <qp...@incubator.apache.org>.
    [ https://issues.apache.org/jira/browse/QPID-2410?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12836744#action_12836744 ] 

Andrew Stitcher commented on QPID-2410:
---------------------------------------

I think the SSL layer may need to patch together multiple SSL buffers to get (up to) 64k buffers as otherwise messages larger than 16k can't be sent.

> perftest hang in SSL on Windows with large buffers
> --------------------------------------------------
>
>                 Key: QPID-2410
>                 URL: https://issues.apache.org/jira/browse/QPID-2410
>             Project: Qpid
>          Issue Type: Bug
>          Components: C++ Client
>    Affects Versions: 0.7
>         Environment: Windows client, Linux broker
>            Reporter: Cliff Jansen
>            Assignee: Steve Huston
>
> The following command:
>   perftest --count 1 --size 102400 -P ssl --port 5671 --broker linuxhost --username testuser --password secret --mechanism PLAIN
> hangs on a Windows client.  Reducing the message body size to 1024 bytes makes the hang go away, as does turning off SSL.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project:      http://qpid.apache.org
Use/Interact: mailto:dev-subscribe@qpid.apache.org