Hi Romain, Concerning the first component or new langage proposed based on assert, what will be the added value to use it instead of the existing "simple" language ? Can we imagine that missing functionalities covered by assert are simply added to the simple language instead of creating a new one ? I just think about rationality to maintain so much expression languages in camel and avoid having too much. By the way, this question should also be raised for some existing and question too their pertinence.
Regards, Charles On Mon, May 23, 2011 at 5:27 PM, Romain Manni-Bucau <rmannibu...@gmail.com> wrote: > Hi, > > i wrote 2 camel components, > > - the first one is very simple and could be a language: camel-assert ( > http://code.google.com/p/rmannibucau/source/browse/camel/camel-assert/): it > just allow to check values in a route, i know i could have used simple but i > wanted something more close to junit Assert class and really more simple > than what is dont to evaluate a language expression. > > from("direct:arrayEquals").to("assert:equals").to("mock:arrayEquals"); > > template.sendBodyAndHeader("direct:arrayEquals", new String[] { "a", > "b" }, AssertComponent.ACTUAL_HEADER_KEY, new String[] { "a", "b" }); > > > - the second one is simple too but can be useful when you work with files: > camel-codec ( > http://code.google.com/p/rmannibucau/source/browse/camel/#camel%2Fcamel-codec), > it allows to create hashes from a file. > > from("direct:start").to("codec:MD5").to("mock:result"); > > sendBody("direct:start", > getClass().getClassLoader().getResourceAsStream("foo.txt")); > Of course both can be used together to check a file ckecksum. > > Any thought about it? I created jira about them. > > - Romain >