camel-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Claus Ibsen" ...@silverbullet.dk>
Subject RE: how to disable warn log message when running HttpGetTest.java ?
Date Fri, 13 Jun 2008 08:23:54 GMT
Hi

Thansk for looking into this. It's a bug in Camel. I have reported it  	 CAMEL-607


Med venlig hilsen
 
Claus Ibsen
......................................
Silverbullet
Skovsgårdsvænget 21
8362 Hørning
Tlf. +45 2962 7576
Web: www.silverbullet.dk
-----Original Message-----
From: jhcha [mailto:jhcha@kds.co.kr] 
Sent: 13. juni 2008 09:46
To: camel-user@activemq.apache.org
Subject: Re: how to disable warn log message when running HttpGetTest.java ?


Dear Camel Developer.

Thanks for reply.

After your reply, I has investigated the reason of that warning message 
more precisely. 
I did understand the Camel TypeConverter more deeply. 

I found why the warning message displayed. 

Tha camel http component type converter class has the two methods having the
same input parameter type
ant return type. 

at org.apache.camel.component.http.HttpConverter.java 

 @Converter
    public ServletInputStream toServletInputStream(HttpMessage message)
throws IOException {
        System.out.println("Converting to an InputStream using the
HttpConverter!");
        HttpServletRequest request = toServletRequest(message);
        if (request != null) {
            return request.getInputStream();
        }
        return null;
    }

    @Converter
    public ServletInputStream toInputStream(HttpMessage message) throws
IOException {
        return toServletInputStream(message);
    }

I don't know why the two methods has the same from and to type. 

Might the toInputStream return type be InputStream ? 
When I replace the toInputStream return type to InputStream, the warning
message disappeared. 

Could you check the camel http component type converter source ? 

Thanks a lot. 

Sincerely.

J. H. Cha 



-- 
View this message in context: http://www.nabble.com/how-to-disable-warn-log-message-when-running-HttpGetTest.java---tp17598680s22882p17817463.html
Sent from the Camel - Users mailing list archive at Nabble.com.


Mime
View raw message