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…