This is an automated email from the ASF dual-hosted git repository. jamesnetherton pushed a commit to branch camel-main in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git
The following commit(s) were added to refs/heads/camel-main by this push: new e6b87c0804 Fix Pinecone WireMock stubs and native support e6b87c0804 is described below commit e6b87c0804056a58025dd3e817b62b8c83a993aa Author: James Netherton <jamesnether...@gmail.com> AuthorDate: Fri Nov 22 09:31:34 2024 +0000 Fix Pinecone WireMock stubs and native support --- .../pinecone/deployment/PineconeProcessor.java | 2 +- integration-tests/pinecone/pom.xml | 2 -- .../quarkus/component/pinecone/it/PineconeTest.java | 2 -- ... indexes-0cb5785f-987c-481d-b49a-51dac8cc4a5a.json} | 12 ++++++------ ... indexes-293cf644-849f-4860-809f-13278d509acb.json} | 14 +++++++------- ... indexes-5854cd4f-0384-40dd-bfa5-bf36592d3a9b.json} | 18 +++++++++--------- ...st-index-92a8d520-01e3-48ae-89eb-1f51beed3276.json} | 12 ++++++------ 7 files changed, 29 insertions(+), 33 deletions(-) diff --git a/extensions/pinecone/deployment/src/main/java/org/apache/camel/quarkus/component/pinecone/deployment/PineconeProcessor.java b/extensions/pinecone/deployment/src/main/java/org/apache/camel/quarkus/component/pinecone/deployment/PineconeProcessor.java index 62471255e4..b43da48454 100644 --- a/extensions/pinecone/deployment/src/main/java/org/apache/camel/quarkus/component/pinecone/deployment/PineconeProcessor.java +++ b/extensions/pinecone/deployment/src/main/java/org/apache/camel/quarkus/component/pinecone/deployment/PineconeProcessor.java @@ -47,7 +47,7 @@ class PineconeProcessor { void registerForReflection(CombinedIndexBuildItem combinedIndex, BuildProducer<ReflectiveClassBuildItem> reflectiveClasses) { Set<String> modelClasses = combinedIndex.getIndex() - .getClassesInPackage(DotName.createSimple("org.openapitools.client.model")) + .getClassesInPackage(DotName.createSimple("org.openapitools.db_control.client.model")) .stream() .map(ClassInfo::name) .map(DotName::toString) diff --git a/integration-tests/pinecone/pom.xml b/integration-tests/pinecone/pom.xml index b2de94ab17..fc9e922817 100644 --- a/integration-tests/pinecone/pom.xml +++ b/integration-tests/pinecone/pom.xml @@ -80,7 +80,6 @@ </dependencies> <profiles> - <!-- https://github.com/apache/camel-quarkus/issues/6808 <profile> <id>native</id> <activation> @@ -108,7 +107,6 @@ </plugins> </build> </profile> - --> <profile> <id>virtualDependencies</id> <activation> diff --git a/integration-tests/pinecone/src/test/java/org/apache/camel/quarkus/component/pinecone/it/PineconeTest.java b/integration-tests/pinecone/src/test/java/org/apache/camel/quarkus/component/pinecone/it/PineconeTest.java index 6e8d53085e..3f5fc4f2f4 100644 --- a/integration-tests/pinecone/src/test/java/org/apache/camel/quarkus/component/pinecone/it/PineconeTest.java +++ b/integration-tests/pinecone/src/test/java/org/apache/camel/quarkus/component/pinecone/it/PineconeTest.java @@ -27,7 +27,6 @@ import io.restassured.RestAssured; import io.restassured.http.ContentType; import org.eclipse.microprofile.config.ConfigProvider; import org.junit.jupiter.api.BeforeAll; -import org.junit.jupiter.api.Disabled; import org.junit.jupiter.api.Test; import org.openapitools.db_control.client.model.IndexModel; @@ -41,7 +40,6 @@ import static org.openapitools.db_control.client.model.IndexModelStatus.StateEnu @QuarkusTestResource(PineconeTestResource.class) @QuarkusTest -@Disabled //https://github.com/apache/camel-quarkus/issues/6808 class PineconeTest { private static Pinecone pinecone; diff --git a/integration-tests/pinecone/src/test/resources/mappings/indexes-6e869a73-c72a-4ebf-be81-fa920caa99df.json b/integration-tests/pinecone/src/test/resources/mappings/indexes-0cb5785f-987c-481d-b49a-51dac8cc4a5a.json similarity index 67% rename from integration-tests/pinecone/src/test/resources/mappings/indexes-6e869a73-c72a-4ebf-be81-fa920caa99df.json rename to integration-tests/pinecone/src/test/resources/mappings/indexes-0cb5785f-987c-481d-b49a-51dac8cc4a5a.json index bf7990a1ff..fbcfc19f22 100644 --- a/integration-tests/pinecone/src/test/resources/mappings/indexes-6e869a73-c72a-4ebf-be81-fa920caa99df.json +++ b/integration-tests/pinecone/src/test/resources/mappings/indexes-0cb5785f-987c-481d-b49a-51dac8cc4a5a.json @@ -1,5 +1,5 @@ { - "id" : "6e869a73-c72a-4ebf-be81-fa920caa99df", + "id" : "0cb5785f-987c-481d-b49a-51dac8cc4a5a", "name" : "indexes", "request" : { "url" : "/indexes", @@ -9,19 +9,19 @@ "status" : 200, "body" : "{\"indexes\":[]}", "headers" : { - "X-Cloud-Trace-Context" : "a4b91f07ef1a9299382ac69f1b2f8e60", + "X-Cloud-Trace-Context" : "bd4d9cb6698e7373332f57eaeeea6592", "access-control-allow-origin" : "*", "Alt-Svc" : "h3=\":443\"; ma=2592000,h3-29=\":443\"; ma=2592000", "Server" : "Google Frontend", "vary" : "origin,access-control-request-method,access-control-request-headers", "content-type" : "application/json", - "Date" : "Tue, 18 Jun 2024 14:46:24 GMT", + "Date" : "Fri, 22 Nov 2024 09:23:39 GMT", "Via" : "1.1 google", - "access-control-expose-headers" : "*", - "x-pinecone-api-version" : "2024-04" + "x-pinecone-api-version" : "2024-10", + "access-control-expose-headers" : "*" } }, - "uuid" : "6e869a73-c72a-4ebf-be81-fa920caa99df", + "uuid" : "0cb5785f-987c-481d-b49a-51dac8cc4a5a", "persistent" : true, "scenarioName" : "scenario-1-indexes", "requiredScenarioState" : "scenario-1-indexes-2", diff --git a/integration-tests/pinecone/src/test/resources/mappings/indexes-764a2311-1f84-43c2-a993-0412caac241b.json b/integration-tests/pinecone/src/test/resources/mappings/indexes-293cf644-849f-4860-809f-13278d509acb.json similarity index 70% rename from integration-tests/pinecone/src/test/resources/mappings/indexes-764a2311-1f84-43c2-a993-0412caac241b.json rename to integration-tests/pinecone/src/test/resources/mappings/indexes-293cf644-849f-4860-809f-13278d509acb.json index fcb10de2da..39aef73586 100644 --- a/integration-tests/pinecone/src/test/resources/mappings/indexes-764a2311-1f84-43c2-a993-0412caac241b.json +++ b/integration-tests/pinecone/src/test/resources/mappings/indexes-293cf644-849f-4860-809f-13278d509acb.json @@ -1,5 +1,5 @@ { - "id" : "764a2311-1f84-43c2-a993-0412caac241b", + "id" : "293cf644-849f-4860-809f-13278d509acb", "name" : "indexes", "request" : { "url" : "/indexes", @@ -7,21 +7,21 @@ }, "response" : { "status" : 200, - "body" : "{\"indexes\":[{\"name\":\"test-index\",\"metric\":\"cosine\",\"dimension\":3,\"status\":{\"ready\":true,\"state\":\"Ready\"},\"host\":\"test-index-3ncz9x1.svc.aped-4627-b74a.pinecone.io\",\"spec\":{\"serverless\":{\"region\":\"us-east-1\",\"cloud\":\"aws\"}}}]}", + "body" : "{\"indexes\":[{\"name\":\"test-index\",\"metric\":\"cosine\",\"dimension\":3,\"status\":{\"ready\":true,\"state\":\"Ready\"},\"host\":\"test-index-3ncz9x1.svc.aped-4627-b74a.pinecone.io\",\"spec\":{\"serverless\":{\"region\":\"us-east-1\",\"cloud\":\"aws\"}},\"deletion_protection\":\"disabled\",\"tags\":null}]}", "headers" : { - "X-Cloud-Trace-Context" : "5160ad22255be98a831fb798589fb58b", + "X-Cloud-Trace-Context" : "5d76189a457047bf315cdd0913392ffe", "access-control-allow-origin" : "*", "Alt-Svc" : "h3=\":443\"; ma=2592000,h3-29=\":443\"; ma=2592000", "Server" : "Google Frontend", "vary" : "origin,access-control-request-method,access-control-request-headers", "content-type" : "application/json", - "Date" : "Tue, 18 Jun 2024 14:46:23 GMT", + "Date" : "Fri, 22 Nov 2024 09:23:37 GMT", "Via" : "1.1 google", - "access-control-expose-headers" : "*", - "x-pinecone-api-version" : "2024-04" + "x-pinecone-api-version" : "2024-10", + "access-control-expose-headers" : "*" } }, - "uuid" : "764a2311-1f84-43c2-a993-0412caac241b", + "uuid" : "293cf644-849f-4860-809f-13278d509acb", "persistent" : true, "scenarioName" : "scenario-1-indexes", "requiredScenarioState" : "Started", diff --git a/integration-tests/pinecone/src/test/resources/mappings/indexes-1635ea23-b8df-42f0-90d6-d30a4fd8205b.json b/integration-tests/pinecone/src/test/resources/mappings/indexes-5854cd4f-0384-40dd-bfa5-bf36592d3a9b.json similarity index 61% rename from integration-tests/pinecone/src/test/resources/mappings/indexes-1635ea23-b8df-42f0-90d6-d30a4fd8205b.json rename to integration-tests/pinecone/src/test/resources/mappings/indexes-5854cd4f-0384-40dd-bfa5-bf36592d3a9b.json index 6c0c204f48..6fa62e106d 100644 --- a/integration-tests/pinecone/src/test/resources/mappings/indexes-1635ea23-b8df-42f0-90d6-d30a4fd8205b.json +++ b/integration-tests/pinecone/src/test/resources/mappings/indexes-5854cd4f-0384-40dd-bfa5-bf36592d3a9b.json @@ -1,33 +1,33 @@ { - "id" : "1635ea23-b8df-42f0-90d6-d30a4fd8205b", + "id" : "5854cd4f-0384-40dd-bfa5-bf36592d3a9b", "name" : "indexes", "request" : { "url" : "/indexes", "method" : "POST", "bodyPatterns" : [ { - "equalToJson" : "{\"name\":\"test-index\",\"dimension\":3,\"metric\":\"cosine\",\"spec\":{\"serverless\":{\"cloud\":\"aws\",\"region\":\"us-east-1\"}}}", + "equalToJson" : "{\"name\":\"test-index\",\"dimension\":3,\"metric\":\"cosine\",\"deletion_protection\":\"disabled\",\"spec\":{\"serverless\":{\"cloud\":\"aws\",\"region\":\"us-east-1\"}}}", "ignoreArrayOrder" : true, "ignoreExtraElements" : true } ] }, "response" : { "status" : 201, - "body" : "{\"name\":\"test-index\",\"metric\":\"cosine\",\"dimension\":3,\"status\":{\"ready\":false,\"state\":\"Initializing\"},\"host\":\"test-index-3ncz9x1.svc.aped-4627-b74a.pinecone.io\",\"spec\":{\"serverless\":{\"region\":\"us-east-1\",\"cloud\":\"aws\"}}}", + "body" : "{\"name\":\"test-index\",\"metric\":\"cosine\",\"dimension\":3,\"status\":{\"ready\":false,\"state\":\"Initializing\"},\"host\":\"test-index-3ncz9x1.svc.aped-4627-b74a.pinecone.io\",\"spec\":{\"serverless\":{\"region\":\"us-east-1\",\"cloud\":\"aws\"}},\"deletion_protection\":\"disabled\",\"tags\":null}", "headers" : { - "X-Cloud-Trace-Context" : "f3437adefa70c626b8ec0df59af4542c", + "X-Cloud-Trace-Context" : "7cae6b2507fa30364f1f71182f9319aa", "access-control-allow-origin" : "*", "Alt-Svc" : "h3=\":443\"; ma=2592000,h3-29=\":443\"; ma=2592000", "Server" : "Google Frontend", "vary" : "origin,access-control-request-method,access-control-request-headers", "content-type" : "application/json", - "x-pinecone-operation-id" : "0da16235-9603-4f43-ab57-c6bb1ef44b7b", - "Date" : "Tue, 18 Jun 2024 14:46:21 GMT", + "x-pinecone-operation-id" : "4e23a028-63e6-430d-9c8a-bbfab9596819", + "Date" : "Fri, 22 Nov 2024 09:23:35 GMT", "Via" : "1.1 google", - "access-control-expose-headers" : "*", - "x-pinecone-api-version" : "2024-04" + "x-pinecone-api-version" : "2024-10", + "access-control-expose-headers" : "*" } }, - "uuid" : "1635ea23-b8df-42f0-90d6-d30a4fd8205b", + "uuid" : "5854cd4f-0384-40dd-bfa5-bf36592d3a9b", "persistent" : true, "insertionIndex" : 4 } \ No newline at end of file diff --git a/integration-tests/pinecone/src/test/resources/mappings/indexes_test-index-5467c4ff-7174-45cf-a3f6-09ad3fdf02d8.json b/integration-tests/pinecone/src/test/resources/mappings/indexes_test-index-92a8d520-01e3-48ae-89eb-1f51beed3276.json similarity index 63% rename from integration-tests/pinecone/src/test/resources/mappings/indexes_test-index-5467c4ff-7174-45cf-a3f6-09ad3fdf02d8.json rename to integration-tests/pinecone/src/test/resources/mappings/indexes_test-index-92a8d520-01e3-48ae-89eb-1f51beed3276.json index 11e2c1467f..28585d8222 100644 --- a/integration-tests/pinecone/src/test/resources/mappings/indexes_test-index-5467c4ff-7174-45cf-a3f6-09ad3fdf02d8.json +++ b/integration-tests/pinecone/src/test/resources/mappings/indexes_test-index-92a8d520-01e3-48ae-89eb-1f51beed3276.json @@ -1,5 +1,5 @@ { - "id" : "5467c4ff-7174-45cf-a3f6-09ad3fdf02d8", + "id" : "92a8d520-01e3-48ae-89eb-1f51beed3276", "name" : "indexes_test-index", "request" : { "url" : "/indexes/test-index", @@ -8,19 +8,19 @@ "response" : { "status" : 202, "headers" : { - "X-Cloud-Trace-Context" : "2ffac0de0f46c1527e21dcd301338ad5", + "X-Cloud-Trace-Context" : "99e9c93ac1094bbc1a4df5f322b49a40", "access-control-allow-origin" : "*", "Alt-Svc" : "h3=\":443\"; ma=2592000,h3-29=\":443\"; ma=2592000", "Server" : "Google Frontend", "vary" : "origin,access-control-request-method,access-control-request-headers", - "Date" : "Tue, 18 Jun 2024 14:46:23 GMT", + "Date" : "Fri, 22 Nov 2024 09:23:37 GMT", "Via" : "1.1 google", "Content-Type" : "text/html", - "access-control-expose-headers" : "*", - "x-pinecone-api-version" : "2024-04" + "x-pinecone-api-version" : "2024-10", + "access-control-expose-headers" : "*" } }, - "uuid" : "5467c4ff-7174-45cf-a3f6-09ad3fdf02d8", + "uuid" : "92a8d520-01e3-48ae-89eb-1f51beed3276", "persistent" : true, "insertionIndex" : 2 } \ No newline at end of file