<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;">Thankyou will try that.<BR><BR>--- On <B>Fri, 2/19/10, Alan DeKok <I><aland@deployingradius.com></I></B> wrote:<BR>
<BLOCKQUOTE style="PADDING-LEFT: 5px; MARGIN-LEFT: 5px; BORDER-LEFT: rgb(16,16,255) 2px solid"><BR>From: Alan DeKok <aland@deployingradius.com><BR>Subject: Re: modules instantiation<BR>To: "FreeRadius users mailing list" <freeradius-users@lists.freeradius.org><BR>Date: Friday, February 19, 2010, 6:07 PM<BR><BR>
<DIV class=plainMail>Latha Krishnamurthi wrote:<BR>> I see that a new instance is getting created when the first one is busy<BR>> handling a request. (I do this this by adding a sleep in the module and<BR>> printing the threadid) I am expecting the xxx_instantiate function to<BR>> get called each time a new instance is created (reading in the<BR>> documentation).<BR><BR> No. The module is NOT having "a new instance created".<BR><BR> A module "instance" is defined by a module configuration. One<BR>configuration: one instance.<BR><BR> The "instance" data is *constant*. The module gets called multiple<BR>times simultaneously from multiple threads when multiple requests are<BR>received.<BR><BR>> This does not happen. I am actually connecting to a<BR>> server in the instantiate function and storing the socket id in the<BR>> *instance, so that I can use it later in the authenticate etc.<BR><BR>
Why?<BR><BR> Is that connection changing the way the module behaves?<BR><BR>> But it seems that the socket id is the same for all the instances.<BR>> *instance seems to be shared by all the instances ??<BR>> <BR>> Am I missing something/configuration, your help is grately appreciated.<BR><BR> If you need to store data that is associated with a particulare<BR>*request*, and is valid only for the lifetime of a request, see<BR>request_data_add(), and request_data_get().<BR><BR> Alan DeKok.<BR>-<BR>List info/subscribe/unsubscribe? See <A href="http://www.freeradius.org/list/users.html" target=_blank>http://www.freeradius.org/list/users.html</A><BR></DIV></BLOCKQUOTE></td></tr></table><br>