[rabbitmq-discuss] Erlang strings and binstrings (newbie question)

Farruco Sanjurjo madtrick at gmail.com
Fri Oct 28 11:29:28 BST 2011


Hi,

I'm using this (
https://github.com/rabbitmq/rabbitmq-tutorials/tree/master/erlang)  erlang
examples as an entry point to RabbitMQ and due to the fact that I'm also a
newbie to erlang there's something I don't get.

In the send.erl example, when you connect to the RabbitMQ server you specify
the host with a string ("localhost") but ,for example, when you specify the
routing_key you use a bitstring (<<"hello">>).

I know the differences between strings and bitstrings but, why don't we
allways use one of them? why sometimes strings and others bitstrings?

Thanks,
Farruco Sanjurjo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rabbitmq.com/pipermail/rabbitmq-discuss/attachments/20111028/d050f906/attachment.htm>


More information about the rabbitmq-discuss mailing list