473,472 Members | 1,856 Online
Bytes | Software Development & Data Engineering Community
Create Post

Home Posts Topics Members FAQ

Log Clutter


Incidentally, am I the only one that finds the new 7.4 log messages too
cluttered? In 7.3 my application printed progress messages using "raise
notice" like this:

2004-08-20 11:58:16 [4369] NOTICE: Processing 6561 1/15127...
2004-08-20 11:58:19 [4369] NOTICE: Processing 6561 1/15127...Done Found 3800
2004-08-20 11:58:19 [4369] NOTICE: Processing 6794 2/15127...
2004-08-20 11:58:20 [4369] NOTICE: Processing 6794 2/15127...Done Found 4000
2004-08-20 11:58:20 [4369] NOTICE: Processing 10045 3/15127...
2004-08-20 11:58:20 [4369] NOTICE: Processing 10045 3/15127...Done Found 0
2004-08-20 11:58:20 [4369] NOTICE: Processing 12325 4/15127...
2004-08-20 11:58:20 [4369] NOTICE: Processing 12325 4/15127...Done Found 0
2004-08-20 11:58:20 [4369] NOTICE: Processing 14957 5/15127...
2004-08-20 11:58:20 [4369] NOTICE: Processing 14957 5/15127...Done Found 0

In 7.4 it helpfully tells me what function and line number is executing, but
since it's always the same it's pretty useless:

2004-08-20 11:58:16 [4369] NOTICE: Processing 6561 1/15127...
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:19 [4369] NOTICE: Processing 6561 1/15127...Done Found 3800
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:19 [4369] NOTICE: Processing 6794 2/15127...
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:20 [4369] NOTICE: Processing 6794 2/15127...Done Found 4000
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:20 [4369] NOTICE: Processing 10045 3/15127...
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:20 [4369] NOTICE: Processing 10045 3/15127...Done Found 0
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:20 [4369] NOTICE: Processing 12325 4/15127...
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:20 [4369] NOTICE: Processing 12325 4/15127...Done Found 0
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:20 [4369] NOTICE: Processing 14957 5/15127...
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();
2004-08-20 11:58:20 [4369] NOTICE: Processing 14957 5/15127...Done Found 0
CONTEXT: PL/pgSQL function "process_regions" line 2 at return
STATEMENT: select process_regions();

It also seems to print these after almost every query I have. That's because I
use SQL functions lang_en()/lang_fr() to handle l10n. It also seems too
chatty.

2004-08-18 21:25:50 [16741] LOG: statement: select $1 [1]
CONTEXT: SQL function "lang_en" during inlining
2004-08-18 21:25:50 [16741] LOG: statement: select $1 [1]
CONTEXT: SQL function "lang_en" during inlining
2004-08-18 21:25:50 [16741] LOG: statement: select $1 [1]
CONTEXT: SQL function "lang_en" during inlining
2004-08-18 21:25:50 [16741] LOG: statement: select $1 [1]
CONTEXT: SQL function "lang_en" during inlining
2004-08-18 21:25:50 [16741] LOG: statement: select $1 [1]
CONTEXT: SQL function "lang_en" during inlining
2004-08-18 21:25:50 [16741] LOG: statement: select $1 [1]
CONTEXT: SQL function "lang_en" during inlining
2004-08-18 21:25:50 [16741] LOG: statement: select $1 [1]
CONTEXT: SQL function "lang_en" during inlining

As far as I can see there's no way to disable either of these two cases
without disabling a lot more messages along with them. It would be nice...

--
greg
---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to ma*******@postgresql.org

Nov 23 '05 #1
2 1110
Greg Stark <gs*****@mit.edu> writes:
Incidentally, am I the only one that finds the new 7.4 log messages too
cluttered? In 7.3 my application printed progress messages using "raise
notice" like this:


We could have RAISE suppress all context. (I think at the moment it only
suppresses the first level of context, which is probably a compromise
that doesn't satisfy anybody.) I'd be inclined to do that only for the
non-error forms of RAISE, though.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 2: you can get off all lists at once with the unregister command
(send "unregister YourEmailAddressHere" to ma*******@postgresql.org)

Nov 23 '05 #2
On Fri, Aug 20, 2004 at 12:08:45PM -0400, Greg Stark wrote:

Incidentally, am I the only one that finds the new 7.4 log messages too
cluttered? In 7.3 my application printed progress messages using "raise
notice" like this:


You could execute a SET LOCAL log_error_verbosity within the function to
decrease the verbosity ... the problem is that only a superuser can do
that, but maybe using a SECURITY DEFINER function to do it for you
helps.

--
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"Endurecerse, pero jamás perder la ternura" (E. Guevara)
---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faqs/FAQ.html

Nov 23 '05 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

7
by: Peter Salzman | last post by:
Hi all, Newish PHP programmer here. I wrote a form select class to help reduce code clutter, but I don't think the effort was worth it. I was hoping to post my attempt and get some ideas from...
28
by: David MacQuigg | last post by:
I'm concerned that with all the focus on obj$func binding, &closures, and other not-so-pretty details of Prothon, that we are missing what is really good - the simplification of classes. There are...
14
by: David MacQuigg | last post by:
I am starting a new thread so we can avoid some of the non-productive argument following my earlier post "What is good about Prothon". At Mr. Hahn's request, I will avoid using the name "Prothon"...
15
by: Ralf W. Grosse-Kunstleve | last post by:
****************************************************************************** This posting is also available in HTML format: http://cci.lbl.gov/~rwgk/python/adopt_init_args_2005_07_02.html...
1
by: Marty McDonald | last post by:
Many of an app's classes could read the config file. The config file could contain many elements, and it will be difficult to know which config file entry belongs to which class. I could adopt a...
16
by: Peter Maas | last post by:
The XHTML file below creates a 2x2 matrix of square images. There is always some space at the bottom borders of the cells (when rendered with Gecko and KHTML, not with IE) and I've found no way so...
75
by: Greg McIntyre | last post by:
I have a Python snippet: f = open("blah.txt", "r") while True: c = f.read(1) if c == '': break # EOF # ... work on c Is some way to make this code more compact and simple? It's a bit...
148
by: onkar | last post by:
Given the following code & variable i . int main(int argc,char **argv){ int i; printf("%d\n",i); return 0; } here i is allocated from bss or stack ?
13
by: Skybuck Flying | last post by:
Hello, Why does C++ use :: for members/methods why not just : ? For example: long Test::TimesOne() const { return mVal; } Alternative:
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
1
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...
0
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each...
1
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome a new...
0
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and...
0
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated ...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.