[jira] [Commented] (PROTON-1403) c proactor library

2017-02-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PROTON-1403?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15862189#comment-15862189
 ] 

ASF subversion and git services commented on PROTON-1403:
-

Commit 1d4fe545e394d1b0eed57dcf36624565f20d69b8 in qpid-proton's branch 
refs/heads/master from [~aconway]
[ https://git-wip-us.apache.org/repos/asf?p=qpid-proton.git;h=1d4fe54 ]

PROTON-1403: c proactor library windows fixes.

Don't build the proactor lib and examples unless there is one for the platform.


> c proactor library
> --
>
> Key: PROTON-1403
> URL: https://issues.apache.org/jira/browse/PROTON-1403
> Project: Qpid Proton
>  Issue Type: Bug
>  Components: proton-c
>Reporter: Alan Conway
>Assignee: Alan Conway
> Fix For: 0.18.0
>
>
> Move the libuv proactor example into an installed library.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Closed] (PROTON-1403) c proactor library

2017-02-10 Thread Alan Conway (JIRA)

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

Alan Conway closed PROTON-1403.
---
   Resolution: Fixed
Fix Version/s: 0.18.0

> c proactor library
> --
>
> Key: PROTON-1403
> URL: https://issues.apache.org/jira/browse/PROTON-1403
> Project: Qpid Proton
>  Issue Type: Bug
>  Components: proton-c
>Reporter: Alan Conway
>Assignee: Alan Conway
> Fix For: 0.18.0
>
>
> Move the libuv proactor example into an installed library.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (PROTON-1403) c proactor library

2017-02-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/PROTON-1403?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15862175#comment-15862175
 ] 

ASF subversion and git services commented on PROTON-1403:
-

Commit afacb16527e9f231ae76d5e16ca0d9ac7edcff86 in qpid-proton's branch 
refs/heads/master from [~aconway]
[ https://git-wip-us.apache.org/repos/asf?p=qpid-proton.git;h=afacb16 ]

PROTON-1403: c proactor library

Move the libuv example proactor into an installed library.


> c proactor library
> --
>
> Key: PROTON-1403
> URL: https://issues.apache.org/jira/browse/PROTON-1403
> Project: Qpid Proton
>  Issue Type: Bug
>  Components: proton-c
>Reporter: Alan Conway
>Assignee: Alan Conway
>
> Move the libuv proactor example into an installed library.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Assigned] (PROTON-1403) c proactor library

2017-02-10 Thread Alan Conway (JIRA)

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

Alan Conway reassigned PROTON-1403:
---

Assignee: Alan Conway

> c proactor library
> --
>
> Key: PROTON-1403
> URL: https://issues.apache.org/jira/browse/PROTON-1403
> Project: Qpid Proton
>  Issue Type: Bug
>  Components: proton-c
>Reporter: Alan Conway
>Assignee: Alan Conway
>
> Move the libuv proactor example into an installed library.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Created] (PROTON-1404) c proactor: improved robustness and testing

2017-02-10 Thread Alan Conway (JIRA)
Alan Conway created PROTON-1404:
---

 Summary: c proactor: improved robustness and testing
 Key: PROTON-1404
 URL: https://issues.apache.org/jira/browse/PROTON-1404
 Project: Qpid Proton
  Issue Type: Improvement
  Components: proton-c
Reporter: Alan Conway
Assignee: Alan Conway


Improve the robustness and test coverage of the C proactor



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Created] (PROTON-1403) c proactor library

2017-02-10 Thread Alan Conway (JIRA)
Alan Conway created PROTON-1403:
---

 Summary: c proactor library
 Key: PROTON-1403
 URL: https://issues.apache.org/jira/browse/PROTON-1403
 Project: Qpid Proton
  Issue Type: Bug
  Components: proton-c
Reporter: Alan Conway


Move the libuv proactor example into an installed library.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Comment Edited] (QPID-7317) Deadlock on publish

2017-02-10 Thread Alan Conway (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-7317?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15861827#comment-15861827
 ] 

Alan Conway edited comment on QPID-7317 at 2/10/17 8:48 PM:


I hope this will address the pulp hang in the wild, I have been unable to 
reproduce it with the fix.

Note you can apply this patch by replacing 
/usr/lib/python2.7/site-packages/qpid/selector.py with 

https://git-wip-us.apache.org/repos/asf?p=qpid-python.git;a=blob_plain;f=qpid/selector.py;h=56b137d1a05da4875c45edcab60cde8084bfed8f;hb=fda9594
   

it is the only file modified and should work with and version of python-qpid 
released in the last year.

If you do see this hang again please report to this JIRA with the output of the 
following commands from the machine where the hung celery workers are:
{code}
> rpm -q python-qpid  # or attach a copy of 
> /usr/lib/python2.7/site-packages/qpid/selector.py
> journalctl #  use --since and --until to get a few minutes 
> before/after the hang
> yum install -y gdb python-debug # needed for worker-stacks script
> worker-stacks # script attached to this JIRA
{code}
Here is log output showing that pulp does indeed use qpid.messaging in an 
illegal state that could have caused a hang prior to this fix. However it is 
not an exact match for reported stack traces so I'm not yet 100% sure the 
problem is solved. I am not able to reproduce the original hang or traces that 
look like it with the fix.

{code}
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
illegal use of qpid.messaging at:
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) File 
"/usr/lib64/python2.7/threading.py", line 784, in __bootstrap
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.__bootstrap_inner()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib64/python2.7/threading.py", line 811, in __bootstrap_inner
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.run()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/pulp/server/async/scheduler.py", line 
55, in run
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.monitor_events()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/pulp/server/async/scheduler.py", line 
82, in monitor_events
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
recv.capture(limit=None, timeout=None, wakeup=True)
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 715, in 
__exit__
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.release()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 330, in 
release
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self._close()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 298, in _close
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self._do_close_self()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 288, in 
_do_close_self
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.maybe_close_channel(self._default_channel)
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 280, in 
maybe_close_channel
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
channel.close()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/transport/qpid.py", line 983, in 
close
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self._broker.close()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/qpidtoollibs/broker.py", line 48, in 
close
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.sess.close()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/qpid/selector.py", line 213, in log_raise
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
_check(exception, 1)
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
qpid.messaging thread has been stopped
Feb 10 14:50:1

[jira] [Updated] (QPID-7317) Deadlock on publish

2017-02-10 Thread Alan Conway (JIRA)

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

Alan Conway updated QPID-7317:
--
Attachment: worker-stacks

Script to generate gdb and python stack traces from all celery worker 
processes. You need to install gdb and python-debug pacakges first.

> Deadlock on publish
> ---
>
> Key: QPID-7317
> URL: https://issues.apache.org/jira/browse/QPID-7317
> Project: Qpid
>  Issue Type: Bug
>  Components: Python Client
>Affects Versions: 0.32
> Environment: python-qpid-0.32-13.fc23.noarch
>Reporter: Brian Bouterse
>Assignee: Alan Conway
> Fix For: qpid-python-1.36.0
>
> Attachments: bad_child.py, bad_child.py, bt.txt, lsof.txt, 
> pystack.17806, spout-hang.py, spout-hang-trace.txt, taabt.txt, worker-stacks
>
>
> When publishing a task with qpid.messaging it deadlocks and our application 
> cannot continue. This has not been a problem for several releases, but within 
> a few days recently, another Satellite developer and I both experienced the 
> issue on separate machines, different distros. He is using a MRG built 
> pacakge (not sure of version). I am using python-qpid-0.32-13.fc23.
> Both deadlocked machines had core dumps taken on the deadlocked processes and 
> only show only 1 Qpid thread when I expect there to be 2. There are other 
> mongo threads, but those are idle as expected and not related. The traces 
> show our application calling into qpid.messaging to publish a message to the 
> message bus.
> This problem happens intermittently, and in cases where message publish is 
> successful I've verified by core dump that there are the expected 2 threads 
> for Qpid.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Commented] (QPID-7317) Deadlock on publish

2017-02-10 Thread Alan Conway (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-7317?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15861827#comment-15861827
 ] 

Alan Conway commented on QPID-7317:
---

I hope this will address the pulp hang in the wild, I have been unable to 
reproduce it with the fix.

Note you can apply this patch by replacing 
/usr/lib/python2.7/site-packages/qpid/selector.py with the patched file, it is 
the only file modified and should work with and version of python-qpid released 
in the last year.

If you do see this hang again please report to this JIRA with the output of the 
following commands from the machine where the hung celery workers are:
{code}
> rpm -q python-qpid  # or attach a copy of 
> /usr/lib/python2.7/site-packages/qpid/selector.py
> journalctl #  use --since and --until to get a few minutes 
> before/after the hang
> yum install -y gdb python-debug # needed for worker-stacks script
> worker-stacks # script attached to this JIRA
{code}
Here is log output showing that pulp does indeed use qpid.messaging in an 
illegal state that could have caused a hang prior to this fix. However it is 
not an exact match for reported stack traces so I'm not yet 100% sure the 
problem is solved. I am not able to reproduce the original hang or traces that 
look like it with the fix.

{code}
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
illegal use of qpid.messaging at:
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) File 
"/usr/lib64/python2.7/threading.py", line 784, in __bootstrap
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.__bootstrap_inner()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib64/python2.7/threading.py", line 811, in __bootstrap_inner
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.run()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/pulp/server/async/scheduler.py", line 
55, in run
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.monitor_events()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/pulp/server/async/scheduler.py", line 
82, in monitor_events
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
recv.capture(limit=None, timeout=None, wakeup=True)
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 715, in 
__exit__
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.release()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 330, in 
release
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self._close()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 298, in _close
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self._do_close_self()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 288, in 
_do_close_self
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.maybe_close_channel(self._default_channel)
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/connection.py", line 280, in 
maybe_close_channel
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
channel.close()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/kombu/transport/qpid.py", line 983, in 
close
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self._broker.close()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/qpidtoollibs/broker.py", line 48, in 
close
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
self.sess.close()
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416)   
File "/usr/lib/python2.7/site-packages/qpid/selector.py", line 213, in log_raise
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
_check(exception, 1)
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
qpid.messaging thread has been stopped
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) 
qpid.messaging was previously stopped at:
Feb 10 14:50:13 pulp-server pulp[7427]: qpid.messaging:ERROR: (7427-28416) Fi

[jira] [Commented] (QPID-7317) Deadlock on publish

2017-02-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-7317?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15861790#comment-15861790
 ] 

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

Commit fda9594010b13d99134c10cff54b0ba9d82c0c27 in qpid-python's branch 
refs/heads/master from [~aconway]
[ https://git-wip-us.apache.org/repos/asf?p=qpid-python.git;h=fda9594 ]

QPID-7317: More robust qpid.selector with better logging

This commit disables the selector and related qpid.messaging objects when the
selector thread exits for any reason: process exit, fork, exception etc.  Any
subsequent use will throw an exception and log the locations of the failed call
and where the selector thread was stopped. This should be slightly more
predictable & robust than commit 037c573 which tried to keep the selector alive
in a daemon thread.

I have not been able to hang the pulp_smash test suite with this patch. The new
logging shows that celery workers do sometimes use qpid.messaging in an illegal
state, which could cause the reported hang. So far I have not seen a stack trace
that is an exact match for reported stacks. If this patch does not address the
pulp problem it should at least provide much better debugging information in
journalctl log output after the hang.


> Deadlock on publish
> ---
>
> Key: QPID-7317
> URL: https://issues.apache.org/jira/browse/QPID-7317
> Project: Qpid
>  Issue Type: Bug
>  Components: Python Client
>Affects Versions: 0.32
> Environment: python-qpid-0.32-13.fc23.noarch
>Reporter: Brian Bouterse
>Assignee: Alan Conway
> Fix For: qpid-python-1.36.0
>
> Attachments: bad_child.py, bad_child.py, bt.txt, lsof.txt, 
> pystack.17806, spout-hang.py, spout-hang-trace.txt, taabt.txt
>
>
> When publishing a task with qpid.messaging it deadlocks and our application 
> cannot continue. This has not been a problem for several releases, but within 
> a few days recently, another Satellite developer and I both experienced the 
> issue on separate machines, different distros. He is using a MRG built 
> pacakge (not sure of version). I am using python-qpid-0.32-13.fc23.
> Both deadlocked machines had core dumps taken on the deadlocked processes and 
> only show only 1 Qpid thread when I expect there to be 2. There are other 
> mongo threads, but those are idle as expected and not related. The traces 
> show our application calling into qpid.messaging to publish a message to the 
> message bus.
> This problem happens intermittently, and in cases where message publish is 
> successful I've verified by core dump that there are the expected 2 threads 
> for Qpid.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Created] (QPIDJMS-264) Incoming messages are dispatched out of order

2017-02-10 Thread Alex Rudyy (JIRA)
Alex Rudyy created QPIDJMS-264:
--

 Summary: Incoming messages are dispatched out of order 
 Key: QPIDJMS-264
 URL: https://issues.apache.org/jira/browse/QPIDJMS-264
 Project: Qpid JMS
  Issue Type: Bug
  Components: qpid-jms-client
Affects Versions: 0.20.0
Reporter: Alex Rudyy
Priority: Critical


Both current trunk version and version 0.20.0 of JMS Client can dispatch 
incoming messages out of order into client application. I did not test earlier 
versions. The messages are received in the right order but Client dispatches 
them occasionally out of order.

I used the following code to reproduce the issue with trunk version of Java 
Broker.

{code}
public static void main(String[] args) throws Exception
{
for (int i=0;i<100;i++)
{
execute(i);
}
}

public static void execute(int iteration) throws Exception
{
System.out.println("Iteration " + iteration);

Connection managingConnection = createConnection();
Session session = 
managingConnection.createSession(Session.SESSION_TRANSACTED);

Connection consumingConnection = createConnection();
Session consumerSession = consumingConnection.createSession(true, 
Session.SESSION_TRANSACTED);

Queue queue = createTestQueue(session, "Q3-test");
session.commit();

MessageConsumer consumer = consumerSession.createConsumer(queue);

Connection producingConnection = createConnection();
Session producerSession = producingConnection.createSession(true, 
Session.SESSION_TRANSACTED);
MessageProducer producer = producerSession.createProducer(queue);

producer.send(producerSession.createTextMessage("msg1"));
producer.send(producerSession.createTextMessage("msg2"));
producer.send(producerSession.createTextMessage("msg3"));
producer.send(producerSession.createTextMessage("msg4"));

producerSession.commit();

consumingConnection.start();
TextMessage tm = (TextMessage) consumer.receive();

System.out.println(">" + tm.getText());
if (!"msg1".equals(tm.getText()))
{
throw new RuntimeException("Unexpected");
}

deleteQueue(session, "Q3-test");
consumingConnection.close();
producingConnection.close();
managingConnection.close();

}

private static Queue createTestQueue(Session session, String queueName) 
throws JMSException
{
MessageProducer producer = 
session.createProducer(session.createQueue("$management"));

MapMessage createMessage = session.createMapMessage();
createMessage.setStringProperty("type", "org.apache.qpid.Queue");
createMessage.setStringProperty("operation", "CREATE");
createMessage.setString("name", queueName);
createMessage.setString("object-path", "org.apache.qpid.Queue");
producer.send(createMessage);
if (session.getTransacted())
{
session.commit();
}
return session.createQueue(queueName);
}

private  static void deleteQueue(Session session, String queueName)throws 
JMSException
{
MessageProducer producer = 
session.createProducer(session.createQueue("$management"));

MapMessage createMessage = session.createMapMessage();
createMessage.setStringProperty("type", "org.apache.qpid.Queue");
createMessage.setStringProperty("operation", "DELETE");
createMessage.setStringProperty("index", "object-path");

createMessage.setStringProperty("key", queueName);
producer.send(createMessage);
if (session.getTransacted())
{
session.commit();
}
}

private static Connection createConnection() throws JMSException, 
NamingException {
Properties properties = new Properties();
properties.put("java.naming.factory.initial", 
"org.apache.qpid.jms.jndi.JmsInitialContextFactory");
properties.put("connectionfactory.myFactoryLookup", 
"amqp://localhost:5672");
Context context = new InitialContext(properties);
try
{
ConnectionFactory factory = (ConnectionFactory) 
context.lookup("myFactoryLookup");
return factory.createConnection("admin", "admin");
}
finally
{
context.close();
}
}
{code}



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Updated] (QPID-7669) Unintended UI changes from switch to swigged Python client for management tools

2017-02-10 Thread Justin Ross (JIRA)

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

Justin Ross updated QPID-7669:
--
Fix Version/s: qpid-cpp-1.37.0

> Unintended UI changes from switch to swigged Python client for management 
> tools
> ---
>
> Key: QPID-7669
> URL: https://issues.apache.org/jira/browse/QPID-7669
> Project: Qpid
>  Issue Type: Bug
>  Components: C++ Broker, C++ Client
>Reporter: Justin Ross
>Assignee: Alan Conway
> Fix For: qpid-cpp-1.37.0
>
>
> http://qpid.2158936.n2.nabble.com/Qpid-tools-with-python-vs-qpid-cpp-messaging-td7659017.html



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



[jira] [Created] (QPID-7669) Unintended UI changes from switch to swigged Python client for management tools

2017-02-10 Thread Justin Ross (JIRA)
Justin Ross created QPID-7669:
-

 Summary: Unintended UI changes from switch to swigged Python 
client for management tools
 Key: QPID-7669
 URL: https://issues.apache.org/jira/browse/QPID-7669
 Project: Qpid
  Issue Type: Bug
  Components: C++ Broker, C++ Client
Reporter: Justin Ross
Assignee: Alan Conway


http://qpid.2158936.n2.nabble.com/Qpid-tools-with-python-vs-qpid-cpp-messaging-td7659017.html



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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



Re: qpid-proton git commit: PROTON-1344: Added missed PN_LISTENER_ACCEPT event from pn_event_type_name()

2017-02-10 Thread Robbie Gemmell
On 6 February 2017 at 18:10, Andrew Stitcher  wrote:
> On Mon, 2017-02-06 at 17:28 +, Robbie Gemmell wrote:
>> On 6 February 2017 at 17:14, Andrew Stitcher 
>> wrote:
>> > On Mon, 2017-02-06 at 17:11 +, Robbie Gemmell wrote:
>> > > This should have its own JIRA given PROTON-1344 was already
>> > > released
>> > > in 0.16.0 several weeks ago (and this also missed 0.17.0 too)
>> >
>> > TBH it's such a small change that I'd have used NO-JIRA except that
>> > there was an obvious piece of work associated with it.
>> >
>> > Andrew
>> >
>>
>> Related JIRA is certainly better than NO-JIRA, though that would
>> still
>> preferably be in the same release as the original change, so I'd
>> likely have called use of that out too in this case. If its a trivial
>> change its likely a trivial JIRA too.
>>
>> Its nice to know whats in a given release, e.g I'm already thinking
>> of
>> 0.17.1. Maybe this would be worth being in that...but on the other
>> hand, if its not important enough to even warrant a JIRA, maybe not.
>
> It's mostly useful for debugging purposes more than anything else (and
> isn't exactly a bug per se), so I'd probably not bother with 0.17.1.
>
> [and now we've written almost 10x the lines of the actual change!]
>

Indeed, it might have been quicker just to raise a JIRA after all, as
well as better for folks looking to see what is in a given release and
why.

I see another commit just went in for the same closed JIRA, along with
a few more with no JIRA. When two thirds of the code changes pushed at
the same time don't have a JIRA for the next release, it doesn't seem
quite how things should be. Either a change is related to the other
commits that did have a JIRA, in which case use them, or they aren't
and then almost all of the time should have their own JIRA.

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



[jira] [Commented] (QPID-7603) [AMQP 1.0] Maximum Delivery Count/Dead-lettering

2017-02-10 Thread ASF subversion and git services (JIRA)

[ 
https://issues.apache.org/jira/browse/QPID-7603?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15860964#comment-15860964
 ] 

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

Commit 1782442 from [~k-wall] in branch 'java/trunk'
[ https://svn.apache.org/r1782442 ]

QPID-7603: [Java Broker] Use Maven dependencyManagement to properly control 
dependency versions even when POM nesting is deep

> [AMQP 1.0] Maximum Delivery Count/Dead-lettering
> 
>
> Key: QPID-7603
> URL: https://issues.apache.org/jira/browse/QPID-7603
> Project: Qpid
>  Issue Type: Improvement
>  Components: Java Broker
>Reporter: Keith Wall
> Fix For: qpid-java-7.0
>
>
> Placeholder for Maximum Delivery Count/Dead-lettering support.
> The current implementation in the Broker is incomplete.  I notice the 
> following areas.  There may be more.
> * The protocol layer needs to trigger the MessageInstance#routeToAlternate
> * Handling of the {{Rejected}} outcome is absent. 
> http://docs.oasis-open.org/amqp/core/v1.0/os/amqp-core-messaging-v1.0-os.html#type-rejected
> * Implement handling of default outcomes.
> * AMQP 1.0 Conversion layer should set Header#setDeliveryCount()
> * I note that the AMQP 0-8..0-10 protocol layers use the 
> MessageInstance#deliveryCount differently to the AMQP 1.0 protocol layer.
> This will need some care to ensure that protocol's play nicely together.
> ** AMQP 0-8..0-10 the delivery count is incremented _before_ the consumer 
> send and then it is reduced if the client returns the message indicating the 
> message is unseen.
> ** AMQP 1.0 specification defines Header field {{delivery-count}} as "The 
> number of unsuccessful previous attempts to deliver this message. If this 
> value is non-zero it can be taken as an indication that the delivery might be 
> a duplicate. On first delivery, the value is zero. It is incremented upon an 
> outcome being settled at the sender, according to rules defined for each 
> outcome.". Currently the AMQP protocol layer populates {{delivery-count}} 
> with {{MessageInstance#deliveryCount}} and it only increments 
> MessageInstance#deliveryCount after the message  is rejected.
> Also verify:
> * Behaviour when the session is rolled back or the recovered.
> * Behaviour when the session or connection is closed.
> * Behaviour when the connection is abruptly dropped.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

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