You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@shindig.apache.org by Viji Subramanian <Vi...@corp.aol.com> on 2008/06/20 03:09:28 UTC
proxy and concat proxy urls
I see that the proxyUrl has been hardcoded to /gadgets/proxy?url= and
concat proxy hardcoded to /gadgets/concat? - for instance in the
DefaultContentRewriter class.
Can this be moved to gadgets.properties as
urls.proxy.prefix=/gadgets/proxy?url=
urls.concat.prefix=/gadgets/concat?
similar to urls.iframe.prefix...so that we could use @Named guice
injection .. for the above two..
I already have an app deployed in tomcat.. with <Context path=""
docBase="mymainapp" /> and when I deploy shindig as a separate app in
tomcat, the proxy and concat proxy calls gives me a 404.. as proxy url
is missing the appname..
http://hostname:8080/gadgets/proxy?... - 404...it has to be
http://hostname:8080/<my shindig app>/gadgets/proxy?url=...
Adding the above would give me the flexibility to specify
urls.proxy.prefix=<my shindig app>/gadgets/proxy?url=.. ...
I had to make the above change to fit my needs.
any thoughts..
thanks
Re: proxy and concat proxy urls
Posted by Viji Subramanian <Vi...@corp.aol.com>.
Kevin Brown wrote:
> On Thu, Jun 19, 2008 at 6:09 PM, Viji Subramanian <
> Viji.Subramanian@corp.aol.com> wrote:
>
>
>> I see that the proxyUrl has been hardcoded to /gadgets/proxy?url= and
>> concat proxy hardcoded to /gadgets/concat? - for instance in the
>> DefaultContentRewriter class.
>>
>> Can this be moved to gadgets.properties as
>>
>> urls.proxy.prefix=/gadgets/proxy?url=
>> urls.concat.prefix=/gadgets/concat?
>> similar to urls.iframe.prefix...so that we could use @Named guice injection
>> .. for the above two..
>>
>
>
> Yeah, this is a real pain -- I had to work around it already for our
> deployment. Louis was going to move this into a config file, but he's on
> vacation right now.
>
> The right thing here is going to be to have a *single* entry in the
> properties file for the context root, with everything else being relative to
> that. That requires cleaning up at least 4-5 places though, so it's not a
> trivial update.
>
> Hard coded urls are bad. Let this be a lesson for anyone who adds new ones
> in the future :).
>
> Go ahead and open a JIRA ticket on this issue so that it isn't forgetten.
>
We ended up using apache ModRewrite instead of changing the shindig code..
nevertheless, hardcoded urls have to be cleaned up..
the ticket key is SHINDIG-400
https://issues.apache.org/jira/browse/SHINDIG-400
thanks
>
>> I already have an app deployed in tomcat.. with <Context path=""
>> docBase="mymainapp" /> and when I deploy shindig as a separate app in
>> tomcat, the proxy and concat proxy calls gives me a 404.. as proxy url is
>> missing the appname..
>> http://hostname:8080/gadgets/proxy?... - 404...it has to be
>> http://hostname:8080/<my shindig app>/gadgets/proxy?url=...
>>
>> Adding the above would give me the flexibility to specify
>> urls.proxy.prefix=<my shindig app>/gadgets/proxy?url=.. ...
>>
>> I had to make the above change to fit my needs.
>>
>> any thoughts..
>>
>> thanks
>>
>>
>>
>>
>>
>>
>
>
Re: proxy and concat proxy urls
Posted by Kevin Brown <et...@google.com>.
On Thu, Jun 19, 2008 at 6:09 PM, Viji Subramanian <
Viji.Subramanian@corp.aol.com> wrote:
> I see that the proxyUrl has been hardcoded to /gadgets/proxy?url= and
> concat proxy hardcoded to /gadgets/concat? - for instance in the
> DefaultContentRewriter class.
>
> Can this be moved to gadgets.properties as
>
> urls.proxy.prefix=/gadgets/proxy?url=
> urls.concat.prefix=/gadgets/concat?
> similar to urls.iframe.prefix...so that we could use @Named guice injection
> .. for the above two..
Yeah, this is a real pain -- I had to work around it already for our
deployment. Louis was going to move this into a config file, but he's on
vacation right now.
The right thing here is going to be to have a *single* entry in the
properties file for the context root, with everything else being relative to
that. That requires cleaning up at least 4-5 places though, so it's not a
trivial update.
Hard coded urls are bad. Let this be a lesson for anyone who adds new ones
in the future :).
Go ahead and open a JIRA ticket on this issue so that it isn't forgetten.
>
>
> I already have an app deployed in tomcat.. with <Context path=""
> docBase="mymainapp" /> and when I deploy shindig as a separate app in
> tomcat, the proxy and concat proxy calls gives me a 404.. as proxy url is
> missing the appname..
> http://hostname:8080/gadgets/proxy?... - 404...it has to be
> http://hostname:8080/<my shindig app>/gadgets/proxy?url=...
>
> Adding the above would give me the flexibility to specify
> urls.proxy.prefix=<my shindig app>/gadgets/proxy?url=.. ...
>
> I had to make the above change to fit my needs.
>
> any thoughts..
>
> thanks
>
>
>
>
>