Re: core.async -- lazy evaluation on take

2015-02-16 Thread Fluid Dynamics
On Monday, February 16, 2015 at 9:42:31 PM UTC-5, Erik Price wrote: > > Yes, the producer’s put will block until the consumer takes, but doesn’t > this still involve an eager initial request (so that the producer will have > something to put in the first place, so that it can block)? > The produc

Re: core.async -- lazy evaluation on take

2015-02-16 Thread Erik Price
Yes, the producer’s put will block until the consumer takes, but doesn’t this still involve an eager initial request (so that the producer will have something to put in the first place, so that it can block)? e ​ On Mon, Feb 16, 2015 at 5:52 PM, wrote: > Make the channel unbuffered, that way it

Re: core.async -- lazy evaluation on take

2015-02-16 Thread janpaulbultmann
Make the channel unbuffered, that way it turns into a rondevouz a la ada and every producer will block until a consumer takes something from it. cheers Jan > On 16.02.2015, at 21:45, Huey Petersen wrote: > > Hello, > > I was playing around with having a lazy sequence abstracting over a paged

core.async -- lazy evaluation on take

2015-02-16 Thread Huey Petersen
Hello, I was playing around with having a lazy sequence abstracting over a paged http request. First off, maybe this is dumb, I dunno, lemme know ;p So (resources "url") returns a seq and no http request is made, but (take 1 (resources "url")) makes a request and (take 50 (resources "url")) ma