Unsupported Groovy DSL Features on Web ConsolePage added by Xueqiang MiUnsupported Groovy DSL Features on Web ConsoleMost of the DSL features have been supported on Web Console, so you can view and edit in an easy way. However, Web Console doesn't support all the features that you can get from an IDE. Here will list and explain the unsupported features, including the reason for giving up them, alternative solutions or some suggestion for those who indeed need to extend them. Unsupported Features Listcreating new classesWhen writing a route in Java DSL, we often create new classes. For example, we may create a processor as follows: from("direct:start").process(new Processor() { public void process(Exchange exchange) { Message in = exchange.getIn(); in.setBody(in.getBody(String.class) + " World!"); } }).to("mock:result"); Here an anonymous inner class is created to process the message. But this feature is not supported on Web Console since it use a groovy class loader to parse the route content and you should use groovy grammar to build the processor.
invoking un-imported classseThis feature also appears frequently. In the try...catch DSL or onException DSL, we may use some external or custom exception classes. But current groovy renderer doesn't process the import packages, so if you should manually add the import lines each time you edit it.
other featuresSome _expression_ and predicate have complex and refractory toString method, so the ExpressionRenderer and PredicateRenderer class written a little hard.
Change Notification Preferences
View Online
|
Add Comment
|
- [CONF] Apache Camel > Unsupported Groovy DSL Features on Web... confluence