You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Paul Joseph Davis (JIRA)" <ji...@apache.org> on 2008/04/29 23:47:55 UTC
[jira] Created: (COUCHDB-49) A patch for the _design%2Fname hack.
A patch for the _design%2Fname hack.
------------------------------------
Key: COUCHDB-49
URL: https://issues.apache.org/jira/browse/COUCHDB-49
Project: CouchDB
Issue Type: Bug
Components: HTTP Interface
Reporter: Paul Joseph Davis
Priority: Minor
I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Paul Joseph Davis (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599729#action_12599729 ]
Paul Joseph Davis commented on COUCHDB-49:
------------------------------------------
I see where you're coming from. But I'm left with the question of whether _design is part of the document name or if _design is more of a namespace for design documents.
Personally, I could see it going either way, but I haven't groked the internals enough to know if there's a reason somewhere else that requires the _design as an actual part of the name or not.
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Christopher Lenz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Christopher Lenz reassigned COUCHDB-49:
---------------------------------------
Assignee: Christopher Lenz
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Assignee: Christopher Lenz
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Christopher Lenz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12602274#action_12602274 ]
Christopher Lenz commented on COUCHDB-49:
-----------------------------------------
No, that hasn't changed, we still want the raw URL. There's just a special exception for design doc URLs.
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Assignee: Christopher Lenz
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Paul Joseph Davis (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Paul Joseph Davis updated COUCHDB-49:
-------------------------------------
Attachment: design_url_escape.patch
Hopefully this passes muster.
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Resolved: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Christopher Lenz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Christopher Lenz resolved COUCHDB-49.
-------------------------------------
Resolution: Fixed
Slightly modified patch applied in r663055. Thanks!
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Assignee: Christopher Lenz
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Shawn Garbett (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12602266#action_12602266 ]
Shawn Garbett commented on COUCHDB-49:
--------------------------------------
Minor Nit?
Line 60-62 of couch_httpd.erl says:
% for the path, use the raw path with the query string and fragment
% removed, but URL quoting left intact
{Path, _, _} = mochiweb_util:urlsplit_path(Req:get(raw_path)),
Should this comment be changed to reflect this modification?
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Assignee: Christopher Lenz
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Christopher Lenz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12599728#action_12599728 ]
Christopher Lenz commented on COUCHDB-49:
-----------------------------------------
The URL encoding is not hackery. Slashes in document IDs are not allowed unencoded, and the document ID of a design document is still just a document ID. So requiring the slash to be encoded is more consistent, IMHO.
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Christopher Lenz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12602237#action_12602237 ]
Christopher Lenz commented on COUCHDB-49:
-----------------------------------------
Damien said on IRC he didn't have a problem with special-casing design doc URLs as you suggest.
What finally pushed me over in favor of this is the Apache's mod_proxy unescapes URLs, so in such a setup, CouchDB would actually see the raw slash. While it's clear that mod_proxy is broken here (at least in reverse proxying mode), I do want to be able to at least edit my design docs in Futon when going through the proxy. :P
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Assignee: Christopher Lenz
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (COUCHDB-49) A patch for the _design%2Fname hack.
Posted by "Christopher Lenz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Christopher Lenz updated COUCHDB-49:
------------------------------------
Fix Version/s: 0.8
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Assignee: Christopher Lenz
> Priority: Minor
> Fix For: 0.8
>
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Work started: (COUCHDB-49) A patch for the _design%2Fname
hack.
Posted by "Christopher Lenz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/COUCHDB-49?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Work on COUCHDB-49 started by Christopher Lenz.
> A patch for the _design%2Fname hack.
> ------------------------------------
>
> Key: COUCHDB-49
> URL: https://issues.apache.org/jira/browse/COUCHDB-49
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Reporter: Paul Joseph Davis
> Assignee: Christopher Lenz
> Priority: Minor
> Attachments: design_url_escape.patch
>
>
> I think I've managed to make a trivial patch so that design documents can be accessed without the %2F hackery. Its pretty simple. Any request that starts with _design is joined back with it's url and then sent to handle_doc_request/5 methods.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.