Re: [Dev] [APIM] New Throttling Engine Database Schema Design
On Fri, Mar 4, 2016 at 1:23 PM, Upekka Anuruddhiwrote: > Whats are QUOTA_POLICY_TYPE, QUOTA attributes > > Throttling can be done based on Request Count (Eg: 4000 req/5 min) or > based on Bandwidth (Eg: 100 MB/1 hour). QUOTA_POLICY_TYPE is either > "RequestCount" or "Bandwidth". QUOTA is the number of requests or the > bandwidth allowed. > So, cant we use a master table to store the quota policy types and map the id here to avoid data repetition? > > > why are these duplicated in AM_POLICY, AM_CONDITION tables? > > Consider the scenario "Allow 20 req/min for requests coming from a > particular ip address range and allow 10 req/min for others". In the above > scenario the quota 20 req/min is relevant to condition (AM_CONDITION table) > and 10 req/min is the default quota relevant to Policy (AM_POLICY table). > +1 > > > On Thu, Mar 3, 2016 at 5:42 PM, Nuwan Dias wrote: > >> The condition table needs to hold the Resource URI template as well. >> >> On Thu, Mar 3, 2016 at 4:28 PM, Upekka Anuruddhi wrote: >> >>> Hi All, >>> >>> This is the database design for saving throttling policies in CEP Based >>> Throttling engine for API Manager. >>> Please share your ideas and suggestions on this. >>> >>> Thanks. >>> Upekka >>> >>> >>> -- >>> *Upekka Pathirana* >>> Software Engineering Intern >>> WSO2 Inc.; http://wso2.com >>> Mobile : +94 (0) 714 868488 >>> upe...@wso2.com >>> >>> ___ >>> Dev mailing list >>> Dev@wso2.org >>> http://wso2.org/cgi-bin/mailman/listinfo/dev >>> >>> >> >> >> -- >> Nuwan Dias >> >> Technical Lead - WSO2, Inc. http://wso2.com >> email : nuw...@wso2.com >> Phone : +94 777 775 729 >> > > > > -- > *Upekka Pathirana* > Software Engineering Intern > WSO2 Inc.; http://wso2.com > Mobile : +94 (0) 714 868488 > upe...@wso2.com > -- *Lahiru Cooray* Software Engineer WSO2, Inc.;http://wso2.com/ lean.enterprise.middleware Mobile: +94 715 654154 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [APIM] New Throttling Engine Database Schema Design
Whats are QUOTA_POLICY_TYPE, QUOTA attributes Throttling can be done based on Request Count (Eg: 4000 req/5 min) or based on Bandwidth (Eg: 100 MB/1 hour). QUOTA_POLICY_TYPE is either "RequestCount" or "Bandwidth". QUOTA is the number of requests or the bandwidth allowed. why are these duplicated in AM_POLICY, AM_CONDITION tables? Consider the scenario "Allow 20 req/min for requests coming from a particular ip address range and allow 10 req/min for others". In the above scenario the quota 20 req/min is relevant to condition (AM_CONDITION table) and 10 req/min is the default quota relevant to Policy (AM_POLICY table). On Thu, Mar 3, 2016 at 5:42 PM, Nuwan Diaswrote: > The condition table needs to hold the Resource URI template as well. > > On Thu, Mar 3, 2016 at 4:28 PM, Upekka Anuruddhi wrote: > >> Hi All, >> >> This is the database design for saving throttling policies in CEP Based >> Throttling engine for API Manager. >> Please share your ideas and suggestions on this. >> >> Thanks. >> Upekka >> >> >> -- >> *Upekka Pathirana* >> Software Engineering Intern >> WSO2 Inc.; http://wso2.com >> Mobile : +94 (0) 714 868488 >> upe...@wso2.com >> >> ___ >> Dev mailing list >> Dev@wso2.org >> http://wso2.org/cgi-bin/mailman/listinfo/dev >> >> > > > -- > Nuwan Dias > > Technical Lead - WSO2, Inc. http://wso2.com > email : nuw...@wso2.com > Phone : +94 777 775 729 > -- *Upekka Pathirana* Software Engineering Intern WSO2 Inc.; http://wso2.com Mobile : +94 (0) 714 868488 upe...@wso2.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
Re: [Dev] [APIM] New Throttling Engine Database Schema Design
Hi Upekka, Please explain the below concerns: Whats are QUOTA_POLICY_TYPE, QUOTA attributes and why are these duplicated in AM_POLICY, AM_CONDITION tables? (As per my understanding we are setting default values when defining a policy and allow users to override when assigning to a condition. Is it the scenario?) Are policies applied against HTTP_VERBs? or against the Condition? Better to give more meaningful names to attributes UNIT_TIME / TIME_UNIT (AM_CONDITION) On Thu, Mar 3, 2016 at 4:28 PM, Upekka Anuruddhiwrote: > Hi All, > > This is the database design for saving throttling policies in CEP Based > Throttling engine for API Manager. > Please share your ideas and suggestions on this. > > Thanks. > Upekka > > > -- > *Upekka Pathirana* > Software Engineering Intern > WSO2 Inc.; http://wso2.com > Mobile : +94 (0) 714 868488 > upe...@wso2.com > > ___ > Dev mailing list > Dev@wso2.org > http://wso2.org/cgi-bin/mailman/listinfo/dev > > -- *Lahiru Cooray* Software Engineer WSO2, Inc.;http://wso2.com/ lean.enterprise.middleware Mobile: +94 715 654154 ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev
[Dev] [APIM] New Throttling Engine Database Schema Design
Hi All, This is the database design for saving throttling policies in CEP Based Throttling engine for API Manager. Please share your ideas and suggestions on this. Thanks. Upekka -- *Upekka Pathirana* Software Engineering Intern WSO2 Inc.; http://wso2.com Mobile : +94 (0) 714 868488 upe...@wso2.com ___ Dev mailing list Dev@wso2.org http://wso2.org/cgi-bin/mailman/listinfo/dev