db_url
(str)xcap_table
(str)rlsubs_table
(str)rlpres_table
(str)clean_period
(int)waitn_time
(int)max_expires
(int)hash_size
(int)xcap_root
(str)integrated_xcap_server
(int)to_presence_code
(int)rls_event
(str)rls_handle_subscribe()
rls_handle_notify()
db_url
parameterxcap_table
parameterrlsubs_table
parameterrlpres_table
parameterclean_period
parameterwaitn_time
parametermax_expires
parameterhash_size
parameterhash_size
parameterintegrated_xcap_server
parameterto_presence_code
parameterrls_event
parameterrls_handle_subscribe
usagerls_handle_notify
usageThe modules is a Resource List Server implementation following the specification in RFC 4662 and RFC 4826.
The server is independent from local presence servers, retrieving presence information with Subscribe-Notify messages.
The module uses the presence module as a library, as it requires a resembling mechanism for handling Subscribe. Therefore, in case the local presence server is not collocated on the same machine with the RL server, the presence module should be loaded in a library mode only (see doc for presence module).
It handles subscription to lists in an event independent way.The default event is presence, but if some other events are to be handled by the server, they should be added using the module parameter "rls_events".
It works with XCAP server for storage. There is also the possibility to configure it to work in an integrated_xcap server mode, when it only queries database for the resource lists documents. This is useful in a small architecture when all the clients use an integrated server and there are no references to exterior documents in their lists.
The same as presence module, it has a caching mode with periodical update in database for subscribe information. The information retrieved with Notify messages is stored in database only.
The following modules must be loaded before this module:
a database module.
sl.
tm.
presence- in a library mode.
pua.
xcap_table
(str)The name of the xcap table in which the integrated server or the xcap_client module writes. If integrated_xcap_server parameter not set, the name of the table must be the same as the one set for the xcap_client module.
Default value is "xcap".
rlsubs_table
(str)The name of the db table where resource lists subscription information is stored.
Default value is "rls_watchers".
rlpres_table
(str)The name of the db table where notified event specific information is stored.
Default value is "rls_presentity".
clean_period
(int)The period at which to check for expired information.
Default value is "100".
waitn_time
(int)The timer period at which the server should attempt to send Notifies with the updated presence state of the subscribed list or watcher information.
Default value is "50".
max_expires
(int)The maximum accepted expires for a subscription to a list.
Default value is "7200".
hash_size
(int)The dimension of the hash table used to store subscription information. This parameter will be used as the power of 2 when computing table size.
Default value is "9 (512)".
integrated_xcap_server
(int)This parameter should be set if only integrated xcap servers are used to store resource lists.
Default value is "0".
to_presence_code
(int)The code to be returned by rls_handle_subscribe function if the processed Subscribe is not a resource list Subscribe. This code can be used in an architecture with presence and rls servers collocated on the same machine, to call handle_subscribe on the message causing this code.
Default value is "0".
rls_event
(str)The default event that RLS handles is presence. If some other events should also be handled by RLS they should be added using this parameter. It can be set more than once.
Default value is ""presence"".
rls_handle_subscribe()
This function detects if a Subscribe message is should be handled by RLS. If not it replies with the configured to_presence_code. If it is, it extracts the dialog info and sends aggregate Notify requests with information for the list.
This function can be used from REQUEST_ROUTE.
Example 1-13. rls_handle_subscribe
usage
... For presence and rls on the same machine: modparam(rls, "to_presence_code", 10) if(is_method("SUBSCRIBE")) { $var(ret_code)= rls_handle_subscribe(); if($var(ret_code)== 10) handle_subscribe(); t_release(); } For rls only: if(is_method("SUBSCRIBE")) { rls_handle_subscribe(); t_release(); } ...
The module requires 2 table in OpenSER database: rls_presentity and rls_watchers.The SQL syntax to create them can be found in rls-create.sql script in the database directories in the openser/scripts folder. You can also find the complete database documentation on the project webpage, http://www.openser-project.org/docs/db-tables/openser-db-devel.html.
Take a look at http://www.openser-project.org/.
First at all check if your question was already answered on one of our mailing lists:
User Mailing List - http://lists.openser-project.org/cgi-bin/mailman/listinfo/users
Developer Mailing List - http://lists.openser-project.org/cgi-bin/mailman/listinfo/devel
E-mails regarding any stable OpenSER release should be sent to
<users@lists.openser-project.org>
and e-mails regarding development versions
should be sent to <devel@lists.openser-project.org>
.
If you want to keep the mail private, send it to
<team@lists.openser-project.org>
.
Please follow the guidelines provided at: http://sourceforge.net/tracker/?group_id=139143.