<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: How to: PECL HTTP request exception and error handling</title>
	<atom:link href="http://www.markfosteronline.com/2009/01/06/how-to-pecl-http-request-exception-and-error-handling/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.markfosteronline.com/2009/01/06/how-to-pecl-http-request-exception-and-error-handling/</link>
	<description>Misadventures in Technology</description>
	<lastBuildDate>Fri, 03 Sep 2010 08:47:02 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0.1</generator>
	<item>
		<title>By: Bas Tard</title>
		<link>http://www.markfosteronline.com/2009/01/06/how-to-pecl-http-request-exception-and-error-handling/comment-page-1/#comment-65</link>
		<dc:creator>Bas Tard</dc:creator>
		<pubDate>Wed, 25 Feb 2009 20:54:50 +0000</pubDate>
		<guid isPermaLink="false">http://www.markfosteronline.com/?p=183#comment-65</guid>
		<description>I&#039;ve been getting too many exceptions using HttpRequest::send() of this type:
HttpInvalidParamException with message &quot;Empty or too short HTTP message: &#039;&#039;&quot; and inner exception HttpRequestException with message &quot;a timeout was reached; connect() timed out!&quot;

The frequency at which this occurred was suspicious so I wrapped the send() in a loop of max 3 attempts and now the code always works even though the 1st attempt sometimes fails.

I&#039;ve had this same problem on different servers with different OS&#039; and different code so there&#039;s obviously something broken in the PECL http code.

I decided to replace all the PECL Http code and this ridiculous workaround with CURL code and I haven&#039;t had a problem since.</description>
		<content:encoded><![CDATA[<p>I&#8217;ve been getting too many exceptions using HttpRequest::send() of this type:<br />
HttpInvalidParamException with message &#8220;Empty or too short HTTP message: &#8221;&#8221; and inner exception HttpRequestException with message &#8220;a timeout was reached; connect() timed out!&#8221;</p>
<p>The frequency at which this occurred was suspicious so I wrapped the send() in a loop of max 3 attempts and now the code always works even though the 1st attempt sometimes fails.</p>
<p>I&#8217;ve had this same problem on different servers with different OS&#8217; and different code so there&#8217;s obviously something broken in the PECL http code.</p>
<p>I decided to replace all the PECL Http code and this ridiculous workaround with CURL code and I haven&#8217;t had a problem since.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: How to use the PHP cURL module to make HTTP requests from PHP - Mark Foster&#8217;s Blog</title>
		<link>http://www.markfosteronline.com/2009/01/06/how-to-pecl-http-request-exception-and-error-handling/comment-page-1/#comment-51</link>
		<dc:creator>How to use the PHP cURL module to make HTTP requests from PHP - Mark Foster&#8217;s Blog</dc:creator>
		<pubDate>Sun, 22 Feb 2009 04:15:11 +0000</pubDate>
		<guid isPermaLink="false">http://www.markfosteronline.com/?p=183#comment-51</guid>
		<description>[...] How to: PECL HTTP request exception and error handling [...]</description>
		<content:encoded><![CDATA[<p>[...] How to: PECL HTTP request exception and error handling [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Dan Delaney</title>
		<link>http://www.markfosteronline.com/2009/01/06/how-to-pecl-http-request-exception-and-error-handling/comment-page-1/#comment-30</link>
		<dc:creator>Dan Delaney</dc:creator>
		<pubDate>Thu, 05 Feb 2009 20:54:44 +0000</pubDate>
		<guid isPermaLink="false">http://www.markfosteronline.com/?p=183#comment-30</guid>
		<description>THANK YOU for this info about the undocumented &quot;innerException&quot; crap. Now I&#039;m finally seeing what the error REALLY is.</description>
		<content:encoded><![CDATA[<p>THANK YOU for this info about the undocumented &#8220;innerException&#8221; crap. Now I&#8217;m finally seeing what the error REALLY is.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
