Re: [HACKERS] Dtrace probes documentation

2009-06-01 Thread Frank Ch. Eigler
Tom Lane  writes:

> [...]
>> See http://blog.endpoint.com/2009/05/postgresql-with-systemtap.html for
>> details. Perhaps it's worth noting in the documentation that SystemTap users
>> will need to use the double-underscore version?
>
> I think a better solution is to persuade the Systemtap guys that they
> ought to accept the single-hyphen spelling.  [...]

Will do: http://sourceware.org/PR10225.

- FChE

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers


Re: [HACKERS] Dtrace probes documentation

2009-05-31 Thread Tom Lane
Joshua Tolley  writes:
> On Thu, May 28, 2009 at 06:28:14PM -0400, Tom Lane wrote:
>> Read 26.4.3 and .4.  I don't know why they have this bizarre set of
>> conventions, but the single-hyphen version is the spelling
>> most visible to end users.

> I thought it might be something like that. I've been playing with SystemTap,
> and found that only the double-underscore version works for ... well, 
> anything.
> See http://blog.endpoint.com/2009/05/postgresql-with-systemtap.html for
> details. Perhaps it's worth noting in the documentation that SystemTap users
> will need to use the double-underscore version?

I think a better solution is to persuade the Systemtap guys that they
ought to accept the single-hyphen spelling.  I've put in a request for
that, we'll see what they think ...

regards, tom lane

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers


Re: [HACKERS] Dtrace probes documentation

2009-05-28 Thread Joshua Tolley
On Thu, May 28, 2009 at 06:28:14PM -0400, Tom Lane wrote:
> Joshua Tolley  writes:
> > The dtrace probes documentation [1] spells each probe name with dashes
> > ("transaction-start", "transaction-commit", etc.). Yet as far as I can see,
> > dtrace only works if you spell the probe names with double underscores
> > ("transaction__start", "transaction__commit", etc.). Why the discrepancy?
> 
> Read 26.4.3 and .4.  I don't know why they have this bizarre set of
> conventions, but the single-hyphen version is the spelling
> most visible to end users.

I thought it might be something like that. I've been playing with SystemTap,
and found that only the double-underscore version works for ... well, anything.
See http://blog.endpoint.com/2009/05/postgresql-with-systemtap.html for
details. Perhaps it's worth noting in the documentation that SystemTap users
will need to use the double-underscore version?

- Josh / eggyknap


signature.asc
Description: Digital signature


Re: [HACKERS] Dtrace probes documentation

2009-05-28 Thread Tom Lane
Joshua Tolley  writes:
> The dtrace probes documentation [1] spells each probe name with dashes
> ("transaction-start", "transaction-commit", etc.). Yet as far as I can see,
> dtrace only works if you spell the probe names with double underscores
> ("transaction__start", "transaction__commit", etc.). Why the discrepancy?

Read 26.4.3 and .4.  I don't know why they have this bizarre set of
conventions, but the single-hyphen version is the spelling
most visible to end users.

regards, tom lane

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers


[HACKERS] Dtrace probes documentation

2009-05-28 Thread Joshua Tolley
The dtrace probes documentation [1] spells each probe name with dashes
("transaction-start", "transaction-commit", etc.). Yet as far as I can see,
dtrace only works if you spell the probe names with double underscores
("transaction__start", "transaction__commit", etc.). Why the discrepancy?
Obvious patch attached, in case this needs to be changed.

- Josh / eggyknap

1: http://www.postgresql.org/docs/8.4/static/dynamic-trace.html

diff --git a/doc/src/sgml/monitoring.sgml b/doc/src/sgml/monitoring.sgml
index ea8b017..672a1fe 100644
--- a/doc/src/sgml/monitoring.sgml
+++ b/doc/src/sgml/monitoring.sgml
@@ -1070,95 +1070,95 @@ SELECT pg_stat_get_backend_pid(s.backendid) AS procpid,

 
 
- transaction-start
+ transaction__start
  (LocalTransactionId)
  Probe that fires at the start of a new transaction.
   arg0 is the transaction id.
 
 
- transaction-commit
+ transaction__commit
  (LocalTransactionId)
  Probe that fires when a transaction completes successfully.
   arg0 is the transaction id.
 
 
- transaction-abort
+ transaction__abort
  (LocalTransactionId)
  Probe that fires when a transaction completes unsuccessfully.
   arg0 is the transaction id.
 
 
- query-start
+ query__start
  (const char *)
  Probe that fires when the processing of a query is started.
   arg0 is the query string.
 
 
- query-done
+ query__done
  (const char *)
  Probe that fires when the processing of a query is complete.
   arg0 is the query string.
 
 
- query-parse-start
+ query__parse__start
  (const char *)
  Probe that fires when the parsing of a query is started.
   arg0 is the query string.
 
 
- query-parse-done
+ query__parse__done
  (const char *)
  Probe that fires when the parsing of a query is complete.
   arg0 is the query string.
 
 
- query-rewrite-start
+ query__rewrite__start
  (const char *)
  Probe that fires when the rewriting of a query is started.
   arg0 is the query string.
 
 
- query-rewrite-done
+ query__rewrite__done
  (const char *)
  Probe that fires when the rewriting of a query is complete.
   arg0 is the query string.
 
 
- query-plan-start
+ query__plan__start
  ()
  Probe that fires when the planning of a query is started.
 
 
- query-plan-done
+ query__plan__done
  ()
  Probe that fires when the planning of a query is complete.
 
 
- query-execute-start
+ query__execute__start
  ()
  Probe that fires when the execution of a query is started.
 
 
- query-execute-done
+ query__execute__done
  ()
  Probe that fires when the execution of a query is complete.
 
 
- statement-status
+ statement__status
  (const char *)
  Probe that fires anytime the server process updates its
   pg_stat_activity.current_query status.
   arg0 is the new status string.
 
 
- checkpoint-start
+ checkpoint__start
  (int)
  Probe that fires when a checkpoint is started.
   arg0 holds the bitwise flags used to distinguish different checkpoint
   types, such as shutdown, immediate or force.
 
 
- checkpoint-done
+ checkpoint__done
  (int, int, int, int, int)
  Probe that fires when a checkpoint is complete.
   (The probes listed next fire in sequence during checkpoint processing.)
@@ -1167,20 +1167,20 @@ SELECT pg_stat_get_backend_pid(s.backendid) AS procpid,
   removed and recycled respectively.
 
 
- clog-checkpoint-start
+ clog__checkpoint__start
  (bool)
  Probe that fires when the CLOG portion of a checkpoint is started.
   arg0 is true for normal checkpoint, false for shutdown
   checkpoint.
 
 
- clog-checkpoint-done
+ clog__checkpoint__done
  (bool)
  Probe that fires when the CLOG portion of a checkpoint is
-  complete. arg0 has the same meaning as for clog-checkpoint-start.
+  complete. arg0 has the same meaning as for 
clog__checkpoint__start.
 
 
- subtrans-checkpoint-start
+ subtrans__checkpoint__start
  (bool)
  Probe that fires when the SUBTRANS portion of a checkpoint is
   started.
@@ -1188,14 +1188,14 @@ SELECT pg_stat_get_backend_pid(s.backendid) AS procpid,
   checkpoint.
 
 
- subtrans-checkpoint-done
+ subtrans__checkpoint__done
  (bool)
  Probe that fires when the SUBTRANS portion of a checkpoint is
   complete. arg0 has the same meaning as for
-  subtrans-checkpoint-start.
+  subtrans__checkpoint__start.
 
 
- multixact-checkpoint-start
+ multixact__checkpoint__start
  (bool)
  Probe that fires when the MultiXact portion of a checkpoint is
   started.
@@ -1203,14 +1203,14 @@ SELECT pg_stat_get_backend_pid(s.