You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@apr.apache.org by Paul Querna <ch...@force-elite.com> on 2004/12/17 16:47:18 UTC

multicast?

So, I have a ~70% done implementation this 'apr_mcast' api.

I am on air planes all day today, so hopefully I can finish up the code.

Any comments on the following API:

/**
  * @defgroup apr_mcast IP Multicast
  * @{
  */

/**
  * Join a Multicast Group
  * @param sock The socket to join a multicast group
  * @param join The address of the multicast group to join
  * @param iface Address of the interface to use.  If NULL is passed, the
  *              defautl multicast interface will be used. (OS Dependent)
  */
APR_DECLARE(apr_status_t) apr_mcast_join(apr_socket_t *sock,
                                          apr_sockaddr_t *join,
                                          apr_sockaddr_t *iface);



/**
  * Leave a Multicast Group.  All arguments must be the same as
  * apr_mcast_join.
  * @param sock The socket to leave a multicast group
  * @param join The address of the multicast group to join
  * @param iface Address of the interface to use.  If NULL is passed, the
  *              defautl multicast interface will be used. (OS Dependent)
  */
APR_DECLARE(apr_status_t) apr_mcast_leave(apr_socket_t *sock,
                                           apr_sockaddr_t *leave,
                                           apr_sockaddr_t *iface);

/**
  * Set the Multicast Time to Live (ttl) for a socket.
  * @param sock The socket to set the multicast ttl
  * @param ttl Time to live to Assign. 0-255, default=1
  * @remark If the TTL is 0, packets will only be seen by sockets on
  * the local machine, with multicast loopback enabled.
  */
APR_DECLARE(apr_status_t) apr_mcast_ttl(apr_socket_t *sock,
                                         apr_byte_t ttl);


/**
  * Enable or disable IP Multicast Loopback
  * @param sock The socket to set multicast loopback
  * @param opt 0=disable, 1=enable
  */
APR_DECLARE(apr_status_t) apr_mcast_loopback(apr_socket_t *sock,
                                              apr_byte_t opt);


/** @} */


Not sure if we want a different base name.. 'apr_socket_multicast' vs 
apr_socket_mcast' vs 'apr_multicast'.

-Paul

Re: multicast?

Posted by Paul Querna <ch...@force-elite.com>.
Graham Leggett wrote:
> Paul Querna wrote:
> 
>> So, I have a ~70% done implementation this 'apr_mcast' api.
> 
> 
> After I have finished up on the LDAP stuff I am working on, my next itch 
> is get mod_backhand ported to httpd v2.0, which uses multicast. It may 
> be worth seeing what backhand does with multicast to make sure all the 
> possible bases are covered in the API.

Yep. A mod_proxy_backhand for lack of a better name is on my hit list 
too.  This was the first logical step, a required dependency for such a 
module, so, it was first on my list.

-Paul

Re: multicast?

Posted by Graham Leggett <mi...@sharp.fm>.
Paul Querna wrote:

> So, I have a ~70% done implementation this 'apr_mcast' api.

After I have finished up on the LDAP stuff I am working on, my next itch 
is get mod_backhand ported to httpd v2.0, which uses multicast. It may 
be worth seeing what backhand does with multicast to make sure all the 
possible bases are covered in the API.

But in short, if you build an apr_mcast api, I can definitely try get 
backhand to use it.

Regards,
Graham
--

Re: multicast?

Posted by Dirk-Willem van Gulik <di...@webweaving.org>.

On Fri, 17 Dec 2004, Paul Querna wrote:

> Any comments on the following API:

Works for me (went through some old loadbalancing module) and seems more
complete than a simple app would need.

Dw