Spring cloud stream solace binder connection

Shruti
Shruti Unconfirmed, Member Posts: 1

Hi Team,

I am trying to connect to solace using spring cloud stream solace binder with all the properties in application.yaml . It keeps giving error for connecting to localhost. Error creating bean with name 'com.solace.spring.cloud.stream.binder.config.SolaceMessageChannelBinderConfiguration': Invocation of init method failed; nested exception is com.solacesystems.jcsmp.JCSMPTransportException: (Client name: NL-C02FH05NMD6W/50490/#001e0002/N3JS4tsT8l  Local port: -1  Remote addr: localhost Remote port: 55555) - Error communicating with the router.Also find attached my properties file.

Where as in my application.yaml I have a completely different host than localhost.

Snapshot of my application.yaml


spring:
  cloud:
    function:
      definition: sink
    stream:
      bindings:
        sink-in-0:
          destination: 'ATP-ORDER-EVENTS-QUEUE'
          group: clientAck
          content-type: 'application/octet-stream'
          consumer:
            batch-mode: true
            useNativeDecoding: true
      binders:
        local-solace:
          type: solace
          environment:
            solace:
              java:
                host: tcps://int-gke-euwe4-int-ingka.messaging.solace.cloud:55443
                msgVpn: int-gke-euwe4
                clientUsername: 
                clientPassword: 
      solace:
        bindings:
          sink-in-0:
            consumer:
              #This adds a topic subscription w/ wildcards to the queue created with a name of TEMPS.Q.SINK above
              queueAdditionalSubscriptions: ingka.om.ado/fulfillmentOrder/full/allocated/1.0/EU/ISOM/RS/>


Answers

  • amackenzie
    amackenzie Member, Employee Posts: 259 Solace Employee

    It might be the binder name not being referenced and defaulting to a binder default localhost.

    Under binders: can you name it something other than `local-solace`? Then under the sink-in-0 section add `binder-name: <yournewname>`

  • marc
    marc Member, Administrator, Moderator, Employee Posts: 898 admin
    edited May 2022 #3

    Hi @Shruti,

    I'm curious if you figured it out. Your configuration looks correct to me but it can be tricky to troubleshoot yaml files w/ spaces.

    Also, I think Spring Boot will accept application.yml or application.yaml but for kicks can you test application.yml instead?