Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
Message from discussion Domain name aliases cause problems for nowjs file caching

Received: by 10.14.119.5 with SMTP id m5mr1039258eeh.55.1307294403507;
        Sun, 05 Jun 2011 10:20:03 -0700 (PDT)
X-BeenThere: nowjs@googlegroups.com
Received: by 10.14.14.136 with SMTP id d8ls503638eed.6.gmail; Sun, 05 Jun 2011
 10:20:02 -0700 (PDT)
Received: by 10.14.95.141 with SMTP id p13mr1045694eef.38.1307294402745;
        Sun, 05 Jun 2011 10:20:02 -0700 (PDT)
Received: by 10.14.95.141 with SMTP id p13mr1045693eef.38.1307294402708;
        Sun, 05 Jun 2011 10:20:02 -0700 (PDT)
Return-Path: <tommed...@gmail.com>
Received: from mail-ey0-f173.google.com (mail-ey0-f173.google.com [209.85.215.173])
        by gmr-mx.google.com with ESMTPS id x47si2507409eef.1.2011.06.05.10.20.02
        (version=TLSv1/SSLv3 cipher=OTHER);
        Sun, 05 Jun 2011 10:20:02 -0700 (PDT)
Received-SPF: pass (google.com: domain of tommed...@gmail.com designates 209.85.215.173 as permitted sender) client-ip=209.85.215.173;
Authentication-Results: gmr-mx.google.com; spf=pass (google.com: domain of tommed...@gmail.com designates 209.85.215.173 as permitted sender) smtp.mail=tommed...@gmail.com; dkim=pass (test mode) header...@gmail.com
Received: by eyb6 with SMTP id 6so1295511eyb.4
        for <nowjs@googlegroups.com>; Sun, 05 Jun 2011 10:20:02 -0700 (PDT)
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed;
        d=gmail.com; s=gamma;
        h=domainkey-signature:mime-version:in-reply-to:references:date
         :message-id:subject:from:to:content-type;
        bh=AMTaVESlAoQ98gZxhCeRc6wLQht9+1phWKV9k7LE/zE=;
        b=ACixHVQxqc6UGF0WhwxCuMQf/UpKqs3KRlzboxqqRRXTB2LqX1kmQ78OI/Oq+ttSde
         A18cybnTS/2eLgLzgqb2ra8xx/r4qjgfBZB5K1EZHO2WyLeH2lZYsbkFjGlH3AsIyA2+
         zJvZVr9V+1QU7fwOv3L+dl57C8VBSkDC1xzP8=
DomainKey-Signature: a=rsa-sha1; c=nofws;
        d=gmail.com; s=gamma;
        h=mime-version:in-reply-to:references:date:message-id:subject:from:to
         :content-type;
        b=wAKX76jpLwdAgb6UCVCMLf3DW1wbtx3+UiGZwurt41CJZn/bvrxvdARWtZ5xL6QRQd
         kfwAVcAzwpMfmCTeP3dO6xZ3Bc722vGK2xGW4a5lPzAm4+lQ8kui0HkzqMpngQUQ/HdZ
         6ykXE1ieuw/dwaQzxKo15AU2RWG+OjkOFJRqQ=
MIME-Version: 1.0
Received: by 10.14.11.132 with SMTP id 4mr1543041eex.45.1307294402371; Sun, 05
 Jun 2011 10:20:02 -0700 (PDT)
Received: by 10.14.95.138 with HTTP; Sun, 5 Jun 2011 10:20:02 -0700 (PDT)
In-Reply-To: <BANLkTi=ZEYus9kAAnr9yOkxyRTArT4F...@mail.gmail.com>
References: <819dad53-8269-4e72-8461-b46836013...@16g2000yqy.googlegroups.com>
	<BANLkTiniOdqj-Z6n9zjZ-wvU3Oj18yA...@mail.gmail.com>
	<BANLkTi=ZEYus9kAAnr9yOkxyRTArT4F...@mail.gmail.com>
Date: Sun, 5 Jun 2011 19:20:02 +0200
Message-ID: <BANLkTi=VcDDZCyp=xhFAbXzGZQOpH5i...@mail.gmail.com>
Subject: Re: [NowJS] Domain name aliases cause problems for nowjs file caching
From: Tom <tommed...@gmail.com>
To: nowjs@googlegroups.com
Content-Type: multipart/alternative; boundary=0016364c7b0978617e04a4fa3266

--0016364c7b0978617e04a4fa3266
Content-Type: text/plain; charset=ISO-8859-1

On another side note Facebook seems to redirect all requests to
http://facebook.com to http://www.facebook.com -- so if you're going this
road, it comes down to a matter of preference on whether you keep www or
not. One argument to keep it would be that many users believe that the www
prefix is mandatory in accessing a site, so that they might feel more
comfortable by actually seeing this 'www' back in the address bar.

Admittedly this does not have much to do with solving your problem. Sorry I
cannot help you further.

Tom

2011/6/5 Eric Zhang <e...@nowjs.com>

> So according to Tom it seems that redirecting clients to a canonical domain
> is the solution because it benefits you SEO wise.
>
>
> One note is the cached files in your case should still work as cross-domain
> and port requests are fully supported with WebSockets, and jsonp-polling. If
> you use the insecure version of the flashsockets swf then you can get
> flashsockets to also work crossdomain/port.
>
> Of course that is not optimal when you can have things not be cross-domain
> but it shouldn't be not working at all. (Detecting whether the connection
> should be cross-domain or not is determined at runtime so it's not a problem
> that cached files are originally set when not-cross-domain but then used in
> cross-domain context)
>
> Wow ok that was a mouthful. Good luck!
>
> Eric
>
>
> On Sun, Jun 5, 2011 at 6:29 AM, Tom <tommed...@gmail.com> wrote:
>
>> The following is slightly related, but not an answer to your question.
>>
>> From a SEO point of view you would gain from 303ing all requests from the
>> www subdomain to the root or the other way around. www is considered to be a
>> subdomain and if you adhere to both you may be penalized as people will link
>> to the same pages in different ways.
>>
>> For example, twitter redirects all requests to http://www.twitter.com to
>> http://twitter.com (but this could also be done the other way around.
>>
>> Tom
>>
>>
>> 2011/6/5 Richard Rodger <rich...@chartaca.com>
>>
>>> Hi Guys,
>>>
>>> I've come across a problem where the site I am using nowjs on can be
>>> reach from www.example.com and example.com
>>>
>>> Depending on which domain alias is used randomly by clients after a
>>> restart, nowjs "fixes" on the domain alias in fileServer.js, and
>>> requests to the other domain don't work - because the cached files are
>>> returned and fall afoul of the cross-domain restriction.
>>>
>>> My fix was to redirect all clients to a canonical domain - is this the
>>> right approach?
>>>
>>> thanks,
>>> Richard
>>>
>>
>>
>

--0016364c7b0978617e04a4fa3266
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: quoted-printable

On another side note Facebook seems to redirect all requests to <a href=3D"=
http://facebook.com">http://facebook.com</a> to <a href=3D"http://www.faceb=
ook.com">http://www.facebook.com</a> -- so if you&#39;re going this road, i=
t comes down to a matter of preference on whether you keep www or not. One =
argument to keep it would be that many users believe that the www prefix is=
 mandatory in accessing a site, so that they might feel more comfortable by=
 actually seeing this &#39;www&#39; back in the address bar.<div>
<br></div><div>Admittedly this does not have much to do with solving your p=
roblem. Sorry I cannot help you further.</div><div><br></div><div>Tom<br><b=
r><div class=3D"gmail_quote">2011/6/5 Eric Zhang <span dir=3D"ltr">&lt;<a h=
ref=3D"mailto:e...@nowjs.com">e...@nowjs.com</a>&gt;</span><br>
<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=
x #ccc solid;padding-left:1ex;">So according to Tom it seems that redirecti=
ng clients to a canonical domain is the solution because it benefits you SE=
O wise.<div>
<br></div><div><br></div><div>One note is the cached files in your case sho=
uld still work as cross-domain and port requests are fully supported with W=
ebSockets, and jsonp-polling. If you use the insecure version of the flashs=
ockets swf then you can get flashsockets to also work crossdomain/port.=A0<=
/div>


<div><br></div><div>Of course that is not optimal when you can have things =
not be cross-domain but it shouldn&#39;t be not working at all. (Detecting =
whether the connection should be cross-domain or not is determined at runti=
me so it&#39;s not a problem that cached files are originally set when not-=
cross-domain but then used in cross-domain context)</div>


<div><br></div><div>Wow ok that was a mouthful. Good luck!</div><div><br></=
div><div><font color=3D"#888888">Eric</font><div><div></div><div class=3D"h=
5"><br><div><br><div class=3D"gmail_quote">On Sun, Jun 5, 2011 at 6:29 AM, =
Tom <span dir=3D"ltr">&lt;<a href=3D"mailto:tommed...@gmail.com" target=3D"=
_blank">tommed...@gmail.com</a>&gt;</span> wrote:<br>


<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=
x #ccc solid;padding-left:1ex"><div>The following is slightly related, but =
not an answer to your question.</div><div><br></div>From a SEO point of vie=
w you would gain from 303ing all requests from the www subdomain to the roo=
t or the other way around. www is considered to be a subdomain and if you a=
dhere to both you may be penalized as people will link to the same pages in=
 different ways.<div>



<br></div><div>For example, twitter redirects all requests to <a href=3D"ht=
tp://www.twitter.com" target=3D"_blank">http://www.twitter.com</a> to <a hr=
ef=3D"http://twitter.com" target=3D"_blank">http://twitter.com</a> (but thi=
s could also be done the other way around.</div>



<div><br></div><div><font color=3D"#888888">Tom</font><div><div></div><div>=
<br><br><div class=3D"gmail_quote">2011/6/5 Richard Rodger <span dir=3D"ltr=
">&lt;<a href=3D"mailto:rich...@chartaca.com" target=3D"_blank">richard@cha=
rtaca.com</a>&gt;</span><br>


<blockquote class=3D"gmail_quote" style=3D"margin:0 0 0 .8ex;border-left:1p=
x #ccc solid;padding-left:1ex">
Hi Guys,<br>
<br>
I&#39;ve come across a problem where the site I am using nowjs on can be<br=
>
reach from <a href=3D"http://www.example.com" target=3D"_blank">www.example=
.com</a> and <a href=3D"http://example.com" target=3D"_blank">example.com</=
a><br>
<br>
Depending on which domain alias is used randomly by clients after a<br>
restart, nowjs &quot;fixes&quot; on the domain alias in fileServer.js, and<=
br>
requests to the other domain don&#39;t work - because the cached files are<=
br>
returned and fall afoul of the cross-domain restriction.<br>
<br>
My fix was to redirect all clients to a canonical domain - is this the<br>
right approach?<br>
<br>
thanks,<br>
<font color=3D"#888888">Richard<br>
</font></blockquote></div><br></div></div></div>
</blockquote></div><br></div></div></div></div>
</blockquote></div><br></div>

--0016364c7b0978617e04a4fa3266--