You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lenya.apache.org by Thorsten Scherler <th...@juntadeandalucia.es> on 2007/05/23 09:46:29 UTC

Global proxy url (was Re: DO NOT REPLY [Bug 42050] - proxying does not work)

On Tue, 2007-05-22 at 07:46 -0700, bugzilla@apache.org wrote:
...
> ------- Additional Comments From thorsten@apache.org  2007-05-22 07:46 -------
> Created an attachment (id=20241)
>  --> (http://issues.apache.org/bugzilla/attachment.cgi?id=20241&action=view)
> proxyTransformer version 1
> 
> This is the first version of the proxy transformer. 
> 
> The open issues are still the following cases:
> a) <link type="text/css" href="/default/modules/homepage/css/homepage.css"
> rel="stylesheet" /> - Using pub but not a valid area
> b) <a href="/index.html"><span>Apache Lenya Homepage</span></a> - the menu
> links which should point to the website IMO anyway
> c) <img alt="he" src="/modules/languageselector/flag-he-13.png" /> and <script
> src="/lenya/menu/menu.js" type="text/javascript"> </script> - point to the
> absolute root.
> 
> a) and c) can be solved introducing a global proxy url. 
> Meaning something like:
> <proxies url="https://www.host.com/lenya/">
> 
> Will now test the patch from andreas.

I tested the patch (nice work Andreas) and in combination with the
proxyTransformer we are nearly done.

What is still missing is a global proxy url that will be used in the
cases a-c.

I propose to extend <proxies root="https://www.host.com/lenya/"> where
we then transform the root "/" to "https://www.host.com/lenya/" in the
above described cases.

For a) it would e.g. be:
href="/default/modules/homepage/css/homepage.css" becomes
href="https://www.host.com/lenya/default/modules/homepage/css/homepage.css" since the first "/" will be replaced by proxies/@root.

wdyt?

salu2
-- 
Thorsten Scherler                                 thorsten.at.apache.org
Open Source Java                      consulting, training and solutions


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org


Re: Global proxy url (was Re: DO NOT REPLY [Bug 42050] - proxying does not work)

Posted by Thorsten Scherler <th...@juntadeandalucia.es>.
On Wed, 2007-05-23 at 10:11 +0200, Andreas Hartmann wrote:
> Thorsten Scherler schrieb:
> > On Tue, 2007-05-22 at 07:46 -0700, bugzilla@apache.org wrote:
> > ...
> >> ------- Additional Comments From thorsten@apache.org  2007-05-22 07:46 -------
> >> Created an attachment (id=20241)
> >>  --> (http://issues.apache.org/bugzilla/attachment.cgi?id=20241&action=view)
> >> proxyTransformer version 1
> >>
> >> This is the first version of the proxy transformer. 
> >>
> >> The open issues are still the following cases:
> >> a) <link type="text/css" href="/default/modules/homepage/css/homepage.css"
> >> rel="stylesheet" /> - Using pub but not a valid area
> 
> IMO this should not be a valid URL with the current architecure.
> It should rather be
> 
>   /default/{area}/modules/homepage/css/homepage.css
> 
> But for the sake of a smooth transition away from areas, we should
> probably leave it like this.
> 
> 
> >> b) <a href="/index.html"><span>Apache Lenya Homepage</span></a> - the menu
> >> links
> 
> That's not a valid link in a production environment.
> 
> > which should point to the website IMO anyway
> 
> +1, let's get rid of links like that.
> 
> 
> >> c) <img alt="he" src="/modules/languageselector/flag-he-13.png" /> and <script
> >> src="/lenya/menu/menu.js" type="text/javascript"> </script> - point to the
> >> absolute root.
> >>
> >> a) and c) can be solved introducing a global proxy url.
> 
> The problem here is that if this URL points to a live environment, you
> can't test the current changes to the modules. You'd need a different
> configuration for the live and authoring environments.
> 
> That could be solved by replacing /{pubId}/modules/... URLs with
> /{pubId}/{area}/modules.
> 
> But I'm not sure if this is the only option, I'll take a closer
> look at the proxy transformer first.

I aggregated all patches from 42050 to one.

Proxying is now back for authoring and live, however all urls based on
usecases are not be proxy at all.

Meaning
http://localhost:8888/default/authoring/index.html?lenya.usecase=ac.login will not be rewritten. 

I guess we need to add the proxyTransformer as last step for the usecase
match, where is it?

salu2
-- 
Thorsten Scherler                                 thorsten.at.apache.org
Open Source Java                      consulting, training and solutions


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org


Re: Global proxy url (was Re: DO NOT REPLY [Bug 42050] - proxying does not work)

Posted by Andreas Hartmann <an...@apache.org>.
Thorsten Scherler schrieb:
> On Tue, 2007-05-22 at 07:46 -0700, bugzilla@apache.org wrote:
> ...
>> ------- Additional Comments From thorsten@apache.org  2007-05-22 07:46 -------
>> Created an attachment (id=20241)
>>  --> (http://issues.apache.org/bugzilla/attachment.cgi?id=20241&action=view)
>> proxyTransformer version 1
>>
>> This is the first version of the proxy transformer. 
>>
>> The open issues are still the following cases:
>> a) <link type="text/css" href="/default/modules/homepage/css/homepage.css"
>> rel="stylesheet" /> - Using pub but not a valid area

IMO this should not be a valid URL with the current architecure.
It should rather be

  /default/{area}/modules/homepage/css/homepage.css

But for the sake of a smooth transition away from areas, we should
probably leave it like this.


>> b) <a href="/index.html"><span>Apache Lenya Homepage</span></a> - the menu
>> links

That's not a valid link in a production environment.

> which should point to the website IMO anyway

+1, let's get rid of links like that.


>> c) <img alt="he" src="/modules/languageselector/flag-he-13.png" /> and <script
>> src="/lenya/menu/menu.js" type="text/javascript"> </script> - point to the
>> absolute root.
>>
>> a) and c) can be solved introducing a global proxy url.

The problem here is that if this URL points to a live environment, you
can't test the current changes to the modules. You'd need a different
configuration for the live and authoring environments.

That could be solved by replacing /{pubId}/modules/... URLs with
/{pubId}/{area}/modules.

But I'm not sure if this is the only option, I'll take a closer
look at the proxy transformer first.

-- Andreas


>> Meaning something like:
>> <proxies url="https://www.host.com/lenya/">
>>
>> Will now test the patch from andreas.
> 
> I tested the patch (nice work Andreas) and in combination with the
> proxyTransformer we are nearly done.
> 
> What is still missing is a global proxy url that will be used in the
> cases a-c.
> 
> I propose to extend <proxies root="https://www.host.com/lenya/"> where
> we then transform the root "/" to "https://www.host.com/lenya/" in the
> above described cases.
> 
> For a) it would e.g. be:
> href="/default/modules/homepage/css/homepage.css" becomes
> href="https://www.host.com/lenya/default/modules/homepage/css/homepage.css" since the first "/" will be replaced by proxies/@root.
> 
> wdyt?
> 
> salu2


-- 
Andreas Hartmann, CTO
BeCompany GmbH
http://www.becompany.ch


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org


Re: Global proxy url (was Re: DO NOT REPLY [Bug 42050] - proxying does not work)

Posted by Thorsten Scherler <th...@juntadeandalucia.es>.
On Wed, 2007-05-23 at 09:46 +0200, Thorsten Scherler wrote:
> On Tue, 2007-05-22 at 07:46 -0700, bugzilla@apache.org wrote:
> ...
> > ------- Additional Comments From thorsten@apache.org  2007-05-22 07:46 -------
> > Created an attachment (id=20241)
> >  --> (http://issues.apache.org/bugzilla/attachment.cgi?id=20241&action=view)
> > proxyTransformer version 1
> > 
> > This is the first version of the proxy transformer. 
> > 
> > The open issues are still the following cases:
> > a) <link type="text/css" href="/default/modules/homepage/css/homepage.css"
> > rel="stylesheet" /> - Using pub but not a valid area
> > b) <a href="/index.html"><span>Apache Lenya Homepage</span></a> - the menu
> > links which should point to the website IMO anyway
> > c) <img alt="he" src="/modules/languageselector/flag-he-13.png" /> and <script
> > src="/lenya/menu/menu.js" type="text/javascript"> </script> - point to the
> > absolute root.
> > 
> > a) and c) can be solved introducing a global proxy url. 
> > Meaning something like:
> > <proxies url="https://www.host.com/lenya/">
> > 
> > Will now test the patch from andreas.
> 
> I tested the patch (nice work Andreas) and in combination with the
> proxyTransformer we are nearly done.
> 
> What is still missing is a global proxy url that will be used in the
> cases a-c.
> 
> I propose to extend <proxies root="https://www.host.com/lenya/"> where

That should read:
<proxies root="https://www.host.com/lenya/" ssl="true"> 

salu2
-- 
Thorsten Scherler                                 thorsten.at.apache.org
Open Source Java                      consulting, training and solutions


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org