[Proposal] Change list of mandatory parameters for rlm_sqlippool
Hi guys, if I understood correctly configuration parameters inside rlm_sqlippool with PW_TYPE_REQUIRED are needed because logic is related with a classic SQL transaction but with some databases for examples PostrgreSQL or Oracle logic could be reduce to a single procedure / function that speedup interaction with database to a single call. So, why not remove PW_TYPE_REQUIRED to allocate_clear, allocate_update and/or others parameters? A list of parameters where remove PW_TYPE_REQUIRED is: - off_clear - on_clear - alive_update - start_update - allocate_update (allocate_find is sufficient) - allocate_clear User can be use it or not but is not a mandatory parameter and so it could be do a choice about use it or not. WDYT G.
On Jun 10, 2015, at 5:56 AM, Geaaru <geaaru@gmail.com> wrote:
if I understood correctly configuration parameters inside rlm_sqlippool with PW_TYPE_REQUIRED are needed because logic is related with a classic SQL transaction but with some databases for examples PostrgreSQL or Oracle logic could be reduce to a single procedure / function that speedup interaction with database to a single call.
Sure.
So, why not remove PW_TYPE_REQUIRED to allocate_clear, allocate_update and/or others parameters?
Maybe. To be honest, I'd prefer to make the queries configurable, as is done with rlm_sql in v3: sqlippool { accounting { on { query = ... } } }
A list of parameters where remove PW_TYPE_REQUIRED is: - off_clear - on_clear - alive_update - start_update - allocate_update (allocate_find is sufficient) - allocate_clear
User can be use it or not but is not a mandatory parameter and so it could be do a choice about use it or not.
Probably a good idea. But fixing the sqlippool to be saner is good, too. Alan DeKok.
Ok. thanks for your reply. Yes, a solution that permit to make the queries configurable is the best. Do you think that before rewrite rlm_sqlippool module could be possible apply a patch that remove PW_TYPE_REQUIRED for some parameters for release 3.0.9? On Wed, 2015-06-10 at 08:42 -0400, Alan DeKok wrote:
On Jun 10, 2015, at 5:56 AM, Geaaru <geaaru@gmail.com> wrote:
if I understood correctly configuration parameters inside rlm_sqlippool with PW_TYPE_REQUIRED are needed because logic is related with a classic SQL transaction but with some databases for examples PostrgreSQL or Oracle logic could be reduce to a single procedure / function that speedup interaction with database to a single call.
Sure.
So, why not remove PW_TYPE_REQUIRED to allocate_clear, allocate_update and/or others parameters?
Maybe. To be honest, I'd prefer to make the queries configurable, as is done with rlm_sql in v3:
sqlippool { accounting { on { query = ... > } }
}
A list of parameters where remove PW_TYPE_REQUIRED is: - off_clear - on_clear - alive_update - start_update - allocate_update (allocate_find is sufficient) - allocate_clear
User can be use it or not but is not a mandatory parameter and so it could be do a choice about use it or not.
Probably a good idea.
But fixing the sqlippool to be saner is good, too.
Alan DeKok.
- List info/subscribe/unsubscribe? See http://www.freeradius.org/list/devel.html
On Jun 10, 2015, at 8:54 AM, Geaaru <geaaru@gmail.com> wrote:
Yes, a solution that permit to make the queries configurable is the best.
Do you think that before rewrite rlm_sqlippool module could be possible apply a patch that remove PW_TYPE_REQUIRED for some parameters for release 3.0.9?
Sure. Send a pull request via github. Alan DeKok.
participants (2)
-
Alan DeKok -
Geaaru