[rabbitmq-discuss] RabbitMQ with Socket Server

Alex Gentle alexgentle at sify.com
Wed Sep 16 01:19:02 BST 2009


>You don't need AMQP on your client side at all based upon your
>descriptions. You already have a methodology for contacting a server
>(the socket connection described). The only role for AMQP would be on
>the server side.

I am not sure how you got that impression. I am not using AMQP on the client
side. I never mentioned it like that. iPhone is the client. AMQP (RabbitMQ)
is installed in our server.

>I think you might be trying to squeeze AMQP (and rabbit) into a place
>where it doesn't fit.
>Why don't you try describing your entire messaging architecture for
>us. Perhaps we can suggest improvements.

Here it is...

iPhone app -> socket server -> RabbitMQ server

iPhone app has some social networking features in addition to the chat
component. Think of it like mini-facebook inside iPhone. When a user types a
message inside chat window of iPhone app, the message travels to Socket
server which directs the message depending on what is on the message header.
If the message header says "this message is for RabbitMQ", socket server
will route to RabbitMQ. When a message comes from RabbitMQ to socket server,
it should have message header that says "Route this to xxxxxx user". Then,
socket server will route the message to appropriate user(s).

It all looks good, but it doesn't work. Because I don't know how to make a
call to RabbitMQ using the message from socket server and how to pass the
message from RabbitMQ to socket server in binary format.

Thanks.


On Mon, Sep 14, 2009 at 8:11 PM, Chuck Remes <cremes.devlist at mac.com> wrote:

>
> On Sep 14, 2009, at 8:09 PM, Alex Gentle wrote:
>
> > >Alex, you haven't explained why your app can only send a specific
> > >binary stream to a socket - for intents and purposes AMQP is no more
> > >than a *stream* of binary data.
> >
> > I am not sure. It's not a specific binary stream, it can be any
> > binary data. But, this binary data can't be interpreted by RabbitMQ
> > unless I put another middle layer to translate this into call to
> > RabbitMQ.
> >
> > >I don't know how the network event notification works in iPhone OS
> > 3.x
> > >(i.e. I don't know whether you get it to pre-empt the phone's
> > kernel).
> >
> > Actually it's not related to iPhone. I was mentioning about polling
> > mechanism in RabbitMQ. Meaning that, RabbitMQ doesn't inform the
> > user when he gets the message. User has to check every few seconds
> > to see if there is anything in his queue. So, iPhone app (OR any
> > application for that matter) needs to constantly check RabbitMQ to
> > see if there is any message. That's going to cost lot of bandwidth
> > when I port the app to mobile devices.
> >
> > Thank you for all the answers.
>
> You don't need AMQP on your client side at all based upon your
> descriptions. You already have a methodology for contacting a server
> (the socket connection described). The only role for AMQP would be on
> the server side.
>
> I think you might be trying to squeeze AMQP (and rabbit) into a place
> where it doesn't fit.
>
> Why don't you try describing your entire messaging architecture for
> us. Perhaps we can suggest improvements.
>
> cr
>
>
> _______________________________________________
> rabbitmq-discuss mailing list
> rabbitmq-discuss at lists.rabbitmq.com
> http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20090915/1afa8faa/attachment.htm 


More information about the rabbitmq-discuss mailing list