Apache Ignite Failed to connect to any address from IP finder (will retry to join topology every 2000 ms

My requirement is, I need to create standalone apache ignite thick client running like a server. and there is a client application will access the Ignite.

I managed to run my Ignite server in openshift environment using KubernetesIpFinder given my namespace and servicename.

When I try to run my Ignite client in openshift using KubernetesIpFinder given same namespace and servicename, I am getting ” Failed to connect to any address from IP finder (will retry to join topology every 2000 ms” Error.

NOTE: Cluster role and binding access already been given.

Below are my details and code

I am using,

Spring Boot version : 3.1.5
Gradle : 8.4 (Wrapper)
Apache Ignite: 2.15.0

SERVER CODE:

    @Bean
    public IgniteConfigurer configurer() {
        return igniteConfig -> {
            igniteConfig.setIgniteInstanceName("myCache");
            igniteConfig.setMetricsLogFrequency(600000); // 10 minutes
            igniteConfig.setPeerClassLoadingEnabled(true);
            igniteConfig.setDiscoverySpi(getTcpDiscoverySpi());
            var communicationSpi = new TcpCommunicationSpi();
            communicationSpi.setMessageQueueLimit(100);
            communicationSpi.setSlowClientQueueLimit(1000);
            igniteConfig.setCommunicationSpi(communicationSpi);

            igniteConfig.setCacheConfiguration(getCacheConfiguration());

        };
    }

    private TcpDiscoverySpi getTcpDiscoverySpi() {
        var spi = new TcpDiscoverySpi();

        var kubConfiguration = new KubernetesConnectionConfiguration();
        kubConfiguration.setNamespace("option-services");
        kubConfiguration.setServiceName("test-ignite-cache-service");

        var ipFinder = new TcpDiscoveryKubernetesIpFinder(kubConfiguration);
        spi.setIpFinder(ipFinder);
        // set timeout properties
        spi.setAckTimeout(90000);
        spi.setSocketTimeout(90000);
        spi.setNetworkTimeout(90000);
        return spi;
    }
    private <K, V> CacheConfiguration<K, V> getCacheConfiguration( ) {
        CacheConfiguration<K, V> cacheCfg = new CacheConfiguration<>();
        cacheCfg.setName("marketCache");
         cacheCfg.setCacheMode(CacheMode.REPLICATED);
        return cacheCfg;
    }

route.yaml
----------
apiVersion: route.openshift.io/v1
kind: Route
metadata:
  annotations:
    haproxy.router.openshift.io/timeout: 600s
  name: test-ignite-cache-service
  namespace: option-services
  labels:
    app: test-ignite-cache-service
spec:
  to:
    kind: Service
    name: test-ignite-cache-service
  port:
    targetPort: 8080
  tls:
    termination: edge
    insecureEdgeTerminationPolicy: None
  wildcardPolicy: None

service.yaml
-----------

apiVersion: v1
kind: Service
metadata:
  name: test-ignite-cache-service
  namespace: option-services
  labels:
    app: test-ignite-cache-service
spec:
  selector:
    deploymentconfig: test-ignite-cache-service
  type: NodePort
  ports:
    - name: 8080-tcp
      port: 8080
      protocol: TCP
      targetPort: 8080
      nodePort: 30080
    - name: 10800-thinclient
      port: 10800
      protocol: TCP
      targetPort: 10800
      nodePort: 30800
  sessionAffinity: None
status:
  loadBalancer: {}


deploymentconfig.yaml
----------------------

apiVersion: apps.openshift.io/v1
kind: DeploymentConfig
metadata:
  name: test-ignite-cache-service
  labels:
    app: test-ignite-cache-service
spec:
  replicas: 1
  selector:
    deploymentConfig: test-ignite-cache-service
  strategy:
    type: Recreate
    recreateParams:
      timeoutSeconds: 600
  triggers: [ ]
  template:
    metadata:
      name: test-ignite-cache-service
      labels:
        deploymentConfig: test-ignite-cache-service
        app: test-ignite-cache-service
    spec:
      terminationGracePeriodSeconds: 75
      serviceAccountName: test-ignite-cache-service
      containers:
        - name: test-ignite-cache-service
          image: {{ .Values.lsImageBase }}:{{ .Chart.AppVersion }}
          imagePullPolicy: Always
          env:
            - name: JAVA_VM_OPTS
              value: "-Dspring.profiles.active=dev"
          livenessProbe:
            failureThreshold: 10
            httpGet:
              path: {{ .Values.healthCheckEndpoint }}
              port: 8080
              scheme: HTTP
            periodSeconds: 60
            successThreshold: 1
            timeoutSeconds: 200
            initialDelaySeconds: 120
          readinessProbe:
            failureThreshold: 10
            httpGet:
              path: {{ .Values.healthCheckEndpoint }}
              port: 8080
              scheme: HTTP
            periodSeconds: 60
            successThreshold: 1
            timeoutSeconds: 200
            initialDelaySeconds: 120
          ports:
            - name: http
              containerPort: 8080
              protocol: TCP
            - name: thinclient
              containerPort: 10800
              protocol: TCP
          resources:
            requests:
              memory: {{ .Values.minMemory }}
              cpu: "100m"
            limits:
              memory: {{ .Values.maxMemory }}
              cpu: "500m"

CLIENT CODE:

 @Bean
    public Ignite igniteC() {
        System.out.println("ignite bean service");

        Ignite ignite = null;
        IgniteConfiguration igniteConfiguration = new IgniteConfiguration();
        igniteConfiguration.setClientMode(true);
        try {

            igniteConfiguration.setDiscoverySpi(getTcpDiscoverySpi());

            TcpCommunicationSpi commSpi = new TcpCommunicationSpi();
            commSpi.setLocalPort(42100);
            commSpi.setMessageQueueLimit(1024);
            commSpi.setSocketWriteTimeout(10000L);
            igniteConfiguration.setCommunicationSpi(commSpi);
            igniteConfiguration.setFailureDetectionTimeout(90000);

            igniteConfiguration.setIncludeEventTypes();
            igniteConfiguration.setPublicThreadPoolSize(16);
            igniteConfiguration.setSystemThreadPoolSize(16);
            igniteConfiguration.setPeerClassLoadingEnabled(true);


            ignite = Ignition.getOrStart(igniteConfiguration);

            ignite.atomicLong("kafkaPartition", 0, true);
            ignite.atomicLong("startNodes", 0, true);

        } catch (IgniteException e) {
            System.out.println("Exception :" + e.getCause().toString());
        }

        return ignite;
    }

private TcpDiscoverySpi getTcpDiscoverySpi() {
        var spi = new TcpDiscoverySpi();

        var kubConfiguration = new KubernetesConnectionConfiguration();
        kubConfiguration.setNamespace("option-services");
        kubConfiguration.setServiceName("test-ignite-cache-service");

        var ipFinder = new TcpDiscoveryKubernetesIpFinder(kubConfiguration);
        spi.setIpFinder(ipFinder);
        // set timeout properties
        spi.setAckTimeout(90000);
        spi.setSocketTimeout(90000);
        spi.setNetworkTimeout(90000);
        return spi;
    }

deploymentconfig.yaml
----------------------

apiVersion: apps.openshift.io/v1
kind: DeploymentConfig
metadata:
  name: test-ignite-cache-standalone
  labels:
    app: test-ignite-cache-standalone
spec:
  replicas: {{ .Values.replicas }}
  selector:
    deploymentConfig: test-ignite-cache-standalone
  strategy:
    type: Recreate
    recreateParams:
      timeoutSeconds: 600
  triggers: [ ]
  template:
    metadata:
      name: test-ignite-cache-standalone
      labels:
        deploymentConfig: test-ignite-cache-standalone
        app: test-ignite-cache-standalone
    spec:
      terminationGracePeriodSeconds: 75
      serviceAccountName: test-ignite-cache-service
      containers:
        - name: test-ignite-cache-standalone
          image: {{ .Values.lsImageBase }}:{{ .Chart.AppVersion }}
          imagePullPolicy: Always
          env:
            - name: JAVA_VM_OPTS
              value: "-Dspring.profiles.active={{ .Values.springProfile }}"
          livenessProbe:
            failureThreshold: 10
            httpGet:
              path: {{ .Values.healthCheckEndpoint }}
              port: 8081
              scheme: HTTP
            periodSeconds: 60
            successThreshold: 1
            timeoutSeconds: 200
            initialDelaySeconds: 120
          readinessProbe:
            failureThreshold: 10
            httpGet:
              path: {{ .Values.healthCheckEndpoint }}
              port: 8081
              scheme: HTTP
            periodSeconds: 60
            successThreshold: 1
            timeoutSeconds: 200
            initialDelaySeconds: 120
          ports:
            - name: http
              containerPort: 8081
              protocol: TCP
            - name: thinclient
              containerPort: 10800
              protocol: TCP
          resources:
            requests:
              memory: {{ .Values.minMemory }}
              cpu: "100m"
            limits:
              memory: {{ .Values.maxMemory }}
              cpu: "500m"


I am expecting to connect my server and client and talk each other how I am doing in my local using localhost addresses.

Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa Dịch vụ tổ chức sự kiện 5 sao Thông tin về chúng tôi Dịch vụ sinh nhật bé trai Dịch vụ sinh nhật bé gái Sự kiện trọn gói Các tiết mục giải trí Dịch vụ bổ trợ Tiệc cưới sang trọng Dịch vụ khai trương Tư vấn tổ chức sự kiện Hình ảnh sự kiện Cập nhật tin tức Liên hệ ngay Thuê chú hề chuyên nghiệp Tiệc tất niên cho công ty Trang trí tiệc cuối năm Tiệc tất niên độc đáo Sinh nhật bé Hải Đăng Sinh nhật đáng yêu bé Khánh Vân Sinh nhật sang trọng Bích Ngân Tiệc sinh nhật bé Thanh Trang Dịch vụ ông già Noel Xiếc thú vui nhộn Biểu diễn xiếc quay đĩa Dịch vụ tổ chức tiệc uy tín Khám phá dịch vụ của chúng tôi Tiệc sinh nhật cho bé trai Trang trí tiệc cho bé gái Gói sự kiện chuyên nghiệp Chương trình giải trí hấp dẫn Dịch vụ hỗ trợ sự kiện Trang trí tiệc cưới đẹp Khởi đầu thành công với khai trương Chuyên gia tư vấn sự kiện Xem ảnh các sự kiện đẹp Tin mới về sự kiện Kết nối với đội ngũ chuyên gia Chú hề vui nhộn cho tiệc sinh nhật Ý tưởng tiệc cuối năm Tất niên độc đáo Trang trí tiệc hiện đại Tổ chức sinh nhật cho Hải Đăng Sinh nhật độc quyền Khánh Vân Phong cách tiệc Bích Ngân Trang trí tiệc bé Thanh Trang Thuê dịch vụ ông già Noel chuyên nghiệp Xem xiếc khỉ đặc sắc Xiếc quay đĩa thú vị
Trang chủ Giới thiệu Sinh nhật bé trai Sinh nhật bé gái Tổ chức sự kiện Biểu diễn giải trí Dịch vụ khác Trang trí tiệc cưới Tổ chức khai trương Tư vấn dịch vụ Thư viện ảnh Tin tức - sự kiện Liên hệ Chú hề sinh nhật Trang trí YEAR END PARTY công ty Trang trí tất niên cuối năm Trang trí tất niên xu hướng mới nhất Trang trí sinh nhật bé trai Hải Đăng Trang trí sinh nhật bé Khánh Vân Trang trí sinh nhật Bích Ngân Trang trí sinh nhật bé Thanh Trang Thuê ông già Noel phát quà Biểu diễn xiếc khỉ Xiếc quay đĩa
Thiết kế website Thiết kế website Thiết kế website Cách kháng tài khoản quảng cáo Mua bán Fanpage Facebook Dịch vụ SEO Tổ chức sinh nhật