[
https://issues.apache.org/jira/browse/COUCHDB-678?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Filipe Manana updated COUCHDB-678:
----------------------------------
Attachment: couchdb-678-trunk.patch
> Virtualhost drops querystring parameters
> ----------------------------------------
>
> Key: COUCHDB-678
> URL: https://issues.apache.org/jira/browse/COUCHDB-678
> Project: CouchDB
> Issue Type: Bug
> Components: HTTP Interface
> Affects Versions: 0.11
> Environment: OSX Snow Leopard 10.6.2, CouchDB 0.11.0b15d10793-git
> Reporter: David Goodlad
> Priority: Minor
> Attachments: couchdb-678-trunk.patch
>
>
> When making GET requests with querystring parameters
> (http://foo/bar?querystring), the query string seems to get dropped in the
> request is to a host with a matching vhost entry.
> I have the following vhost setup in local.ini:
> swift-ca2.swiftshift.local:5984 = /swift-ca
> I've tested my view without vhosts by requesting
> http://localhost:5984/swift-ca/_design/swift/_view/schedules?include_docs=true
> and it works fine (docs are included in the json, as expected). The
> following is the debug log when that request is made:
> [debug] [<0.213.0>] 'GET'
> /swift-ca/_design/swift/_view/schedules?include_docs=true {1,1}
> Headers: [{'Connection',"close"},
> {'Host',"localhost:5984"},
> {'User-Agent',"HTTP%20Client/0.9.1 CFNetwork/454.5 Darwin/10.2.0
> (i386) (MacBookPro5%2C1)"}]
> [debug] [<0.213.0>] OAuth Params: [{"include_docs","true"}]
> [debug] [<0.213.0>] request_group {Pid, Seq} {<0.221.0>,214}
> [info] [<0.213.0>] 127.0.0.1 - - 'GET'
> /swift-ca/_design/swift/_view/schedules?include_docs=true 200
> [debug] [<0.213.0>] Include Doc: <<"ac2a8cdf84a6ad8257bb366c2800410b">> nil
> [debug] [<0.213.0>] Include Doc: <<"ac2a8cdf84a6ad8257bb366c28004747">> nil
> [debug] [<0.213.0>] Include Doc: <<"ac2a8cdf84a6ad8257bb366c280052e3">> nil
> [debug] [<0.213.0>] Include Doc: <<"ac2a8cdf84a6ad8257bb366c28005fac">> nil
> [debug] [<0.213.0>] Include Doc: <<"ac2a8cdf84a6ad8257bb366c2800608c">> nil
> If I, instead, request via the vhost at
> http://swift-ca2.swiftshift.local:5984/_design/swift/_view/schedules?include_docs=true,
> the docs are _not_ included in the resulting json, and the debug log shows
> the following:
> [debug] [<0.94.0>] Vhost Target: '"/swift-ca/_design/swift/_view/schedules"'
> [debug] [<0.94.0>] 'GET' /swift-ca/_design/swift/_view/schedules {1,1}
> Headers: [{'Connection',"close"},
> {'Host',"swift-ca2.swiftshift.local:5984"},
> {'User-Agent',"HTTP%20Client/0.9.1 CFNetwork/454.5 Darwin/10.2.0
> (i386) (MacBookPro5%2C1)"}]
> [debug] [<0.94.0>] OAuth Params: []
> [debug] [<0.91.0>] Spawning new group server for view group _design/swift in
> database swift-ca.
> [debug] [<0.94.0>] request_group {Pid, Seq} {<0.221.0>,214}
> [info] [<0.94.0>] 127.0.0.1 - - 'GET' /swift-ca/_design/swift/_view/schedules
> 200
> [debug] [<0.81.0>] New task status for swift-ca _design/swift: Finishing.
> Note that in the second line the querystring is omitted.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.