[ANN] Ring-jetty9-adapter(rj9a) updated with HTTP2 support

2015-07-26 Thread Ning Sun
-BEGIN PGP SIGNED MESSAGE- Hash: SHA256 Hi all, I am pleased to announce the 0.9 release of ring-jetty9-adapter(rj9a): https://github.com/sunng87/ring-jetty9-adapter The new version is based on Jetty 9.3.1, which means you will be able to run your existed clojure web application on HTTP

Re: [ANN] Ring-jetty9-adapter(rj9a) updated with HTTP2 support

2015-07-26 Thread Max Penet
Hi, It doesn't seem to work for me, I get " invalid_preface" error returned by the server (tried with latest firefox, chrome, chromium on linux). I will give nghttp2 a go, maybe me env is somehow busted, but other http2 websites (webtide, google etc) work fine on http2. Cheers, Max On Su

Creating a jar file based on a profile's :source-paths

2015-07-26 Thread khaled . kebbe
As per the subject, is there a way to generate a jar file that consists of only the source files specified within a profile for example: :source-paths ["xyz"] :profiles {:a_profile {:main a.b.c :name abc :source-paths ["abc"]} } Basically, all I want to be able to do

Java 8 Lambda Interop

2015-07-26 Thread Andrew Oberstar
Hi, I'm wondering if anyone has a good approach for making calls from Clojure to Java APIs (e.g. Stream API) that expect a @FunctionalInterface type. Ideally, IFn would transparently work, but I'm guessing that requires some compiler changes. Right now, the best I can think of is a function or m

New ring middleware: browser-caching

2015-07-26 Thread Stephen Lester
Hello everyone, I just wrote my first ring middleware (I'm pretty much a newbie to functional programming and Clojure in general), and I'd appreciate if someone wants to give me some tips or constructive criticism (and it can be off-list as well). The goal is to enable per-file-type browser

Re: What is the best way to pass log configs everywhere without a global var?

2015-07-26 Thread James Reeves
On 25 July 2015 at 15:50, crocket wrote: > Logging libraries seem to rely on a global config. This looks like a > dangerous state that could blow up. > I researched a little, and there seems to be reader monad and dependency > injection, all of which feel awkard. > > Is there not a decent approac

Re: What is the best way to pass log configs everywhere without a global var?

2015-07-26 Thread crocket
How those logs are outputted is stored in a global state called log configuration. So, I think the separation was done. How else do you want to separate that? On Mon, Jul 27, 2015 at 12:20 PM, James Reeves wrote: > On 25 July 2015 at 15:50, crocket wrote: >> >> Logging libraries seem to rely on

Re: What is the best way to pass log configs everywhere without a global var?

2015-07-26 Thread Mikera
On Saturday, 25 July 2015 22:50:55 UTC+8, crocket wrote: > > Logging libraries seem to rely on a global config. This looks like a > dangerous state that could blow up. > I researched a little, and there seems to be reader monad and dependency > injection, all of which feel awkard. > > Is there no

Re: What is the best way to pass log configs everywhere without a global var?

2015-07-26 Thread James Reeves
On 27 July 2015 at 05:25, crocket wrote: > How those logs are outputted is stored in a global state called log > configuration. So, I think the separation was done. > How else do you want to separate that? > Traditionally, logging code is written something like: (log/info "HTTP request to"