Bug 725998 - Windows C++/.NET client sometimes does not inform about exceptions on stderr
Summary: Windows C++/.NET client sometimes does not inform about exceptions on stderr
Keywords:
Status: NEW
Alias: None
Product: Red Hat Enterprise MRG
Classification: Red Hat
Component: qpid-sdk
Version: 2.0
Hardware: Unspecified
OS: Windows
low
low
Target Milestone: ---
: ---
Assignee: messaging-bugs
QA Contact: MRG Quality Engineering
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-07-27 09:42 UTC by Petra Svobodová
Modified: 2021-10-01 04:41 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed:
Target Upstream Version:


Attachments (Terms of Use)

Description Petra Svobodová 2011-07-27 09:42:03 UTC
Description of problem:

If an exception caused by failed authentication on a broker occurs the std error is in some cases empty; see the Windows Command line transcriptions bellow:

Correct output:
---------------
C:\>C:\qpid\bin\csharp.example.spout.exe --broker dh
cp-lab-187.englab.brq.redhat.com:5672 --content "HI" --connection-options {usern
ame:guestY,password:guestY,sasl-mechanism:PLAIN} --count 1 "yy;{create:sender,de
lete:receiver}"
2011-07-26 10:23:54 warning Broker closed connection: 320, connection-forced: Au
thentication failed
Exception Org.Apache.Qpid.Messaging.QpidException: Failed to connect (reconnect
disabled)
   at Org.Apache.Qpid.Messaging.Connection.Open()
   at Org.Apache.Qpid.Messaging.Examples.Spout.Main(String[] args) in c:\qpid\do
tnet_examples\examples\csharp.example.spout\csharp.example.spout.cs:line 73.

Incorrect output with empty stderr:
-----------------------------------
C:\>C:\qpid\bin\csharp.example.spout.exe --broker dh
cp-lab-187.englab.brq.redhat.com:5672 --content "HI" --connection-options {usern
ame:guestY,password:guestY,sasl-mechanism:PLAIN} --count 1 "yy;{create:sender,de
lete:receiver}"
Exception Org.Apache.Qpid.Messaging.QpidException: Failed to connect (reconnect
disabled)
   at Org.Apache.Qpid.Messaging.Connection.Open()
   at Org.Apache.Qpid.Messaging.Examples.Spout.Main(String[] args) in c:\qpid\do
tnet_examples\examples\csharp.example.spout\csharp.example.spout.cs:line 73.


Version-Release number of selected component (if applicable):
qpid-cpp-x86-2.0.0.7
Rhel5-1.3.3 and Rhel6-2.0
 

How reproducible:
10 - 30 %


Steps to Reproduce:
1. Set authentication request in the broker configuration file.
2. Restart the qpidd service on the broker.
3. Run the "spout" command in loop: C:\qpid\bin\csharp.example.spout.exe --broker dh
cp-lab-187.englab.brq.redhat.com:5672 --content "HI" --connection-options {usern
ame:guestY,password:guestY,sasl-mechanism:PLAIN} --count 1 "yy;{create:sender,de
lete:receiver}"
  

Actual results:
The std error is sometimes empty.


Expected results:
The std error should contain a message about the occurred exception.

Comment 1 Justin Ross 2011-11-09 19:36:12 UTC
Chuck, comments?

Comment 2 Chuck Rolke 2011-11-09 20:18:37 UTC
This looks like a race condition between the message emitted to stderr by 
the qpid C++ library code (2011-07-26 10:23:54 warning Broker closed connection: 
320, connection-forced:Authentication failed) and the text printed to stdout by
the .NET application (Exception Org.Apache.Qpid.Messaging.QpidException...).

The problem still needs more investigation.


Note You need to log in before you can comment on or make changes to this bug.