Re: Clojure web server benchmarks

2013-01-07 Thread Peter Taoussanis
A couple folks asked for higher concurrency numbers, so I've bumped the max to 92. Many of the servers can comfortably hit 500+ on my hardware, but others begin acting erratically. Want to first eliminate the possibility that the trouble is on my end (e.g. OS TCP tuning), then I'll bump the

Re: Copying (immigrating) macros from namespace to namespace

2013-01-07 Thread the80srobot
Stuart, You're right that it breaks identity. How about a different approach then - I can get the list of referred vars from a namespace, and vars can cary metadata. A natural way to add more flexibility would be to add a flag - let's call it :export - to referred vars that I'd like for

Re: what is js/ in clojurescript?

2013-01-07 Thread Peter Taoussanis
I would not rely on this behavior. Follow Clojure's property access conventions. Sorry to dig this up again - would just like to clarify: The idiomatic way of accessing something like `window.location.pathname` then would be (aget js/window location pathname), or nested .- accesses, correct?

Re: what is js/ in clojurescript?

2013-01-07 Thread David Nolen
Yes a warning would be great as well as fixing the examples. Ticket patch welcome. On Monday, January 7, 2013, Peter Taoussanis wrote: I would not rely on this behavior. Follow Clojure's property access conventions. Sorry to dig this up again - would just like to clarify: The idiomatic

Re: what is js/ in clojurescript?

2013-01-07 Thread Peter Taoussanis
Thanks David. Ticket patch welcome. I've been lazy / holding out for the electronic CA, but I'll make a note to come back to this if no one else steps up. Cheers! -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email

ANN - modern-cljs series of tutorial

2013-01-07 Thread Giacomo Cosenza
Hello everyone, after more than a month doing other stuff, I published a new tutorial on clojurescript. This tutorial introduces domina events. Hope it helps My best Mimmo p.s. I also removed the three tutorials that talked about the patch and the test of CLJS compiler. Me and my interns

Re: ANN - modern-cljs series of tutorial

2013-01-07 Thread Giacomo Cosenza
https://github.com/magomimmo/modern-cljs/blob/master/doc/tutorial-08.md as usual I forgot the link.sorry about that mimmo On Jan 7, 2013, at 3:26 PM, Giacomo Cosenza wrote: Hello everyone, after more than a month doing other stuff, I published a new tutorial on clojurescript which

Re: reduce, reduce-kv, map, mapv, reducers/map and nil

2013-01-07 Thread Wolodja Wentland
On Thu, Nov 01, 2012 at 22:34 +0900, Alan Busby wrote: On Thu, Nov 1, 2012 at 8:27 PM, Wolodja Wentland babi...@gmail.com wrote: Oh, fold-into-map and fold-into-map-with would be wonderful and I tried to implement the former along the lines of fold-into-vec, but the performance was

Client-Server comunication with shoreleave

2013-01-07 Thread Francesco Agozzino
Hi all... I'm an italian mathematician/developer and I'm working on a small tutorial on ClojureScript/Clojure. I'd like to give an insight into client server comunication via the shoreleave library and lein ring. Actually, I'd like to validate a email/password with this simple cljs function

Re: Client-Server comunication with shoreleave

2013-01-07 Thread Paul deGrandis
Hi Francesco, Robert Stuttafird's example might help you out: https://github.com/robert-stuttaford/demo-enfocus-pubsub-remote You may also want to use the remote macros on the client side, they might clean up the code for you a bit. (ns CLJS-NS (:require-macros

Re: (seq? x) vr.s (not (empty? x))

2013-01-07 Thread Alexander Pugachev
Hi, sorry for touching this subject, but I have a question which looks to me related to the thread. There is not-empty function in the sequences library. If not-empty is there should we use it instead of (seq c) to check if a sequence is not empty? The doc does not propose to use (not-empty

Convincing employer to go for Clojure

2013-01-07 Thread David Jacobs
Hey guys, As someone who's written Clojure for a couple of years now, I would love to convince my new company to build our platform using Clojure from the start. Clojure is certainly a possibility for our small team, but a few questions will have to be answered before I can convince everyone

Re: (seq? x) vr.s (not (empty? x))

2013-01-07 Thread Sean Corfield
(seq x) will return a sequence if x is not empty, regardless of what type x was, e.g., (seq [1 2 3]) = (1 2 3) (not-empty x) will return the original collection if it is not empty, e.g., (not-empty [1 2 3]) = [1 2 3] If you need a sequence, you'll want to use seq; if you need the original

Re: Convincing employer to go for Clojure

2013-01-07 Thread Sean Corfield
On Mon, Jan 7, 2013 at 3:02 PM, David Jacobs da...@wit.io wrote: 1. Would it be harder to hire if we built our apps with Clojure? More specifically: Hiring for people who know about or already love Clojure/FP is certainly a nice filter for talent, but is it too stringent of a filter? What

Re: reduce, reduce-kv, map, mapv, reducers/map and nil

2013-01-07 Thread Alan Busby
On Tue, Jan 8, 2013 at 12:18 AM, Wolodja Wentland babi...@gmail.com wrote: On Thu, Nov 01, 2012 at 22:34 +0900, Alan Busby wrote: On Thu, Nov 1, 2012 at 8:27 PM, Wolodja Wentland babi...@gmail.com wrote: Oh, fold-into-map and fold-into-map-with would be wonderful and I tried to

ANN: core.logic 0.8.0-rc1

2013-01-07 Thread David Nolen
If you are still using core.logic 0.7.5 now's a good time to try the latest :) From 0.8.0-beta5 to 0.8.0-rc1 Enhancements * Add `seqc` constraint, this is preferred over `listo` as found in TRS Bux Fixes * LOGIC-100: undiscard diseqality constraints * LOGIC-101: fix suprising

Re: Convincing employer to go for Clojure

2013-01-07 Thread Gert Verhoog
On 8/01/2013, at 12:02 PM, David Jacobs wrote: 1. Would it be harder to hire if we built our apps with Clojure? More specifically: Hiring for people who know about or already love Clojure/FP is certainly a nice filter for talent, but is it too stringent of a filter? Finding really good

symbolic protocols

2013-01-07 Thread kovas boguta
This is a pretty embryonic idea, but I'm wondering if anyone has thought the same, or seen relevant examples/literature. The idea is: What if we could attach protocols to symbols themselves? so (foo '(bar 1)) would have its behavior defined by a protocol implemented on the symbol bar. This

Re: symbolic protocols

2013-01-07 Thread kovas boguta
one example use case: validating expressions (valid? '(foo (bar 1))) - protocol implemented by foo decides if it likes its argument structure various semantics about the symbol can be encoded in the protocols. On Tue, Jan 8, 2013 at 1:56 AM, kovas boguta kovas.bog...@gmail.com wrote: This is

Re: Convincing employer to go for Clojure

2013-01-07 Thread Devin Walters
You say an employer without saying our employer. Without a doubt, a *team* must be convinced of Clojure first. Assuming your team is convinced, then my argument is this: You will attract better, smarter people by shifting your company toward Clojure. Avoiding it is comfortable, but ignoring

Re: symbolic protocols

2013-01-07 Thread kovas boguta
Close. The defmulti would be closer to (defmulti mm first) because we need to dig into the list to get the first symbol. But there need to be a way to recurse as well, if you want to interprete the whole expression. That part is hard to capture in the multimethod. (interprete '(foo (bar 1)))

core.logic: datomic unification

2013-01-07 Thread Austin Haas
The datomic unification code in core.logic has bit-rotted. It depends on IUnifyWithSequential, which was removed in this commit: https://github.com/clojure/core.logic/commit/bbc4e820128d5a0745ce3d79cd3bbd9401a1bf55 I'm trying to understand how to update the code, but I don't get how

Re: symbolic protocols

2013-01-07 Thread kovas boguta
Maybe the use cases would be more clearer if I fleshed out the interprete operation. The typical case would be (interprete expression [protocol1 protocol2 protocol3 ...]) interprete would limit its operation the protocols specified; everything else would be inert. To implement compiler passes,

Unit testing

2013-01-07 Thread Eric MacAdie
Is there a common unit testing framework for Clojure? I did some googling, put all the results were a couple of years old. - Eric MacAdie -- You received this message because you are subscribed to the Google Groups Clojure group. To post to this group, send email to clojure@googlegroups.com