[jira] [Commented] (QPID-6197) qpid.messaging does not support unicode for username

2015-01-12 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-6197?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14273636#comment-14273636
 ] 

ASF subversion and git services commented on QPID-6197:
---

Commit 1651102 from [~eallen] in branch 'qpid/trunk'
[ https://svn.apache.org/r1651102 ]

QPID-6197: Allow unicode values in connection response field

 qpid.messaging does not support unicode for username
 

 Key: QPID-6197
 URL: https://issues.apache.org/jira/browse/QPID-6197
 Project: Qpid
  Issue Type: Bug
  Components: Python Client
Affects Versions: 0.26
Reporter: Brian Bouterse
Assignee: Ernest Allen
Priority: Minor
 Attachments: bz1158558.patch


 When using qpid.messaging I cannot use unicode in the connection objects.
 Here is a reproducer snippet:
  from qpid.messaging.endpoints import Connection
  opts = {'username': u'guest', 'sasl_mechanisms': 'ANONYMOUS', 'host': 
  '127.0.0.1', 'timeout': 4, 'password': '', 'port': 5672, 'transport': 
  'tcp'}
  Connection.establish(**opts)
 Traceback (most recent call last):
   File stdin, line 1, in module
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 68, in establish
 conn.open(timeout=timeout)
   File string, line 6, in open
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 268, in open
 self.attach(timeout=timeout)
   File string, line 6, in attach
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 286, in attach
 if not self._ewait(lambda: self._transport_connected and not 
 self._unlinked(), timeout=timeout):
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 219, in _ewait
 self.check_error()
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 212, in check_error
 raise e
 qpid.messaging.exceptions.InternalError: Traceback (most recent call last):
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 652, 
 in write
 op.dispatch(self)
   File /usr/lib/python2.7/site-packages/qpid/ops.py, line 84, in dispatch
 getattr(target, handler)(self, *args)
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 713, 
 in do_connection_start
 mechanism=mech, response=initial))
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 684, 
 in write_op
 self._op_enc.write(op)
   File /usr/lib/python2.7/site-packages/qpid/framing.py, line 218, in write
 enc = self.encode_compound(op)
   File /usr/lib/python2.7/site-packages/qpid/framing.py, line 244, in 
 encode_compound
 sc.write_compound(op)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 327, in 
 write_compound
 sc.write_fields(op)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 365, in 
 write_fields
 enc(value)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 229, in 
 write_vbin32
 self.write(b)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 401, in write
 self.encoded += s
 UnicodeDecodeError: 'ascii' codec can't decode byte 0x92 in position 7: 
 ordinal not in range(128)
 If you change username from u'guest' to 'guest' it works. I tested the other 
 strings referenced in the above dictionary and no other string besides 
 username being unicode caused a traceback.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Updated] (QPID-6197) qpid.messaging does not support unicode for username

2015-01-12 Thread Ernest Allen (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6197?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ernest Allen updated QPID-6197:
---
Fix Version/s: 0.31

 qpid.messaging does not support unicode for username
 

 Key: QPID-6197
 URL: https://issues.apache.org/jira/browse/QPID-6197
 Project: Qpid
  Issue Type: Bug
  Components: Python Client
Affects Versions: 0.26
Reporter: Brian Bouterse
Assignee: Ernest Allen
Priority: Minor
 Fix For: 0.31

 Attachments: bz1158558.patch


 When using qpid.messaging I cannot use unicode in the connection objects.
 Here is a reproducer snippet:
  from qpid.messaging.endpoints import Connection
  opts = {'username': u'guest', 'sasl_mechanisms': 'ANONYMOUS', 'host': 
  '127.0.0.1', 'timeout': 4, 'password': '', 'port': 5672, 'transport': 
  'tcp'}
  Connection.establish(**opts)
 Traceback (most recent call last):
   File stdin, line 1, in module
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 68, in establish
 conn.open(timeout=timeout)
   File string, line 6, in open
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 268, in open
 self.attach(timeout=timeout)
   File string, line 6, in attach
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 286, in attach
 if not self._ewait(lambda: self._transport_connected and not 
 self._unlinked(), timeout=timeout):
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 219, in _ewait
 self.check_error()
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 212, in check_error
 raise e
 qpid.messaging.exceptions.InternalError: Traceback (most recent call last):
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 652, 
 in write
 op.dispatch(self)
   File /usr/lib/python2.7/site-packages/qpid/ops.py, line 84, in dispatch
 getattr(target, handler)(self, *args)
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 713, 
 in do_connection_start
 mechanism=mech, response=initial))
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 684, 
 in write_op
 self._op_enc.write(op)
   File /usr/lib/python2.7/site-packages/qpid/framing.py, line 218, in write
 enc = self.encode_compound(op)
   File /usr/lib/python2.7/site-packages/qpid/framing.py, line 244, in 
 encode_compound
 sc.write_compound(op)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 327, in 
 write_compound
 sc.write_fields(op)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 365, in 
 write_fields
 enc(value)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 229, in 
 write_vbin32
 self.write(b)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 401, in write
 self.encoded += s
 UnicodeDecodeError: 'ascii' codec can't decode byte 0x92 in position 7: 
 ordinal not in range(128)
 If you change username from u'guest' to 'guest' it works. I tested the other 
 strings referenced in the above dictionary and no other string besides 
 username being unicode caused a traceback.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Resolved] (QPID-6197) qpid.messaging does not support unicode for username

2015-01-12 Thread Ernest Allen (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6197?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ernest Allen resolved QPID-6197.

Resolution: Fixed

 qpid.messaging does not support unicode for username
 

 Key: QPID-6197
 URL: https://issues.apache.org/jira/browse/QPID-6197
 Project: Qpid
  Issue Type: Bug
  Components: Python Client
Affects Versions: 0.26
Reporter: Brian Bouterse
Assignee: Ernest Allen
Priority: Minor
 Fix For: 0.31

 Attachments: bz1158558.patch


 When using qpid.messaging I cannot use unicode in the connection objects.
 Here is a reproducer snippet:
  from qpid.messaging.endpoints import Connection
  opts = {'username': u'guest', 'sasl_mechanisms': 'ANONYMOUS', 'host': 
  '127.0.0.1', 'timeout': 4, 'password': '', 'port': 5672, 'transport': 
  'tcp'}
  Connection.establish(**opts)
 Traceback (most recent call last):
   File stdin, line 1, in module
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 68, in establish
 conn.open(timeout=timeout)
   File string, line 6, in open
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 268, in open
 self.attach(timeout=timeout)
   File string, line 6, in attach
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 286, in attach
 if not self._ewait(lambda: self._transport_connected and not 
 self._unlinked(), timeout=timeout):
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 219, in _ewait
 self.check_error()
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 212, in check_error
 raise e
 qpid.messaging.exceptions.InternalError: Traceback (most recent call last):
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 652, 
 in write
 op.dispatch(self)
   File /usr/lib/python2.7/site-packages/qpid/ops.py, line 84, in dispatch
 getattr(target, handler)(self, *args)
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 713, 
 in do_connection_start
 mechanism=mech, response=initial))
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 684, 
 in write_op
 self._op_enc.write(op)
   File /usr/lib/python2.7/site-packages/qpid/framing.py, line 218, in write
 enc = self.encode_compound(op)
   File /usr/lib/python2.7/site-packages/qpid/framing.py, line 244, in 
 encode_compound
 sc.write_compound(op)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 327, in 
 write_compound
 sc.write_fields(op)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 365, in 
 write_fields
 enc(value)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 229, in 
 write_vbin32
 self.write(b)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 401, in write
 self.encoded += s
 UnicodeDecodeError: 'ascii' codec can't decode byte 0x92 in position 7: 
 ordinal not in range(128)
 If you change username from u'guest' to 'guest' it works. I tested the other 
 strings referenced in the above dictionary and no other string besides 
 username being unicode caused a traceback.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Commented] (QPID-6197) qpid.messaging does not support unicode for username

2015-01-12 Thread Ernest Allen (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-6197?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14273637#comment-14273637
 ] 

Ernest Allen commented on QPID-6197:


Patch checked in: Committed revision 1651102

 qpid.messaging does not support unicode for username
 

 Key: QPID-6197
 URL: https://issues.apache.org/jira/browse/QPID-6197
 Project: Qpid
  Issue Type: Bug
  Components: Python Client
Affects Versions: 0.26
Reporter: Brian Bouterse
Assignee: Ernest Allen
Priority: Minor
 Fix For: 0.31

 Attachments: bz1158558.patch


 When using qpid.messaging I cannot use unicode in the connection objects.
 Here is a reproducer snippet:
  from qpid.messaging.endpoints import Connection
  opts = {'username': u'guest', 'sasl_mechanisms': 'ANONYMOUS', 'host': 
  '127.0.0.1', 'timeout': 4, 'password': '', 'port': 5672, 'transport': 
  'tcp'}
  Connection.establish(**opts)
 Traceback (most recent call last):
   File stdin, line 1, in module
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 68, in establish
 conn.open(timeout=timeout)
   File string, line 6, in open
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 268, in open
 self.attach(timeout=timeout)
   File string, line 6, in attach
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 286, in attach
 if not self._ewait(lambda: self._transport_connected and not 
 self._unlinked(), timeout=timeout):
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 219, in _ewait
 self.check_error()
   File /usr/lib/python2.7/site-packages/qpid/messaging/endpoints.py, line 
 212, in check_error
 raise e
 qpid.messaging.exceptions.InternalError: Traceback (most recent call last):
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 652, 
 in write
 op.dispatch(self)
   File /usr/lib/python2.7/site-packages/qpid/ops.py, line 84, in dispatch
 getattr(target, handler)(self, *args)
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 713, 
 in do_connection_start
 mechanism=mech, response=initial))
   File /usr/lib/python2.7/site-packages/qpid/messaging/driver.py, line 684, 
 in write_op
 self._op_enc.write(op)
   File /usr/lib/python2.7/site-packages/qpid/framing.py, line 218, in write
 enc = self.encode_compound(op)
   File /usr/lib/python2.7/site-packages/qpid/framing.py, line 244, in 
 encode_compound
 sc.write_compound(op)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 327, in 
 write_compound
 sc.write_fields(op)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 365, in 
 write_fields
 enc(value)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 229, in 
 write_vbin32
 self.write(b)
   File /usr/lib/python2.7/site-packages/qpid/codec010.py, line 401, in write
 self.encoded += s
 UnicodeDecodeError: 'ascii' codec can't decode byte 0x92 in position 7: 
 ordinal not in range(128)
 If you change username from u'guest' to 'guest' it works. I tested the other 
 strings referenced in the above dictionary and no other string besides 
 username being unicode caused a traceback.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Commented] (QPID-6305) Failed Tests

2015-01-12 Thread Eddie Davis (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-6305?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14273678#comment-14273678
 ] 

Eddie Davis commented on QPID-6305:
---

ctest -VV   results: 

UpdateCTestConfiguration  from 
:/home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/BLD/DartConfiguration.tcl
Parse Config 
file:/home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/BLD/DartConfiguration.tcl
UpdateCTestConfiguration  from 
:/home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/BLD/DartConfiguration.tcl
Parse Config 
file:/home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/BLD/DartConfiguration.tcl
Test project /home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/BLD
Constructing a list of tests
Done constructing a list of tests
Checking test dependency graph...
Checking test dependency graph end
test 1
  Start  1: api_check_qpidtypes

1: Test command: /home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/src/check-abi 
/usr/bin/c++ 
/home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/BLD/src/libqpidtypes.so 
/home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/src/libqpidtypes-api-symbols.txt
1: Test timeout computed to be: 1500
1: Exported by library but not in spec
1: ===
1: typeinfo for qpid::types::Exception
1: typeinfo for qpid::types::InvalidConversion
1: typeinfo name for qpid::types::Exception
1: typeinfo name for qpid::types::InvalidConversion
1: vtable for qpid::types::Exception
1: vtable for qpid::types::InvalidConversion
 1/31 Test  #1: api_check_qpidtypes ..   Passed0.32 sec
test 2
  Start  2: api_check_qpidmessaging

2: Test command: /home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/src/check-abi 
/usr/bin/c++ 
/home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/BLD/src/libqpidmessaging.so 
/home/edavis/Downloads/QPID/Broker/qpid-cpp-0.30/src/libqpidmessaging-api-symbols.txt
2: Test timeout computed to be: 1500
2: Exported by library but not in spec
2: ===
2: qpid::messaging::AddressParser::AddressParser(std::string const)
2: qpid::messaging::AddressParser::parseList(std::listqpid::types::Variant, 
std::allocatorqpid::types::Variant )
2: qpid::messaging::AddressParser::parseMap(std::mapstd::string, 
qpid::types::Variant, std::lessstd::string, 
std::allocatorstd::pairstd::string const, qpid::types::Variant  )
2: qpid::messaging::AuthenticationFailure::AuthenticationFailure(std::string 
const)
2: qpid::messaging::AuthenticationFailure::~AuthenticationFailure()
2: qpid::messaging::Connection::getUrl() const
2: qpid::messaging::Connection::reconnect()
2: qpid::messaging::Connection::reconnect(std::string const)
2: qpid::messaging::ConnectionOptions::ConnectionOptions(std::mapstd::string, 
qpid::types::Variant, std::lessstd::string, 
std::allocatorstd::pairstd::string const, qpid::types::Variant   const)
2: qpid::messaging::ConnectionOptions::set(std::string const, 
qpid::types::Variant const)
2: 
qpid::messaging::FailoverUpdates::FailoverUpdates(qpid::messaging::FailoverUpdates
 const)
2: qpid::messaging::FailoverUpdates::operator=(qpid::messaging::FailoverUpdates 
const)
2: qpid::messaging::Handleqpid::messaging::ConnectionImpl::Handle()
2: qpid::messaging::Handleqpid::messaging::ConnectionImpl::isNull() const
2: qpid::messaging::Handleqpid::messaging::ConnectionImpl::isValid() const
2: qpid::messaging::Handleqpid::messaging::ConnectionImpl::operator bool() 
const
2: qpid::messaging::Handleqpid::messaging::ConnectionImpl::operator!() const
2: qpid::messaging::Handleqpid::messaging::ReceiverImpl::Handle()
2: qpid::messaging::Handleqpid::messaging::ReceiverImpl::isNull() const
2: qpid::messaging::Handleqpid::messaging::ReceiverImpl::isValid() const
2: qpid::messaging::Handleqpid::messaging::ReceiverImpl::operator bool() const
2: qpid::messaging::Handleqpid::messaging::ReceiverImpl::operator!() const
2: qpid::messaging::Handleqpid::messaging::SenderImpl::Handle()
2: qpid::messaging::Handleqpid::messaging::SenderImpl::isNull() const
2: qpid::messaging::Handleqpid::messaging::SenderImpl::isValid() const
2: qpid::messaging::Handleqpid::messaging::SenderImpl::operator bool() const
2: qpid::messaging::Handleqpid::messaging::SenderImpl::operator!() const
2: qpid::messaging::Handleqpid::messaging::SessionImpl::Handle()
2: qpid::messaging::Handleqpid::messaging::SessionImpl::isNull() const
2: qpid::messaging::Handleqpid::messaging::SessionImpl::isValid() const
2: qpid::messaging::Handleqpid::messaging::SessionImpl::operator bool() const
2: qpid::messaging::Handleqpid::messaging::SessionImpl::operator!() const
2: qpid::messaging::Message::setProperties(std::mapstd::string, 
qpid::types::Variant, std::lessstd::string, 
std::allocatorstd::pairstd::string const, qpid::types::Variant   const)
2: qpid::messaging::MessageImpl::getBytes() const
2: qpid::messaging::MessageImpl::getContent() const
2: qpid::messaging::MessageImpl::getContentType() const
2: 

[jira] [Commented] (QPID-6305) Failed Tests

2015-01-12 Thread Eddie Davis (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-6305?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14273682#comment-14273682
 ] 

Eddie Davis commented on QPID-6305:
---

Where is the cmake log?

 Failed Tests
 

 Key: QPID-6305
 URL: https://issues.apache.org/jira/browse/QPID-6305
 Project: Qpid
  Issue Type: Test
  Components: C++ Broker
Affects Versions: 0.30
 Environment: Redhat Enterprise linux 6
Reporter: Eddie Davis

 Downloaded latest 0.30  followed build instructions and everything seemed 
 to build fine. So I ran the tests and this is the result that I got. 
 The following tests FAILED:
 3 - unit_test (Failed)
11 - qpid-client-test (Failed)
12 - quick_perftest (Failed)
13 - quick_topictest (Failed)
14 - quick_txtest (Failed)
15 - quick_txtest2 (Failed)
16 - msg_group_tests (Failed)
17 - run_header_test (Failed)
18 - python_tests (Failed)
20 - ha_tests (Failed)
21 - qpidd_qmfv2_tests (Failed)
26 - queue_flow_limit_tests (Failed)
 How do I resolve these issues? 
 Cannot seem to find a document on the tests run?
 Hopefully, this is a quick fix. 
 thanks,
 Ed. 



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



Re: New Defects reported by Coverity Scan for Apache-Qpid

2015-01-12 Thread Gordon Sim

On 01/11/2015 10:06 PM, scan-ad...@coverity.com wrote:

Please find the latest report on new defect(s) introduced to Apache-Qpid found 
with Coverity Scan.

1 new defect(s) introduced to Apache-Qpid found with Coverity Scan.
7 defect(s), reported by Coverity Scan earlier, were marked fixed in the recent 
build analyzed by Coverity Scan.

New defect(s) Reported-by: Coverity Scan
Showing 1 of 1 defect(s)


** CID 1262251:  Double free  (USE_AFTER_FREE)



*** CID 1262251:  Double free  (USE_AFTER_FREE)
/qpidbuilds/trunk/qpid/cpp/src/qpid/broker/LossyLvq.h: 34 in 
qpid::broker::LossyLvq::~LossyLvq()()
28 namespace broker {
29 class MessageMap;
30
31 /**
32  * Combination of LossyQueue and Lvq behaviours.
33  */

 CID 1262251:  Double free  (USE_AFTER_FREE)
 Calling qpid::broker::LossyQueue::~LossyQueue() frees pointer 
this-externalQueueStore which has already been freed.


I think coverity is wrong here. It seems to believe that the destructor 
for PersistableQueue will be called twice for the same instance. However 
this is not my understanding of the way c++ works or the behaviour I see 
in practice.


Lvq and LossyQueue use virtual inheritance when extending the Queue so 
the LossyLvq that inherits from each of them will still have one 
instance of Queue as its superclass, and the constructor and destructor 
of Queue will be called only once.


Am I wrong in any of this? Is there a platform where the destructor for 
PersistableQueue is called twice when freeing a given instance of LossyLvq?



34 class LossyLvq : public Lvq, public LossyQueue
35 {
36   public:
37 LossyLvq(const std::string, std::auto_ptrMessageMap, const 
QueueSettings, MessageStore* const, management::Manageable*, Broker*);
38 };
39 }} // namespace qpid::broker
40



-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Updated] (DISPATCH-96) Installing qpid_dispatch_site and qpid_dispatch/management does not work with make DESTDIR

2015-01-12 Thread Darryl L. Pierce (JIRA)

 [ 
https://issues.apache.org/jira/browse/DISPATCH-96?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Darryl L. Pierce updated DISPATCH-96:
-
Attachment: 0001-DISPATCH-96-Fix-installing-the-qpid_dispatch_site.py.patch

This patch adds a new cached variable named USE_SETUP_PY.

The default behavior is for the install to behave as it did before the change, 
using setup.py to do the install (USE_SETUP_PY=1).

When creating the CMake build environment, the user can override this 
(-DUSE_SETUP_PY=0), which will cause CMake to install the Python bits install 
to the sitelib directory.

 Installing qpid_dispatch_site and qpid_dispatch/management does not work with 
 make DESTDIR
 

 Key: DISPATCH-96
 URL: https://issues.apache.org/jira/browse/DISPATCH-96
 Project: Qpid Dispatch
  Issue Type: New Feature
  Components: Container
Affects Versions: 0.3
Reporter: Darryl L. Pierce
Assignee: Darryl L. Pierce
Priority: Minor
 Attachments: 
 0001-DISPATCH-96-Fix-installing-the-qpid_dispatch_site.py.patch


 Currently, when installing qpid_dispatch_site and qpid_dispatch.management, 
 CMake shells out to a buildtools script to do the work. However, in some 
 environments (such as when using DESTDIR to constrain installs) this doesn't 
 work.
 We need a solution that honors the DESTDIR constraint at install time.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Created] (DISPATCH-96) Installing qpid_dispatch_site and qpid_dispatch/management does not work with make DESTDIR

2015-01-12 Thread Darryl L. Pierce (JIRA)
Darryl L. Pierce created DISPATCH-96:


 Summary: Installing qpid_dispatch_site and 
qpid_dispatch/management does not work with make DESTDIR
 Key: DISPATCH-96
 URL: https://issues.apache.org/jira/browse/DISPATCH-96
 Project: Qpid Dispatch
  Issue Type: New Feature
  Components: Container
Affects Versions: 0.3
Reporter: Darryl L. Pierce
Assignee: Darryl L. Pierce
Priority: Minor


Currently, when installing qpid_dispatch_site and qpid_dispatch.management, 
CMake shells out to a buildtools script to do the work. However, in some 
environments (such as when using DESTDIR to constrain installs) this doesn't 
work.

We need a solution that honors the DESTDIR constraint at install time.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Assigned] (QPID-6308) [C++ Messaging] Server example never sends utf8 responses

2015-01-12 Thread Chuck Rolke (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6308?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Chuck Rolke reassigned QPID-6308:
-

Assignee: Chuck Rolke

 [C++ Messaging] Server example never sends utf8 responses
 -

 Key: QPID-6308
 URL: https://issues.apache.org/jira/browse/QPID-6308
 Project: Qpid
  Issue Type: Bug
  Components: C++ Client
Affects Versions: 0.30
 Environment: Qpid trunk on Fedora 19 Linux. 
 Running C++ Broker and C++ Messaging Server example.
 Amqp.Net Lite Client example
Reporter: Chuck Rolke
Assignee: Chuck Rolke

 Qpid C++ Messaging and Amqp.Net Lite have some issues interoperating.
 * Amqp.Net Lite encodes/decodes strings with binary encoding primitive 
 ** str8-utf8 0xA1
 * Qpid C++ Server decodes received str8-utf8 0xA1 strings ok but sends all 
 replies with
 ** vbin8 0xA0
 * Qpid C++ Client always sends strings as
 ** vbin8 0xA0
 Modifying the Server example to:
 {noformat}
 Message response;
 response.setContentObject( request.getContentObject() );
 sender.send(response);
 {noformat}
 preserves the str8-utf8 encoding in the response but doesn't process the 
 message.
 The server example would be improved if it generated utf8 replies to utf8 
 requests.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Updated] (DISPATCH-96) Installing qpid_dispatch_site and qpid_dispatch/management does not work with make DESTDIR

2015-01-12 Thread Ted Ross (JIRA)

 [ 
https://issues.apache.org/jira/browse/DISPATCH-96?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ted Ross updated DISPATCH-96:
-
Fix Version/s: 0.4

 Installing qpid_dispatch_site and qpid_dispatch/management does not work with 
 make DESTDIR
 

 Key: DISPATCH-96
 URL: https://issues.apache.org/jira/browse/DISPATCH-96
 Project: Qpid Dispatch
  Issue Type: New Feature
  Components: Container
Affects Versions: 0.3
Reporter: Darryl L. Pierce
Assignee: Darryl L. Pierce
Priority: Minor
 Fix For: 0.4

 Attachments: 
 0001-DISPATCH-96-Fix-installing-the-qpid_dispatch_site.py.patch


 Currently, when installing qpid_dispatch_site and qpid_dispatch.management, 
 CMake shells out to a buildtools script to do the work. However, in some 
 environments (such as when using DESTDIR to constrain installs) this doesn't 
 work.
 We need a solution that honors the DESTDIR constraint at install time.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



Review Request 29821: C++ Messaging Server example preserves request string encoding

2015-01-12 Thread Chug Rolke

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29821/
---

Review request for qpid and Gordon Sim.


Bugs: QPID-6308
https://issues.apache.org/jira/browse/QPID-6308


Repository: qpid


Description
---

The example as-is sends strings as vbin8 0xA0 binary encoding only, regardless 
of the request string format. This patch preserves the request string encoding 
scheme and uses it in the response.


Diffs
-

  trunk/qpid/cpp/examples/messaging/server.cpp 1650356 

Diff: https://reviews.apache.org/r/29821/diff/


Testing
---

Tested against Qpid C++ client and Amqp.Net Lite (utf8-only) clients.


Thanks,

Chug Rolke



Re: Review Request 29821: C++ Messaging Server example preserves request string encoding

2015-01-12 Thread Gordon Sim

---
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/29821/#review67710
---



trunk/qpid/cpp/examples/messaging/server.cpp
https://reviews.apache.org/r/29821/#comment111792

It's a shame it needs to be as ugly as this. I'd actually thought 
content-object would be interpreted as a utf8 string on the 1.0 path if no 
encoding was specified, but I see that is not yet the case.

Would also be nice to have a simpler  way of creating a variant with 
encoding.

However I'm fine with your change as is, since these are really wider 
improvements.


- Gordon Sim


On Jan. 12, 2015, 9:30 p.m., Chug Rolke wrote:
 
 ---
 This is an automatically generated e-mail. To reply, visit:
 https://reviews.apache.org/r/29821/
 ---
 
 (Updated Jan. 12, 2015, 9:30 p.m.)
 
 
 Review request for qpid and Gordon Sim.
 
 
 Bugs: QPID-6308
 https://issues.apache.org/jira/browse/QPID-6308
 
 
 Repository: qpid
 
 
 Description
 ---
 
 The example as-is sends strings as vbin8 0xA0 binary encoding only, 
 regardless of the request string format. This patch preserves the request 
 string encoding scheme and uses it in the response.
 
 
 Diffs
 -
 
   trunk/qpid/cpp/examples/messaging/server.cpp 1650356 
 
 Diff: https://reviews.apache.org/r/29821/diff/
 
 
 Testing
 ---
 
 Tested against Qpid C++ client and Amqp.Net Lite (utf8-only) clients.
 
 
 Thanks,
 
 Chug Rolke
 




[jira] [Commented] (QPID-6013) qpid-route shall warn that federation link hasn't been created

2015-01-12 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-6013?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14274281#comment-14274281
 ] 

ASF subversion and git services commented on QPID-6013:
---

Commit 1651216 from [~eallen] in branch 'qpid/trunk'
[ https://svn.apache.org/r1651216 ]

QPID-6013 qpid-route should warn when a federation link was not created 
successfully

 qpid-route shall warn that federation link hasn't been created
 --

 Key: QPID-6013
 URL: https://issues.apache.org/jira/browse/QPID-6013
 Project: Qpid
  Issue Type: Bug
  Components: Python Tools
Affects Versions: 0.22
Reporter: Ernest Allen
Priority: Minor
 Attachments: bz797073.patch


 When creating a federation route between two brokers where the underlying 
 link isn't created properly (due to networking issue or due to failed 
 authentication), qpid-route command shall warn about it. Otherwise users 
 don't know the command hasn't fully succeeded.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Assigned] (QPID-6013) qpid-route shall warn that federation link hasn't been created

2015-01-12 Thread Ernest Allen (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6013?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ernest Allen reassigned QPID-6013:
--

Assignee: Ernest Allen

 qpid-route shall warn that federation link hasn't been created
 --

 Key: QPID-6013
 URL: https://issues.apache.org/jira/browse/QPID-6013
 Project: Qpid
  Issue Type: Bug
  Components: Python Tools
Affects Versions: 0.22
Reporter: Ernest Allen
Assignee: Ernest Allen
Priority: Minor
 Fix For: 0.31

 Attachments: bz797073.patch


 When creating a federation route between two brokers where the underlying 
 link isn't created properly (due to networking issue or due to failed 
 authentication), qpid-route command shall warn about it. Otherwise users 
 don't know the command hasn't fully succeeded.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Updated] (QPID-6013) qpid-route shall warn that federation link hasn't been created

2015-01-12 Thread Ernest Allen (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6013?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ernest Allen updated QPID-6013:
---
Fix Version/s: 0.31

 qpid-route shall warn that federation link hasn't been created
 --

 Key: QPID-6013
 URL: https://issues.apache.org/jira/browse/QPID-6013
 Project: Qpid
  Issue Type: Bug
  Components: Python Tools
Affects Versions: 0.22
Reporter: Ernest Allen
Assignee: Ernest Allen
Priority: Minor
 Fix For: 0.31

 Attachments: bz797073.patch


 When creating a federation route between two brokers where the underlying 
 link isn't created properly (due to networking issue or due to failed 
 authentication), qpid-route command shall warn about it. Otherwise users 
 don't know the command hasn't fully succeeded.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Resolved] (QPID-6013) qpid-route shall warn that federation link hasn't been created

2015-01-12 Thread Ernest Allen (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6013?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ernest Allen resolved QPID-6013.

Resolution: Fixed

 qpid-route shall warn that federation link hasn't been created
 --

 Key: QPID-6013
 URL: https://issues.apache.org/jira/browse/QPID-6013
 Project: Qpid
  Issue Type: Bug
  Components: Python Tools
Affects Versions: 0.22
Reporter: Ernest Allen
Assignee: Ernest Allen
Priority: Minor
 Fix For: 0.31

 Attachments: bz797073.patch


 When creating a federation route between two brokers where the underlying 
 link isn't created properly (due to networking issue or due to failed 
 authentication), qpid-route command shall warn about it. Otherwise users 
 don't know the command hasn't fully succeeded.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Updated] (QPID-6306) [Java Broker] restrict the Broker to a single ACL provider at a time

2015-01-12 Thread Rob Godfrey (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6306?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Rob Godfrey updated QPID-6306:
--
Status: Reviewable  (was: In Progress)

 [Java Broker] restrict the Broker to a single ACL provider at a time
 

 Key: QPID-6306
 URL: https://issues.apache.org/jira/browse/QPID-6306
 Project: Qpid
  Issue Type: Improvement
  Components: Java Broker
Reporter: Rob Godfrey
Assignee: Rob Godfrey
 Fix For: 0.31


 Given the current model it only makes sense to support a single ACL provider 
 at a time, and to allow for that ACL provider to be updated to take in an 
 updated acl file without restarting the broker



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Resolved] (QPID-6253) Name the Qpid AMQP acceptor threads

2015-01-12 Thread Rob Godfrey (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6253?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Rob Godfrey resolved QPID-6253.
---
Resolution: Fixed

 Name the Qpid AMQP acceptor threads
 ---

 Key: QPID-6253
 URL: https://issues.apache.org/jira/browse/QPID-6253
 Project: Qpid
  Issue Type: Improvement
  Components: Java Broker
Reporter: Keith Wall
Priority: Trivial
 Fix For: 0.31


 To assist in problem resolution when examining log files, thread dumps and 
 the like, it would be helpful if the Java Broker named its port acceptor 
 threads.  They currently carry the default name provided by the JVM.
  



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Commented] (QPID-6309) [Java Broker] Implement Group Provider which does not require external file for groups, but instead stores in config

2015-01-12 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-6309?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=14274394#comment-14274394
 ] 

ASF subversion and git services commented on QPID-6309:
---

Commit 1651230 from [~godfrer] in branch 'qpid/trunk'
[ https://svn.apache.org/r1651230 ]

QPID-6309 : Add group provider which stores user to group mapping in config

 [Java Broker] Implement Group Provider which does not require external file 
 for groups, but instead stores in config
 

 Key: QPID-6309
 URL: https://issues.apache.org/jira/browse/QPID-6309
 Project: Qpid
  Issue Type: Improvement
  Components: Java Broker
Reporter: Rob Godfrey
Assignee: Rob Godfrey

 Currently the only group provider implemented uses an external file for the 
 mapping of users to groups.  Additionally a group provider which stores the 
 assignment in the config database should be provided



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Updated] (QPID-6263) [Java Broker] Move remaining ApplicationRegistry functionality into server.Broker class

2015-01-12 Thread Rob Godfrey (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6263?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Rob Godfrey updated QPID-6263:
--
Status: Reviewable  (was: In Progress)

 [Java Broker] Move remaining ApplicationRegistry functionality into 
 server.Broker class
 ---

 Key: QPID-6263
 URL: https://issues.apache.org/jira/browse/QPID-6263
 Project: Qpid
  Issue Type: Improvement
  Components: Java Broker
Reporter: Rob Godfrey
Assignee: Rob Godfrey
 Fix For: 0.31


 The ApplicationRegistry has been continually whittled away and there is now 
 very little remaining (none of it pertaining to being a registry of 
 applications).   The class is only now referenced from server.Broker, so 
 inline the functionality into that class.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Assigned] (QPID-6281) Child of type SessionAdapter already exists with name of 0

2015-01-12 Thread Rob Godfrey (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6281?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Rob Godfrey reassigned QPID-6281:
-

Assignee: Rob Godfrey

 Child of type SessionAdapter already exists with name of 0
 --

 Key: QPID-6281
 URL: https://issues.apache.org/jira/browse/QPID-6281
 Project: Qpid
  Issue Type: Bug
  Components: Java Broker
Affects Versions: 0.30
Reporter: Mark Soderquist
Assignee: Rob Godfrey

 We are using Mule ESB 3.5.0 with the Qpid 0.30 AMQP 1.0 JMS libraries to 
 connect to a Qpid 0.30 server and getting the following error:
 org.apache.qpid.server.model.AbstractConfiguredObject$DuplicateNameException: 
 Child of type SessionAdapter already exists with name of 0
 Following this error it appears the Qpid server immediately terminates the 
 socket:
 java.net.SocketException: Connection reset
   at java.net.SocketInputStream.read(SocketInputStream.java:196)
   at java.net.SocketInputStream.read(SocketInputStream.java:122)
   at sun.security.ssl.InputRecord.readFully(InputRecord.java:442)
   at sun.security.ssl.InputRecord.read(InputRecord.java:480)
   at sun.security.ssl.SSLSocketImpl.readRecord(SSLSocketImpl.java:927)
   at sun.security.ssl.SSLSocketImpl.readDataRecord(SSLSocketImpl.java:884)
   at sun.security.ssl.AppInputStream.read(AppInputStream.java:102)
   at java.io.InputStream.read(InputStream.java:101)
   at 
 org.apache.qpid.amqp_1_0.client.TCPTransportProvier.doRead(TCPTransportProvier.java:207)
   at 
 org.apache.qpid.amqp_1_0.client.TCPTransportProvier.access$000(TCPTransportProvier.java:43)
   at 
 org.apache.qpid.amqp_1_0.client.TCPTransportProvier$1.run(TCPTransportProvier.java:158)
   at java.lang.Thread.run(Thread.java:745)
 We don't understand if this is correct behavior that can be remedied or if it 
 is a bug.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Created] (QPID-6309) [Java Broker] Implement Group Provider which does not require external file for groups, but instead stores in config

2015-01-12 Thread Rob Godfrey (JIRA)
Rob Godfrey created QPID-6309:
-

 Summary: [Java Broker] Implement Group Provider which does not 
require external file for groups, but instead stores in config
 Key: QPID-6309
 URL: https://issues.apache.org/jira/browse/QPID-6309
 Project: Qpid
  Issue Type: Improvement
  Components: Java Broker
Reporter: Rob Godfrey
Assignee: Rob Godfrey


Currently the only group provider implemented uses an external file for the 
mapping of users to groups.  Additionally a group provider which stores the 
assignment in the config database should be provided



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



[jira] [Created] (QPID-6308) [C++ Messaging] Server example never sends utf8 responses

2015-01-12 Thread Chuck Rolke (JIRA)
Chuck Rolke created QPID-6308:
-

 Summary: [C++ Messaging] Server example never sends utf8 responses
 Key: QPID-6308
 URL: https://issues.apache.org/jira/browse/QPID-6308
 Project: Qpid
  Issue Type: Bug
  Components: C++ Client
Affects Versions: 0.30
 Environment: Qpid trunk on Fedora 19 Linux. 
Running C++ Broker and C++ Messaging Server example.
Amqp.Net Lite Client example
Reporter: Chuck Rolke


Qpid C++ Messaging and Amqp.Net Lite have some issues interoperating.

* Amqp.Net Lite encodes/decodes strings with binary encoding primitive 
** str8-utf8 0xA1

* Qpid C++ Server decodes received str8-utf8 0xA1 strings ok but sends all 
replies with
** vbin8 0xA0

* Qpid C++ Client always sends strings as
** vbin8 0xA0

Modifying the Server example to:
{noformat}
Message response;
response.setContentObject( request.getContentObject() );
sender.send(response);
{noformat}

preserves the str8-utf8 encoding in the response but doesn't process the 
message.

The server example would be improved if it generated utf8 replies to utf8 
requests.




--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



Re: New Defects reported by Coverity Scan for Apache-Qpid

2015-01-12 Thread Chuck Rolke


- Original Message -
 From: Gordon Sim g...@redhat.com
 To: dev@qpid.apache.org
 Sent: Monday, January 12, 2015 7:55:23 AM
 Subject: Re: New Defects reported by Coverity Scan for Apache-Qpid
 
 On 01/11/2015 10:06 PM, scan-ad...@coverity.com wrote:
  Please find the latest report on new defect(s) introduced to Apache-Qpid
  found with Coverity Scan.
 
  1 new defect(s) introduced to Apache-Qpid found with Coverity Scan.
  7 defect(s), reported by Coverity Scan earlier, were marked fixed in the
  recent build analyzed by Coverity Scan.
 
  New defect(s) Reported-by: Coverity Scan
  Showing 1 of 1 defect(s)
 
 
  ** CID 1262251:  Double free  (USE_AFTER_FREE)
 
 
  
  *** CID 1262251:  Double free  (USE_AFTER_FREE)
  /qpidbuilds/trunk/qpid/cpp/src/qpid/broker/LossyLvq.h: 34 in
  qpid::broker::LossyLvq::~LossyLvq()()
  28 namespace broker {
  29 class MessageMap;
  30
  31 /**
  32  * Combination of LossyQueue and Lvq behaviours.
  33  */
   CID 1262251:  Double free  (USE_AFTER_FREE)
   Calling qpid::broker::LossyQueue::~LossyQueue() frees pointer
   this-externalQueueStore which has already been freed.
 
 I think coverity is wrong here. It seems to believe that the destructor
 for PersistableQueue will be called twice for the same instance. However
 this is not my understanding of the way c++ works or the behaviour I see
 in practice.
 
 Lvq and LossyQueue use virtual inheritance when extending the Queue so
 the LossyLvq that inherits from each of them will still have one
 instance of Queue as its superclass, and the constructor and destructor
 of Queue will be called only once.
 
 Am I wrong in any of this? Is there a platform where the destructor for
 PersistableQueue is called twice when freeing a given instance of LossyLvq?
 
  34 class LossyLvq : public Lvq, public LossyQueue
  35 {
  36   public:
  37 LossyLvq(const std::string, std::auto_ptrMessageMap, const
  QueueSettings, MessageStore* const, management::Manageable*, Broker*);
  38 };
  39 }} // namespace qpid::broker
  40
 
 
 -
 To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
 For additional commands, e-mail: dev-h...@qpid.apache.org
 
 

Visual Studio 2010 x64 generates five new warnings compiling LossyLvq code. 
The code may be correct and the compiler is known to warn on correct code.
That said, if the code could be reorganized to avoid the warnings maybe
Coverity would stop complaining as well.

3d:\users\crolke\git\rh-qpid\qpid\cpp\src\qpid\broker\LossyLvq.h(38): 
  warning C4250: 'qpid::broker::LossyLvq' : 
inherits 'qpid::broker::Lvq::qpid::broker::Lvq::push' via dominance
3 D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/Lvq.h(39) : 
  see declaration of 'qpid::broker::Lvq::push'

3d:\users\crolke\git\rh-qpid\qpid\cpp\src\qpid\broker\LossyLvq.h(38): 
   warning C4250: 'qpid::broker::LossyLvq' : 
 inherits 
'qpid::broker::LossyQueue::qpid::broker::LossyQueue::checkDepth' via dominance
3  
D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/LossyQueue.h(36) : 
  see declaration of 'qpid::broker::LossyQueue::checkDepth'

3C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\memory(931): 
   warning C4150: deletion of pointer to incomplete type 
'qpid::broker::MessageMap'; no destructor called
3  
D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/QueueCursor.h(65) : 
  see declaration of 'qpid::broker::MessageMap'
3  C:\Program Files (x86)\Microsoft Visual Studio 
10.0\VC\include\memory(930) : while compiling class template member function 
'std::auto_ptr_Ty::~auto_ptr(void)'
3  with
3  [
3  _Ty=qpid::broker::MessageMap
3  ]
3  ..\..\cpp\src\qpid\broker\LossyLvq.cpp(27) : see reference to class 
template instantiation 'std::auto_ptr_Ty' being compiled
3  with
3  [
3  _Ty=qpid::broker::MessageMap
3  ]
3  QueueFactory.cpp


3D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/LossyLvq.h(38): warning 
C4250: 'qpid::broker::LossyLvq' : inherits 
'qpid::broker::Lvq::qpid::broker::Lvq::push' via dominance
3  D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/Lvq.h(39) : 
see declaration of 'qpid::broker::Lvq::push'

3D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/LossyLvq.h(38): warning 
C4250: 'qpid::broker::LossyLvq' : inherits 
'qpid::broker::LossyQueue::qpid::broker::LossyQueue::checkDepth' via dominance
3  
D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/LossyQueue.h(36) : see 
declaration of 'qpid::broker::LossyQueue::checkDepth'

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: 

[jira] [Updated] (QPID-6307) Link starvation may occur when multiple links within a connection consume from the same queue

2015-01-12 Thread Ken Giusti (JIRA)

 [ 
https://issues.apache.org/jira/browse/QPID-6307?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ken Giusti updated QPID-6307:
-
Description: 
When multiple links on the same connection are competing for messages on the 
same queue, if the messages arrive at a slow rate one link will end up 
consuming all the messages.  

Messages should be load balanced across all the consuming links within the 
connection.

  was:
When multiple consuming links are competing for messages on the same queue, if 
the messages arrive at a slow rate one link will end up consuming all the 
messages.  

Messages should be load balanced across all the consuming links.

Summary: Link starvation may occur when multiple links within a 
connection consume from the same queue  (was: Link starvation may occur when 
multiple links consume from the same queue)

 Link starvation may occur when multiple links within a connection consume 
 from the same queue
 -

 Key: QPID-6307
 URL: https://issues.apache.org/jira/browse/QPID-6307
 Project: Qpid
  Issue Type: Bug
  Components: C++ Broker
Affects Versions: 0.30
Reporter: Ken Giusti
 Fix For: 0.31

 Attachments: recv-order.py


 When multiple links on the same connection are competing for messages on the 
 same queue, if the messages arrive at a slow rate one link will end up 
 consuming all the messages.  
 Messages should be load balanced across all the consuming links within the 
 connection.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

-
To unsubscribe, e-mail: dev-unsubscr...@qpid.apache.org
For additional commands, e-mail: dev-h...@qpid.apache.org



Re: New Defects reported by Coverity Scan for Apache-Qpid

2015-01-12 Thread Gordon Sim

On 01/12/2015 06:00 PM, Chuck Rolke wrote:

Visual Studio 2010 x64 generates five new warnings compiling LossyLvq code.
The code may be correct and the compiler is known to warn on correct code.
That said, if the code could be reorganized to avoid the warnings maybe
Coverity would stop complaining as well.


[...]


3C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\memory(931):
warning C4150: deletion of pointer to incomplete type 
'qpid::broker::MessageMap'; no destructor called
3  
D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/QueueCursor.h(65) :
   see declaration of 'qpid::broker::MessageMap'
3  C:\Program Files (x86)\Microsoft Visual Studio 
10.0\VC\include\memory(930) : while compiling class template member function 
'std::auto_ptr_Ty::~auto_ptr(void)'
3  with
3  [
3  _Ty=qpid::broker::MessageMap
3  ]
3  ..\..\cpp\src\qpid\broker\LossyLvq.cpp(27) : see reference to class 
template instantiation 'std::auto_ptr_Ty' being compiled
3  with
3  [
3  _Ty=qpid::broker::MessageMap
3  ]
3  QueueFactory.cpp


That one seems fair, and I've checked in what I believe is a fix for that.


3D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/LossyLvq.h(38): warning 
C4250: 'qpid::broker::LossyLvq' : inherits 
'qpid::broker::Lvq::qpid::broker::Lvq::push' via dominance
3  D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/Lvq.h(39) : 
see declaration of 'qpid::broker::Lvq::push'

3D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/LossyLvq.h(38): warning 
C4250: 'qpid::broker::LossyLvq' : inherits 
'qpid::broker::LossyQueue::qpid::broker::LossyQueue::checkDepth' via dominance
3  
D:\Users\crolke\git\rh-qpid\qpid\cpp\src\qpid/broker/LossyQueue.h(36) : see 
declaration of 'qpid::broker::LossyQueue::checkDepth'


Those are exactly the methods I expect to be inherited. LossyQueue 
alters the implementation of checkDepth() to support the 'ring' 
behaviour, Lvq alters the implementation of push() to support the lvq 
behaviour. What I wanted was a Queue type that inherited both these 
behaviours. To me, this is exactly the use case virtual inheritance was 
intended for.


I could of course organise the code so as not to need to use virtual 
inheritance, but I'd rather only do that if there was a good reason.


With respect to the last two warnings  above, does the attached patch 
resolve them? (This overrides both methods in the most derived class and 
explicitly chooses the implementation to use).


diff --git a/qpid/cpp/src/qpid/broker/LossyLvq.cpp b/qpid/cpp/src/qpid/broker/LossyLvq.cpp
index f59ecc1..0d773bc 100644
--- a/qpid/cpp/src/qpid/broker/LossyLvq.cpp
+++ b/qpid/cpp/src/qpid/broker/LossyLvq.cpp
@@ -27,4 +27,14 @@ namespace broker {
 LossyLvq::LossyLvq(const std::string n, std::auto_ptrMessageMap m, const QueueSettings s, MessageStore* const ms, management::Manageable* p, Broker* b)
 : Queue(n, s, ms, p, b), Lvq(n, m, s, ms, p, b), LossyQueue(n, s, ms, p, b) {}
 
+void LossyLvq::push(Message message, bool isRecovery)
+{
+Lvq::push(message, isRecovery);
+}
+
+bool LossyLvq::checkDepth(const QueueDepth increment, const Message message)
+{
+return LossyQueue::checkDepth(increment, message);
+}
+
 }} // namespace qpid::broker
diff --git a/qpid/cpp/src/qpid/broker/LossyLvq.h b/qpid/cpp/src/qpid/broker/LossyLvq.h
index e0a266a..1ccc64a 100644
--- a/qpid/cpp/src/qpid/broker/LossyLvq.h
+++ b/qpid/cpp/src/qpid/broker/LossyLvq.h
@@ -35,6 +35,8 @@ class LossyLvq : public Lvq, public LossyQueue
 {
   public:
 LossyLvq(const std::string, std::auto_ptrMessageMap, const QueueSettings, MessageStore* const, management::Manageable*, Broker*);
+void push(Message msg, bool isRecovery=false);
+bool checkDepth(const QueueDepth increment, const Message);
 };
 }} // namespace qpid::broker
 
diff --git a/qpid/cpp/src/qpid/broker/LossyQueue.h b/qpid/cpp/src/qpid/broker/LossyQueue.h
index 705865f..02ad127 100644
--- a/qpid/cpp/src/qpid/broker/LossyQueue.h
+++ b/qpid/cpp/src/qpid/broker/LossyQueue.h
@@ -33,7 +33,7 @@ class LossyQueue : public virtual Queue
 {
   public:
 LossyQueue(const std::string, const QueueSettings, MessageStore* const, management::Manageable*, Broker*);
-bool checkDepth(const QueueDepth increment, const Message);
+virtual bool checkDepth(const QueueDepth increment, const Message);
   private:
 };
 }} // namespace qpid::broker
diff --git a/qpid/cpp/src/qpid/broker/Lvq.h b/qpid/cpp/src/qpid/broker/Lvq.h
index 26ba2b4..55837ed 100644
--- a/qpid/cpp/src/qpid/broker/Lvq.h
+++ b/qpid/cpp/src/qpid/broker/Lvq.h
@@ -36,7 +36,7 @@ class Lvq : public virtual Queue
 {
   public:
 Lvq(const std::string, std::auto_ptrMessageMap, const QueueSettings, MessageStore* const, management::Manageable*, Broker*);
-void push(Message msg, bool isRecovery=false);
+virtual void push(Message msg, bool isRecovery=false);
   private:
 MessageMap