SwellRT / swellrt

SwellRT main project. Server, JavaScript and Java clients
http://swellrt.org/
Apache License 2.0
234 stars 34 forks source link

No 'Access-Control-Allow-Origin' header in access calls #104

Closed atd closed 8 years ago

atd commented 8 years ago

swellrt.org is showing the following message:

XMLHttpRequest cannot load http://demo.swellrt.org/swell/access/write/demo.swellrt.org/s+mCDtyYi9oeA/~/swl+root;sid=tqe0534sa26b1bkd6zawue0ev. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://swellrt.org' is therefore not allowed access. The response had HTTP status code 504.

pablojan commented 8 years ago

I've ran into this yesterday and it seems more likely a timeout problem. Please check in the browser's network log the load time of that request.

2016-02-11 11:08 GMT+01:00 Antonio Tapiador notifications@github.com:

swellrt.org is showing the following message:

XMLHttpRequest cannot load http://demo.swellrt.org/swell/access/write/demo.swellrt.org/s+mCDtyYi9oeA/~/swl+root;sid=tqe0534sa26b1bkd6zawue0ev. No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'http://swellrt.org' is therefore not allowed access. The response had HTTP status code 504.

— Reply to this email directly or view it on GitHub https://github.com/P2Pvalue/swellrt/issues/104.

atd commented 8 years ago

I am trying to reproduce it, but the pad does not load in Chromium

It works ok in Iceweasel

pablojan commented 8 years ago

Ok, please check the requests to

http://demo.swellrt.org/swell/access http://demo.swellrt.org/swell/access/write/demo.swellrt.org/s+mCDtyYi9oeA/%7E/swl+root;sid=tqe0534sa26b1bkd6zawue0ev

I really think they are the problem.

2016-02-11 12:22 GMT+01:00 Antonio Tapiador notifications@github.com:

I am trying to reproduce it, but the pad does not load in Chromium

It works ok in Iceweasel

— Reply to this email directly or view it on GitHub https://github.com/P2Pvalue/swellrt/issues/104#issuecomment-182814065.

atd commented 8 years ago
GET /swell/access/write/demo.swellrt.org/s+mCDtyYi9oeA/~/swl+root;sid=tqe0534sa26b1bkd6zawue0ev HTTP/1.1
Host: demo.swellrt.org
Connection: keep-alive
Origin: http://swellrt.org
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/47.0.2526.80 Safari/537.36
Content-Type: application/x-www-form-urlencoded
Accept: */*
Referer: http://swellrt.org/
Accept-Encoding: gzip, deflate, sdch
Accept-Language: en-US,en;q=0.8,es;q=0.6
Cookie: WSESSIONID=tqe0534sa26b1bkd6zawue0ev

HTTP/1.1 200 OK
Server: nginx/1.6.2
Date: Thu, 11 Feb 2016 12:07:25 GMT
Content-Type: application/json
Transfer-Encoding: chunked
Connection: keep-alive
Access-Control-Allow-Origin: http://swellrt.org
Access-Control-Allow-Credentials: true
Access-Control-Expose-Headers: 
Cache-Control: no-store

{"waveId":"demo.swellrt.org/s+mCDtyYi9oeA","waveletId":"demo.swellrt.org/swl+root","canWrite":true,"canRead":true,"participantId":"_anonymous_tqe0534sa26b1bkd6zawue0ev@demo.swellrt.org"}
pablojan commented 8 years ago

@atd did you run into this issue during last week?

atd commented 8 years ago

It still takes about 30 seconds to respond to that request, pad loads after 1 minute (Chromium 47)

pablojan commented 8 years ago

Ok, I working on that, it's related with participation model and #156

2016-02-17 12:01 GMT+01:00 Antonio Tapiador notifications@github.com:

It still takes about 30 seconds to respond to that request, pad loads after 1 minute (Chromium 47)

— Reply to this email directly or view it on GitHub https://github.com/P2Pvalue/swellrt/issues/104#issuecomment-185155346.

pablojan commented 8 years ago

Caused by the currently removed request access operation