Currently, the existing examples may not have all 3 (C, CPP, LUA)
versions available. Often it is just 1.

On other note, for me, it is helpful to see multiple examples in the
same language so I can copy and combine ideas from them when I need to
write a new plugin for new functionality.

Kit

On Fri, May 24, 2019 at 10:13 AM Sudheer Vinukonda
<sudheervinuko...@yahoo.com.invalid> wrote:
>
>  Hmm..I typically use examples to find a relevant sample code for a use case 
> I'm interested in. For example, if I'm looking to write a transform plugin, 
> I'd try and find an existing example for transform. The C/CPP/LUA API is 
> great, of course, but that's usually my second level of search.
> From that perspective, I'm curious to see if it would make sense to consider 
> a "functional" abstraction layer under which, we can add the various API 
> flavors? For example, SSL, Headers, Intercept, Transform etc and then under 
> each of those, you've C, CPP, LUA etc.
> Thoughts?
> Thanks,
> Sudheer
>
>     On Friday, May 24, 2019, 9:42:28 AM PDT, Shu Kit Chan 
> <chanshu...@gmail.com> wrote:
>
>  Leif made a suggestion on the PR and suggested the following structure 
> instead
>
>     example/
>         plugins/
>             c-api/
>                 null-transform/
>             cpp-api/
>                 ...
>             lua-api/
>                 ...
>         configs/
>             forward/
>             reverse/
>             transparent/
>
> I think it is easier to find the c/c++/lua examples this way as well.
>
> Any comments?
>
> Kit
>
> On Fri, May 24, 2019 at 12:47 AM Shu Kit Chan <chanshu...@gmail.com> wrote:
> >
> > Here is the PR for this change.
> > https://github.com/apache/trafficserver/pull/5573
> >
> > Thanks.
> >
> > Kit
> >
> > On Tue, May 21, 2019 at 12:29 PM Steven R. Feltner <sfelt...@godaddy.com> 
> > wrote:
> > >
> > > +1
> > >
> > > On 5/21/19, 2:50 AM, "Shu Kit Chan" <chanshu...@gmail.com> wrote:
> > >
> > >    Notice: This email is from an external sender.
> > >
> > >
> > >
> > >    Hi,
> > >
> > >    During the spring summit, we discussed changing the structure example
> > >    directory to include some lua scripts as well as other future works
> > >
> > >    Here is my proposal -
> > >
> > >    /example/plugins/ - I will move all existing plugin examples 
> > > underneath here
> > >    /example/plugins/lua/ - I will put a few lua scripts as example here
> > >    /example/config/ - in future we can put some directories here showing
> > >    examples of configuration files (e.g. cache.config, ip_allow.config,
> > >    logging.yaml, etc)
> > >
> > >    Any thoughts?
> > >
> > >    Thanks.
> > >
> > >    Kit
> > >
> > >

Reply via email to