You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When you hit that page (/metadata/record.iso.xml), Django sends a request to CouchDB requesting all of the urls. CouchDB responds very quickly, but then the crummy part starts. Django has to determine whether or not you have permission to view each one of the records. If you are logged out (an anonymous user), then Django has to pull out of the list each item that is unpublished. If you are logged in, Django shows URLs to unpublished records that you have access to. Django performs the authorization query one record at a time. Iterating over a large number of records takes a really long time, and eventually Nginx decides that there's not a response coming back and times out.
Remedies:
Change CouchDB view so that it only returns public records and Django doesn't have to run any permissions checks
Change the whole thing so that CouchDB is authentication-aware and only returns relevant records
Debugging on branch permissions.
The text was updated successfully, but these errors were encountered:
From Ryan:
When you hit that page (/metadata/record.iso.xml), Django sends a request to CouchDB requesting all of the urls. CouchDB responds very quickly, but then the crummy part starts. Django has to determine whether or not you have permission to view each one of the records. If you are logged out (an anonymous user), then Django has to pull out of the list each item that is unpublished. If you are logged in, Django shows URLs to unpublished records that you have access to. Django performs the authorization query one record at a time. Iterating over a large number of records takes a really long time, and eventually Nginx decides that there's not a response coming back and times out.
Remedies:
Debugging on branch
permissions
.The text was updated successfully, but these errors were encountered: