Hi Please find the attached app it demonstrate some features of Velocity and how we can use it to generate api conf.
The template we have to write will be something similar to "template.xml" found in the root directory. To try the app give executing permission to "run.sh" script and execute it. Cheers Jo On Wed, Oct 30, 2013 at 5:29 AM, Sanjeewa Malalgoda <[email protected]>wrote: > > > > On Mon, Oct 28, 2013 at 10:08 PM, Joseph Fonseka <[email protected]> wrote: > >> >> Hi All >> >> Shall we use Apache Velocity to generate synapse config for APIs. Key >> benefits using Velocity over current method are. >> >> 1. Will be able to reduce the existing number of template files. ( Eg. To >> enable / disable JWT only need to use If condition inside the template ) >> > Are we enable JWT per API now? AFAIK we will do it in global level using > api-manager.xml file. > >> >> 2. Can move most of the config generating logic in to the template thus >> reducing the complexity of the template builders. >> >> 3. Can come up with more powerful and flexible templates. ( Eg. If tenant >> id is passed to template user can customize how the apis are generated >> based on tenants ) >> >> Apache Velocity is already included in APIM so we do not need additional >> dependencies. >> >> +1 for having more flexible template engine inside AM. AFAIU we will use > template model and use velocity to generate different templates with > different parameters (using same template format). It would be iadeal if > you can provide some sample. > > Thanks, > sanjeewa. > >> Regards >> Jo >> >> -- >> *Joseph Fonseka* >> WSO2 Inc.; http://wso2.com >> lean.enterprise.middleware >> >> mobile: +94 772 512 430 >> skype: jpfonseka >> >> * <http://lk.linkedin.com/in/rumeshbandara>* >> >> > > > -- > * > * > *Sanjeewa Malalgoda* > Senior Software Engineer > WSO2 Inc. > Mobile : +94713068779 > > <http://sanjeewamalalgoda.blogspot.com/>blog > :http://sanjeewamalalgoda.blogspot.com/<http://sanjeewamalalgoda.blogspot.com/> > > > -- -- *Joseph Fonseka* WSO2 Inc.; http://wso2.com lean.enterprise.middleware mobile: +94 772 512 430 skype: jpfonseka * <http://lk.linkedin.com/in/rumeshbandara>*
avtest.tar.gz
Description: GNU Zip compressed data
_______________________________________________ Architecture mailing list [email protected] https://mail.wso2.org/cgi-bin/mailman/listinfo/architecture
