activemq-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Alex Dean (JIRA)" <j...@apache.org>
Subject [jira] Reopened: (AMQ-3094) ajax client does not receive all messages
Date Thu, 23 Dec 2010 23:47:47 GMT

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

Alex Dean reopened AMQ-3094:
----------------------------


Dejan: Take a look at the message properties in https://issues.apache.org/jira/secure/attachment/12466851/write_message_response_debugging_output.txt.
 There are four messages here, but only 1 of them gets delivered.

The interesting bits are these:
  message=<message type="chat" from="test-user">message two</message>
  text = <message type="chat" from="test-user">message five</message>
  destination = topic://CHAT.DEMO
  m1=<message type="chat" from="test-user">message three</message>
  m2=<message type="chat" from="test-user">message four</message>
  m3=<message type="chat" from="test-user">message five</message>
  t1=send
  t3=send
  t2=send
  d1=topic://CHAT.DEMO
  d2=topic://CHAT.DEMO
  d3=topic://CHAT.DEMO

When an ajax client sends many messages in a short amount of time, they are then delivered
to other clients in a single ActiveMQTextMessage.  writeMessageResponse() doesn't handle this
properly, and only delivers one of the messages to a subscriber.

I'm not sure if this is a problem on the sending or receiving side.  (Is it legitimate to
have multiple messages piled into a single ActiveMQTextMessage like this?)  I agree the junit
test now passes, but I don't think the issue is resolved yet.  I'll work on getting some more
tests created which reproduce this issue.  For now, you should be able to reproduce it using
the chat-send.html script I've already attached to the ticket.

> ajax client does not receive all messages
> -----------------------------------------
>
>                 Key: AMQ-3094
>                 URL: https://issues.apache.org/jira/browse/AMQ-3094
>             Project: ActiveMQ
>          Issue Type: Bug
>    Affects Versions: 5.4.2
>         Environment: OSX 10.6 on MacBook Pro
> java version "1.6.0_20"
> Java(TM) SE Runtime Environment (build 1.6.0_20-b02-279-10M3065)
> Java HotSpot(TM) 64-Bit Server VM (build 16.3-b01-279, mixed mode)
>            Reporter: Alex Dean
>            Assignee: Dejan Bosanac
>             Fix For: 5.5.0
>
>         Attachments: AjaxTest-output.txt, AjaxTest.java, chat-send.html, include-commons-httpclient-in-pom-xml.patch,
write_message_response_debugging.patch, write_message_response_debugging_output.txt
>
>
> Not all messages written to a destination are delivered to an ajax client.  This seems
particularly true if more than 1 message should be returned to a client at once.  Often, if
5 messages are available, only the first 1 is actually returned in the <ajax-response>
XML.  The other 4 are lost.
> Steps to reproduce:
>  * Place the attached chat-sent.html in activemq/webapps/demo/  (or in activemq-trunk/activemq-web-demo/src/main/webapp
in an svn working copy).
>  * Start ActiveMQ.
>  * Browse to http://localhost:8161/demo/chat.html & join the chat room.
>  * In a new window, browse to http://localhost:8161/demo/chat-send.html
> chat-send.html will send 5 message to topic://CHAT.DEMO.  Only 1 (or sometimes 2) messages
will be received by the original browser window which is subscribed to the topic.  The activemq
web admin will verify that 5 messages were actually sent.

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


Mime
View raw message