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

Avoid trying to retrieve the default ds if a named one should be used #668

Merged
merged 2 commits into from
Jun 12, 2024

Conversation

jmartisk
Copy link
Collaborator

Fixes #667

@jmartisk jmartisk requested a review from a team as a code owner June 12, 2024 10:02
Copy link
Collaborator

@geoand geoand left a comment

Choose a reason for hiding this comment

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

Thanks!

@geoand
Copy link
Collaborator

geoand commented Jun 12, 2024

Any chance we can get a test?

@jmartisk
Copy link
Collaborator Author

Hmm, the tests in pgvector module are using @QuarkusTest. We will probably need to rewrite them to use quarkus-junit5-internal because they can't be mixed together.

@jmartisk
Copy link
Collaborator Author

I'll try that

@geoand
Copy link
Collaborator

geoand commented Jun 12, 2024

🙏

@jmartisk
Copy link
Collaborator Author

jmartisk commented Jun 12, 2024

After switching to quarkus-junit5-internal some of the existing tests start throwing really weird errors (IllegalArgumentException from reflectively calling methods with wrong arguments), I think it has something to do with being parametrized via @MethodSource (https://github.com/langchain4j/langchain4j/blob/0.31.0/langchain4j-core/src/test/java/dev/langchain4j/store/embedding/EmbeddingStoreWithFilteringIT.java#L27), maybe the Quarkus-internal testing framework doesn't support that.

@geoand
Copy link
Collaborator

geoand commented Jun 12, 2024

Indeed they don't AFAIR

@jmartisk
Copy link
Collaborator Author

We can work around it by temporarily extending EmbeddingStoreIT instead of EmbeddingStoreWithFilteringIT, then we won't have any parametrized tests, but we would lose test coverage of metadata filtering...

@geoand
Copy link
Collaborator

geoand commented Jun 12, 2024

Up to you

@geoand geoand merged commit 470a775 into quarkiverse:main Jun 12, 2024
12 checks passed
@jmartisk jmartisk deleted the issue-667 branch June 12, 2024 13:30
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

Successfully merging this pull request may close these issues.

Exception when using a named datasource for pgvector
3 participants