#41190 [Opn]: Two proposed patches for sybase_ct module

From: Date: Mon, 30 Apr 2007 14:58:20 +0000
Subject: #41190 [Opn]: Two proposed patches for sybase_ct module
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-112107@lists.php.net to get a copy of this message
 ID:               41190
 User updated by:  nick at marden dot org
 Reported By:      nick at marden dot org
 Status:           Open
 Bug Type:         Feature/Change Request
 Operating System: Linux
 PHP Version:      5.2.1
 Assigned To:      thekid
 New Comment:

The point of the second patch (specifically the {HOSTNAME} part) isn't
to be a substitute for a gethostname() function - although it would be
nice to have one.

The point is to have the sybct.hostname default to the local hostname
*without any user intervention*, something that is not currently the
case.

The reason I added the {HOSTNAME} support is that in our production
environment we often have multiple servers running PHP and it's nice to
know which one is connecting to Sybase in the case of long-running
queries, etc. So by putting

{HOSTNAME}-serverA

or

{HOSTNAME}-serverB

I give myself a shorthand to determine which process is causing trouble
on the Sybase database.


Previous Comments:
------------------------------------------------------------------------

[2007-04-30 06:56:59] thekid@php.net

Assigning to myself, I like the first patch but am not sure about the
second - I'd rather like to see a gethostname() function in PHP with
which one could accomplish this in userland.

------------------------------------------------------------------------

[2007-04-25 20:11:45] nick at marden dot org

Description:
------------
I have two patches that I would like to propose for the PHP5 Sybase-CT
module.

The first adds the (very useful) functions sybase_output_params() and
sybase_return_status() functions. The patch is here:

http://www.marden.org/php-sybase-ct/php5-sybase_ct.return_status-and-output_params.patch

and the documentation is here:

http://www.marden.org/php-sybase-ct/return_status-and-output_params.txt

The second patch corrects (IMO) the behavior of sybct.hostname to
default to the hostname of the current system. It also supports
{HOSTNAME} as a substitution variable in the sybct.hostname parameter, a
feature that I have found useful in our server farm. The patch is here:

http://www.marden.org/php-sybase-ct/php-sybase_ct.hostname.patch





------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=41190&edit=1


Thread (14 messages)

« previous php.bugs (#112107) next »