Uploaded image for project: 'Red Hat Fuse'
  1. Red Hat Fuse
  2. ENTESB-17031

CamelHttpUri in http-sink kamelet overriden if used with InMemoryChannel

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Blocker
    • Camel-K-GA
    • Camel-K-GA
    • Camel-K
    • None
    • False
    • False
    • % %
    • Todo
    • Undefined

    Description

      When a KameletBinding is created

      spec:
        sink:
          properties:
            httpUrl: 'http://httpbin/get'
            method: GET
          ref:
            apiVersion: camel.apache.org/v1alpha1
            kind: Kamelet
            name: http-sink
            namespace: mmuzikar
        source:
          ref:
            apiVersion: messaging.knative.dev/v1
            kind: InMemoryChannel
            name: ch9a5
      

      The resulting integration reports Invalid url: /channels/ch9a5. If you are forwarding/bridging http endpoints, then enable the bridgeEndpoint option on the endpoint: http://httpbin/get/

      When I logged the headers right before the exchange goes into {{url}} the following headers were set

      Accept-Encoding=gzip
      CamelCloudEventID=25CA6830ABF0840-00000000000003CE
      CamelCloudEventSource=source
      CamelCloudEventTime=2021-07-20T10:20:15.706Z
      CamelCloudEventType=org.apache.camel.event
      CamelCloudEventVersion=1.0
      CamelHttpMethod=GET
      CamelHttpPath=
      CamelHttpQuery=null
      CamelHttpUri=/channels/ch9a5
      Content-Length=11
      Forwarded=for=10.129.2.160;proto=http
      Host=inmem-to-http-sink.mmuzikar.svc.cluster.local
      K-Proxy-Request=activator
      Traceparent=00-6137759d8bd77f9ae9a2c71941146b06-93d684204576d565-00
      User-Agent=Go-http-client/1.1
      X-Forwarded-For=10.129.2.160,10.128.2.87
      X-Forwarded-Proto=http
      X-Request-Id=1bab0289-1f3d-4ab1-a448-3c6e57ce018f
      

      It looks like the CamelHttpUri is not set correctly when knative is used

      Attachments

        Activity

          People

            acosenti Andrea Cosentino
            mmuzikar Martin Muzikar
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: