<!-- Module FAQ -->

<chapter>
	
	<title>&faqguide;</title>
	<qandaset defaultlabel="number">
	<qandaentry>
		<question>
		<para>What is the maximum lenght of a AMQP message?</para>
		</question>
		<answer>
		<para>
			The maximum length of a datagram event is 16384 bytes.
		</para>
		</answer>
	</qandaentry>
	<qandaentry>
		<question>
		<para>Where can I find more about OpenSIPS?</para>
		</question>
		<answer>
		<para>
			Take a look at &osipshomelink;.
		</para>
		</answer>
	</qandaentry>
	<qandaentry>
		<question>
		<para>What is the vhost used by the AMQP server?</para>
		</question>
		<answer>
			<para>
			Currently, the only vhost supported is <emphasis>'/'</emphasis>.
		</para>
		</answer>
	</qandaentry>
	<qandaentry>
		<question>
		<para>How can I set a vhost in the socket?</para>
		</question>
		<answer>
		<para>
				This version doesn't support a different vhost.
		</para>
		</answer>
	</qandaentry>
	<qandaentry>
		<question>
		<para>How can I send an event to my RabbitMQ server?</para>
		</question>
		<answer>
			<para>
				This module acts as a transport module for the OpenSIPS
				Event Interface. Therefore, this module should follow the
				Event Interface behavior:
			</para>
			<para>
				The first step is to subscribe the RabbitMQ server to
				the OpenSIPS Event Interface. This can be done using the
				<emphasis>subscribe_event</emphasis> core function:
			</para>

		<example>
			<title>Event subscription</title>
		<programlisting format="linespecific">
startup_route {
	subscribe_event("E_RABBITMQ_EVENT", "rabbitmq:127.0.0.1/queue");
}
		</programlisting>
		</example>
			<para>
				The next step is to raise the event from the script,
				using the <emphasis>raise_event</emphasis> core function:
			</para>
		<example>
			<title>Event subscription</title>
		<programlisting format="linespecific">
route {
	...
	/* decided that an event should be raised */
	raise_event("E_RABBITMQ_EVENT");
	...
}
		</programlisting>
		</example>
			<para>
				NOTE that the event used above is only to exemplify the
				usage from the script. Any event published through the
				OpenSIPS Event Interface can be raised using this module.
			</para>

		</answer>
	</qandaentry>
	<qandaentry>
		<question>
		<para>Where can I find more information about RabbitMQ?</para>
		</question>
		<answer>
		<para>
			You can find more information about RabbitMQ  on
			their official website
			(<ulink url='http://www.rabbitmq.com/'>
				http://www.rabbitmq.com/</ulink>).
		</para>
		</answer>
	</qandaentry>

	<qandaentry>
		<question>
		<para>Where can I post a question about this module?</para>
		</question>
		<answer>
		<para>
			First at all check if your question was already answered on one of
			our mailing lists: 
		</para>
		<itemizedlist>
			<listitem>
			<para>User Mailing List - &osipsuserslink;</para>
			</listitem>
			<listitem>
			<para>Developer Mailing List - &osipsdevlink;</para>
			</listitem>
		</itemizedlist>
		<para>
			E-mails regarding any stable &osips; release should be sent to 
			&osipsusersmail; and e-mails regarding development versions
			should be sent to &osipsdevmail;.
		</para>
		<para>
			If you want to keep the mail private, send it to 
			&osipshelpmail;.
		</para>
		</answer>
	</qandaentry>
	<qandaentry>
		<question>
		<para>How can I report a bug?</para>
		</question>
		<answer>
		<para>
			Please follow the guidelines provided at:
			&osipsbugslink;.
		</para>
		</answer>
	</qandaentry>
	</qandaset>
</chapter>

