Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-25 Thread Willy Tarreau
On Mon, Jul 24, 2017 at 02:38:41PM +0200, Willy Tarreau wrote: > On Mon, Jul 24, 2017 at 02:04:16PM +0200, Thierry FOURNIER wrote: > > On Thu, 20 Jul 2017 15:26:52 +0200 > > You will found in attchement a patch which add the proxy name as member > > of the proxy object. > > > > Willy, can you

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-24 Thread Willy Tarreau
On Mon, Jul 24, 2017 at 02:04:16PM +0200, Thierry FOURNIER wrote: > On Thu, 20 Jul 2017 15:26:52 +0200 > You will found in attchement a patch which add the proxy name as member > of the proxy object. > > Willy, can you apply it ? I'd like to but there's no attachment, so even trying hard I'm

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-24 Thread Willy Tarreau
On Mon, Jul 24, 2017 at 02:27:03PM +0200, Thierry FOURNIER wrote: > an other case pop in my mind: with this solution, the "listen" proxies > will be declared in both lists. I think that it is the expected behaviour, > but I have some doubt about the usage. Yes I think it's desirable. > I can add

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-24 Thread Thierry FOURNIER
On Mon, 24 Jul 2017 14:03:30 +0200 Willy Tarreau wrote: > Hi Thierry, > > On Mon, Jul 24, 2017 at 01:30:23PM +0200, Thierry FOURNIER wrote: > > Ok. After brainstorm, I think that the it will be netter to keep the > > current behaviour to avoid breaking existing Lua implementations.

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-24 Thread Adis Nezirovic
On 07/24/2017 01:30 PM, Thierry FOURNIER wrote: > I think that the most reliable way is adding anoter tree. We keep the > "proxies" tree base with existing, and we add two trees "frontends" and > "backends" which contains respecticely the list of frontends and > backends. This would work for me

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-24 Thread Thierry FOURNIER
On Thu, 20 Jul 2017 15:26:52 +0200 Adis Nezirovic wrote: > On 07/20/2017 02:55 PM, Willy Tarreau wrote: > > So you can have : > > 0 or 1 "listen" > > 0 or 1 "frontend" + 0 or 1 "backend" > > > > Just a few ideas come to my mind : > > - is it possible to store

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-24 Thread Willy Tarreau
Hi Thierry, On Mon, Jul 24, 2017 at 01:30:23PM +0200, Thierry FOURNIER wrote: > Ok. After brainstorm, I think that the it will be netter to keep the > current behaviour to avoid breaking existing Lua implementations. > > Adding other entries with prefix "@f:" and "@b:" in the same list that >

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-24 Thread Thierry FOURNIER
On Thu, 20 Jul 2017 15:26:52 +0200 Adis Nezirovic wrote: > On 07/20/2017 02:55 PM, Willy Tarreau wrote: > > So you can have : > > 0 or 1 "listen" > > 0 or 1 "frontend" + 0 or 1 "backend" > > > > Just a few ideas come to my mind : > > - is it possible to store

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-20 Thread Adis Nezirovic
On 07/20/2017 02:55 PM, Willy Tarreau wrote: > So you can have : > 0 or 1 "listen" > 0 or 1 "frontend" + 0 or 1 "backend" > > Just a few ideas come to my mind : > - is it possible to store arrays into arrays ? I mean, could we have > for example core.proxies["foo"].side[FRONT|BACK]

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-20 Thread Willy Tarreau
Hi guys, On Thu, Jul 20, 2017 at 02:35:22PM +0200, Adis Nezirovic wrote: > On 07/20/2017 12:17 PM, Thierry FOURNIER wrote: > > I understand the problem, but I can't accept this patch because it makes > > the proxies list unusable. Your patch remove the proxies names, and the > > user cannot have

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-20 Thread Adis Nezirovic
On 07/20/2017 12:17 PM, Thierry FOURNIER wrote: > I understand the problem, but I can't accept this patch because it makes > the proxies list unusable. Your patch remove the proxies names, and the > user cannot have solution for knowning the real name of the proxies > now called 1, 2, 3, ... > >

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-20 Thread Thierry FOURNIER
Hi Adis, Sorry, I dont saw this patch proposal. I understand the problem, but I can't accept this patch because it makes the proxies list unusable. Your patch remove the proxies names, and the user cannot have solution for knowning the real name of the proxies now called 1, 2, 3, ... I propose

Re: [PATCH] Support proxies with identical names in Lua core.proxies

2017-07-19 Thread Willy Tarreau
Hi Adis, I missed this one. Thierry, I *think* it's OK, are you OK with me merging it ? Willy On Mon, Jun 05, 2017 at 05:37:23PM +0200, Adis Nezirovic wrote: > Hi guys, > > While playing with Lua API I've noticed that core.proxies attribute > doesn't return all the proxies, more precisely the