You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@activemq.apache.org by Upperstage <ja...@gmail.com> on 2012/11/27 02:58:37 UTC

Cross Domain - ActiveMQ queue on localhost

Is there a generally accepted approach (best practice) for POST'ing to a
queue on the same machine as the browser? I'd like to like to use a browser
as a sort of console for a user to interact with local hardware (via
ActiveMQ) as well as using the browser in a more typical manner.

So, based on data from a central host, a user can use the browser to post to
a local queue and another local application can pick up the message from the
queue.

Can anybody help?



--
View this message in context: http://activemq.2283324.n4.nabble.com/Cross-Domain-ActiveMQ-queue-on-localhost-tp4659788.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Cross Domain - ActiveMQ queue on localhost

Posted by Upperstage <ja...@gmail.com>.
I will try that and add comments/results here. Thanks.



--
View this message in context: http://activemq.2283324.n4.nabble.com/Cross-Domain-ActiveMQ-queue-on-localhost-tp4659788p4659841.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Cross Domain - ActiveMQ queue on localhost

Posted by Dejan Bosanac <de...@nighttale.net>.
Hi,

I didn't try to use ajax client in batch mode, but you have a source
of amq.js so some debugging could help.

Also, why don't you try websockets as IMHO it's much more natural way
to do messaging from browser.


Regards
--
Dejan Bosanac
----------------------
Red Hat, Inc.
FuseSource is now part of Red Hat
dbosanac@redhat.com
Twitter: @dejanb
Blog: http://sensatic.net
ActiveMQ in Action: http://www.manning.com/snyder/


On Tue, Nov 27, 2012 at 1:55 PM, Upperstage <ja...@gmail.com> wrote:
> I've seen your posts on this forum; thank you for taking the time to reply
> (so quickly).
>
> The demos allow me to POST (once), but the error handler is called after the
> POST.  If I reset the "batch mode" flag in the error handler, then I can
> POST more than once.  However, every POST results in a call to the error
> handler - and NO DATA from the ApacheMQ server.  I can't help but to think
> something is wrong.
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.nabble.com/Cross-Domain-ActiveMQ-queue-on-localhost-tp4659788p4659810.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Cross Domain - ActiveMQ queue on localhost

Posted by Upperstage <ja...@gmail.com>.
I've seen your posts on this forum; thank you for taking the time to reply
(so quickly).

The demos allow me to POST (once), but the error handler is called after the
POST.  If I reset the "batch mode" flag in the error handler, then I can
POST more than once.  However, every POST results in a call to the error
handler - and NO DATA from the ApacheMQ server.  I can't help but to think
something is wrong.



--
View this message in context: http://activemq.2283324.n4.nabble.com/Cross-Domain-ActiveMQ-queue-on-localhost-tp4659788p4659810.html
Sent from the ActiveMQ - User mailing list archive at Nabble.com.

Re: Cross Domain - ActiveMQ queue on localhost

Posted by Dejan Bosanac <de...@nighttale.net>.
Hi,

there are variety of mechanisms that can do that:

http://activemq.apache.org/rest.html
http://activemq.apache.org/ajax.html
http://activemq.apache.org/websockets.html

I'd suggest you to look at web demos that come with the ActiveMQ distribution at

http://localhost:8161/demo

Regards
--
Dejan Bosanac
----------------------
Red Hat, Inc.
FuseSource is now part of Red Hat
dbosanac@redhat.com
Twitter: @dejanb
Blog: http://sensatic.net
ActiveMQ in Action: http://www.manning.com/snyder/


On Tue, Nov 27, 2012 at 2:58 AM, Upperstage <ja...@gmail.com> wrote:
> Is there a generally accepted approach (best practice) for POST'ing to a
> queue on the same machine as the browser? I'd like to like to use a browser
> as a sort of console for a user to interact with local hardware (via
> ActiveMQ) as well as using the browser in a more typical manner.
>
> So, based on data from a central host, a user can use the browser to post to
> a local queue and another local application can pick up the message from the
> queue.
>
> Can anybody help?
>
>
>
> --
> View this message in context: http://activemq.2283324.n4.nabble.com/Cross-Domain-ActiveMQ-queue-on-localhost-tp4659788.html
> Sent from the ActiveMQ - User mailing list archive at Nabble.com.