Null check in camel routes

In camel routes, null check of body content can be done as given below: .choice() .when(body().isNull()) .log(LoggingLevel.INFO, “Body is null”) .otherwise() .log(LoggingLevel.INFO, “Body is not null”) .endChoice() If you are doing null check on a exchange header, this can be done using: .choice() .when(header(“sampleheader”).isNull()) .log(LoggingLevel.INFO, “Value of exchange header ‘sampleheader’ is null”) .otherwise() .log(LoggingLevel.INFO, “Value Read More…

Apache Camel – Message History

Message history in Apache Camel is available since camel 2.12. Message history of a message will help to trace out the list of all applications that the message passed through since its origination. When a message is sent to an endpoint, that endpoint information is stored in message history.Message history is stored as exchange property. Read More…

List of JavaDoc tags

Following are the list of JavaDoc tags available. Tag Available from Use @author 1.0 To mention author name of the class @deprecated 1.0 To notify that a given API is no longer supported and shouldn’t be used anymore @exception 1.0 To add Throws subheading to the generated documentation, wit classname & description @param 1.0 Parameter Read More…

How to resolve maven dependency conflicts

When dealing with lots of maven dependencies we normally ends up with conflicts. This can be due to different versions of same library in classpath. In this case we have to manually identify the exact maven dependencies with which this library is added. Maven provides an option to list all the libraries added to classpath due Read More…

Abbreviations used in Java world

AFC – Application Foundation Classes AJAX – Asynchronous JavaScript and XML ANT – Another Neat Tool AWT – Abstract Window Toolkit CMP – Container Managed Persistence CMT – Container Managed Transaction EJB – Enterprise Java Beans GWT – Google Web Toolkit IDE – Integrated Development Environment JAR – Java Archive JAX – Java API for Read More…

Solution for iframe issue in iPad

iframe is behaved differently in iPad compared to other web browsers with different platform. It can be solved with the following set of code: <div style=”border:1px solid black;height:202px; width:402px;overflow:auto;”> <iframe style=”border:1px solid black;height:200px; width:400px;overflow:auto;” src=”http://jyothis.co.in”/> </div> A demo of this solution can be viewed from the following link: http://demo.jyothis.co.in/iframe/

HTML form tag and new line

Sometimes the browser will display a new line in HTML page where the form tag is started. This can be fixed by using any of the following CSS/HTML code. In CSS file: form {display: inline; } In HTML (inline CSS) <form style=”display: inline;”></form>