Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Couchbase Java SDK 3 #2447

Closed
daschl opened this issue Mar 17, 2020 · 4 comments
Closed

Support Couchbase Java SDK 3 #2447

daschl opened this issue Mar 17, 2020 · 4 comments
Milestone

Comments

@daschl
Copy link
Member

daschl commented Mar 17, 2020

Hi,

I've been chatting a bit with @bsideup, but I wanted to open an actual issue about it so we can track it. Currently the couchbase container only supports SDK 2, because 2 and 3 on the same classpath do not work. I'm working on a version that does not need the SDK at all to perform its work so ideally it can support both versions at the same time. Since there are dependencies on other projects they can link to this issue if needed.

I'm going to open a PR once the work is ready to review.

daschl added a commit to daschl/testcontainers-java that referenced this issue Mar 27, 2020
This changeset completely reworks the couchbase module and hopefully
greatly improve the out-of-the-box experience. Note that this is a
breaking change over the previous code because by intention it does
NOT depend on SDK 2 so you can test SDK 2 and 3 with it at the same
time.

Highlights:

 - Removed the need for a SDK, so both 2 and 3 can be used with it.
 - Updated to 6.5.0 baseline and using alternate addresses for
   "proper" port exposure without having to rely on the socat
   proxy container like the previous version had to.
 - Allows to define which services should be exposed and handles
   states automatically (i.e. will not try to create the primary
   index if the query service is not enabled).

Note that a bunch of tests have been removed since they are not
adequate anymore. A side effect of the alternate address change
is that older servers cannot be used. 6.5.0 is available in both
CE and EE, and Couchbase in general allows EE versions to be used
in development and testing so we should use it if we can.
@unhuman
Copy link

unhuman commented Mar 31, 2020

I was just looking for this! Excited that this will go in.

@rnorth
Copy link
Member

rnorth commented Apr 13, 2020

This was released in https://github.com/testcontainers/testcontainers-java/releases/tag/1.14.0 🎉

Thanks for the contribution!

@johnspade
Copy link

Have SDK 2/3 incompatibility issues been resolved?

@bsideup
Copy link
Member

bsideup commented Apr 14, 2020

@johnspade yes. The module is SDK-free now thanks to @daschl :)

@bsideup bsideup added this to the 1.14.0 milestone Apr 14, 2020
quincy pushed a commit to quincy/testcontainers-java that referenced this issue May 28, 2020
…2491)

* Rewrite couchbase module. closes testcontainers#2447

This changeset completely reworks the couchbase module and hopefully
greatly improve the out-of-the-box experience. Note that this is a
breaking change over the previous code because by intention it does
NOT depend on SDK 2 so you can test SDK 2 and 3 with it at the same
time.

Highlights:

 - Removed the need for a SDK, so both 2 and 3 can be used with it.
 - Updated to 6.5.0 baseline and using alternate addresses for
   "proper" port exposure without having to rely on the socat
   proxy container like the previous version had to.
 - Allows to define which services should be exposed and handles
   states automatically (i.e. will not try to create the primary
   index if the query service is not enabled).

Note that a bunch of tests have been removed since they are not
adequate anymore. A side effect of the alternate address change
is that older servers cannot be used. 6.5.0 is available in both
CE and EE, and Couchbase in general allows EE versions to be used
in development and testing so we should use it if we can.

* Wait until query respsonds with 200

* fixes

* add `getBootstrap*DirectPort()` methods, review fixes

* Restore `getConnectionString()`

* Apply suggestions from code review

Co-Authored-By: Kevin Wittek <kiview@users.noreply.github.com>

* Update docs

* Update docs (2)

Co-authored-by: Michael Nitschinger <michael@nitschinger.at>
Co-authored-by: Kevin Wittek <kiview@users.noreply.github.com>
sd-yip added a commit to sd-yip/testcontainers-java that referenced this issue May 11, 2021
sd-yip added a commit to sd-yip/testcontainers-java that referenced this issue May 12, 2021
sd-yip added a commit to sd-yip/testcontainers-java that referenced this issue May 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants