Hi Your code is not easy to read and you dont show all the needed code.
There is csimple in BuilderSupport BuilderSupport is part of RouteBuilder and AdviceWithRouteBuilder so you should have that out of the box. But if you are using the lambda style then its only an interface, and then you dont have the base class of BuilderSupport. And for that we need those static methods on Builder, which are missing. I created a ticket https://issues.apache.org/jira/browse/CAMEL-16066 On Wed, Jan 20, 2021 at 6:54 PM Markus Steiner <scea2...@yahoo.com.invalid> wrote: > > Thanks a lot Claus for your advice. > > I’m already aware of all that you‘ve kindly explained but as my original mail > below was not well formatted you did not get my point. > > The problem is just that there is NO csimple method out there I could make > use of! Following my original mail again in a better formatted style. Hope > this makes it clear about the issue: > > Hi > > Using Camel 3.7.0 inside afterApplicationStart method of my custom > org.apache.camel.spring.boot.CamelContextConfiguration class I have something > already working like: > > AdviceWith.weaveById(MY_PATTERN).after().wireTap(MY_URI) > .newExchangeHeader(MY_DATE_HEADER, simple(${date:now}")) > .newExchangeBody(simple(${exchangeProperty["foo"].remove('bar')})); > > How could I switch to use csimple here as there seems no > org.apache.camel.builder.Builder#csimple method be available. In contrast to > org.apache.camel.builder.Builder#simple. > > I think somehow a class with the corresponding method should get generated at > build time to delegate the call to > org.apache.camel.language.csimple.CSimpleHelper#date. Maybe? > > Thanks > > > Am 20.01.2021 um 17:13 schrieb Claus Ibsen <claus.ib...@gmail.com>: > > > > Hi > > > > You need Camel 3.7, and there is a csimple you can use instead of simple. > > > > And then you need to either pre compile or use camel-csimple-joor. > > > > See the 2 examples at > > > > https://github.com/apache/camel-examples/tree/master/examples/camel-example-csimple > > https://github.com/apache/camel-examples/tree/master/examples/camel-example-csimple-joor > > > >> On Sat, Jan 16, 2021 at 11:34 PM Markus Steiner > >> <scea2...@yahoo.com.invalid> wrote: > >> > >> Hi > >> Using Camel 3.7.0 inside afterApplicationStart method of my custom > >> org.apache.camel.spring.boot.CamelContextConfiguration class I have > >> something already working like: > >> AdviceWith.weaveById(MY_PATTERN).after().wireTap(MY_URI) > >> .newExchangeHeader(MY_DATE_HEADER, simple(${date:now}")) > >> .newExchangeBody(simple(${exchangeProperty["foo"].remove('bar')})); > >> How could I switch to use csimple here as there seems no > >> org.apache.camel.builder.Builder.csimple method out there. I think somehow > >> a class with the corresponding method should get generated at build time > >> to delegate the call to > >> org.apache.camel.language.csimple.CSimpleHelper#date. Maybe? > >> Thanks > > > > > > > > -- > > Claus Ibsen > > ----------------- > > http://davsclaus.com @davsclaus > > Camel in Action 2: https://www.manning.com/ibsen2 > -- Claus Ibsen ----------------- http://davsclaus.com @davsclaus Camel in Action 2: https://www.manning.com/ibsen2