Hi Gordon,

thanks a lot for help. Condition gives exactly what I needs.

Here is an output from the broker when trace+ is enabled on protocol level.

Scenario:
send 1 message with incorrect subject and afterwards send 3 messages with
correct subject.
3 messages will get delivered to the queue.

---------------------------------------------------------------------------------------------------------------------------------------------
2015-09-17 09:28:14 [Network] info Set TCP_NODELAY on connection to
172.16.81.5:61576
2015-09-17 09:28:14 [Broker] info Using AMQP 1.0 (with SASL layer)
2015-09-17 09:28:14 [Security] info SASL: Mechanism list: PLAIN DIGEST-MD5
CRAM-MD5
2015-09-17 09:28:14 [Protocol] debug
qpid.172.16.153.10:29999-172.16.81.5:61576 Sent SASL-MECHANISMS(PLAIN
DIGEST-MD5 CRAM-MD5) 50
2015-09-17 09:28:14 [Protocol] debug
qpid.172.16.153.10:29999-172.16.81.5:61576 writing protocol header: 1-0
2015-09-17 09:28:14 [Protocol] debug
qpid.172.16.153.10:29999-172.16.81.5:61576 Received SASL-INIT(PLAIN,
amqpsrv\x00amqpsrv\x00amqpsrv)
2015-09-17 09:28:14 [Security] info SASL: Starting authentication with
mechanism: PLAIN
2015-09-17 09:28:14 [Protocol] debug
qpid.172.16.153.10:29999-172.16.81.5:61576 Sent SASL-OUTCOME(0) 16
2015-09-17 09:28:14 [Security] info
qpid.172.16.153.10:29999-172.16.81.5:61576 Authenticated as amqpsrv@QPID9999
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]:   -> AMQP
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]:   <- AMQP
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @open(16)
[container-id="reactor", hostname="172.16.153.10:29999",
max-frame-size=512, channel-max=32767, idle-time-out=500]
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @begin(17)
[next-outgoing-id=0, incoming-window=2048, outgoing-window=2147483647]
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @attach(18)
[name="broadcast", handle=0, role=false, snd-settle-mode=2,
rcv-settle-mode=0, source=@source(40) [address="broadcast", durable=0,
timeout=0, dynamic=false], target=@target(41) [address="broadcast",
durable=0, timeout=0, dynamic=false], initial-delivery-count=0]
2015-09-17 09:28:14 [Protocol] debug
qpid.172.16.153.10:29999-172.16.81.5:61576 link 0x2636830 attached on
0x26998b0
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 -> @open(16)
[container-id="a11b7eb6-efbb-4883-915d-bbe792589e51", idle-time-out=500,
properties={:product="qpid-cpp", :version="0.34", :platform="Linux", :host="
cbgd03.xeop.de"}]
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 -> @begin(17)
[remote-channel=0, next-outgoing-id=0, incoming-window=2147483647,
outgoing-window=0]
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 -> @attach(18)
[name="broadcast", handle=0, role=true, snd-settle-mode=2,
rcv-settle-mode=0, source=@source(40) [durable=0, timeout=0,
dynamic=false], target=@target(41) [address="broadcast", durable=0,
timeout=0, dynamic=false], initial-delivery-count=0]
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 -> @flow(19)
[next-incoming-id=0, incoming-window=2147483647, next-outgoing-id=0,
outgoing-window=0, handle=0, delivery-count=0, link-credit=500, drain=false]
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 -> (EMPTY FRAME)
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- (EMPTY FRAME)

2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @transfer(20) [handle=0,
delivery-id=0, delivery-tag=b"\x01\x00\x00\x00\x00\x00\x00\x00",
message-format=0, settled=true, more=false] (353)
"\x00Sp\xd0\x00\x00\x00\x0b\x00\x00\x00\x05BP\x04@BR
\x00\x00Ss\xd0\x00\x00\x00B\x00\x00\x00\x0d@
@\xa1\x09broadcast\xa1\x14ppp-broadcast.Public@S\x01@
@\x83\x00\x00\x00\x00\x00\x00\x00\x00\x83\x00\x00\x01O\xda4$\xde@R\x00@\x00Sw\xa0\xffHello
1\x00\x10\x00\x00\x00\x80k\xa3z\x01\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\xe8V\x85z\x01\x00\x00\x00\x00\x00\x00\x00\x06\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00$\x00\x00\x00\x00\x00\x00\x0e\x02\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfd\x07\x00\x00\xf0V\x85z\x00\x00\x00\x00\x90\xdf\x0f\x00\xff\xff\xff\xff!\x04\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x03\x00\x00\x00\x00\x00\x00\x00\x98W\x85z\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xa0W\x85z\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x04\x00\x00\x00\x00\x00\x00\x86E\x00\x00\x00\x00\x00\x00\x1a\x00\x00\x00\x00\x00\x00\x00>\x00\x01\x00\x00\x00\x00\x005\x00\x00\x00\x00\x00\x00\x00>\x00\x01\x00\x00\x00\x00\x00\x09\x82
\x08\x82 \x08\x82"... (truncated)
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @transfer(20) [handle=0,
delivery-id=1, delivery-tag=b"\x02\x00\x00\x00\x00\x00\x00\x00",
message-format=0, settled=true, more=false] (349)
"\x00Sp\xd0\x00\x00\x00\x0b\x00\x00\x00\x05BP\x04@BR
\x00\x00Ss\xd0\x00\x00\x00>\x00\x00\x00\x0d@
@\xa1\x09broadcast\xa1\x10broadcast.Public@S\x02@
@\x83\x00\x00\x00\x00\x00\x00\x00\x00\x83\x00\x00\x01O\xda4%3@R\x00@\x00Sw\xa0\xffHello
2\x00\x10\x00\x00\x00\x80k\xa3z\x01\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\xe8V\x85z\x01\x00\x00\x00\x00\x00\x00\x00\x06\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00$\x00\x00\x00\x00\x00\x00\x0e\x02\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfd\x07\x00\x00\xf0V\x85z\x00\x00\x00\x00\x90\xdf\x0f\x00\xff\xff\xff\xff!\x04\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x03\x00\x00\x00\x00\x00\x00\x00\x98W\x85z\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xa0W\x85z\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x04\x00\x00\x00\x00\x00\x00\x86E\x00\x00\x00\x00\x00\x00\x1a\x00\x00\x00\x00\x00\x00\x00>\x00\x01\x00\x00\x00\x00\x005\x00\x00\x00\x00\x00\x00\x00>\x00\x01\x00\x00\x00\x00\x00\x09\x82
\x08\x82 \x08\x82>\x0"... (truncated)
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @transfer(20) [handle=0,
delivery-id=2, delivery-tag=b"\x03\x00\x00\x00\x00\x00\x00\x00",
message-format=0, settled=true, more=false] (349)
"\x00Sp\xd0\x00\x00\x00\x0b\x00\x00\x00\x05BP\x04@BR
\x00\x00Ss\xd0\x00\x00\x00>\x00\x00\x00\x0d@
@\xa1\x09broadcast\xa1\x10broadcast.Public@S\x03@
@\x83\x00\x00\x00\x00\x00\x00\x00\x00\x83\x00\x00\x01O\xda4%\x97@R\x00@\x00Sw\xa0\xffHello
3\x00\x10\x00\x00\x00\x80k\xa3z\x01\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\xe8V\x85z\x01\x00\x00\x00\x00\x00\x00\x00\x06\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00$\x00\x00\x00\x00\x00\x00\x0e\x02\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfd\x07\x00\x00\xf0V\x85z\x00\x00\x00\x00\x90\xdf\x0f\x00\xff\xff\xff\xff!\x04\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x03\x00\x00\x00\x00\x00\x00\x00\x98W\x85z\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xa0W\x85z\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x04\x00\x00\x00\x00\x00\x00\x86E\x00\x00\x00\x00\x00\x00\x1a\x00\x00\x00\x00\x00\x00\x00>\x00\x01\x00\x00\x00\x00\x005\x00\x00\x00\x00\x00\x00\x00>\x00\x01\x00\x00\x00\x00\x00\x09\x82
\x08\x82 \x08\x82>\x0"... (truncated)
2015-09-17 09:28:14 [Security] info ACL Deny id:amqpsrv@QPID9999
action:publish ObjectType:exchange Name:broadcast
2015-09-17 09:28:14 [Protocol] error Error processing deliveries:
amqpsrv@QPID9999 cannot publish to broadcast with routing-key
ppp-broadcast.Public
(/builddir/build/BUILD/qpid-cpp-0.34/src/qpid/broker/amqp/Authorise.cpp:118)
2015-09-17 09:28:14 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 -> @detach(22) [handle=0,
closed=true, error=@error(29) [condition=:"amqp:unauthorized-access",
description="amqpsrv@QPID9999 cannot publish to broadcast with routing-key
ppp-broadcast.Public
(/builddir/build/BUILD/qpid-cpp-0.34/src/qpid/broker/amqp/Authorise.cpp:118)"]]
2015-09-17 09:28:15 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- (EMPTY FRAME)

2015-09-17 09:28:15 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @transfer(20) [handle=0,
delivery-id=3, delivery-tag=b"\x04\x00\x00\x00\x00\x00\x00\x00",
message-format=0, settled=true, more=false] (349)
"\x00Sp\xd0\x00\x00\x00\x0b\x00\x00\x00\x05BP\x04@BR
\x00\x00Ss\xd0\x00\x00\x00>\x00\x00\x00\x0d@
@\xa1\x09broadcast\xa1\x10broadcast.Public@S\x04@
@\x83\x00\x00\x00\x00\x00\x00\x00\x00\x83\x00\x00\x01O\xda4%\xfb@R\x00@\x00Sw\xa0\xffHello
4\x00\x10\x00\x00\x00\x80k\xa3z\x01\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\xe8V\x85z\x01\x00\x00\x00\x00\x00\x00\x00\x06\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x00\x01\x00\x00$\x00\x00\x00\x00\x00\x00\x0e\x02\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xfd\x07\x00\x00\xf0V\x85z\x00\x00\x00\x00\x90\xdf\x0f\x00\xff\xff\xff\xff!\x04\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x03\x00\x00\x00\x00\x00\x00\x00\x98W\x85z\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\xa0W\x85z\x00\x00\x00\x00\x00\x00\x01\x00\x00\x00\x00\x00\x00\x04\x00\x00\x00\x00\x00\x00\x86E\x00\x00\x00\x00\x00\x00\x1a\x00\x00\x00\x00\x00\x00\x00>\x00\x01\x00\x00\x00\x00\x005\x00\x00\x00\x00\x00\x00\x00>\x00\x01\x00\x00\x00\x00\x00\x09\x82
\x08\x82 \x08\x82>\x0"... (truncated)
2015-09-17 09:28:15 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @detach(22) [handle=0,
closed=true]
2015-09-17 09:28:15 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 <- @close(24) []
2015-09-17 09:28:15 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]:   <- EOS
2015-09-17 09:28:15 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 -> (EMPTY FRAME)
2015-09-17 09:28:15 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]: 0 -> @close(24) []
2015-09-17 09:28:15 [Protocol] trace
[qpid.172.16.153.10:29999-172.16.81.5:61576]:   -> EOS



2015-09-16 15:33 GMT+02:00 Gordon Sim <g...@redhat.com>:

> On 09/16/2015 02:02 PM, Tomáš Šoltys wrote:
>
>> Thanks Gordon,
>>
>> I have already noticed that I am getting PN_LINK_REMOTE_CLOSE event type.
>> But I am not able to get any error.
>> pn_error_text(pn_link_error(pn_event_link(pEvent))) returns NULL.
>>
>
> Try pn_link_remote_condition & pn_condition_get_description instead of
> pn_link_error and pn_error_text.
>
> Other thing that I do not understand is, that after sending erroneous
>> message I am still able to send messages (this time with correct subject)
>> to broker without any problem and messages are delivered.
>>
>> I thought that event type PN_LINK_REMOTE_CLOSE indicated that link was on
>> remote side closed.
>>
>
> That does indeed sound odd. Do you have a protocol trace to hand?
>
>


-- 
Tomáš Šoltys
tomas.sol...@gmail.com
http://www.range-software.com
(+420) 776-843-663

Reply via email to