[PATCH] Reduce logging in dbpool_mysql.c

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[PATCH] Reduce logging in dbpool_mysql.c

Donald Jackson-6
Hi there,

This is a simple patch to reduce excessive logging output of dbpool_mysql.c

As we know many people run their Kannel systems with debug logging enabled so running with '-v 1' isn't a solution to this problem and I see no benefit of having this repetitive logging.

Thanks,
Donald

dbpool_mysql_reduce_logging.patch (960 bytes) Download Attachment
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: [PATCH] Reduce logging in dbpool_mysql.c

Rene Kluwen

I don’t agree completely with your reasoning.

Either you want debug information or you don’t.

Enabling debug information yields a lot of information.

What about if you want to debug the mysql pool usage?

 

Still +0 from me in case it’s redundant info.

 

Van: devel [mailto:[hidden email]] Namens Donald Jackson
Verzonden: zaterdag 24 september 2016 12:03
Aan: kannel_dev_mailinglist <[hidden email]>
Onderwerp: [PATCH] Reduce logging in dbpool_mysql.c

 

Hi there,

 

This is a simple patch to reduce excessive logging output of dbpool_mysql.c

 

As we know many people run their Kannel systems with debug logging enabled so running with '-v 1' isn't a solution to this problem and I see no benefit of having this repetitive logging.

 

Thanks,

Donald

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [PATCH] Reduce logging in dbpool_mysql.c

Donald Jackson-6
I'm on your side but many Kannel users run in debug log level, and this particular information is the same every time - it doesn't change from request to request. It's a non essential patch just 'nice to have' for most.

On Saturday, 24 September 2016, Rene Kluwen <[hidden email]> wrote:

I don’t agree completely with your reasoning.

Either you want debug information or you don’t.

Enabling debug information yields a lot of information.

What about if you want to debug the mysql pool usage?

 

Still +0 from me in case it’s redundant info.

 

Van: devel [mailto:<a href="javascript:_e(%7B%7D,&#39;cvml&#39;,&#39;devel-bounces@kannel.org&#39;);" target="_blank">devel-bounces@kannel.org] Namens Donald Jackson
Verzonden: zaterdag 24 september 2016 12:03
Aan: kannel_dev_mailinglist <<a href="javascript:_e(%7B%7D,&#39;cvml&#39;,&#39;devel@kannel.org&#39;);" target="_blank">devel@...>
Onderwerp: [PATCH] Reduce logging in dbpool_mysql.c

 

Hi there,

 

This is a simple patch to reduce excessive logging output of dbpool_mysql.c

 

As we know many people run their Kannel systems with debug logging enabled so running with '-v 1' isn't a solution to this problem and I see no benefit of having this repetitive logging.

 

Thanks,

Donald



--
Donald Jackson
http://www.elite-sms-software.com
http://www.ddj.co.za
http://www.thearchitech.com
donald(a)thearchitech.com
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [PATCH] Reduce logging in dbpool_mysql.c

Stipe Tolj-2
In reply to this post by Rene Kluwen
Am 24.09.2016 13:57, schrieb Rene Kluwen:
> I don’t agree completely with your reasoning.
>
> Either you want debug information or you don’t.
>
> Enabling debug information yields a lot of information.
>
> What about if you want to debug the mysql pool usage?
>
> Still +0 from me in case it’s redundant info.

both points are viable. I know what Donald means here. He wants DEBUG
level, but not cluttered with "too much deep" info.

I would suggest wrapping the debug() line into a #ifdef DO_DEBUG which
CAN be defined in the header section of the source file itself. So
people CAN easily add it as extra DEBUG level information, but we
wouldn't see it in the "normal" DEBUG way.

--
Best Regards,
Stipe Tolj

-------------------------------------------------------------------
Düsseldorf, NRW, Germany

Kannel Foundation                 tolj.org system architecture
http://www.kannel.org/            http://www.tolj.org/

stolj at kannel.org               st at tolj.org
-------------------------------------------------------------------

Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

RE: [PATCH] Reduce logging in dbpool_mysql.c

amalysh
Hi,

definitely -1 for #ifdef. 
And I agree with Rene here, debug is debug and if you don't like it => don't enable it.
Kannel has enough infos what's going on even without debug enabled and if users
enable debug they don't have to complain about too much information.

Thanks,
Alexander Malysh
 

From: [hidden email]
Sent: Monday, September 26, 2016 07:35 PM
To:
Cc: [hidden email]
Subject: Re: [PATCH] Reduce logging in dbpool_mysql.c
Am 24.09.2016 13:57, schrieb Rene Kluwen:
> I don’t agree completely with your reasoning.
>
> Either you want debug information or you don’t.
>
> Enabling debug information yields a lot of information.
>
> What about if you want to debug the mysql pool usage?
>
> Still +0 from me in case it’s redundant info.

both points are viable. I know what Donald means here. He wants DEBUG
level, but not cluttered with "too much deep" info.

I would suggest wrapping the debug() line into a #ifdef DO_DEBUG which
CAN be defined in the header section of the source file itself. So
people CAN easily add it as extra DEBUG level information, but we
wouldn't see it in the "normal" DEBUG way.

--
Best Regards,
Stipe Tolj

-------------------------------------------------------------------
Düsseldorf, NRW, Germany

Kannel Foundation tolj.org system architecture
http://www.kannel.org/ http://www.tolj.org/

stolj at kannel.org st at tolj.org
-------------------------------------------------------------------
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [PATCH] Reduce logging in dbpool_mysql.c

Donald Jackson-4
Patch withdrawn :)

On 18 October 2016 at 13:24, Alexander Malysh <[hidden email]> wrote:
Hi,

definitely -1 for #ifdef. 
And I agree with Rene here, debug is debug and if you don't like it => don't enable it.
Kannel has enough infos what's going on even without debug enabled and if users
enable debug they don't have to complain about too much information.

Thanks,
Alexander Malysh
 

From: [hidden email]
Sent: Monday, September 26, 2016 07:35 PM
To:
Cc: [hidden email]
Subject: Re: [PATCH] Reduce logging in dbpool_mysql.c
Am 24.09.2016 13:57, schrieb Rene Kluwen:
> I don’t agree completely with your reasoning.
>
> Either you want debug information or you don’t.
>
> Enabling debug information yields a lot of information.
>
> What about if you want to debug the mysql pool usage?
>
> Still +0 from me in case it’s redundant info.

both points are viable. I know what Donald means here. He wants DEBUG
level, but not cluttered with "too much deep" info.

I would suggest wrapping the debug() line into a #ifdef DO_DEBUG which
CAN be defined in the header section of the source file itself. So
people CAN easily add it as extra DEBUG level information, but we
wouldn't see it in the "normal" DEBUG way.

--
Best Regards,
Stipe Tolj

-------------------------------------------------------------------
Düsseldorf, NRW, Germany

Kannel Foundation tolj.org system architecture
http://www.kannel.org/ http://www.tolj.org/

stolj at kannel.org st at tolj.org
-------------------------------------------------------------------



--
Donald Jackson
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [PATCH] Reduce logging in dbpool_mysql.c

amalysh
:-)

Am 18.10.2016 um 22:38 schrieb Donald Jackson <[hidden email]>:

Patch withdrawn :)

On 18 October 2016 at 13:24, Alexander Malysh <[hidden email]> wrote:
Hi,

definitely -1 for #ifdef. 
And I agree with Rene here, debug is debug and if you don't like it => don't enable it.
Kannel has enough infos what's going on even without debug enabled and if users
enable debug they don't have to complain about too much information.

Thanks,
Alexander Malysh
 

From: [hidden email]
Sent: Monday, September 26, 2016 07:35 PM
To:
Cc: [hidden email]
Subject: Re: [PATCH] Reduce logging in dbpool_mysql.c
Am 24.09.2016 13:57, schrieb Rene Kluwen:
> I don’t agree completely with your reasoning.
>
> Either you want debug information or you don’t.
>
> Enabling debug information yields a lot of information.
>
> What about if you want to debug the mysql pool usage?
>
> Still +0 from me in case it’s redundant info.

both points are viable. I know what Donald means here. He wants DEBUG
level, but not cluttered with "too much deep" info.

I would suggest wrapping the debug() line into a #ifdef DO_DEBUG which
CAN be defined in the header section of the source file itself. So
people CAN easily add it as extra DEBUG level information, but we
wouldn't see it in the "normal" DEBUG way.

--
Best Regards,
Stipe Tolj

-------------------------------------------------------------------
Düsseldorf, NRW, Germany

Kannel Foundation tolj.org system architecture
http://www.kannel.org/ http://www.tolj.org/

stolj at kannel.org st at tolj.org
-------------------------------------------------------------------



--
Donald Jackson

Loading...