couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Paul Frazee (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (COUCHDB-1651) Server responds 400 "Exceeded rewrite recursion limit" indefinitely
Date Tue, 12 Feb 2013 03:07:13 GMT

    [ https://issues.apache.org/jira/browse/COUCHDB-1651?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13576330#comment-13576330
] 

Paul Frazee commented on COUCHDB-1651:
--------------------------------------

Another update as I work on this. I removed all root-level rewrites. Here are my vhosts (I
have multiple design documents in use):

{code}
grimwire.com/_browserid = /_browserid
grimwire.com/local      = /grimwire/_design/local/_rewrite
grimwire.com/_changes   = /grimwire/_changes
grimwire.com/assets     = /grimwire/_design/assets/_rewrite
grimwire.com/email      = /email/_design/email/_rewrite
grimwire.com            = /grimwire/_design/grimwire/_rewrite
{code}

And here are the four rewrite jsons:

{code}
[
	{
		"from":"",
		"to":"index.html",
		"method":"GET"
	},
	{
		"from":"/posts",
		"to":"_list/wallpost/wallpost-by-created_at",
		"method":"GET"
	},
	{
		"from":"/posts",
		"to":"_update/wallpost",
		"method":"POST"
	},
	{
		"from":"/posts/:id",
		"to":"_show/wallpost/:id",
		"method":"GET"
	},
	{
		"from":"/posts/:id",
		"to":"_update/wallpost/:id",
		"method":"PUT"
	},
	{
		"from":"/types/:id",
		"to":"_show/type/_design/local",
		"query":{"type":":id"},
		"method":"GET"
	},
	{
		"from":"/apps/*",
		"to":"/apps/*"
	},
	{
		"from":"/assets/*",
		"to":"/assets/*"
	},
	{
		"from":"/docs/*",
		"to":"/docs/*"
	},
	{
		"from":"/lib/*",
		"to":"/lib/*"
	}
]

{code}
[
	{ "from": "", "to": "index.html", "method": "GET" },
	{ "from": "index.html", "to": "index.html", "method": "GET" },
	{ "from": "index.css", "to": "index.css", "method": "GET" },
	{ "from": "index.js", "to": "index.js", "method": "GET" },
	{ "from": "grim/*", "to": "grim/*", "method": "GET" }
]
{code}

{code}
[
	{
		"from":"",
		"to":"_update/message",
		"method":"POST"
	},
	{
		"from":"",
		"to":"../../",
		"method":"GET"
	},
	{
		"from":"/:key",
		"to":"../../:key",
		"method":"GET"
	}
]
{code}

{code}
[
    {
        "from": "bootstrap/*",
        "to": "bootstrap/*"
    },
    {
        "from": "fontello/*",
        "to": "fontello/*"
    },
    {
        "from":"icons/*",
        "to": "icons/*"
    }
]
{code}

I got suspicious of my vhosts (because one application is root-level) so I moved that app
to a subpath (grimwire.com/grim/). However, that didn't solve the problem.

Usually, I can trigger the problem within 10-15 refreshes of a page (each of which triggers
35 asset requests).
                
> Server responds 400 "Exceeded rewrite recursion limit" indefinitely
> -------------------------------------------------------------------
>
>                 Key: COUCHDB-1651
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-1651
>             Project: CouchDB
>          Issue Type: Bug
>          Components: HTTP Interface
>            Reporter: Paul Frazee
>
> Running 1.2.1 on Windows 7 as a service.
> hosts file includes "127.0.0.1 grimwire.local"
> CouchDB conf includes vhosts entries:
> grimwire.local:5984	         /grimwire/_design/grimwire/_rewrite
> grimwire.local:5984/local	 /grimwire/_design/local/_rewrite
> 'grimwire' design doc rewrites:
> [
> 	{
> 		"from": "",
> 		"to": "index.html",
> 		"method": "GET"
> 	},
> 	{
> 		"from": "*",
> 		"to": "*"
> 	}
> ]
> 'local' design doc rewrites:
> [
> 	{
> 		"from":"",
> 		"to":"index.html",
> 		"method":"GET"
> 	},
> 	{
> 		"from":"/posts",
> 		"to":"_list/wallpost/wallpost-by-created_at",
> 		"method":"GET"
> 	},
> 	{
> 		"from":"/posts",
> 		"to":"_update/wallpost",
> 		"method":"POST"
> 	},
> 	{
> 		"from":"/posts/:id",
> 		"to":"_show/wallpost/:id",
> 		"method":"GET"
> 	},
> 	{
> 		"from":"/posts/:id",
> 		"to":"_update/wallpost/:id",
> 		"method":"PUT"
> 	},
> 	{
> 		"from":"*",
> 		"to":"*"
> 	}
> ]
> Problem:
> The requests work as expected for some unknown period, then begin to respond with a 400
status and the "Exceeded rewrite recursion limit" error message. Changing the rewrites rules
for both applications, including setting them to empty arrays, had no effect.
> The problem was solved by restarting the CouchDB service.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira

Mime
View raw message