Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id DBAD3200D27 for ; Wed, 25 Oct 2017 14:45:10 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id D9F08160BF2; Wed, 25 Oct 2017 12:45:10 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 0A5011609E5 for ; Wed, 25 Oct 2017 14:45:09 +0200 (CEST) Received: (qmail 8831 invoked by uid 500); 25 Oct 2017 12:45:08 -0000 Mailing-List: contact users-help@camel.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: users@camel.apache.org Delivered-To: mailing list users@camel.apache.org Received: (qmail 8819 invoked by uid 99); 25 Oct 2017 12:45:08 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd3-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 25 Oct 2017 12:45:08 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd3-us-west.apache.org (ASF Mail Server at spamd3-us-west.apache.org) with ESMTP id D150418071F for ; Wed, 25 Oct 2017 12:45:07 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd3-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: -1.901 X-Spam-Level: X-Spam-Status: No, score=-1.901 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, KAM_NUMSUBJECT=0.5, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-2.8, RCVD_IN_SORBS_SPAM=0.5, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd3-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-us.apache.org ([10.40.0.8]) by localhost (spamd3-us-west.apache.org [10.40.0.10]) (amavisd-new, port 10024) with ESMTP id x7upK8iE2uK0 for ; Wed, 25 Oct 2017 12:45:06 +0000 (UTC) Received: from mail-qk0-f175.google.com (mail-qk0-f175.google.com [209.85.220.175]) by mx1-lw-us.apache.org (ASF Mail Server at mx1-lw-us.apache.org) with ESMTPS id 14EB65FD01 for ; Wed, 25 Oct 2017 12:45:06 +0000 (UTC) Received: by mail-qk0-f175.google.com with SMTP id k123so30298093qke.3 for ; Wed, 25 Oct 2017 05:45:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to; bh=4uwRmW5gshfdhZjtA07zurj6V+VVWsCU7Ga60Obkf48=; b=AcrPhwIrrdTJzSwcdm8HgBoFQD3AcA3RG8utMB5GhjniiQ3luFXoC4rCkvnj/6hdrM UrSozD0dg5iDnqen/mB4YBQ82TcAgk8M1FYJcoeatXpL/GQdbn+Qt07/UdhKqjTuYRk9 8tkVJQO+wsqF9ATzwnu9IsbT57CvnPNEw8CmkcX27G2wXR3oddyvZM+IrQlZnLomS8Dg /DszZ3Gcfh/K7EstmGAu6sPUzmxRE8a4O8lwV/zdIQ05CPqN07rzcuTFjkCm9D156CKB KEX0gK/iomgjTKTwWbFExlp9EFPUHQenEWzcQUf6ZnkucdLQOpDr3TOkrTk1PkcAhFw0 6NoA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to; bh=4uwRmW5gshfdhZjtA07zurj6V+VVWsCU7Ga60Obkf48=; b=sDbXqalG/2+eg6+oq9dy/9jKdJSn78kiPXjGkO95dOp+UIeA6d8WJtfHwOOV/IowmG iy8lVof0CqssBannSE9CmOJol2rXke7gWzFPrJBxk9rn6TKfmSv9EAU/GXEJ04rcLsoz myk7igcXpMMdoKxK3zC46KKEo/MVc8lK/EjklEjDQ1lOdO5qKarquUNmA2pKQ2lDW3d/ 2ZcP+/Urhi0ynGSyapkjI7JQ5LQxkb7zLC3ib/QVB1qX8xIssJAFnr2MOvDadYBD0alc uSlHD5qVK/CBUFw+bHbVi2ph8u/isTWLwM2HwLoPiTGc+iLwATePC1umomLp4Ieq67Wp FwHg== X-Gm-Message-State: AMCzsaX3M85BJeDVGl6OCVbMBrGFmZ93A8twmWZwuvaRfyvAT9Ehpzlk o57hoDdyAwJJyQZGqZK/uu7mV/xd6wsB2oLYjaEtXWlZ X-Google-Smtp-Source: ABhQp+SK8tl5iM4guw/Yc7SFhBSxAShyO2sNqHxkexLEkctnCCvg2qtlMH3jeRYcDv/UaPQwOxFzq6LbtCG40ynELI4= X-Received: by 10.55.130.5 with SMTP id e5mr2616599qkd.155.1508935499179; Wed, 25 Oct 2017 05:44:59 -0700 (PDT) MIME-Version: 1.0 Received: by 10.200.35.97 with HTTP; Wed, 25 Oct 2017 05:44:38 -0700 (PDT) In-Reply-To: References: From: Claus Ibsen Date: Wed, 25 Oct 2017 14:44:38 +0200 Message-ID: Subject: Re: Problem with upgrade from camel 2.19.3 to camel 2.20.0 To: "users@camel.apache.org" Content-Type: text/plain; charset="UTF-8" archived-at: Wed, 25 Oct 2017 12:45:11 -0000 Builds from source, or wait until the apache CI server is able to succesfully build and publish snapshots to apache snapshot repo https://www.apache.org/dev/repository-faq.html On Wed, Oct 25, 2017 at 2:13 PM, Dicken George wrote: > Okay. Thank you update and for creating an JIRA ticket. > > I see it is already resolved. However, in order to test it locally on my > dev environment, i cannot find the artifactory where i could download the > changes from this ticket https://issues.apache.org/jira/browse/CAMEL-11945 > > Where can i get the camel 2.21.0-snapshot or 2.20.1-snapshot artifactory? > > > > On Wed, Oct 25, 2017 at 12:01 PM, Claus Ibsen wrote: > >> Hi >> >> See ticket >> https://issues.apache.org/jira/browse/CAMEL-11945 >> >> On Tue, Oct 24, 2017 at 3:36 PM, Dicken George >> wrote: >> > Dear Fellow Developers, >> > >> > Just recently, I tried to upgrade my camel-spring boot project form camel >> > 2.19.3 to camel 2.20.0 and I face the problem that, I cannot boot up my >> > application any more, and I get the following stack trace >> > >> > java.lang.NullPointerException >> > at >> > com.haufe.ssmp.sfdc.api.app.BeanConfiguration.afterApplicationStart( >> BeanConfiguration.java:66) >> > at >> > org.apache.camel.spring.boot.RoutesCollector.onApplicationEvent( >> RoutesCollector.java:226) >> > at >> > org.apache.camel.spring.boot.RoutesCollector.onApplicationEvent( >> RoutesCollector.java:54) >> > at >> > org.springframework.context.event.SimpleApplicationEventMulticas >> ter.doInvokeListener(SimpleApplicationEventMulticaster.java:172) >> > at >> > org.springframework.context.event.SimpleApplicationEventMulticas >> ter.invokeListener(SimpleApplicationEventMulticaster.java:165) >> > at >> > org.springframework.context.event.SimpleApplicationEventMulticas >> ter.multicastEvent(SimpleApplicationEventMulticaster.java:139) >> > at >> > org.springframework.context.support.AbstractApplicationContext. >> publishEvent(AbstractApplicationContext.java:393) >> > at >> > org.springframework.context.support.AbstractApplicationContext. >> publishEvent(AbstractApplicationContext.java:347) >> > at >> > org.springframework.context.support.AbstractApplicationContext. >> finishRefresh(AbstractApplicationContext.java:883) >> > at >> > org.springframework.boot.context.embedded.EmbeddedWebApplicationContext. >> finishRefresh(EmbeddedWebApplicationContext.java:144) >> > at >> > org.springframework.context.support.AbstractApplicationContext.refresh( >> AbstractApplicationContext.java:546) >> > at >> > org.springframework.boot.context.embedded.EmbeddedWebApplicationContext. >> refresh(EmbeddedWebApplicationContext.java:122) >> > at >> > org.springframework.boot.SpringApplication.refresh( >> SpringApplication.java:693) >> > at >> > org.springframework.boot.SpringApplication.refreshContext( >> SpringApplication.java:360) >> > at >> > org.springframework.boot.SpringApplication.run( >> SpringApplication.java:303) >> > at >> > org.springframework.boot.SpringApplication.run( >> SpringApplication.java:1118) >> > at >> > org.springframework.boot.SpringApplication.run( >> SpringApplication.java:1107) >> > at com.haufe.ssmp.sfdc.api.Application.main(Application.java:12) >> > >> > Due to my complex use case, i would like to start one specific route >> > manually and not use the autoconfiguration and autostart from >> camelcontext. >> > I do this in my configuration class by over riding the before application >> > start and after application start methods. >> > >> > @Configuration >> > class BeanConfiguration implements CamelContextConfiguration { >> > private static final Logger log = >> > LoggerFactory.getLogger(BeanConfiguration.class); >> > >> > @Override >> > public void beforeApplicationStart(CamelContext camelContext) { >> > camelContext.setPackageScanClassResolver(new >> > FatJarPackageScanClassResolver()); >> > camelContext.resolveDataFormat("json-jackson"); >> > } >> > >> > @Autowired >> > SalesforceComponent sfdcComp; >> > >> > @Override >> > public void afterApplicationStart(CamelContext camelContext) { >> > >> > try { >> > sfdcComp.start(); >> > camelContext.startRoute("salesforce-versions"); >> > Route theRoute = camelContext.getRoute(" >> salesforce-versions"); >> > Endpoint ep = theRoute.getEndpoint(); >> > >> > Exchange exchange = ep.createExchange(); >> > ProducerTemplate template = >> > exchange.getContext().createProducerTemplate(); >> > DefaultExchange o = (DefaultExchange) template.request(ep, >> new >> > Processor() { >> > >> > @Override >> > public void process(Exchange exchange) throws Exception { >> > // TODO Auto-generated method stub >> > >> > } >> > }); >> > Object result = o.getOut().getBody(); >> > if(result == null && !(result instanceof ArrayList)) >> > throw new Exception("No Salesforce version, login >> > failed."); >> > >> > ArrayList theList = (ArrayList) result; >> > if(theList.size() <= 1) >> > throw new Exception("No Salesforce version got, login >> > failed."); >> > log.debug("Connection to salesforce successfully >> established:"); >> > >> > } catch (Exception e) { >> > // TODO Auto-generated catch block >> > e.printStackTrace(); >> > throw new RuntimeException("No Connection to salesforce"); >> > } >> > >> > } >> > In this code, i saw during my debugging that it was able to start the >> > routes in camelcontext object and get the endpoints, however with version >> > 2.20.0 I see my routes are not added to the camelcontext and no routes >> are >> > started. >> > >> > Could anyone help me here to trouble shoot this issue ? >> > >> > Thanks in advance >> > -- >> > >> > Dicken George >> >> >> >> -- >> Claus Ibsen >> ----------------- >> http://davsclaus.com @davsclaus >> Camel in Action 2: https://www.manning.com/ibsen2 >> > > > > -- > > Dicken George -- Claus Ibsen ----------------- http://davsclaus.com @davsclaus Camel in Action 2: https://www.manning.com/ibsen2