You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@couchdb.apache.org by Oleg Cohen <ol...@gmail.com> on 2016/05/19 17:30:57 UTC
Re: Gatling tests.
Hi Guillaume,
Very nice package! We are trying to run it against a 2.0 DB, but since we have our DB username/pwd protected the test is failing with first 401 and then 404 errors. Is there a way to add DB credentials?
Thank you!
Oleg
> On Jan 29, 2016, at 2:50 PM, Guillaume Belrose <ka...@gmail.com> wrote:
>
> Guillaume
Re: Gatling tests.
Posted by Guillaume Belrose <ka...@gmail.com>.
Hi Oleg,
I think CouchDB 2.0 uses HTTP Basic authentication. You can simply modify your Scala simulation file to include the credentials that you want to pass.
For example, in my CouchDBSimulation.scala file, I will append the credentials to the http protocol like so:
val httpConf = http.baseURL(System.getProperty(s"$prefix.serverUrl", "http://127.0.0.1:5984")).basicAuth("foo","bar")
I’ve tested this with CouchDB 1.6 ( but not with 2.0 but it should work the same way).
Out of the box, Gatling also supports Digest authentication (see http://gatling.io/docs/2.0.0-RC2/http/http_protocol.html <http://gatling.io/docs/2.0.0-RC2/http/http_protocol.html>)
Guillaume.
> On 19 May 2016, at 19:30, Oleg Cohen <ol...@gmail.com> wrote:
>
> Hi Guillaume,
>
> Very nice package! We are trying to run it against a 2.0 DB, but since we have our DB username/pwd protected the test is failing with first 401 and then 404 errors. Is there a way to add DB credentials?
>
> Thank you!
> Oleg
>
>> On Jan 29, 2016, at 2:50 PM, Guillaume Belrose <ka...@gmail.com> wrote:
>>
>> Guillaume
>