Re: IPC Open / IPC Run

2003-07-18 Thread Barrie Slaymaker
On Fri, Jul 18, 2003 at 12:30:22PM -0500, Cameron B. Prince wrote: I just realized, I meant to say IPC::Run below from my previous post. I also read a post about IPC::Open... I looked at the synopsis and it looks rather complicated. Only if you're trying to do something complicated, like

Re: IPC::Run

2003-07-18 Thread Barrie Slaymaker
On Fri, Jul 18, 2003 at 01:18:12PM -0500, Cameron B. Prince wrote: Hi Barrie, I dug out an old note from you and started trying IPC::Run. Here's what I have so far: sub MP3Check { my ($self,$params) = @_; use IPC::Run qw( run timeout ); my @command = (

Re: [ANNOUNCE] StateMachine::Gestinanna 0.01

2002-08-01 Thread Barrie Slaymaker
On Wed, Jul 31, 2002 at 09:08:54PM -0500, James G Smith wrote: My apologies. np :). It's fun to prattle on about my babies ;). The StateML:: stuff does sound neat though :) I'm wanting to eventually put together a gui for creating web-based wizard-like applications -- draw the circles

Re: [ANNOUNCE] StateMachine::Gestinanna 0.01

2002-07-31 Thread Barrie Slaymaker
On Wed, Jul 31, 2002 at 07:25:48PM -0500, James G Smith wrote: XML::SAX::Machines This is an XML SAX processing framework, nothing to do with state machines I'm afraid. I do have another distribution (not on CPAN, let me know if you want a copy) in the StateML:: namespace that takes an XML

Re: Here is my backtrace, please solove my problem

2001-11-10 Thread Barrie Slaymaker
On Sat, Nov 10, 2001 at 12:10:03PM -0800, SubbaReddy M wrote: /soft/Apache-ASP-2.27/make_httpd/mod_perl-1.26/core: No such file or directory. You need a core file to do this... gdb is kindly pointing out that you don't have one. and i am really thankfull for your help. I'm just

Cache::* and MD5 collisions [was: [OT] Data store options]

2001-11-08 Thread Barrie Slaymaker
On Thu, Nov 08, 2001 at 08:59:55AM -0800, Bill Moseley wrote: Hi, verbose I'm looking for a little discussion on selecting a data storage method, and I'm posting here because Cache::Cache often is discussed here (along with Apache::Session). And people here are smart, of course ;).

Re: Cache::* and MD5 collisions [was: [OT] Data store options]

2001-11-08 Thread Barrie Slaymaker
On Thu, Nov 08, 2001 at 10:54:11AM -0800, Andrew Ho wrote: Let me point out that if you are using MD5 hashes for directory spreading (i.e. to spread a large number of files across a tree of directories so that no one directory is filled with too many files for efficient filesystem access),

Sanity check: statically linking binary extensions like GD in to httpd

2001-10-25 Thread Barrie Slaymaker
I'm seeking a sanity check on statically linked binary extensions in with httpd. I've built what I want, but the build is not easily automatable, and I'm hoping I missed an easy alternative somewhere. Background: we have a .png that we want to generate on the fly with up to several thousand

Re: memory leaking with closures

2001-09-07 Thread Barrie Slaymaker
On Fri, Sep 07, 2001 at 12:27:58AM -0700, Alex Krohn wrote: while (1) { { my $var = 'x' x 50; my $sub = sub { my $sub2 = sub { $var; } }; } # $var and $sub should be gone, but memory is never freed sleep 1; # Don't crash things =) }

Re: modperl 2.0

2001-08-16 Thread Barrie Slaymaker
Thank you, much better. I can't make out the difference between the two command lines (again, I ask you to please clean up your script output, or just copy and paste from your terminal to your mailer, those ^Hs and ^]s make things hard to decipher). Can you do a type perl perl5.6.0 perl5.6.1,

Re: modperl 2.0

2001-08-12 Thread Barrie Slaymaker
On Sun, Aug 12, 2001 at 03:46:24PM -0600, The Doctor wrote: This is not going well with me as this forces to stay at perl 5.00503 until BSD/OS comes up with the new perl distrubution. Again, I don't follow. What leads you to that conclusion? - Barrie

Re: modperl 2.0

2001-08-12 Thread Barrie Slaymaker
On Sun, Aug 12, 2001 at 03:47:09PM -0600, The Doctor wrote: perl 5.6.1 calling itself perl 5.6.0 Come off of it! I don't know where you got that idea.

Re: modperl 2.0

2001-08-12 Thread Barrie Slaymaker
On Sun, Aug 12, 2001 at 03:55:26PM -0600, The Doctor wrote: When I ran perl 5.6.1 it was identifying itself as perl 5.6.0 . Identity crisis?? Dunno, but you can bet it's not right. Care to post the command and results? Sounds like a symlink problem, you might want to use some combination

Re: Poor man's connection pooling

2000-09-06 Thread Barrie Slaymaker
Michael Peppler wrote: Based on preliminary tests I was able to use a 1 in 10 ratio of database handles per httpd child processes, which, on a large site would cut down on the number of connections that the database server needs to handle. I'd be interested to see how this compares with

Re: Poor man's connection pooling

2000-09-06 Thread Barrie Slaymaker
Michael Peppler wrote: The back-end is Sybase. The actual connect time isn't the issue here (for me.) It's the sheer number of connections, and the potential issue with the number of sockets in CLOSE_WAIT or TIME_WAIT state on the database server. We're looking at a farm of 40 front-end

Re: [OT] DNS question (slightly mod_perl related...)

2000-08-31 Thread Barrie Slaymaker
Matt Sergeant wrote: Yes, I believe the entry is simply *.domain.com! Then use mod_rewrite to map the right folder. Yup. Beware though, there are certain issues you may need to think of if you're going to be sending/receiving mail from these domain names. One problem is the reverse name

Apache::Reload problems

2000-08-29 Thread Barrie Slaymaker
Passing this along from the mason list. Original Message Subject: [OT]Apache::Reload (was Re: [Mason]More "At The Forge" articles) Date: 29 Aug 2000 10:59:35 +0400 From: [EMAIL PROTECTED] (Alexei V. Barantsev) To: [EMAIL PROTECTED] References: [EMAIL PROTECTED] Dave Rolsky

Re: using modules written in C?

2000-08-17 Thread Barrie Slaymaker
Mikael Claesson wrote: with mod_perl it looks even better. Cool. Welcome. I plan to keep all lowerlevel database stuff in C, and embed it in a perl module. Will this make things run slower than if I made it all in perl? Usually faster, but whether that's significant in your application

Re: [ANNOUNCE] Apache::Dispatch-0.03

2000-08-09 Thread Barrie Slaymaker
Roger Espel Llima wrote: @{"${class}::ISA"} Incidentally, does anyone know of a way to do this that works under strict? The above requires a "no strict 'refs'" to work. Something like this we3nt by on p5p a while ago (IIRCC): @{$main::{"$class\::"}-{ISA}} but that's a lot more

Improving cache coherency [Was: Idea of an apache module]

2000-07-12 Thread Barrie Slaymaker
aaron wrote: for example, in discussion software you have a very clear moment when you want to invalidate specific pages: when a message arrives. now i don't want squid or any other cache to even check w/ every request. i know darn well when the cache is no longer valid! I've been

Re: Forking off lengthy processes

2000-07-10 Thread Barrie Slaymaker
Jeremy Howard wrote: * fork(): Memory hog, since it copies the entire Apache process (is this right--does it share the memory for all the modules etc...?) Assuming you're on a modern Unixish system, it shouldn't be bad at all if you don't change too many variables and if the child doesn't

Re: File upload gateway (was Re: Forking off lengthy processes)

2000-07-10 Thread Barrie Slaymaker
I said: The most often wished-for approach is for a http cache to accept the whole request before passing it through to the main httpd, but I'm not aware of any that do that. Jeremy Howard wrote: How do proxy servers like Squid work? Squid, Apache in cache mode, et al, was what I

Re: Is variable initialization necessary?

2000-07-10 Thread Barrie Slaymaker
Drew Taylor wrote: Does anyone have good evidence either way? I don't see how Csub { my $foo ; ... could ever fail to undef $foo, modulo bugs in perl. A hell of a lot of code wouldn't work, then. My practice is to never init lexicals to undef/(), and only to '' or 0 if they might be used

Re: [RFC] Swapping Prevention

2000-06-20 Thread Barrie Slaymaker
A nit: the distinction between paging and swapping doesn't seem clear to me. You describe the paging process, then talk about how you should never swap. Or maybe that's too detailed for your intended audience. - Barrie

Re: IPC::Open2 v5.6.0 failures.

2000-06-17 Thread Barrie Slaymaker
[EMAIL PROTECTED] wrote: Is this a know bug? Is there a bug? Not that I know of, did you check the archives? Is it right in front of my face? Something seems odd to me, see below, but it shouldn't be causing you too much grief. First, to educate me, what's encrypt do differently than

Re: Logging response times

2000-06-14 Thread Barrie Slaymaker
Eric Jain wrote: I'm sure there is a better method, which also is able to log more detailed than just in seconds... Haven't used it under mod_perl, but Time::HiRes is available: http://search.cpan.org/search?mode=modulequery=Time%3A%3AHiRes - Barrie

Re: system

2000-06-08 Thread Barrie Slaymaker
"Reilly, Thomas" wrote: If any one can give me a few lines of code I would appreciate it. One way is: use IPC::Run qw( run close_terminal ) ; run( sub { # ... your code here ... sleep 15 ; }, init = sub { close_terminal ; exit if fork ;

Method overhead benchmarks [Was: [performance/benchmark] printing techniques]

2000-06-08 Thread Barrie Slaymaker
Stephen Zander wrote: As Matt has already commented, in the handler the method call overheads swamps all the other activities. Just to clarify: that's only important if you are doing very few other activities, or if those other activities also include a high percentage of method calls:

Re: [performance/benchmark] printing techniques

2000-06-08 Thread Barrie Slaymaker
[Sorry for the delay: didn't notice this since it was sent only to the list] Eric Cholet wrote, in part: I never advocated optimizing at the expense of the above criteria, we were discussing optimizations only. I certainly believe a program is a compromise, and have often chosen some of

Re: Method overhead benchmarks [Was: [performance/benchmark] printingtechniques]

2000-06-08 Thread Barrie Slaymaker
Matt Sergeant wrote: You also forgot that print() goes to a tied STDOUT, which is even more of an overhead... Yeah, that'd probably swamp almost all other effects Stas is testing right there, and it explains Stas's test results when varying $|. - Barrie

Re: [performance/benchmark] printing techniques

2000-06-07 Thread Barrie Slaymaker
Eric Cholet wrote: These things add up, so don't you think that whatever can be optimized, should ? Wrong question, IMHO: it's what you optimize for that counts. Several things come to mind that are often more important than performance and often mean not optimizing for performance (these