You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by or...@apache.org on 2024/03/21 17:38:00 UTC
(camel) branch main updated: CAMEL-20485: cleanup references to Qdrant
This is an automated email from the ASF dual-hosted git repository.
orpiske pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git
The following commit(s) were added to refs/heads/main by this push:
new d450a167967 CAMEL-20485: cleanup references to Qdrant
d450a167967 is described below
commit d450a167967aacd0455fc5fad6b2ee55e214f08d
Author: Otavio Rodolfo Piske <an...@gmail.com>
AuthorDate: Thu Mar 21 17:34:15 2024 +0100
CAMEL-20485: cleanup references to Qdrant
---
components/camel-milvus/pom.xml | 33 +++++++++++-----------
.../org/apache/camel/transformer/qdrant-embeddings | 2 --
.../camel/transformer/qdrant-embeddings.json | 14 ---------
.../src/main/docs/milvus-component.adoc | 2 +-
.../MilvusEmbeddingsDataTypeTransformer.java | 4 +--
5 files changed, 20 insertions(+), 35 deletions(-)
diff --git a/components/camel-milvus/pom.xml b/components/camel-milvus/pom.xml
index f8a8e088c79..f97db8767c6 100644
--- a/components/camel-milvus/pom.xml
+++ b/components/camel-milvus/pom.xml
@@ -17,7 +17,8 @@
limitations under the License.
-->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+ xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
@@ -35,7 +36,7 @@
<camel.surefire.parallel>true</camel.surefire.parallel>
<camel.surefire.parallel.factor>4</camel.surefire.parallel.factor>
- <!-- Qdrant is not available on these platforms -->
+ <!-- Milvus is not available on these platforms -->
<skipITs.ppc64le>true</skipITs.ppc64le>
<skipITs.s390x>true</skipITs.s390x>
<skipTests.ppc64le>true</skipTests.ppc64le>
@@ -58,20 +59,20 @@
<groupId>io.milvus</groupId>
<artifactId>milvus-sdk-java</artifactId>
<version>2.3.4</version>
- <exclusions>
- <exclusion>
- <groupId>org.apache.logging.log4j</groupId>
- <artifactId>log4j-api</artifactId>
- </exclusion>
- <exclusion>
- <groupId>org.apache.logging.log4j</groupId>
- <artifactId>log4j-core</artifactId>
- </exclusion>
- <exclusion>
- <groupId>org.apache.logging.log4j</groupId>
- <artifactId>log4j-slf4j-impl</artifactId>
- </exclusion>
- </exclusions>
+ <exclusions>
+ <exclusion>
+ <groupId>org.apache.logging.log4j</groupId>
+ <artifactId>log4j-api</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.logging.log4j</groupId>
+ <artifactId>log4j-core</artifactId>
+ </exclusion>
+ <exclusion>
+ <groupId>org.apache.logging.log4j</groupId>
+ <artifactId>log4j-slf4j-impl</artifactId>
+ </exclusion>
+ </exclusions>
</dependency>
<!-- test dependencies -->
diff --git a/components/camel-milvus/src/generated/resources/META-INF/services/org/apache/camel/transformer/qdrant-embeddings b/components/camel-milvus/src/generated/resources/META-INF/services/org/apache/camel/transformer/qdrant-embeddings
deleted file mode 100644
index ccd7a4be1ed..00000000000
--- a/components/camel-milvus/src/generated/resources/META-INF/services/org/apache/camel/transformer/qdrant-embeddings
+++ /dev/null
@@ -1,2 +0,0 @@
-# Generated by camel build tools - do NOT edit this file!
-class=org.apache.camel.component.milvus.transform.MilvusEmbeddingsDataTypeTransformer
diff --git a/components/camel-milvus/src/generated/resources/META-INF/services/org/apache/camel/transformer/qdrant-embeddings.json b/components/camel-milvus/src/generated/resources/META-INF/services/org/apache/camel/transformer/qdrant-embeddings.json
deleted file mode 100644
index 2eaeb37bfa7..00000000000
--- a/components/camel-milvus/src/generated/resources/META-INF/services/org/apache/camel/transformer/qdrant-embeddings.json
+++ /dev/null
@@ -1,14 +0,0 @@
-{
- "transformer": {
- "kind": "transformer",
- "name": "qdrant:embeddings",
- "title": "Qdrant (Embeddings)",
- "description": "Prepares the message to become an object writable by Milvus component",
- "deprecated": false,
- "javaType": "org.apache.camel.component.milvus.transform.MilvusEmbeddingsDataTypeTransformer",
- "groupId": "org.apache.camel",
- "artifactId": "camel-milvus",
- "version": "4.5.0-SNAPSHOT"
- }
-}
-
diff --git a/components/camel-milvus/src/main/docs/milvus-component.adoc b/components/camel-milvus/src/main/docs/milvus-component.adoc
index 6cb4d2e2c5d..2d43b1efe64 100644
--- a/components/camel-milvus/src/main/docs/milvus-component.adoc
+++ b/components/camel-milvus/src/main/docs/milvus-component.adoc
@@ -8,7 +8,7 @@
:tabs-sync-option:
:component-header: Only producer is supported
//Manually maintained attributes
-:camel-spring-boot-name: qdrant
+:camel-spring-boot-name: milvus
*Since Camel {since}*
diff --git a/components/camel-milvus/src/main/java/org/apache/camel/component/milvus/transform/MilvusEmbeddingsDataTypeTransformer.java b/components/camel-milvus/src/main/java/org/apache/camel/component/milvus/transform/MilvusEmbeddingsDataTypeTransformer.java
index 1aed3d370f7..dd86fe9cece 100644
--- a/components/camel-milvus/src/main/java/org/apache/camel/component/milvus/transform/MilvusEmbeddingsDataTypeTransformer.java
+++ b/components/camel-milvus/src/main/java/org/apache/camel/component/milvus/transform/MilvusEmbeddingsDataTypeTransformer.java
@@ -31,7 +31,7 @@ import org.apache.camel.spi.DataTypeTransformer;
import org.apache.camel.spi.Transformer;
/**
- * Maps a Langchain Embeddings to a Milvus InsertParam/Upsert Param to write an embeddings vector on a Milvus Database.
+ * Maps a LangChain Embeddings to a Milvus InsertParam/Upsert Param to write an embeddings vector on a Milvus Database.
*/
@DataTypeTransformer(name = "milvus:embeddings",
description = "Prepares the message to become an object writable by Milvus component")
@@ -39,7 +39,7 @@ public class MilvusEmbeddingsDataTypeTransformer extends Transformer {
@Override
public void transform(Message message, DataType fromType, DataType toType) {
- Embedding embedding = message.getHeader("CamelLangchainEmbeddingsVector", Embedding.class);
+ Embedding embedding = message.getHeader("CamelLangChainEmbeddingsVector", Embedding.class);
String textFieldName = message.getHeader(Milvus.Headers.TEXT_FIELD_NAME, () -> "text", String.class);
String vectorFieldName = message.getHeader(Milvus.Headers.VECTOR_FIELD_NAME, () -> "vector", String.class);
String collectionName = message.getHeader(Milvus.Headers.COLLECTION_NAME, () -> "embeddings", String.class);