From jhannah at omnihotels.com Fri Nov 3 12:37:57 2006 From: jhannah at omnihotels.com (Jay Hannah) Date: Fri, 3 Nov 2006 14:37:57 -0600 Subject: [Omaha.pm] FW: DBD::Informix & $SIG{ALRM} & /etc/services Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B06F5D40D@exchange2k3.omnihotels.net> I sent this off to dbi-users today. :) j -----Original Message----- From: Jay Hannah Sent: Friday, November 03, 2006 2:37 PM To: 'dbi-users at perl.org' Cc: 'jonathan.leffler at gmail.com' Subject: DBD::Informix & $SIG{ALRM} & /etc/services Weird. My alarm(2) takes 14 seconds? Is DBD::Informix or something else overriding my $SIG{ALRM}? If I substitute the connect() call with a sleep 10, then my alarm(2) takes 2 seconds, as I expected. :) Thanks, j $ cat j.t use strict; use DBI; my $dbh; eval { local $SIG{ALRM} = sub { die "timeout\n" }; alarm(2); # seconds before time out $dbh = DBI->connect('dbi:Informix:omni at drprod_tcp'); alarm(0); # cancel alarm (if connect worked fast) }; alarm(0); # cancel alarm (if eval failed) chomp $@; print "[$@][$DBI::err][$DBI::errstr]\n"; $ time perl j.t [timeout][-931][SQL: -931: Cannot locate drprod_tcp service/tcp service in /etc/services.] real 0m14.320s user 0m0.319s sys 0m0.044s $ perl -MDBI -e 'DBI->installed_versions' Perl : 5.008004 (i686-linux) OS : linux (2.6.4-52-smp) DBI : 1.46 DBD::Sybase : 1.04 DBD::Sponge : 11.10 DBD::Proxy : install_driver(Proxy) failed: Can't locate RPC/PlClient.pm in @INC DBD::Informix : 2003.04 DBD::File : 0.31 DBD::ExampleP : 11.12 DBD::DBM : 0.02 From jhannah at omnihotels.com Fri Nov 3 12:52:39 2006 From: jhannah at omnihotels.com (Jay Hannah) Date: Fri, 3 Nov 2006 14:52:39 -0600 Subject: [Omaha.pm] FW: DBD::Informix & $SIG{ALRM} & /etc/services Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B06F5D45A@exchange2k3.omnihotels.net> Oops! Mildly embarassing, below. I guess I'm glad upgrading didn't fix it -- I would have felt pretty silly. j -----Original Message----- From: Jay Hannah Sent: Friday, November 03, 2006 2:52 PM To: dbi-users at perl.org Cc: jonathan.leffler at gmail.com Subject: RE: DBD::Informix & $SIG{ALRM} & /etc/services Oops. I noticed my versions were behind. I upgraded DBI and DBD::Informix. I'm still getting the same behavior (14.3 seconds to time out), so I'm still curious about what might be going on. Thanks, j $ perl -MDBI -e'DBI->installed_versions' Perl : 5.008004 (i686-linux) OS : linux (2.6.4-52-smp) DBI : 1.53 DBD::Sybase : 1.04 DBD::Sponge : 11.10 DBD::Proxy : install_driver(Proxy) failed: Can't locate RPC/PlClient.pm in @INC DBD::Informix : 2005.02 DBD::File : 0.35 DBD::ExampleP : 11.12 DBD::DBM : 0.03 From jhannah at omnihotels.com Fri Nov 3 13:03:44 2006 From: jhannah at omnihotels.com (Jay Hannah) Date: Fri, 3 Nov 2006 15:03:44 -0600 Subject: [Omaha.pm] FW: Test::Harness jacks PERL5LIB which jacks our SEED tests under your new dynamic t directory thing... Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B06F5D482@exchange2k3.omnihotels.net> Below, a pretty geeky thing I hit recently. I have no idea why Test::Harness messes with $PERL5LIB and then puts it back. Survey: Besides my coworkers and Andy, does anyone out there use Test::*? How many tests do you have? For software that does what? Anyone else use PERL5LIB? j -----Original Message----- From: Jay Hannah Sent: Friday, October 20, 2006 5:35 PM To: Sean Baker Cc: Trey Bianchini Subject: Test::Harness jacks PERL5LIB which jacks our SEED tests under your new dynamic t directory thing... Doh.......... jhannah at razorbill:~/M/Pegasus/Message> prove -r t/AALSRQ............................ok t/AALSRQ_seed_1A....................Cannot read '/usr/lib/perl5/site_perl/Omni/MVC:/usr/lib/perl5/5.8.7/i686-linux:/usr/ lib/perl5/5.8.7:/usr/lib/perl5/site_perl/5.8.7/i686-linux:/usr/lib/perl5 /site_perl/5.8.7:/usr/lib/perl5/site_perl:./Model/omares/Simple/smls_rat es_avail.unl'. [[[/usr/lib/perl5/site_perl/Omni/MVC:/usr/lib/perl5/5.8.7/i686-linux:/us r/lib/perl5/5.8.7:/usr/lib/perl5/site_perl/5.8.7/i686-linux:/usr/lib/per l5/site_perl/5.8.7:/usr/lib/perl5/site_perl:.]]] at /usr/lib/perl5/site_perl/Omni/MVC/Model/DB/Informix.pm line 891, line 1. jhannah at razorbill:~/M/Pegasus/Message> cat j.t die "[[[$ENV{PERL5LIB}]]]"; jhannah at razorbill:~/M/Pegasus/Message> prove -r j.t j....[[[/usr/lib/perl5/site_perl/Omni/MVC:/usr/lib/perl5/5.8.7/i686-linu x:/usr/lib/perl5/5.8.7:/usr/lib/perl5/site_perl/5.8.7/i686-linux:/usr/li b/perl5/site_perl/5.8.7:/usr/lib/perl5/site_perl:.]]] at j.t line 1. j....dubious Test returned status 255 (wstat 65280, 0xff00) FAILED--1 test script could be run, alas--no output ever seen push @DB::typeahead, "o pager=less", "f Test/Harness/Straps.pm", "b 284", j....Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harne ss/Straps.pm:284): 284: local $ENV{PERL5LIB} = $self->_INC2PERL5LIB; DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:285): 285: if ( $Test::Harness::Debug ) { DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:291): 291: my $line = $self->_command_line($file); DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:293): 293: unless ( open(FILE, "$line|" )) { DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:298): 298: my %results = $self->analyze_fh($file, \*FILE); DB<4> [[[/usr/lib/perl5/site_perl/Omni/MVC:/usr/lib/perl5/5.8.7/i686-linux:/us r/lib/perl5/5.8.7:/usr/lib/perl5/site_perl/5.8.7/i686-linux:/usr/lib/per l5/site_perl/5.8.7:/usr/lib/perl5/site_perl:.]]] at j.t line 1. n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:299): 299: my $exit = close FILE; DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:300): 300: $results{'wait'} = $?; DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:301): 301: if( $? && $self->{_is_vms} ) { DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:305): 305: $results{'exit'} = _wait2exit($?); DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:307): 307: $results{passing} = 0 unless $? == 0; DB<4> n Test::Harness::Straps::analyze_file(/usr/lib/perl5/5.8.7/Test/Harness/St raps.pm:309): 309: $self->_restore_PERL5LIB(); From andy at petdance.com Fri Nov 3 13:10:01 2006 From: andy at petdance.com (Andy Lester) Date: Fri, 3 Nov 2006 15:10:01 -0600 Subject: [Omaha.pm] FW: Test::Harness jacks PERL5LIB which jacks our SEED tests under your new dynamic t directory thing... In-Reply-To: <29AB736ABCE5C745ABF9C93B02F2C27B06F5D482@exchange2k3.omnihotels.net> References: <29AB736ABCE5C745ABF9C93B02F2C27B06F5D482@exchange2k3.omnihotels.net> Message-ID: <860EBD11-B6C1-40C9-AF40-6D081D022BAE@petdance.com> On Nov 3, 2006, at 3:03 PM, Jay Hannah wrote: > Below, a pretty geeky thing I hit recently. > > I have no idea why Test::Harness messes with $PERL5LIB and then > puts it > back. > > Survey: Besides my coworkers and Andy, does anyone out there use > Test::*? How many tests do you have? For software that does what? > Anyone > else use PERL5LIB? You know I maintain Test::Harness, right? :-) -- Andy Lester => andy at petdance.com => www.petdance.com => AIM:petdance From jay at jays.net Fri Nov 3 17:40:55 2006 From: jay at jays.net (Jay Hannah) Date: Fri, 03 Nov 2006 19:40:55 -0600 Subject: [Omaha.pm] FW: Test::Harness jacks PERL5LIB which jacks our SEED tests under your new dynamic t directory thing... In-Reply-To: <860EBD11-B6C1-40C9-AF40-6D081D022BAE@petdance.com> References: <29AB736ABCE5C745ABF9C93B02F2C27B06F5D482@exchange2k3.omnihotels.net> <860EBD11-B6C1-40C9-AF40-6D081D022BAE@petdance.com> Message-ID: <454BEFA7.3020200@jays.net> Andy Lester wrote: > On Nov 3, 2006, at 3:03 PM, Jay Hannah wrote: >> I have no idea why Test::Harness messes with $PERL5LIB and then >> puts it back. >> >> Survey: Besides my coworkers and Andy, does anyone out there use >> Test::*? How many tests do you have? For software that does what? >> Anyone else use PERL5LIB? > > You know I maintain Test::Harness, right? :-) I specifically said *besides Andy*. :) But if you want to tell me why Test::Harness messes with PERL5LIB I'm happy to listen. No biggie, we worked around it. I was just surprised, that's all. j From ajgrothe at yahoo.com Sat Nov 4 20:20:11 2006 From: ajgrothe at yahoo.com (Aaron Grothe) Date: Sat, 4 Nov 2006 20:20:11 -0800 (PST) Subject: [Omaha.pm] New Perl Project out at Sourceforge.net Message-ID: <20061105042011.99883.qmail@web34403.mail.mud.yahoo.com> Hey Mongers, I've just put the first public release of Vipaka up at Sourceforge. Vipaka is a tool to monitor Oracle Databases. Vipaka is based on a program called Karma written by Sean Hull several years ago. Vipaka is written in Perl with DBI/DBD for the database access layer. I've been maintaining my own private branch for the last couple of years, updating the links page, fixing problems with newer versions of Perl and the like. I think my private version has finally reached the point where it is ready to be released to the public. The project is out at http://vipka.sourceforge.net It works pretty well under GNU/Linux. I've still got some work to do to get it work 100% under Microsoft Windows, I might need to rework a bit of the daemon process handling. If anybody has any comments or suggestions please let me know. I'm currently thinking of redoing the html generation engine to use something more modern like Mason. Thanks, Aaron -=-=- "The Journey is the Reward" - Old Zen Buddhist Saying --------------------------------- Access over 1 million songs - Yahoo! Music Unlimited Try it today. -------------- next part -------------- An HTML attachment was scrubbed... URL: http://mail.pm.org/pipermail/omaha-pm/attachments/20061104/3762f9c7/attachment.html From jay at jays.net Sat Nov 4 23:39:19 2006 From: jay at jays.net (Jay Hannah) Date: Sun, 5 Nov 2006 01:39:19 -0600 Subject: [Omaha.pm] New Perl Project out at Sourceforge.net In-Reply-To: <20061105042011.99883.qmail@web34403.mail.mud.yahoo.com> References: <20061105042011.99883.qmail@web34403.mail.mud.yahoo.com> Message-ID: On Nov 4, 2006, at 10:20 PM, Aaron Grothe wrote: > The project is out at http://vipka.sourceforge.net (We mainly mess with Informix & mySQL, not Oracle.) Something is wrong with your site? j ------------- An error has been encountered in accessing this page. 1. Server: vipka.sourceforge.net 2. URL path: / 3. Error notes: File does not exist: /home/groups/v/vi/vipka/htdocs/ 4. Error type: 404 5. Request method: GET 6. Request query string: 7. Time: 2006-11-04 23:37:18 PST (1162712238) Reporting this problem: The problem you have encountered is with a project web site hosted by SourceForge.net. This issue should be reported to the SourceForge.net-hosted project (not to SourceForge.net). If this is a severe or recurring/persistent problem, please do one of the following, and provide the error text (numbered 1 through 7, above): 1. Contact the project via their designated support resources. 2. Contact the project administrators of this project via email (see the upper right-hand corner of the Project Summary page for their usernames) at user-name at users.sourceforge.net If you are a member of the project that maintains this web content, please refer to the Site Documentation regarding the project web service for further assistance. ----------- From durod at novia.net Sun Nov 5 00:07:38 2006 From: durod at novia.net (Paul Duran) Date: Sun, 05 Nov 2006 02:07:38 -0600 Subject: [Omaha.pm] New Perl Project out at Sourceforge.net In-Reply-To: References: <20061105042011.99883.qmail@web34403.mail.mud.yahoo.com> Message-ID: <1162714058.5492.6.camel@localhost.localdomain> I've written many a perl script against Sybase and MySQL. Some backup scripts using BRU and Oracle. I wouldn't mind seeing more threads using these platforms. On Sun, 2006-11-05 at 01:39 -0600, Jay Hannah wrote: > On Nov 4, 2006, at 10:20 PM, Aaron Grothe wrote: > > The project is out at http://vipka.sourceforge.net > > (We mainly mess with Informix & mySQL, not Oracle.) > > Something is wrong with your site? > > j > > ------------- > An error has been encountered in accessing this page. > > 1. Server: vipka.sourceforge.net > 2. URL path: / > 3. Error notes: File does not exist: /home/groups/v/vi/vipka/htdocs/ > 4. Error type: 404 > 5. Request method: GET > 6. Request query string: > 7. Time: 2006-11-04 23:37:18 PST (1162712238) > > Reporting this problem: The problem you have encountered is with a > project web site hosted by SourceForge.net. This issue should be > reported to the SourceForge.net-hosted project (not to SourceForge.net). > > If this is a severe or recurring/persistent problem, please do one of > the following, and provide the error text (numbered 1 through 7, above): > > 1. Contact the project via their designated support resources. > 2. Contact the project administrators of this project via email > (see the upper right-hand corner of the Project Summary page for > their usernames) at user-name at users.sourceforge.net > > If you are a member of the project that maintains this web content, > please refer to the Site Documentation regarding the project web > service for further assistance. > ----------- > > > > _______________________________________________ > Omaha-pm mailing list > Omaha-pm at pm.org > http://mail.pm.org/mailman/listinfo/omaha-pm > From jay at jays.net Sun Nov 5 05:54:38 2006 From: jay at jays.net (Jay Hannah) Date: Sun, 5 Nov 2006 07:54:38 -0600 Subject: [Omaha.pm] New Perl Project out at Sourceforge.net In-Reply-To: <1162714058.5492.6.camel@localhost.localdomain> References: <20061105042011.99883.qmail@web34403.mail.mud.yahoo.com> <1162714058.5492.6.camel@localhost.localdomain> Message-ID: On Nov 5, 2006, at 2:07 AM, Paul Duran wrote: > I've written many a perl script against Sybase and MySQL. Some backup > scripts using BRU and Oracle. I wouldn't mind seeing more threads > using > these platforms. we do: - DBD::Informix - DBD::mySQL - DBD::Sybase (for MS-SQL via freetds) - DBD::Proxy (for Oracle via DBD::Oracle installed in 1 location) We tried DBD::JDBC for talking to Oracle, but hit fetchrow_hashref() bugs so abandoned it. On Nov 5, 2006, at 2:24 AM, George Neill wrote: > http://vipaka.sourceforge.net, miss-spelled vipaka :) Not responding on port 80. :( j From ajgrothe at yahoo.com Sun Nov 5 08:57:28 2006 From: ajgrothe at yahoo.com (Aaron Grothe) Date: Sun, 5 Nov 2006 08:57:28 -0800 (PST) Subject: [Omaha.pm] New Perl Project out at Sourceforge.net In-Reply-To: Message-ID: <20061105165728.58426.qmail@web34403.mail.mud.yahoo.com> Hey Jay, Thanks for the pointer. I've turned in a support request. I'm thinking about already moving it off of sourceforge.net. I would move to Savannah, but I don't like the GFDL (GNU Free Documentation License) which they require you use and they don't like Oracle. Maybe move it to Google's code site? Apparently this bug has nailed a bunch of projects running at sourceforge. Thanks, Aaron -=-=- "The Journey is the Reward" - Old Zen Buddhist Saying --- Jay Hannah wrote: > On Nov 4, 2006, at 10:20 PM, Aaron Grothe wrote: > > The project is out at http://vipka.sourceforge.net > > (We mainly mess with Informix & mySQL, not Oracle.) > > Something is wrong with your site? > > j > > ------------- > An error has been encountered in accessing this page. > > 1. Server: vipka.sourceforge.net > 2. URL path: / > 3. Error notes: File does not exist: > /home/groups/v/vi/vipka/htdocs/ > 4. Error type: 404 > 5. Request method: GET > 6. Request query string: > 7. Time: 2006-11-04 23:37:18 PST (1162712238) > > Reporting this problem: The problem you have encountered is with a > > project web site hosted by SourceForge.net. This issue should be > reported to the SourceForge.net-hosted project (not to > SourceForge.net). > > If this is a severe or recurring/persistent problem, please do one > of > the following, and provide the error text (numbered 1 through 7, > above): > > 1. Contact the project via their designated support resources. > 2. Contact the project administrators of this project via email > > (see the upper right-hand corner of the Project Summary page for > their usernames) at user-name at users.sourceforge.net > > If you are a member of the project that maintains this web content, > > please refer to the Site Documentation regarding the project web > service for further assistance. > ----------- > > > > _______________________________________________ > Omaha-pm mailing list > Omaha-pm at pm.org > http://mail.pm.org/mailman/listinfo/omaha-pm > ____________________________________________________________________________________ Access over 1 million songs - Yahoo! Music Unlimited (http://music.yahoo.com/unlimited) From jhannah at omnihotels.com Mon Nov 6 10:20:08 2006 From: jhannah at omnihotels.com (Jay Hannah) Date: Mon, 6 Nov 2006 12:20:08 -0600 Subject: [Omaha.pm] FW: DBD::Informix & $SIG{ALRM} & /etc/services Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B06F5DCC3@exchange2k3.omnihotels.net> FYI. In case you care about my Informix $SIG{ALRM} woes. :) j -----Original Message----- From: Jonathan Leffler [mailto:jonathan.leffler at gmail.com] Sent: Friday, November 03, 2006 4:30 PM To: Jay Hannah Cc: dbi-users at perl.org; Guardian of DBD::Informix Subject: Re: DBD::Informix & $SIG{ALRM} & /etc/services On 11/3/06, Jay Hannah wrote: Oops. I noticed my versions were behind. I upgraded DBI and DBD::Informix. I'm still getting the same behavior (14.3 seconds to time out), so I'm still curious about what might be going on. CSDK probably uses alarm itself - for connection timeouts, no less - so your attempt to use alarm at the same time is likely to cause confusion somewhere. You could probably track this with the equivalent of truss (strace on Linux?), looking for alarm system calls in the output. You'd probably be able to identify your own alarm(2) call; you might have to work harder to identify which other alarm() calls are made before you see SIGALRM fire. Interestingly, the manual page for the system call is usually designated alarm(2) as well as you using an alarm function call with the argument value 2. $ perl -MDBI -e'DBI->installed_versions' Perl : 5.008004 (i686-linux) OS : linux (2.6.4-52-smp) DBI : 1.53 DBD::Sybase : 1.04 DBD::Sponge : 11.10 DBD::Proxy : install_driver(Proxy) failed: Can't locate RPC/PlClient.pm in @INC DBD::Informix : 2005.02 DBD::File : 0.35 DBD::ExampleP : 11.12 DBD::DBM : 0.03 -- Jonathan Leffler #include Guardian of DBD::Informix - v2005.02 - http://dbi.perl.org "I don't suffer from insanity - I enjoy every minute of it." From jay at jays.net Mon Nov 6 18:14:13 2006 From: jay at jays.net (Jay Hannah) Date: Mon, 6 Nov 2006 20:14:13 -0600 Subject: [Omaha.pm] Fwd: [dynamic_omaha] Rebol tomorrow night! References: <20061106235700.14851.qmail@server271.com> Message-ID: I'm going tomorrow (Tue) night. Anyone want to crash the Dynamic Languages User Group with me? (Perl is included in their language list. gotzta represent!) -grin- Omaha Dynamic Language User Group: http://www.blainebuxton.com/odynug/ Rebol: http://en.wikipedia.org/wiki/Rebol j Begin forwarded message: > From: "Blaine Buxton" > Date: November 6, 2006 5:57:00 PM CST > To: "dynamic_omaha at blainebuxton.com" > Subject: [dynamic_omaha] Rebol tomorrow night! > Reply-To: "Blaine Buxton" > > Just a quick reminder than Rebol is tomorrow night at the meeting. > See you there @ 7pm! > -- > Blaine Buxton > Mad Computer Scientist In Training > http://www.blainebuxton.com From pbaker at omnihotels.com Tue Nov 7 05:17:05 2006 From: pbaker at omnihotels.com (Sean Baker) Date: Tue, 7 Nov 2006 07:17:05 -0600 Subject: [Omaha.pm] Fwd: [dynamic_omaha] Rebol tomorrow night! Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B06FC1155@exchange2k3.omnihotels.net> >Rebol: >http://en.wikipedia.org/wiki/Rebol Interesting. The guy who wrote Rebol wrote the OS for the Amiga. I had two (a 500 & 2000)! Ahhh, those were the days..... Sean Baker Software Architect From jay at jays.net Fri Nov 10 13:35:17 2006 From: jay at jays.net (Jay Hannah) Date: Fri, 10 Nov 2006 15:35:17 -0600 Subject: [Omaha.pm] Perl solution request In-Reply-To: <4336988b0611090850w61014e9cgaafcdf4a496111b4@mail.gmail.com> References: <4336988b0611090850w61014e9cgaafcdf4a496111b4@mail.gmail.com> Message-ID: <4554F095.1030507@jays.net> Paul Hanson wrote: > I know this can be done, but it's implementation is boggling me. > > We have a ****ton of IBM servers, many of which are nearing their 'put > out to pasture' date. The issue is finding out which ones are close > and which should be there by now. Well, IBM conveniently has a web > page dedicated to this. However, it's not easy to script. I've made > several valiant but failed attempts with curl, lynx, links, etc. > > I remember reading somewhere about a HTML::Mechanize I think it's > called, where you are able to get information from a page. However, > with my limited Perl skills (=0) and my lack of time I was wondering > if you wouldn't mind looking in to this. > > The URL is > > http://www-307.ibm.com/pc/support/site.wss/warrantyLookup.do?type=XXXX&serial=XXXXXXX&country=897&iws=off > > Where "X" could be the machine type and the serial number I've been > able to manually plug in these with success. > > Samples: > 8676 - KP-DRC21 > 8843 - 99GTK75 > > Would you have time to look into this and help me find a solution? > Ideally, it would take a text file as input for the two variables and > spew the info out into a new text file. > > If you have further questions or just want to mock me, feel free to email. > > Thanks! > -Paul Hi Paul -- Here's what I could do for you in 15m. WWW::Mechanize is pretty cool. From this point forward you'll need to parse the super-ugly humongous HTML table that IBM throws your data into. Perhaps try HTML::TableExtract? Should be pretty easy...? I hope that helps you get going. Cheers, j $ cat j.pl use WWW::Mechanize; my $mech = WWW::Mechanize->new(); my $url = "http://www-307.ibm.com/pc/support/site.wss/warrantyLookup.do?type=__AAA__&serial=__BBB__&country=897&iws=off"; open (IN, "warranty_list.txt"); while () { chomp; my ($type, $serial) = split " - "; my $tmpurl = $url; $tmpurl =~ s/__AAA__/$type/; $tmpurl =~ s/__BBB__/$serial/; print "Fetching $tmpurl...\n"; $mech->get( $tmpurl ); my @lines = split "\n", $mech->content; foreach (@lines) { if (/Expiration date/) { # This is where your data is... Hand $_ into HTML::TableExtract? # s/<.*?>//g; # throw all HTML away... print; last; } } print "\n\n"; } $ cat warranty_list.txt 8676 - KP-DRC21 8843 - 99GTK75 $ perl j.pl Fetching http://www-307.ibm.com/pc/support/site.wss/warrantyLookup.do?type=8676&serial=KP-DRC21&country=897&iws=off...
Type:Model:Serial number:
867661XKPDRC21

Status:Expiration date:Location:
Out of warranty2006-09-08UNITED STATES
Warranty service upgrades & maintenance servicesWarranty service upgrades and maintenance services

Description:
This product has a three year limited warranty and is entitled to parts, labor and on-site repair service. Service is available Monday-Friday, except holidays, with a next business day response objective. Many parts can also be delivered to you using the Customer Replaceable Unit (CRU) method.
Fetching http://www-307.ibm.com/pc/support/site.wss/warrantyLookup.do?type=8843&serial=99GTK75 &country=897&iws=off...
Type:Model:Serial number:
88432RU99GTK75

Status:Expiration date:Location:
In warranty2009-03-31UNITED STATES
Warranty service upgrades & maintenance servicesWarranty service upgrades and maintenance services

Description:
This product has a three year limited warranty and is entitled to parts, labor and on-site repair service. Service is available Monday-Friday, except holidays, with a next business day response objective. Many parts can also be delivered to you using the Customer Replaceable Unit (CRU) method.
From jay at jays.net Tue Nov 14 16:51:24 2006 From: jay at jays.net (Jay Hannah) Date: Tue, 14 Nov 2006 18:51:24 -0600 Subject: [Omaha.pm] Pizza pie! yee-ha Message-ID: <455A648C.7080707@jays.net> Everybody: woo-hoo! We have a new corporate sponsor! Jimmy Smith with Paragon IT Professionals is buying our pizza now, starting last month! Thanks Jimmy!! I'll get the website updated and start sending out the props you so richly deserve every month. :) We'll raise a slice in your honor tonight! :) Re ColdFusion: I'm not aware that any Perl Mongers are ColdFusioners. I sent you that link because you were asking about ColdFusion folks on the phone the other day. The Omaha ColdFusion user group is probably a good place to start. :) j currently sitting at Reboot the User for the November secret meeting regretting not having my act together. (Super swamped at work lately. sorry.......) -------- Original Message -------- Subject: RE: Perl Mongers: pizza Date: Tue, 14 Nov 2006 10:55:36 -0600 From: Jimmy M. Smith To: Jay Hannah Jay, I have ordered the pizza for tonight. They will delivery it to Reboot at 7:00pm. I order a meat lovers and a cheese pizza. PS I just noticed that you have a link to the ColdFusion site. Do you have a large ColdFusion present in the user group? Thank you, Jimmy Smith Branch Sales Manager PARAGON IT Professionals 11840 Nicholas Street, Suite 101 Omaha, NE 68154 (402) 504-4091 Ext. 305 (402) 504-4150 Fax www.paragonitpros.com "I.T. Phone Home." Bring your Information Technology career home to Nebraska! Visit http://www.paragonitpros.com/itphonehome.aspx From jay at jays.net Tue Nov 14 16:55:28 2006 From: jay at jays.net (Jay Hannah) Date: Tue, 14 Nov 2006 18:55:28 -0600 Subject: [Omaha.pm] Wow. In-Reply-To: <455a3093.6255c1bc.20e8.57da@mx.google.com> References: <455a3093.6255c1bc.20e8.57da@mx.google.com> Message-ID: <455A6580.4000900@jays.net> Kenn wrote: > I think I just met your .net counterpart. Maybe even Larry Walls (perl guru?). Larry who? http://www.perl.org/advocacy/white_camel/ 2006: Jay Hannah, Josh McAdams, Randal Schwartz -laugh- (Are you on the PM list?) j I got the "hubris" thing down :) From jay at jays.net Tue Nov 14 18:21:39 2006 From: jay at jays.net (Jay Hannah) Date: Tue, 14 Nov 2006 20:21:39 -0600 Subject: [Omaha.pm] we need a 1 liner Message-ID: <455A79B3.4080102@jays.net> Can anyone tell me what the 1 liner for this is before Andy does? :) j my @old = @{$self->{pools}}; my @new; foreach (@old) { if (@$_ > 0) { push @new, $_; } } $self->{pools} = \@new; From andy at petdance.com Tue Nov 14 18:47:07 2006 From: andy at petdance.com (Andy Lester) Date: Tue, 14 Nov 2006 20:47:07 -0600 Subject: [Omaha.pm] we need a 1 liner In-Reply-To: <455A79B3.4080102@jays.net> References: <455A79B3.4080102@jays.net> Message-ID: <0FB32764-D740-4BE7-B7DF-B8E0A7FAA981@petdance.com> On Nov 14, 2006, at 8:21 PM, Jay Hannah wrote: > Can anyone tell me what the 1 liner for this is before Andy does? Looks like not. :-) # Here's the original my @old = @{$self->{pools}}; my @new; foreach (@old) { if (@$_ > 0) { push @new, $_; } } $self->{pools} = \@new; # We can easily substitute @old out, and turn the push() into postfix my @new; foreach ( @{$self->{pools}} ) { push @new, $_ if (@$_ > 0); } $self->{pools} = \@new; # What we're really doing is a grep. We're saying "for everything that # matches a given criteria, stick it in @new". So write it like so my @new = grep { @$_ > 0 } @{$self->{pools}}; $self->{pools} = \@new; # Now we can remove the @new entirely with an anonymous array # constructor. $self->{pools} = [ grep { @$_ > 0 } @{$self->{pools}} ]; # I think it's clearer this way. What you're saying is: $self->{pools} = [ # assign an anonymous array that contains grep # everything that matches { @$_ > 0 } # the condition that the dereferenced # "it" is not empty @{$self->{pools}} ]; # using this list. Another way to have done the same thing, since you're reading from and assigning to the same list, would have been to iterate over the array and delete all the elements such that @{element} == 0, but I think this one is cleaner to read. xoxo, Andy -- Andy Lester => andy at petdance.com => www.petdance.com => AIM:petdance From reynacho at gmail.com Tue Nov 14 19:11:51 2006 From: reynacho at gmail.com (Jake Churchill) Date: Tue, 14 Nov 2006 21:11:51 -0600 Subject: [Omaha.pm] Pizza pie! yee-ha In-Reply-To: <455A648C.7080707@jays.net> References: <455A648C.7080707@jays.net> Message-ID: <455A8577.7000006@gmail.com> I'm a "Coldfusioner" Jay Hannah wrote: > Everybody: woo-hoo! We have a new corporate sponsor! Jimmy Smith with Paragon IT Professionals is buying our pizza now, starting last month! > > Thanks Jimmy!! I'll get the website updated and start sending out the props you so richly deserve every month. :) We'll raise a slice in your honor tonight! :) > > Re ColdFusion: I'm not aware that any Perl Mongers are ColdFusioners. I sent you that link because you were asking about ColdFusion folks on the phone the other day. The Omaha ColdFusion user group is probably a good place to start. :) > > j > currently sitting at Reboot the User for the November secret meeting regretting not having my act together. (Super swamped at work lately. sorry.......) > > > > -------- Original Message -------- > Subject: RE: Perl Mongers: pizza > Date: Tue, 14 Nov 2006 10:55:36 -0600 > From: Jimmy M. Smith > To: Jay Hannah > > Jay, > > I have ordered the pizza for tonight. They will delivery it to Reboot at > 7:00pm. I order a meat lovers and a cheese pizza. > > PS I just noticed that you have a link to the ColdFusion site. Do you > have a large ColdFusion present in the user group? > > Thank you, > > > Jimmy Smith > Branch Sales Manager > PARAGON IT Professionals > 11840 Nicholas Street, Suite 101 > Omaha, NE 68154 > (402) 504-4091 Ext. 305 > (402) 504-4150 Fax > www.paragonitpros.com > "I.T. Phone Home." > Bring your Information Technology career home to Nebraska! Visit > http://www.paragonitpros.com/itphonehome.aspx > > > _______________________________________________ > Omaha-pm mailing list > Omaha-pm at pm.org > http://mail.pm.org/mailman/listinfo/omaha-pm > > From ryan at cfwebtools.com Wed Nov 15 06:23:19 2006 From: ryan at cfwebtools.com (Ryan Stille) Date: Wed, 15 Nov 2006 08:23:19 -0600 Subject: [Omaha.pm] Pizza pie! yee-ha In-Reply-To: <455A648C.7080707@jays.net> References: <455A648C.7080707@jays.net> Message-ID: <455B22D7.2010506@cfwebtools.com> Jay Hannah wrote: > ..... > > Re ColdFusion: I'm not aware that any Perl Mongers are ColdFusioners. I sent you that link because you were asking about ColdFusion folks on the phone the other day. The Omaha ColdFusion user group is probably a good place to start. :) > > Just one. :-) I am a Perl Monger (t-shirt and everything), I also help run the ColdFusion users group, http://www.necfug.com. That reminds me I wanted let you guys know I'll be doing a presentation on Adobe Spry on the 28th this month at the CF users group. Spry is an AJAX framework that uses XML. So it can work with PHP, Perl, ColdFusion, anything that can generate XML. It uses very little javascript, its mostly tag based - so you JavaScript haters (Jay) now have an easy way to to AJAX and some very neat "Web 2.0" effects. Come check it out. And just to keep up with the Perl Mongers, we have free pizza at our meetings too! Meeting info: http://necfug.com/index_meetings.cfm -Ryan From pbaker at omnihotels.com Wed Nov 15 08:03:06 2006 From: pbaker at omnihotels.com (Sean Baker) Date: Wed, 15 Nov 2006 10:03:06 -0600 Subject: [Omaha.pm] we need a 1 liner Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B071202C7@exchange2k3.omnihotels.net> $self->{pools} = grep { $_ > 0 } @{$self->{pools}}; Test script: #!/usr/bin/perl my @old = (-1,0,1,2,3,4,5); @old = grep { $_ > 0 } @old; foreach (@old) { print "$_\n"; } pbaker at razorbill:~> perl t.pl 1 2 3 4 5 Sean Baker Software Architect Omni Hotels -----Original Message----- From: omaha-pm-bounces+pbaker=omnihotels.com at pm.org [mailto:omaha-pm-bounces+pbaker=omnihotels.com at pm.org] On Behalf Of Jay Hannah Sent: Tuesday, November 14, 2006 8:22 PM To: Perl Mongers of Omaha, Nebraska USA Subject: [Omaha.pm] we need a 1 liner Can anyone tell me what the 1 liner for this is before Andy does? :) j my @old = @{$self->{pools}}; my @new; foreach (@old) { if (@$_ > 0) { push @new, $_; } } $self->{pools} = \@new; _______________________________________________ Omaha-pm mailing list Omaha-pm at pm.org http://mail.pm.org/mailman/listinfo/omaha-pm From pbaker at omnihotels.com Wed Nov 15 08:06:24 2006 From: pbaker at omnihotels.com (Sean Baker) Date: Wed, 15 Nov 2006 10:06:24 -0600 Subject: [Omaha.pm] we need a 1 liner Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B071202DC@exchange2k3.omnihotels.net> Grrrr... if I only read this last night. Sean -----Original Message----- From: omaha-pm-bounces+pbaker=omnihotels.com at pm.org [mailto:omaha-pm-bounces+pbaker=omnihotels.com at pm.org] On Behalf Of Andy Lester Sent: Tuesday, November 14, 2006 8:47 PM To: Perl Mongers of Omaha, Nebraska USA Subject: Re: [Omaha.pm] we need a 1 liner On Nov 14, 2006, at 8:21 PM, Jay Hannah wrote: > Can anyone tell me what the 1 liner for this is before Andy does? Looks like not. :-) From jay at jays.net Thu Nov 16 11:12:42 2006 From: jay at jays.net (Jay Hannah) Date: Thu, 16 Nov 2006 13:12:42 -0600 (CST) Subject: [Omaha.pm] FIXME, July 2001 Message-ID: Justin: Remember this? Scary, huh? My favorite part of this code snippet is the FIXME from July 2001. Ya, I'll get right on that. :) j RCS file: /cvs/source/specific/gds/perl/comserver/cserr_handler-b.pl,v ---------------------------- revision 1.1 date: 2001/07/30 19:20:47; author: jhopkins; state: Exp; Initial revision 1.1 (jhopkins 30-Jul-01): while(1) 1.1 (jhopkins 30-Jul-01): { 1.1 (jhopkins 30-Jul-01): $/ = '||||'; # FIXME? 1.1 (jhopkins 30-Jul-01): my $errmsg = <$readfh>; 1.1 (jhopkins 30-Jul-01): $/ = "\n"; 1.1 (jhopkins 30-Jul-01): if((!defined $errmsg) || ($errmsg =~ /^\s*$/)) 1.1 (jhopkins 30-Jul-01): { 1.1 (jhopkins 30-Jul-01): # Someone closed the pipe 1.1 (jhopkins 30-Jul-01): exit(0); 1.1 (jhopkins 30-Jul-01): } 1.1 (jhopkins 30-Jul-01): $errmsg =~ s/\|\|\|\|$//; From griffinheart at go.com Sun Nov 19 19:27:46 2006 From: griffinheart at go.com (griffinheart at go.com) Date: Mon, 20 Nov 2006 03:27:46 +0000 (UTC) Subject: [Omaha.pm] Omaha-pm Digest, Vol 31, Issue 7 Message-ID: <29579594.1163993266641.JavaMail.?@fh127.dia.he.tucows.com> I have a non-Perl-related problem. I have no sound in web browsers, but sound in almost all other programs (including Winamp). The only sound I can get from web browsers is when it loads something with the browser such as Windows Media Player. I think the problem is more fundamental than Firefox or IE as I've reinstalled both programs and tried "fixes" that worked for people with "no sound in web browsers." Also, a few other programs don't have sound, such as the old, possibly dos-based, Legends of the Ur-Quan Masters. Thanks for your time. Any help would be appreciated. Hopefully I haven't annoyed any of you with this e-mail. Griff. From jay at jays.net Tue Nov 21 05:41:38 2006 From: jay at jays.net (Jay Hannah) Date: Tue, 21 Nov 2006 07:41:38 -0600 Subject: [Omaha.pm] FWD: FIXME, July 2001 References: <455EE046.6010402@jays.net> Message-ID: <0229FD96-6A7E-4652-AB04-5034DE44826B@jays.net> -laugh- Justin lives in China nowadays. :) j Begin forwarded message: > From: Justin Hopkins > Date: November 18, 2006 4:28:22 AM CST > > Hmmm, very scary. Thats why I fled the hemisphere. It was only a > matter of time before I was discovered. > > Happily there is no extradition treaty. > > -- > Justin Hopkins > jhop at jays.net > > Jay Hannah wrote: >> Justin: Remember this? Scary, huh? >> My favorite part of this code snippet is the FIXME from July 2001. >> Ya, I'll get right on that. :) >> j >> RCS file: /cvs/source/specific/gds/perl/comserver/cserr_handler- >> b.pl,v >> ---------------------------- >> revision 1.1 >> date: 2001/07/30 19:20:47; author: jhopkins; state: Exp; >> Initial revision >> 1.1 (jhopkins 30-Jul-01): while(1) >> 1.1 (jhopkins 30-Jul-01): { >> 1.1 (jhopkins 30-Jul-01): $/ = '||||'; # FIXME? >> 1.1 (jhopkins 30-Jul-01): my $errmsg = <$readfh>; >> 1.1 (jhopkins 30-Jul-01): $/ = "\n"; >> 1.1 (jhopkins 30-Jul-01): if((!defined $errmsg) || ($errmsg >> =~ /^\s*$/)) >> 1.1 (jhopkins 30-Jul-01): { >> 1.1 (jhopkins 30-Jul-01): # Someone closed the pipe >> 1.1 (jhopkins 30-Jul-01): exit(0); >> 1.1 (jhopkins 30-Jul-01): } >> 1.1 (jhopkins 30-Jul-01): $errmsg =~ s/\|\|\|\|$//; From dan at linder.org Tue Nov 21 06:49:31 2006 From: dan at linder.org (Daniel Linder) Date: Tue, 21 Nov 2006 08:49:31 -0600 (CST) Subject: [Omaha.pm] FWD: FIXME, July 2001 In-Reply-To: <0229FD96-6A7E-4652-AB04-5034DE44826B@jays.net> References: <455EE046.6010402@jays.net> <0229FD96-6A7E-4652-AB04-5034DE44826B@jays.net> Message-ID: <41985.68.13.153.38.1164120571.squirrel@www.linder.org> Jay Hannah wrote: > Justin: Remember this? Scary, huh? [...snip...] > 1.1 (jhopkins 30-Jul-01): $/ = '||||'; # FIXME? > 1.1 (jhopkins 30-Jul-01): my $errmsg = <$readfh>; So, what does the FIXME line do? >From "http://www.kichwa.com/quik_ref/spec_variables.html", it says the "$/" variable contains...: The input record separator, newline by default. $/ may be set to a value longer than one character in order to match a multi-character delimiter. If $/ is undefined, no record separator is matched, and will read everything to the end of the current file. So, If I read it right, this causes the next line to continue reading from the file $readfh, and put all characters up to but not including four 'pipe' symbols, right? I.e. if the $readfh file handle pointed to a file whose contents was this: This is line 1\n this is line 2\n this is line 3||||This is the beginning of a new "record"\n This is really on line 4\n||||This is the end of the file. Then, the first time $readfh is used, the $errmsg variable contains: "This is line 1\nthis is line 2\nthis is line 3" The next time, it would contain: "This is the beginning of a new "record"\nThis is really on line 4\n" And finally, it would contain: "This is the end of the file." If I understand this, the kicker here is that the "\n" characters are also placed into the $errmsg variable. Correct? Dan - - - - "Wait for that wisest of all counselors, time." -- Pericles "I do not fear computers, I fear the lack of them." -- Isaac Asimov From jhannah at omnihotels.com Tue Nov 28 07:44:12 2006 From: jhannah at omnihotels.com (Jay Hannah) Date: Tue, 28 Nov 2006 09:44:12 -0600 Subject: [Omaha.pm] 2007 daylight savings time change Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B072F81AA@exchange2k3.omnihotels.net> From: David Jackson Sent: Tuesday, November 28, 2006 8:12 AM > http://www.networkworld.com/newsletters/nt/2006/1106nt1.html?t5 Wow. Looks like Perl only cares that the OS is patched? http://www.iiug.org/resources/articles/dls_2007.html Good thing we don't code under dozens of JREs (Java). Shall we drop by the Java Users Group and watch them recompile their JREs? -grin- I wonder if Perl6 will suffer this JRE problem? Gotta love Perl5. :) j From dan at linder.org Tue Nov 28 12:00:07 2006 From: dan at linder.org (Daniel Linder) Date: Tue, 28 Nov 2006 14:00:07 -0600 (CST) Subject: [Omaha.pm] 2007 daylight savings time change In-Reply-To: <29AB736ABCE5C745ABF9C93B02F2C27B072F81AA@exchange2k3.omnihotels.net> References: <29AB736ABCE5C745ABF9C93B02F2C27B072F81AA@exchange2k3.omnihotels.net> Message-ID: <51920.68.13.153.38.1164744007.squirrel@www.linder.org> On Tue, November 28, 2006 09:44, Jay Hannah wrote: > From: David Jackson > Sent: Tuesday, November 28, 2006 8:12 AM >> http://www.networkworld.com/newsletters/nt/2006/1106nt1.html?t5 > > Wow. Looks like Perl only cares that the OS is patched? > > http://www.iiug.org/resources/articles/dls_2007.html > > Good thing we don't code under dozens of JREs (Java). Shall we drop by > the Java Users Group and watch them recompile their JREs? -grin- > > I wonder if Perl6 will suffer this JRE problem? Gotta love Perl5. :) I can only hope that the developers of P6 break that out into a separate module (or continue to rely on the OS). Of course I can see some people taking the option of just letting some systems be off by 1 hour for a few extra weeks... :( (How many times have we seen the flashing "12:00" on VCRs...) Dan - - - - "Wait for that wisest of all counselors, time." -- Pericles "I do not fear computers, I fear the lack of them." -- Isaac Asimov "Soon we will be able to harness the rotational energy from Orwell's grave to solve all world energy problems." -- /. user GigsVT (208848) GPG fingerprint:6FFD DB94 7B96 0FD8 EADF 2EE0 B2B0 CC47 4FDE 9B68 From jhannah at omnihotels.com Wed Nov 29 08:33:40 2006 From: jhannah at omnihotels.com (Jay Hannah) Date: Wed, 29 Nov 2006 10:33:40 -0600 Subject: [Omaha.pm] You can't go wrong with 1; Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B07334561@exchange2k3.omnihotels.net> You can never have too many "1;" lines in your programs. I have no idea why I put that there 21 months ago. :) j SLEEP: while (sleep $sleephack) { $debug && print "\n\nI'm awake!\n"; $sleephack = $sleep; my $running = running(); next if ($running >= $max_rcvlbmns_to_run); if (keys %waiting < $max_rcvlbmns_to_run - $running) { %waiting = get_waiting_list(); } 1; RUNONE: for (1..$max_rcvlbmns_to_run - $running) { last unless %waiting; $number_checked = 0; my $next_to_run = next_to_run(%waiting); $debug && print "Run $next_to_run\n"; system("nice -n 20 /oexec/__obin/rcvlbmn.4ge $next_to_run &"); delete $waiting{$next_to_run}; } $debug && print "Sleeping now.\n"; $debug && print "I still know of " . scalar(keys %waiting) . " props waiting.\n"; } From jay at jays.net Wed Nov 29 09:01:33 2006 From: jay at jays.net (Jay Hannah) Date: Wed, 29 Nov 2006 11:01:33 -0600 (CST) Subject: [Omaha.pm] Project doc overkill Message-ID: -lol- Is it a good thing or a bad thing when my lines of documentation to lines of code ratio exceeds 95%? Wrote this in June this year and yes, just 5 months later I definately needed all of that documentation to understand what the heck I was thinking... :) j =head2 next_obj Return whichever outbound filehandle I should write to next and advance my memorized {last_obj_used} value. my $obj = $buffers->next_obj; See source code for a warning about write()'ing to an inbound connection. B (jhannah 2006-06-29) This method's job is to return the next obj/filehandle/child we should write a payload to. The original implementation of this method was a simple round robin system. Under round robin queuing if you have 6 children, then each payload is sent to each child in order. Once a payload is sent to the last child, we start over at the first child. And so on. Pretty simple. 'first free' queuing is different. Instead of just blindly writing to the next child, we attempt to find the next child which is not busy. Which ones are busy? Well, under first free queuing it is assumed that each child can and should only handle one payload at a time. Therefore, when a write is made to a child that child is flagged as "busy" here in the Buffers class. When the child is done processing, it should return its response. Receiving a response from a child triggers that child as no longer busy, so its status is cleared and it is once again free to receive a payload. So when a write() call is made we go fishing for the next available child to write to. This process starts as simply as the round robin system: We know which child we wrote to last, so we'll look to see if the next one is free. If it is, that's the one we'll write to. If it's busy, we'll increment our counter and try again, wrapping around our child list if we hit the end. If we make a full loop and it turns out that all of our children are busy, then we'll have to give up for now, saving this payload for later transmission. Hopefully one of our children will be free the next time we go searching. Note that 'first free' queuing will probably not make you happy if your children don't respond to requests. No response means Control::Multiplex will forever think your child is still working on the first payload we sent it, and will never send a second payload to that child. Further, you're likely to be dissatisfied if your children enjoy receiving more than one payload at a time. Under 'round robin' queuing children are sent work as fast as possible, but under 'first free' queuing any given child only ever has one payload to process at a time. =cut sub next_obj { my ($self, $label) = @_; my $logger = $self->get_logger; if (defined $self->{outbound}->{$label}) { confess "ACK!" if ($label eq "INBOUND"); if ($self->{queuing} eq "first free") { $logger->debug("Buffers.pm next_obj() has decided to use next_obj_first_free()"); return $self->next_obj_first_free($label); } else { $logger->debug("Buffers.pm next_obj() has decided to use next_obj_round_robin()"); return $self->next_obj_round_robin($label); } } elsif (defined $self->{inbound}->{$label}) { # We don't know about that outbound label, but this is an inbound label and # apparently we want to write back out to it. (Like an inbound TCP.) # ... # We probably can't write back to the first (0th) element in this array because that's # probably the listening socket. Bummer. Let's write back to the second one in the array. # Note this is NOT safe if there are 5 connections connected and you # want to specifically write back to the one whose input just caused the read() -- # I'll probably have to implement that logic some day, but I don't need it for # any project current on the books. Currently we write() all our output back to # a single inbound connection, or a single outbound TCP connection for all inbound # work... -jhannah 11/8/04 return $self->{inbound}->{$label}->{objs}->[1]; } else { return undef; } } From ryan at cfwebtools.com Wed Nov 29 08:43:46 2006 From: ryan at cfwebtools.com (Ryan Stille) Date: Wed, 29 Nov 2006 10:43:46 -0600 Subject: [Omaha.pm] Project doc overkill In-Reply-To: References: Message-ID: <456DB8C2.4080800@cfwebtools.com> > > -lol- > > Is it a good thing or a bad thing when my lines of documentation to lines > of code ratio exceeds 95%? I'm the same way, sometimes my comments could be short stories. :-) -Ryan From sidney.omaha.pm at gmail.com Wed Nov 29 09:06:01 2006 From: sidney.omaha.pm at gmail.com (sidney.omaha.pm at gmail.com) Date: Wed, 29 Nov 2006 11:06:01 -0600 Subject: [Omaha.pm] Project doc overkill In-Reply-To: Message-ID: <3.0.6.32.20061129110601.00e8d100@pop.radiks.net> At 11:01 AM 11/29/2006 -0600, Jay Hannah wrote: > >-lol- > >Is it a good thing or a bad thing when my lines of documentation to lines >of code ratio exceeds 95%? It's a good thing. When's the next meeting? I can't remember which day of which week of the month it's supposed to be. If somebody will clue me in, I'll crontab it. -Sidney From jhannah at omnihotels.com Wed Nov 29 09:58:41 2006 From: jhannah at omnihotels.com (Jay Hannah) Date: Wed, 29 Nov 2006 11:58:41 -0600 Subject: [Omaha.pm] One liners are good for you Message-ID: <29AB736ABCE5C745ABF9C93B02F2C27B07334743@exchange2k3.omnihotels.net> I love rattling through various one-liners trying to find the answer to the question I'm looking for. I almost had by first-ever successful use of -a, but not quite. perldoc perlrun is your friend. :) j ps -ef | perl -nae 'print "$F[8]\n"' | more ps -ef | perl -pe 's/.*\d+:\d\d //;' | sort | uniq -c | more ps -ef | perl -ne '/.*\d+:\d\d (.*?) /; print "$1\n"' | sort | uniq -c | more From jay at jays.net Thu Nov 30 05:53:39 2006 From: jay at jays.net (Jay Hannah) Date: Thu, 30 Nov 2006 07:53:39 -0600 Subject: [Omaha.pm] Project doc overkill In-Reply-To: <3.0.6.32.20061129110601.00e8d100@pop.radiks.net> References: <3.0.6.32.20061129110601.00e8d100@pop.radiks.net> Message-ID: <687D16E0-7C7D-4BF9-9466-6099B1D09E25@jays.net> On Nov 29, 2006, at 11:06 AM, sidney.omaha.pm at gmail.com wrote: > When's the next meeting? I can't remember which day of which week > of the > month it's supposed to be. If somebody will clue me in, I'll > crontab it. http://omaha.pm.org/ It's the big box at the top. :) j