[Maria-developers] MariaDB limits
Hello guys, I have a lot of clients requesting some kind of per user limiting based on the information from the STATISTICS tables. I'm thinking of creating a patch that will add this functionality by creating two more tables in the INFORMATION_SCHEMA: USER_LIMITS CLIENT_LIMITS They will have some parts of the structure of USER_STATISTICS and CLIENT_STATISTICS and will keep only values for limits. By default a 0 would mean no limit. Do you have any comments about my aproach? Would you be willing to accept a patch that adds such functionality? I want to know before I start work on this project if the community is interested in such enhancement of MariaDB. Regards, Marian
@Marain .. you probably know this: http://dev.mysql.com/doc/refman/5.1/en/user-resources.html . This is same for MySQL and MariaDB. I_S is a *read-only* database. And if you want to add more configurable per-user limitations such should IMHO go to the `mysql` database. I also don't think (for compability) that it should be more rows added `mysql`.`user` then, but maybe rather a new table specific for such patch ( `mysql`.`user_addon` or whatever). But what per-user limitations do you want to add exactly? Peter (from Webyog and thus not a MariaDB developer - just a follower here) On Mon, Jun 20, 2011 at 20:03, Marian Marinov <mm@yuhu.biz> wrote:
Hello guys, I have a lot of clients requesting some kind of per user limiting based on the information from the STATISTICS tables.
I'm thinking of creating a patch that will add this functionality by creating two more tables in the INFORMATION_SCHEMA: USER_LIMITS CLIENT_LIMITS
They will have some parts of the structure of USER_STATISTICS and CLIENT_STATISTICS and will keep only values for limits. By default a 0 would mean no limit.
Do you have any comments about my aproach?
Would you be willing to accept a patch that adds such functionality?
I want to know before I start work on this project if the community is interested in such enhancement of MariaDB.
Regards, Marian
_______________________________________________ Mailing list: https://launchpad.net/~maria-developers Post to : maria-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~maria-developers More help : https://help.launchpad.net/ListHelp
On Monday 20 June 2011 21:24:05 Peter Laursen wrote:
@Marain .. you probably know this: http://dev.mysql.com/doc/refman/5.1/en/user-resources.html . This is same for MySQL and MariaDB.
Yup, I know those. But I need to have those also per 24h period not only 1h.
I_S is a *read-only* database. And if you want to add more configurable per-user limitations such should IMHO go to the `mysql` database. I also don't think (for compability) that it should be more rows added `mysql`.`user` then, but maybe rather a new table specific for such patch ( `mysql`.`user_addon` or whatever).
But what per-user limitations do you want to add exactly?
I'm working in the shared hosting industry and I'm interested in the CPU_TIME, BUSY_TIME, BYTES_RECEIVED and BYTES_SEND. I agree that the best place would be the mysql database and a separate table/tables. However I believe that it would be best if once the values are changed, they appear in the INFORMATION_SCHEMA.
Peter (from Webyog and thus not a MariaDB developer - just a follower here)
On Mon, Jun 20, 2011 at 20:03, Marian Marinov <mm@yuhu.biz> wrote:
Hello guys, I have a lot of clients requesting some kind of per user limiting based on the information from the STATISTICS tables.
I'm thinking of creating a patch that will add this functionality by creating
two more tables in the INFORMATION_SCHEMA: USER_LIMITS CLIENT_LIMITS
They will have some parts of the structure of USER_STATISTICS and CLIENT_STATISTICS and will keep only values for limits. By default a 0 would mean no limit.
Do you have any comments about my aproach?
Would you be willing to accept a patch that adds such functionality?
I want to know before I start work on this project if the community is interested in such enhancement of MariaDB.
Regards, Marian
_______________________________________________ Mailing list: https://launchpad.net/~maria-developers Post to : maria-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~maria-developers More help : https://help.launchpad.net/ListHelp
-- Best regards, Marian Marinov
Hi, Marian! On Jun 20, Marian Marinov wrote:
But what per-user limitations do you want to add exactly?
I'm interested in the CPU_TIME, BUSY_TIME, BYTES_RECEIVED and BYTES_SEND.
What do you plan to do when a user reaches his limit on, say, CPU_TIME? Lock the account till the end of the 24h period? Regards, Sergei
@Sergei .. I cannot reply on behalf of Marian, of course. But the current 'limitation_per_hour' user settings would have same considerations in this respect as 'limitation_per_24hour' proposed by Marian would as far as I can see. Either it is * between current_time and current_day:00:00:00 -- from midnight if you like * or between current time and current_time-1day . -- from 24 hours ago What does 'limitation_per_hour' user settings do currently? * between now() and hour(now()) -- from last time minutes were '00' * or (between now()-1day) and hour(now()) -- from 1 hour ago (hope you understand my pseudocode and explanation) For consistence I think that 'limitation_per_24hour' should work exactly like current 'limitation_per_hour' do. I could actually suggest a (global only) server variable/startup option '--user_limit_time_interval' that manages if settings in ´mysql`.'user` should be per second|minute|hour|day|week|month ... Or just introduce it in seconds and let 3600 be default. Then "--user_limit_time_interval=7200" would change the limitations in ´mysql`.'user` to have effect for a 2-hour period and not a 1-hour period. Not that I need such thing myself but that would be a consistent and compatible implementation of Marian's request if I understand. -- Peter On Tue, Jun 21, 2011 at 14:23, Sergei Golubchik <serg@askmonty.org> wrote:
Hi, Marian!
On Jun 20, Marian Marinov wrote:
But what per-user limitations do you want to add exactly?
I'm interested in the CPU_TIME, BUSY_TIME, BYTES_RECEIVED and BYTES_SEND.
What do you plan to do when a user reaches his limit on, say, CPU_TIME? Lock the account till the end of the 24h period?
Regards, Sergei
_______________________________________________ Mailing list: https://launchpad.net/~maria-developers Post to : maria-developers@lists.launchpad.net Unsubscribe : https://launchpad.net/~maria-developers More help : https://help.launchpad.net/ListHelp
participants (3)
-
Marian Marinov
-
Peter Laursen
-
Sergei Golubchik