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

Salesforce-source kamelet doesnt work in CK3

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • Blocker
    • camel-k-1.6.4-GA
    • camel-k-1.6.4-GA
    • Camel-K
    • None
    • False
    • False
    • % %
    • +
    • Automated

    Description

      public class MyRouteBuilder extends RouteBuilder {
          final String logMessage = "${body}";
      
          @Override
          public void configure() throws Exception {
              from("kamelet:salesforce-source?password=<password>&clientId=<client id>&loginUrl=https://login.salesforce.com&query=SELECT Id, FirstName, LastName, Email, Company FROM Lead WHERE Email='b08e7tnbTests@gmail.com'&topicName=kamelet-topic1&clientSecret=<secret>&userName=fuse.salesforce@gmail.com").log(logMessage);
          }
      }
      

      results in:

      2022-03-02 07:59:04,633 ERROR [org.apa.cam.qua.mai.CamelMainRuntime] (main) Failed to start application: org.apache.camel.RuntimeCamelException: org.apache.camel.VetoCamelContextStartException: Failure creating route from template: salesforce-source
      	at org.apache.camel.RuntimeCamelException.wrapRuntimeException(RuntimeCamelException.java:66)
      	at org.apache.camel.support.service.BaseService.doFail(BaseService.java:413)
      	at org.apache.camel.impl.engine.AbstractCamelContext.doFail(AbstractCamelContext.java:3350)
      	at org.apache.camel.support.service.BaseService.fail(BaseService.java:342)
      	at org.apache.camel.impl.engine.AbstractCamelContext.failOnStartup(AbstractCamelContext.java:4847)
      	at org.apache.camel.impl.engine.AbstractCamelContext.init(AbstractCamelContext.java:2487)
      	at org.apache.camel.support.service.BaseService.start(BaseService.java:111)
      	at org.apache.camel.impl.engine.AbstractCamelContext.start(AbstractCamelContext.java:2494)
      	at org.apache.camel.impl.DefaultCamelContext.start(DefaultCamelContext.java:245)
      	at org.apache.camel.quarkus.main.CamelMain.doStart(CamelMain.java:94)
      	at org.apache.camel.support.service.BaseService.start(BaseService.java:119)
      	at org.apache.camel.quarkus.main.CamelMain.startEngine(CamelMain.java:139)
      	at org.apache.camel.quarkus.main.CamelMainRuntime.start(CamelMainRuntime.java:49)
      	at org.apache.camel.quarkus.core.CamelBootstrapRecorder.start(CamelBootstrapRecorder.java:45)
      	at io.quarkus.deployment.steps.CamelBootstrapProcessor$boot-173480958.deploy_0(CamelBootstrapProcessor$boot-173480958.zig:101)
      	at io.quarkus.deployment.steps.CamelBootstrapProcessor$boot-173480958.deploy(CamelBootstrapProcessor$boot-173480958.zig:40)
      	at io.quarkus.runner.ApplicationImpl.doStart(ApplicationImpl.zig:581)
      	at io.quarkus.runtime.Application.start(Application.java:101)
      	at io.quarkus.runtime.ApplicationLifecycleManager.run(ApplicationLifecycleManager.java:101)
      	at io.quarkus.runtime.Quarkus.run(Quarkus.java:66)
      	at io.quarkus.runtime.Quarkus.run(Quarkus.java:42)
      	at io.quarkus.runtime.Quarkus.run(Quarkus.java:119)
      	at io.quarkus.runner.GeneratedMain.main(GeneratedMain.zig:29)
      	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      	at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
      	at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      	at java.base/java.lang.reflect.Method.invoke(Method.java:566)
      	at io.quarkus.bootstrap.runner.QuarkusEntryPoint.doRun(QuarkusEntryPoint.java:48)
      	at io.quarkus.bootstrap.runner.QuarkusEntryPoint.main(QuarkusEntryPoint.java:25)
      Caused by: org.apache.camel.VetoCamelContextStartException: Failure creating route from template: salesforce-source
      	at org.apache.camel.component.kamelet.KameletComponent$LifecycleHandler.onContextInitialized(KameletComponent.java:422)
      	at org.apache.camel.impl.engine.AbstractCamelContext.doInit(AbstractCamelContext.java:2766)
      	at org.apache.camel.quarkus.core.FastCamelContext.doInit(FastCamelContext.java:165)
      	at org.apache.camel.support.service.BaseService.init(BaseService.java:83)
      	at org.apache.camel.impl.engine.AbstractCamelContext.init(AbstractCamelContext.java:2475)
      	... 23 more
      Caused by: org.apache.camel.component.kamelet.KameletNotFoundException: Kamelet with id salesforce-source not found in locations: classpath:/kamelets
      	at org.apache.camel.component.kamelet.KameletComponent$LifecycleHandler.createRouteForEndpoint(KameletComponent.java:410)
      	at org.apache.camel.component.kamelet.KameletComponent$LifecycleHandler.onContextInitialized(KameletComponent.java:419)
      	... 27 more
      Caused by: org.apache.camel.FailedToCreateRouteException: Failed to create route salesforce-source-1: Route(salesforce-source-1)[From[{{local-salesforce}}:{{topic... because of Failed to resolve endpoint: local-salesforce-1://kamelet-topic1?clientId=<clientid>&clientSecret=xxxxxx&loginUrl=https%3A%2F%2Flogin.salesforce.com&notifyForFields=ALL&notifyForOperationCreate=true&notifyForOperationDelete=false&notifyForOperationUndelete=false&notifyForOperationUpdate=false&password=xxxxxx&sObjectQuery=SELECT+Id%2C+FirstName%2C+LastName%2C+Email%2C+Company+FROM+Lead+WHERE+Email%3D+%27b08e7tnbTests%40gmail.com%27&updateTopic=true&userName=fuse.salesforce%40gmail.com due to: Failed to resolve endpoint: local-salesforce-1://kamelet-topic1?clientId=<clientid>&clientSecret=xxxxxx&loginUrl=https%3A%2F%2Flogin.salesforce.com&notifyForFields=ALL&notifyForOperationCreate=true&notifyForOperationDelete=false&notifyForOperationUndelete=false&notifyForOperationUpdate=false&password=xxxxxx&sObjectQuery=SELECT+Id%2C+FirstName%2C+LastName%2C+Email%2C+Company+FROM+Lead+WHERE+Email%3D+%27b08e7tnbTests%40gmail.com%27&updateTopic=true&userName=fuse.salesforce%40gmail.com due to: There are 5 parameters that couldn't be set on the endpoint. Check the uri if the parameters are spelt correctly and that they are properties of the endpoint. Unknown parameters=[{clientId=<clientid>, clientSecret=<secret>, loginUrl=https://login.salesforce.com, password=<password>, userName=fuse.salesforce@gmail.com}]
      	at org.apache.camel.reifier.RouteReifier.createRoute(RouteReifier.java:80)
      	at org.apache.camel.impl.DefaultModelReifierFactory.createRoute(DefaultModelReifierFactory.java:49)
      	at org.apache.camel.impl.DefaultCamelContext.startRouteDefinitions(DefaultCamelContext.java:826)
      	at org.apache.camel.component.kamelet.KameletComponent$LifecycleHandler.createRouteForEndpoint(KameletComponent.java:405)
      	... 28 more
      Caused by: org.apache.camel.ResolveEndpointFailedException: Failed to resolve endpoint: local-salesforce-1://kamelet-topic1?clientId=<clientid>&clientSecret=xxxxxx&loginUrl=https%3A%2F%2Flogin.salesforce.com&notifyForFields=ALL&notifyForOperationCreate=true&notifyForOperationDelete=false&notifyForOperationUndelete=false&notifyForOperationUpdate=false&password=xxxxxx&sObjectQuery=SELECT+Id%2C+FirstName%2C+LastName%2C+Email%2C+Company+FROM+Lead+WHERE+Email%3D+%27b08e7tnbTests%40gmail.com%27&updateTopic=true&userName=fuse.salesforce%40gmail.com due to: Failed to resolve endpoint: local-salesforce-1://kamelet-topic1?clientId=<clientid>&clientSecret=xxxxxx&loginUrl=https%3A%2F%2Flogin.salesforce.com&notifyForFields=ALL&notifyForOperationCreate=true&notifyForOperationDelete=false&notifyForOperationUndelete=false&notifyForOperationUpdate=false&password=xxxxxx&sObjectQuery=SELECT+Id%2C+FirstName%2C+LastName%2C+Email%2C+Company+FROM+Lead+WHERE+Email%3D+%27b08e7tnbTests%40gmail.com%27&updateTopic=true&userName=fuse.salesforce%40gmail.com due to: There are 5 parameters that couldn't be set on the endpoint. Check the uri if the parameters are spelt correctly and that they are properties of the endpoint. Unknown parameters=[{clientId=<clientid>, clientSecret=<secret>, loginUrl=https://login.salesforce.com, password=<password>, userName=fuse.salesforce@gmail.com}]
      	at org.apache.camel.impl.engine.AbstractCamelContext.doGetEndpoint(AbstractCamelContext.java:962)
      	at org.apache.camel.impl.engine.AbstractCamelContext.getEndpoint(AbstractCamelContext.java:844)
      	at org.apache.camel.support.CamelContextHelper.getMandatoryEndpoint(CamelContextHelper.java:58)
      	at org.apache.camel.reifier.AbstractReifier.resolveEndpoint(AbstractReifier.java:177)
      	at org.apache.camel.reifier.RouteReifier.doCreateRoute(RouteReifier.java:94)
      	at org.apache.camel.reifier.RouteReifier.createRoute(RouteReifier.java:74)
      	... 31 more
      Caused by: org.apache.camel.ResolveEndpointFailedException: Failed to resolve endpoint: local-salesforce-1://kamelet-topic1?clientId=<clientid>&clientSecret=xxxxxx&loginUrl=https%3A%2F%2Flogin.salesforce.com&notifyForFields=ALL&notifyForOperationCreate=true&notifyForOperationDelete=false&notifyForOperationUndelete=false&notifyForOperationUpdate=false&password=xxxxxx&sObjectQuery=SELECT+Id%2C+FirstName%2C+LastName%2C+Email%2C+Company+FROM+Lead+WHERE+Email%3D+%27b08e7tnbTests%40gmail.com%27&updateTopic=true&userName=fuse.salesforce%40gmail.com due to: There are 5 parameters that couldn't be set on the endpoint. Check the uri if the parameters are spelt correctly and that they are properties of the endpoint. Unknown parameters=[{clientId=<clientid>, clientSecret=<secret>, loginUrl=https://login.salesforce.com, password=<password>, userName=fuse.salesforce@gmail.com}]
      	at org.apache.camel.support.DefaultComponent.validateParameters(DefaultComponent.java:299)
      	at org.apache.camel.support.DefaultComponent.createEndpoint(DefaultComponent.java:192)
      	at org.apache.camel.impl.engine.AbstractCamelContext.doGetEndpoint(AbstractCamelContext.java:928)
      	... 36 more
      

      the same error happens when configuring the kamelet via application properties (configmap) or secret.

      Worked OK with in 1.6.0

      Attachments

        Activity

          People

            acosenti Andrea Cosentino
            avano@redhat.com Andrej Vano
            Andrej Vano Andrej Vano
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: