Re: Implementing a Oauth2 provider with clauth and friend

2014-12-15 Thread Sebastian Bensusan
Hi Dave, I am planning to use friend-oauth2 to handle "third party workflows". It is exactly what I need to consume third party oauth services, but from what I understood from the source code, it doesn't help me offer my own oauth service. I'm struggling with the design for an oauth service th

Re: Memoize in the real world

2014-12-15 Thread Andy Dwelly
It looks very similar to the pattern I was trying to avoid in the first place. I've also got the problem of multiple threads (and its been pointed out that my original solution was not thread safe). In my experience bugs of an 'extremely rare but could conceivably happen' nature are the sort of

Re: Implementing a Oauth2 provider with clauth and friend

2014-12-15 Thread Dave Della Costa
I'm a bit confused--if you are building your own oauth2 server (correct me if I misunderstood--you want users to use oauth2 to authenticate against your own service?), what purpose does a Friend workflow have in this context? Seems like you could skip Friend altogether. DD (2014/12/15 17:40), Se

Re: Handling increasingly-intensive processes

2014-12-15 Thread Thomas Heller
Hey, without knowing much about your application/business needs its hard to speculate what might be good for you. The root of your problem might be CouchDB since it was never meant for "Big Data" and since we are talking tweets I generally think "a lot". I'm not sure how your map value looks bu

Re: Implementing a Oauth2 provider with clauth and friend

2014-12-15 Thread Sebastian Bensusan
Users should also be able to authenticate using my site credentials OR Linkedins. I thought friend-oauth would be useful to allow the Linkedin authentication. I am a little lost on where to start. I could start from my own auth and then add Linkedin to it with friend, or start with friend and a

Re: Implementing a Oauth2 provider with clauth and friend

2014-12-15 Thread Sam Ritchie
I've just implemented this with Facebook login on a single-page app using Om and Sente. I'm planning on writing it up (who ISN'T planning on writing up all their open source stuff in glorious detail? Imagine the blog posts!!), but before I get around to code I can offer my little state flow cha

Re: Mocking java class for test.

2014-12-15 Thread James Reeves
The easiest way would be to wrap the class constructor in a function and override that. - James On 15 December 2014 at 04:20, Eunmin Kim wrote: > Hi! My question is, How can I exchange a java class for test like > `with-redefs`? > > (defn run-a > [] > (... some logic > (.run (AClass. )

Re: Memoize in the real world

2014-12-15 Thread Sergey Didenko
As I understand this var approach is used for development purposes, so in theory it should not occur in production. I wonder though why someone would prefer it to atoms. -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email

New Functional Programming Job Opportunities

2014-12-15 Thread Functional Jobs
Here are some functional programming job opportunities that were posted recently: Front End Developer at RVspotfinder.com http://functionaljobs.com/jobs/8772-front-end-developer-at-rvspotfindercom Cheers, Sean Murphy FunctionalJobs.com -- You received this message because you are subsc

[ANN] Signals - 0.1.0

2014-12-15 Thread Steven Yi
Hi All, I'd like to announce a new Clojure library called Signals: http://github.com/kunstmusik/signals This is a library for working with time-varying signals (mutable data). It's designed with the view that Clojure's IDeref's (i.e. atoms, refs, agents) are time-varying signal sources. It use

Re: Implementing a Oauth2 provider with clauth and friend

2014-12-15 Thread Sebastian Bensusan
Thanks Sam. The gist is very helpful (as well as the Friend + Liberator post). I see you are generating and maintaining your own tokens (" exchange for long-lived token"). Did you write custom code for this or is there some library I should look at? Sebastian -- You received this message

Re: Implementing a Oauth2 provider with clauth and friend

2014-12-15 Thread Sam Ritchie
That's actually the Facebook token. Facebook's JS API will give you a token that lasts for about an hour. You have to use your app's ID and secret to make a server-side request and upgrade that short token to a long-lived (~60 day) token. I'm not acting as an OAuth provider, just storing crede