camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ravi narayanan <geekstuf...@gmail.com>
Subject Re: warning while calling Bean ref in camel route
Date Fri, 29 Apr 2016 08:54:54 GMT
Hi,

Still iam getting warning when i use bean ref


warn message

10:48:07,147 WARN  [org.apache.camel.util.ObjectHelper]
(http-/127.0.0.1:8080-11) Cannot find class: A1_Sync_Con_RQRequestReceived


<bean ref="Audit"
method="logAuditMessage(${body},'A1_Sync_Con_RQ Request Received :')" />

java method:
public void logAuditMessage(BihMessage body,String message)
{
String Header = BihMessageHandler.prepareBihHeader(body);
BIHLogger logger=new BIHLogger();
logger.logBIHAuditMessage(message +
Header,Level.INFO,"C:\\Logfiles\\Audit.log");
}


Regards,
Ravi

On Thu, Apr 28, 2016 at 8:04 PM, ravi narayanan <geekstuff24@gmail.com>
wrote:

> Hi John,
> I have tried it and getting the same error...
>
>
> On Thursday, 28 April 2016, John D. Ament <johndament@apache.org> wrote:
>
>> You should quote the string when passing it in, e.g.
>>
>> <bean ref="Audit"
>>
>> method="logAuditMessage(${body},'A1_Sync_Con_RQ Request Received :')" />
>>
>> Then it will be passed in as the second argument as a string.
>>
>> On Thu, Apr 28, 2016 at 11:48 AM ravi21588 <ravi21588@gmail.com> wrote:
>>
>> > Hi All,
>> >
>> > Iam getting below warn when i call the bean ref in camel route
>> >
>> >
>> > 17:44:18,385 WARN  [org.apache.camel.util.ObjectHelper]
>> > (http-/127.0.0.1:8080-18) Cannot find class:
>> A1_Sync_Con_RQRequestReceived
>> >
>> > <bean ref="Audit"
>> >
>> > method="logAuditMessage(${body},A1_Sync_Con_RQ Request Received :)" />
>> >
>> >
>> > Java class:
>> >
>> > package com.example.switchyard.a1.sync.consumer.rq;
>> >
>> > import javax.enterprise.context.ApplicationScoped;
>> > import javax.inject.Named;
>> >
>> > import org.apache.log4j.Level;
>> >
>> > import com.agcs.bih.message.model.v2.BihMessage;
>> > import com.agcs.bih.message.v2.BIHLogger;
>> > import com.agcs.bih.message.v2.BihMessageHandler;
>> >
>> > @Named("Audit")
>> > @ApplicationScoped
>> > public class Audit {
>> >
>> >         public void logAuditMessage(BihMessage body,String message)
>> >         {
>> >                 String Header =
>> BihMessageHandler.prepareBihHeader(body);
>> >                 BIHLogger logger=new BIHLogger();
>> >                 logger.logBIHAuditMessage(message +
>> > Header,Level.INFO,"C:\\Logfiles\\Audit.log");
>> >         }
>> >
>> > }
>> >
>> >
>> > Can you please tell me what might be issue.
>> >
>> >
>> >
>> > --
>> > View this message in context:
>> >
>> http://camel.465427.n5.nabble.com/warning-while-calling-Bean-ref-in-camel-route-tp5781911.html
>> > Sent from the Camel - Users mailing list archive at Nabble.com.
>> >
>>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message