Skip to content

Conversation

@russcam
Copy link
Contributor

@russcam russcam commented Apr 2, 2024

Closes #992

What does this PR do?

This commit adds a qdrant container to the list of supported Testcontainers, for use with the Qdrant vector database.

The qdrant container allows configuration of:

  • an API key to authenticate to Qdrant
  • a certificate and private key in PEM format used to secure communication to Qdrant with Transport Layer Security

Why is it important?

Provides a qdrant test container for folks that need it

Related issues

#992
Supersedes #994

How to test this PR

Run tests in Testcontainers.Qdrant.Tests

russcam added 5 commits March 30, 2024 09:17
This commit adds a qdrant container to the list of supported
Testcontainers.

The qdrant container allows configuration of:

- an API key to authenticate to Qdrant
- an x509 certificate used to secure communication to Qdrant with
  Transport Layer Security
- a custom configuration file. See
  https://qdrant.tech/documentation/guides/configuration/

Closes testcontainers#992
Qdrant uses rustls for TLS, which does not accept IPv4 or IPv6 addresses as the hostname in SNI, adhering
to RFC 6066: https://www.rfc-editor.org/rfc/rfc6066#page-7

Sending an IPv4 or IPv6 address as the hostname in SNI causes the handshake to be rejected and
qdrant to log

WARN rustls::msgs::handshake: Illegal SNI hostname received "127.0.0.1"

By default, .NET on linux sends the DNS name in the URI in Server Name Indication (SNI),
irrespective of whether it's an IP address or not. In order to resolve this, a custom
Host request header is added, per

dotnet/runtime#20876 (comment)
@netlify
Copy link

netlify bot commented Apr 2, 2024

Deploy Preview for testcontainers-dotnet ready!

Name Link
🔨 Latest commit cf77f83
🔍 Latest deploy log https://app.netlify.com/sites/testcontainers-dotnet/deploys/67d3e5e91793440008b3710a
😎 Deploy Preview https://deploy-preview-1149--testcontainers-dotnet.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@russcam russcam mentioned this pull request Apr 2, 2024
@russcam russcam changed the title Qdrant container feat: add Qdrant module Apr 4, 2024
russcam and others added 6 commits April 6, 2024 16:28
This commit moves the wait for strategy to
use the readyz endpoint. If a certificate has
been specified, perform the check with TLS and
allow any certificate to pass validation.
The qdrant gRPC client uses .NET Framework build
of Grpc.Net.Client, which uses WinHttpHandler. The
wiring up is easier on net462 if net462 is targeted
specifically. Same reason why the Milvus container
also targets net462 (testcontainers#1131 (comment)).
Copy link
Collaborator

@HofmeisterAn HofmeisterAn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the PR 🙏. I have reviewed it and made some minor changes to align with the repository standards. I have a some suggestions regarding the certificates. I am happy to merge the PR after we have sorted them out.

@russcam russcam requested a review from HofmeisterAn April 21, 2024 08:03
@HofmeisterAn HofmeisterAn added enhancement New feature or request module An official Testcontainers module labels May 17, 2024
@eddumelendez
Copy link
Member

It will be nice to add some docs for the module and how to use it.

russcam added 4 commits March 8, 2025 11:47
This commit updates the version of the image and the
official Qdrant client, and adds docs on how to use
the container.
@russcam
Copy link
Contributor Author

russcam commented Mar 8, 2025

@HofmeisterAn @eddumelendez I've updated this PR with latest on develop and added documentation. Looking forward to seeing this merged.

@HofmeisterAn
Copy link
Collaborator

I'll try to review it by the end of this week.

Copy link
Member

@eddumelendez eddumelendez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@HofmeisterAn HofmeisterAn changed the title feat: add Qdrant module feat: Add Qdrant module Mar 14, 2025
Copy link
Collaborator

@HofmeisterAn HofmeisterAn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks ⭐.

@HofmeisterAn HofmeisterAn merged commit 2c691d2 into testcontainers:develop Mar 14, 2025
67 checks passed
@russcam russcam deleted the qdrant-container branch March 14, 2025 09:03
@russcam
Copy link
Contributor Author

russcam commented Mar 18, 2025

Thanks for merging @HofmeisterAn. Do you have a rough idea when this might be released?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request module An official Testcontainers module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Feature]: Add Qdrant test container

4 participants