Ask a Question

Soap UI Pro - Using Couchbase as DataSource - Could somebody help with it?

Occasional Contributor

Soap UI Pro - Using Couchbase as DataSource - Could somebody help with it?

I am attempting to use Couchbase DB as datasource. CB bucked has to be authenticated with username/password to query. I have searched all the available forums, I do not find any reliable ones for accomplishing this.


Can somebody help with this in details...

Community Hero

Re: Soap UI Pro - Using Couchbase as DataSource - Could somebody help with it?



I dont know couchbase myself - but I had a quick look around and I suspect it will be similar to other DB connections in SoapUI.


You use JDBC to connect to a database in SoapUI  - so you need to determine the Couchbase JDBC connection string - something like the following:





You'll need to investigate which version of Java Couchbase uses via JDBC and get the appropriate version of Java also.  Just a note - Couchbase seems new and so will probably use a recent version of Java - I need to highlight that if the version of Java is too old - this will impact negatively with any groovyscripting you have in your soapui project (for example I had to use .jar files that were developed for java 2 - this broke my groovyscripts).


You'll also need to find the driver .jar files SoapUI will use to connect to the database. 


I put together the following instructions for myself when connecting to a MIMER RDBMS - I'd follow these instructions and just swap out the couchbase relevant bits


1.  Install relevant version of JDK - that your Couchbase DB .jar files use to create a JDBC connection

2.  Ensure PATH environment variable doesn't point to another version of Java

3.  Set JAVA_HOME to JDKvX.Xs bin directory (e.g. C:\jdkv1.8\bin) - e.g. at command prompt run 'set JAVA_HOME=%JAVA_HOME%;C:\jdkv1.8\bin'

4.  At command prompt run 'java -version' to ensure it's picking up JDKv1.8 rather than other versions of Java

5.  Download the couchbase jdbc driver file (???????.jar) and copy this to 'C:\Program Files\SmartBear\ReadyAPI-n.n.n\bin\ext'

6.  Create or  update the CLASSPATH environment variable, pointing to the location of the .jar file.  Run the following command via command prompt 'set CLASSPATH=%CLASSPATH%;C:\Program Files\SmartBear\ReadyAPI-n.n.n\bin\ext'

7.  Within SoapUI's JDBC preferences, add in an entry - 'Driver column' value = 'UniqueIdentifier/com.couchbase.jdbc.Driver'.  In the 'Connection String Template' column add in the value 'jdbc:couchbase://[Host]:[Port]/[Database];'  

Hopefully something like the above will sort your connection.


I should highlight that I struggled with the connection string for the MIMER db - I had to alter it slightly from the published info to get it to work - but that was the major problem I had


have a look here for the info you need for drivers, connection strings etc.






if this helped answer the post, could you please mark it as 'solved'? Also if you consider whether the title of your post is relevant? Perhaps if the post is solved, it might make sense to update the Subject header field of the post to something more descriptive? This will help people when searching for problems. Ta
New Member

Re: Soap UI Pro - Using Couchbase as DataSource - Could somebody help with it?



I'm not familiar enough with Soap UI, but I am familiar with Couchbase. I can tell you that Couchbase does not ship with ODBC or JDBC support at this time. However, there are ODBC and JDBC drivers available from third parties Simba and CData:


Couchbase also has a REST API available. If you're interested in using that API to run N1QL queries (N1QL is Couchbase's implementation of SQL), you can do so: check out the N1QL REST API documentation here:

Showing results for 
Search instead for 
Did you mean: