Yes, I am referencing the tests. They don't include how to make it work in a standalone camel. The question is how to get the instance of SalesforceComponent in the CamelContext of the instance of standalone org.apache.camel.main.Main. So i've done it in my RouteBuilder configure() where i can add the SalesforceComponent instance to the context in the route:
public class RoutePollSalesforce extends RouteBuilder { ... public void configure() throws Exception { ... SalesforceComponent component = new SalesforceComponent(); component.setLoginConfig(this.loginConfig); component.setPackages(new String[]{ Program_Schedule__c.class.getPackage().getName() }); this.getContext().addComponent("salesforce", component); from("direct:pollSalesforce") .to("salesforce:query?q=SELECT+Id,Name+FROM+Program_Schedule__c"); } } and now the complaint is this, which I don't understand yet: Exception in thread "main" org.apache.camel.FailedToCreateRouteException: Failed to create route route4 at: >>> To[salesforce:query?q=SELECT+Id,Name+FROM+Program_Schedule__c] <<< in route: Route(route4)[[From[direct:pollSalesforce]] -> [To[salesforc... because of Failed to resolve endpoint: salesforce://query?q=SELECT+Id%2CName+FROM+Program_Schedule__c due to: Failed to resolve endpoint: salesforce://query?q=SELECT+Id%2CName+FROM+Program_Schedule__c due to: There are 1 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=[{q=SELECT Id,Name FROM Program_Schedule__c}] at org.apache.camel.model.RouteDefinition.addRoutes(RouteDefinition.java:1028) at org.apache.camel.model.RouteDefinition.addRoutes(RouteDefinition.java:185) at org.apache.camel.impl.DefaultCamelContext.startRoute(DefaultCamelContext.java:841) at org.apache.camel.impl.DefaultCamelContext.startRouteDefinitions(DefaultCamelContext.java:2911) at org.apache.camel.impl.DefaultCamelContext.doStartCamel(DefaultCamelContext.java:2634) at org.apache.camel.impl.DefaultCamelContext.access$000(DefaultCamelContext.java:167) at org.apache.camel.impl.DefaultCamelContext$2.call(DefaultCamelContext.java:2483) at org.apache.camel.impl.DefaultCamelContext$2.call(DefaultCamelContext.java:2479) at org.apache.camel.impl.DefaultCamelContext.doWithDefinedClassLoader(DefaultCamelContext.java:2502) at org.apache.camel.impl.DefaultCamelContext.doStart(DefaultCamelContext.java:2479) at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:61) at org.apache.camel.impl.DefaultCamelContext.start(DefaultCamelContext.java:2448) at org.apache.camel.main.Main.doStart(Main.java:124) at org.apache.camel.support.ServiceSupport.start(ServiceSupport.java:61) at org.apache.camel.main.MainSupport.run(MainSupport.java:150) at com.disney.datg.Driver.startDriver(Driver.java:77) at com.disney.datg.Driver.main(Driver.java:88) -- View this message in context: http://camel.465427.n5.nabble.com/how-to-get-loginConfig-into-standalone-camel-salesforce-component-tp5771694p5771876.html Sent from the Camel - Users mailing list archive at Nabble.com.