mwilliams-right_http_connection 1.2.101 → 1.2.102
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION +1 -1
- data/lib/right_http_connection.rb +2 -2
- metadata +1 -1
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
1.2.
|
1
|
+
1.2.102
|
@@ -382,12 +382,12 @@ them.
|
|
382
382
|
# EOFError means the server closed the connection on us.
|
383
383
|
rescue EOFError => e
|
384
384
|
@logger.debug("#{err_header} server #{@server} closed connection")
|
385
|
+
finish
|
385
386
|
|
386
387
|
# if we have waited long enough - raise an exception...
|
387
388
|
if raise_on_eof_exception?
|
388
389
|
exception = get_param(:exception) || RuntimeError
|
389
390
|
@logger.warn("#{err_header} raising #{exception} due to permanent EOF being received from #{@server}, error age: #{Time.now.to_i - eof_time.to_i}")
|
390
|
-
# @http = nil (may be required)
|
391
391
|
raise exception.new("Permanent EOF is being received from #{@server}.")
|
392
392
|
else
|
393
393
|
# ... else just sleep a bit before new retry
|
@@ -396,6 +396,7 @@ them.
|
|
396
396
|
reset_fileptr_offset(request, mypos)
|
397
397
|
end
|
398
398
|
rescue Exception => e # See comment at bottom for the list of errors seen...
|
399
|
+
finish
|
399
400
|
# if ctrl+c is pressed - we have to reraise exception to terminate proggy
|
400
401
|
if e.is_a?(Interrupt) && !( e.is_a?(Errno::ETIMEDOUT) || e.is_a?(Timeout::Error))
|
401
402
|
@logger.debug( "#{err_header} request to server #{@server} interrupted by ctrl-c")
|
@@ -403,7 +404,6 @@ them.
|
|
403
404
|
elsif e.is_a?(ArgumentError) && e.message.include?('wrong number of arguments (5 for 4)')
|
404
405
|
# seems our net_fix patch was overriden...
|
405
406
|
exception = get_param(:exception) || RuntimeError
|
406
|
-
# @http = nil (may be required)
|
407
407
|
raise exception.new('incompatible Net::HTTP monkey-patch')
|
408
408
|
end
|
409
409
|
# oops - we got a banana: log it
|