You are viewing a plain text version of this content. The canonical link for it is here.
Posted to log4php-dev@logging.apache.org by Ivan Habunek <iv...@gmail.com> on 2013/12/01 09:42:07 UTC

Re: MDC, NDC (was: Re: Restarting development)

On 30 November 2013 21:23, Christian Grobmeier <gr...@gmail.com> wrote:
>> We actually have MDC and NDC.
>>
> Thanks. I know remember that I put some work in these classes before ages.
>
> In this case I am caring about the docs.
>
> However I never found much sense in the NDC. Any objections to remove NDC?

I never used it, but I can foresee a scenario where it would be
useful. It doesn't present much in the way of maintenance so I think
we should keep it.

Ivan

Re: MDC, NDC (was: Re: Restarting development)

Posted by Christian Grobmeier <gr...@gmail.com>.
On 1 Dec 2013, at 17:25, Ivan Habunek wrote:

> Cool. Be sure to work on the docs branch, docs folder. The Sphinx
> docs. Not the old xdoc web site. Keep in mind those docs are for
> 2.3.1, not 3.0.
>
> I will merge it into v3 branch after releasing 2.3.1. to prevent
> duplicate effort.
>
> Is that ok for you?

Yes, thanks a lot!

>
> Regards,
> Ivan
>
> On 1 December 2013 17:20, Christian Grobmeier <gr...@gmail.com> 
> wrote:
>> On 1 Dec 2013, at 11:37, Ivan Habunek wrote:
>>
>>> On 1 December 2013 11:23, Christian Grobmeier <gr...@gmail.com> 
>>> wrote:
>>>>
>>>> In Log4j2 we have not kept it because we lack of such a scenario. 
>>>> In
>>>> addition people
>>>> seem to be confused over NDC. Curious about your ideas here (also 
>>>> useful
>>>> for
>>>> docs, in case we keep it).
>>>
>>>
>>> Consider a scenario where you have a layered application. Imagine 
>>> your
>>> request has to go through a series of layers (like a protocol stack,
>>> for example). You can make each layer add an entry to the NDC. Then
>>> when something is logged, you could know exactly where you are in 
>>> the
>>> stack, and what the components in the stack are. When leaving a 
>>> layer,
>>> you just pop() the entry you added on arrival.
>>
>>
>> Basically you could do that with MDC as well (pushing an object 
>> instead of a
>> primitive value).
>> But I see your point. Let's leave it in for now, I am going to work 
>> through
>> some docs.
>>
>>
>> Cheers
>>
>>>
>>> Ivan
>>
>>
>>
>> ---
>> http://www.grobmeier.de
>> @grobmeier
>> GPG: 0xA5CC90DB


---
http://www.grobmeier.de
@grobmeier
GPG: 0xA5CC90DB

Re: MDC, NDC (was: Re: Restarting development)

Posted by Ivan Habunek <iv...@gmail.com>.
Cool. Be sure to work on the docs branch, docs folder. The Sphinx
docs. Not the old xdoc web site. Keep in mind those docs are for
2.3.1, not 3.0.

I will merge it into v3 branch after releasing 2.3.1. to prevent
duplicate effort.

Is that ok for you?

Regards,
Ivan

On 1 December 2013 17:20, Christian Grobmeier <gr...@gmail.com> wrote:
> On 1 Dec 2013, at 11:37, Ivan Habunek wrote:
>
>> On 1 December 2013 11:23, Christian Grobmeier <gr...@gmail.com> wrote:
>>>
>>> In Log4j2 we have not kept it because we lack of such a scenario. In
>>> addition people
>>> seem to be confused over NDC. Curious about your ideas here (also useful
>>> for
>>> docs, in case we keep it).
>>
>>
>> Consider a scenario where you have a layered application. Imagine your
>> request has to go through a series of layers (like a protocol stack,
>> for example). You can make each layer add an entry to the NDC. Then
>> when something is logged, you could know exactly where you are in the
>> stack, and what the components in the stack are. When leaving a layer,
>> you just pop() the entry you added on arrival.
>
>
> Basically you could do that with MDC as well (pushing an object instead of a
> primitive value).
> But I see your point. Let's leave it in for now, I am going to work through
> some docs.
>
>
> Cheers
>
>>
>> Ivan
>
>
>
> ---
> http://www.grobmeier.de
> @grobmeier
> GPG: 0xA5CC90DB

Re: MDC, NDC (was: Re: Restarting development)

Posted by Christian Grobmeier <gr...@gmail.com>.
On 1 Dec 2013, at 11:37, Ivan Habunek wrote:

> On 1 December 2013 11:23, Christian Grobmeier <gr...@gmail.com> 
> wrote:
>> In Log4j2 we have not kept it because we lack of such a scenario. In
>> addition people
>> seem to be confused over NDC. Curious about your ideas here (also 
>> useful for
>> docs, in case we keep it).
>
> Consider a scenario where you have a layered application. Imagine your
> request has to go through a series of layers (like a protocol stack,
> for example). You can make each layer add an entry to the NDC. Then
> when something is logged, you could know exactly where you are in the
> stack, and what the components in the stack are. When leaving a layer,
> you just pop() the entry you added on arrival.

Basically you could do that with MDC as well (pushing an object instead 
of a primitive value).
But I see your point. Let's leave it in for now, I am going to work 
through some docs.

Cheers

>
> Ivan


---
http://www.grobmeier.de
@grobmeier
GPG: 0xA5CC90DB

Re: MDC, NDC (was: Re: Restarting development)

Posted by Ivan Habunek <iv...@gmail.com>.
On 1 December 2013 11:23, Christian Grobmeier <gr...@gmail.com> wrote:
> In Log4j2 we have not kept it because we lack of such a scenario. In
> addition people
> seem to be confused over NDC. Curious about your ideas here (also useful for
> docs, in case we keep it).

Consider a scenario where you have a layered application. Imagine your
request has to go through a series of layers (like a protocol stack,
for example). You can make each layer add an entry to the NDC. Then
when something is logged, you could know exactly where you are in the
stack, and what the components in the stack are. When leaving a layer,
you just pop() the entry you added on arrival.

Ivan

Re: MDC, NDC (was: Re: Restarting development)

Posted by Christian Grobmeier <gr...@gmail.com>.
On 1 Dec 2013, at 9:42, Ivan Habunek wrote:

> On 30 November 2013 21:23, Christian Grobmeier <gr...@gmail.com> 
> wrote:
>>> We actually have MDC and NDC.
>>>
>> Thanks. I know remember that I put some work in these classes before 
>> ages.
>>
>> In this case I am caring about the docs.
>>
>> However I never found much sense in the NDC. Any objections to remove 
>> NDC?
>
> I never used it, but I can foresee a scenario where it would be
> useful.

In Log4j2 we have not kept it because we lack of such a scenario. In 
addition people
seem to be confused over NDC. Curious about your ideas here (also useful 
for docs, in case we keep it).

> It doesn't present much in the way of maintenance so I think
> we should keep it.

On the other hand it's always a bit risky to have code in the base which 
is either not used
or really cared about

Cheers

>
> Ivan


---
http://www.grobmeier.de
@grobmeier
GPG: 0xA5CC90DB