Account Options

  1. Sign in
The old Google Groups will be going away soon, but your browser is incompatible with the new version.
Google Groups Home
« Groups Home
slurp on over slow HTTP crashes clojure?
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  4 messages - Collapse all  -  Translate all to Translated (View all originals)
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
 
From:
To:
Cc:
Followup To:
Add Cc | Add Followup-to | Edit Subject
Subject:
Validation:
For verification purposes please type the characters you see in the picture below or the numbers you hear by clicking the accessibility icon. Listen and type the numbers you hear
 
the80srobot  
View profile  
 More options Jul 18 2012, 11:14 am
From: the80srobot <a...@ingenious.cz>
Date: Wed, 18 Jul 2012 08:14:24 -0700 (PDT)
Local: Wed, Jul 18 2012 11:14 am
Subject: slurp on over slow HTTP crashes clojure?

Hello,

I apologize if this isn't the right place to post this.

I've seen slurp exhibit some very strange behavior when querying a
particular URL at certain times of day - it seems that a call to slurp as
such:

(slurp "http://support.clean-mx.de/clean-mx/viruses.php?limit=0,150")

will crash clojure if that site is particularly slow to load. Downloading
the same URL using curl succeeds eventually and the download is just over 2
MB, which shouldn't cause Java to run out of memory, but nevertheless that
is what seems to be happening, as the following is sometimes thrown before
the REPL dies:

Exception in thread "Thread-12" java.lang.OutOfMemoryError: Java heap space

> Bye for now!

I haven't been able to recreate this issue with other URLs. I realize this
isn't much to go on, but has anyone else encountered this problem before?

-Adam


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Colin Jones  
View profile  
 More options Jul 19 2012, 4:40 pm
From: Colin Jones <trptco...@gmail.com>
Date: Thu, 19 Jul 2012 13:40:48 -0700 (PDT)
Local: Thurs, Jul 19 2012 4:40 pm
Subject: Re: slurp on over slow HTTP crashes clojure?

Is this using REPLy / a lein2-previewX repl, by chance? I fixed a memory
leak in REPLy yesterday that happened in long-running command scenarios,
and could have caused this behavior
(see https://github.com/technomancy/leiningen/issues/691 for details).

- Colin


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Devin Walters  
View profile  
 More options Jul 19 2012, 4:41 pm
From: Devin Walters <dev...@gmail.com>
Date: Thu, 19 Jul 2012 16:41:06 -0400
Local: Thurs, Jul 19 2012 4:41 pm
Subject: Re: slurp on over slow HTTP crashes clojure?

I've had this issue when the network I was on was way overloaded. It seems like it might be nice to have it at least fail gracefully. IIRC I switched to using the http lib. It seems like at the very least a graceful failure from slurp would be an improvement.

Cheers,
'(Devin Walters)

On Jul 18, 2012, at 11:14 AM, the80srobot <a...@ingenious.cz> wrote:


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Stuart Sierra  
View profile  
 More options Jul 20 2012, 9:32 am
From: Stuart Sierra <the.stuart.sie...@gmail.com>
Date: Fri, 20 Jul 2012 06:32:22 -0700 (PDT)
Local: Fri, Jul 20 2012 9:32 am
Subject: Re: slurp on over slow HTTP crashes clojure?

The 'slurp' function on a URL dispatches to java.net.HttpURLConnection,
which is pretty primitive as HTTP clients go. If you need to handle slow
sites or large responses, you'll probably be better off with a real HTTP
client library.

-S


 
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »