directory-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Li Chuan" <lichuan...@gmail.com>
Subject Re: Warning "PDU has been fully decoded but there are still bytes in the buffer"
Date Fri, 17 Oct 2008 09:06:36 GMT
On Fri, Oct 17, 2008 at 10:38 AM, Emmanuel Lecharny <elecharny@gmail.com>wrote:

> Li Chuan wrote:
>
>> Hi guys,
>>
>> I'd like to ask, I noticed that the 1.5.3 server sometimes warns about
>> "PDU
>> has been fully decoded but there are still bytes in the buffer" by the
>> Asn1Decoder class. I guess the author had attempted to address the issue
>> but
>> left it open. Could someone share his knowledge about the background?
>> Thank
>> you very much!
>>
>>
> Are you in DEBUG mode when you get this message ?
>
> In any case, this is just to inform that when we receive some bytes, they
> can contain more than one PDU. When the first PDU has been decoded, the
> decoder says that there are more bytes to read.
>
> I would like to get a bit more of context, in order to tell you if it's a
> bug (likely not) or simply a message you receive at the wrong log level
> (warning instead of debug).
>
> Thanks !
>
>> Regards,
>>  Chuan
>>
>>
>>
>
>
> --
> --
> cordialement, regards,
> Emmanuel L├ęcharny
> www.iktek.com
> directory.apache.org
>
>
>
Hi, it is not the debug mode I am in. I could only say it seems to have to
do with canceling operations (connection gets closed when it is still doing
its job?) . I found these lines in Asn1Decoder (1.5.3) being responsible for
this warning case:

...
                case TLVStateEnum.PDU_DECODED:
                    // We have to deal with the case where there are
                    // more bytes in the buffer, but the PDU has been
decoded.
                    log.warn( "The PDU has been fully decoded but there are
still bytes in the buffer." );

                    hasRemaining = false;

                    break;
...

And did you mean that the rest bytes belong to another PDU yet to be
decoded? If so I think it would be just fine! : )

Regards,
  Chuan

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