You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by da...@apache.org on 2023/03/11 12:28:11 UTC
[camel-spring-boot] 02/02: CAMEL-19133: camel-zookeeper - Serialize MetaData in camel-cloud service discovery problem. Thanks to geyipeng for patch.
This is an automated email from the ASF dual-hosted git repository.
davsclaus pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-spring-boot.git
commit bf2159b1933068f5f9be854351128a65154346d8
Author: Claus Ibsen <cl...@gmail.com>
AuthorDate: Sat Mar 11 13:27:55 2023 +0100
CAMEL-19133: camel-zookeeper - Serialize MetaData in camel-cloud service discovery problem. Thanks to geyipeng for patch.
---
.../springboot/cloud/ZooKeeperServiceRegistryTest.java | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/components-starter/camel-zookeeper-starter/src/test/java/org/apache/camel/component/zookeeper/springboot/cloud/ZooKeeperServiceRegistryTest.java b/components-starter/camel-zookeeper-starter/src/test/java/org/apache/camel/component/zookeeper/springboot/cloud/ZooKeeperServiceRegistryTest.java
index 37e595511c5..0c1c2ad8347 100644
--- a/components-starter/camel-zookeeper-starter/src/test/java/org/apache/camel/component/zookeeper/springboot/cloud/ZooKeeperServiceRegistryTest.java
+++ b/components-starter/camel-zookeeper-starter/src/test/java/org/apache/camel/component/zookeeper/springboot/cloud/ZooKeeperServiceRegistryTest.java
@@ -23,7 +23,7 @@ import java.util.UUID;
import org.apache.camel.CamelContext;
import org.apache.camel.cloud.ServiceRegistry;
-import org.apache.camel.component.zookeeper.cloud.ZooKeeperServiceRegistry;
+import org.apache.camel.component.zookeeper.cloud.MetaData;
import org.apache.camel.impl.cloud.DefaultServiceDefinition;
import org.apache.camel.test.AvailablePortFinder;
import org.apache.curator.framework.CuratorFramework;
@@ -99,7 +99,7 @@ public class ZooKeeperServiceRegistryTest {
.build()
);
- final Collection<ServiceInstance<ZooKeeperServiceRegistry.MetaData>> services = zkClient.discovery().queryForInstances(SERVICE_NAME);
+ final Collection<ServiceInstance<MetaData>> services = zkClient.discovery().queryForInstances(SERVICE_NAME);
assertThat(services).hasSize(1);
assertThat(services).first().hasFieldOrPropertyWithValue("id", SERVICE_ID);
@@ -129,17 +129,17 @@ public class ZooKeeperServiceRegistryTest {
public static class ZooKeeperTestClient {
private final CuratorFramework curator;
- private final ServiceDiscovery<ZooKeeperServiceRegistry.MetaData> discovery;
+ private final ServiceDiscovery<MetaData> discovery;
public ZooKeeperTestClient(String nodes) {
curator = CuratorFrameworkFactory.builder()
.connectString(nodes)
.retryPolicy(new ExponentialBackoffRetry(1000, 3))
.build();
- discovery = ServiceDiscoveryBuilder.builder(ZooKeeperServiceRegistry.MetaData.class)
+ discovery = ServiceDiscoveryBuilder.builder(MetaData.class)
.client(curator)
.basePath(SERVICE_PATH)
- .serializer(new JsonInstanceSerializer<>(ZooKeeperServiceRegistry.MetaData.class))
+ .serializer(new JsonInstanceSerializer<>(MetaData.class))
.build();
}
@@ -147,7 +147,7 @@ public class ZooKeeperServiceRegistryTest {
return curator;
}
- public ServiceDiscovery<ZooKeeperServiceRegistry.MetaData> discovery() {
+ public ServiceDiscovery<MetaData> discovery() {
return discovery;
}