Re: Is Clojure right for me?

2013-12-27 Thread Robert Levy
Mark, Your comment "Clojure's namespaces are quite limited in ways that frequently cause me pain" brings to mind Daniel Spiewak's talk on modularity in functional languages: http://2013.flatmap.no/spiewak.html. It might be interesting to Massimiliano as well. Spiewak is actually criticizing Haske

Re: Is Clojure right for me?

2013-12-27 Thread Mark Engelberg
Yes! This is very much what I'm talking about. When we talk about why we don't need classes in Clojure, we're usually talking about how we have better tools for inheritance, polymorphism, encpasulation, mutable state, etc. But classes are also powerful namespaces, and Clojure's namespaces aren't

Re: Is Clojure right for me?

2013-12-27 Thread Walter van der Laan
First, regarding OO. When programming Clojure I never think about adding objects to the application, I think "how can I extend the language so it is better tailored to my application domain?". And for a lot of domains good libraries are already available. So, for the example that you gave I woul

Re: Finding available methods or docs for a value type

2013-12-27 Thread Niels van Klaveren
Anthony Grimes made a find-fn that finds functions based on input parameters and output functions. So something like (find-fn clojure.core [1 2] {:a 1 :b 2}) would return vals and (find-fn clojure.core [:a :b] {:a 1 :b 2}) would return keys. It would be great

Re: Finding available methods or docs for a value type

2013-12-27 Thread Matching Socks
How does it do that?! >From the README at the linked page: "what it does is take input arguments and an expected output, and it tries out every function and macro in a set of namespaces, collecting the names of the ones that produce the output for the input arguments passed." Cool! But... le

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
The point is that Clojure is not the only modern language out there. I can't possibly learn them all in depth just to decide which language to use for my production code. That would be time-inefficient because my goal in not to learn languages, but to pick up a new language suitable for my needs

Re: Is Clojure right for me?

2013-12-27 Thread John Chijioke
Words play a very important role in expressing ideas. For me, I think clojure is mostly about ideas. A way of doing things. For me clojure was intuitive from day one. The notion of programming with functions applied to data. So in clojure data structures are emphasized as a way of representing

Akka-like framework in Clojure ?

2013-12-27 Thread Eric Le Goff
Hi, After a long background with imperative languages such as Java, I recently spent some time learning functionnal programming, starting with Scala. I had the opporrtunity to build a demo project based on the Akka framework. Now I am starting learning Clojure, and would be curious to know if the

Re: Akka-like framework in Clojure ?

2013-12-27 Thread Tim Visher
Hi Eric, On Fri, Dec 27, 2013 at 3:54 AM, Eric Le Goff wrote: > After a long background with imperative languages such as Java, I recently > spent some time learning functionnal programming, starting with Scala. I had > the opporrtunity to build a demo project based on the Akka framework. > > Now

Re: Is Clojure right for me?

2013-12-27 Thread Luc Prefontaine
Then we have more in common than you may think :) I learned Ruby first, went through Scala which appeared in the same time frame, all this to pick up the language of choice to replace Java and Ruby which we used to prototype our product. All this took around 9 months including the time to get

Re: Finding available methods or docs for a value type

2013-12-27 Thread Tim Visher
On Fri, Dec 27, 2013 at 6:27 AM, Niels van Klaveren wrote: > Anthony Grimes made a find-fn that finds functions based on input parameters > and output functions. > > So something like (find-fn clojure.core [1 2] {:a 1 :b 2}) would return vals > and (find-fn clojure.core [:a :b] {:a 1 :b 2}) would

Re: Is Clojure right for me?

2013-12-27 Thread Stuart Halloway
Yes, thanks Mark. It seems to me that you are saying "namespaces make poor maps". Stipulated. So why not use records or maps? I think that where my experience differs from yours is summarized in your comment "In Clojure, a project often begins with a bunch of functions sharing some immutable sta

Re: Is Clojure right for me?

2013-12-27 Thread Luc Prefontaine
I would add that you *need* to write some code to get a feeling about a new language. Feature comparisons may help you up to a certain degree. However deciding about how efficient you may become using a new language requires you to dive at least a bit into it. Not all brains are wired the same.

Re: Akka-like framework in Clojure ?

2013-12-27 Thread Jan Herich
Hi Eric, Maybe pulsar is what you are looking for, but i recommend you to also discover the other way of doing concurrency in clojure instead of the actor model -> have a look at CSP and its

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
On Friday, December 27, 2013 7:29:22 AM UTC+1, Sean Corfield wrote: > > On Thu, Dec 26, 2013 at 8:32 AM, Massimiliano Tomassoli > > How do you decompose large systems in Clojure? > > I'm curious as to why you think only OOP allows you to decompose large > systems? Between namespaces, protocols,

Re: Akka-like framework in Clojure ?

2013-12-27 Thread Tibor Mlynarik
Hi Eric, I haven't tried it's Clojure api, but Quasar/Pulsar [1] looks promising. https://groups.google.com/forum/#!msg/clojure/1xxxTti6Vi0/m9HtBXankzUJ cheers, Tibor [1] http://puniverse.github.io/pulsar/ On Friday, December 27, 2013 9:54:16 AM UTC+1, Eric Le Goff wrote: > > > Hi, > > After

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
I've seen Clojure in action and I know it's extremely concise and expressive. What I wanted to know is how it copes with complexity when you develop complex systems. You can't get an idea of that just by writing some code and getting a feeling about the language, IMHO. When I studied OOP at Uni

Re: Is Clojure right for me?

2013-12-27 Thread Malcolm Sparks
I modularize my Clojure systems using Jig: https://github.com/juxt/jig - it's one of many possible approaches. On 27 December 2013 15:23, Massimiliano Tomassoli wrote: > On Friday, December 27, 2013 7:29:22 AM UTC+1, Sean Corfield wrote: > >> On Thu, Dec 26, 2013 at 8:32 AM, Massimiliano Tomasso

Re: Is Clojure right for me?

2013-12-27 Thread Softaddicts
It took us some time to structure the code at the time and now with protocols we went under a other restructuring a year ago. I agree this part can be hard (structuring the code) but at the time we started protocols were not yet there hence some of the restructuring. Best practices also evolved

Re: Is Clojure right for me?

2013-12-27 Thread Mars0i
On Friday, December 27, 2013 10:02:46 AM UTC-6, Massimiliano Tomassoli wrote: > > I've seen Clojure in action and I know it's extremely concise and > expressive. What I wanted to know is how it copes with complexity when you > develop complex systems. > My intuition is that getting rid of or

Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Mark Engelberg
I ended up accidentally injecting a completely different thread of discussion into the "Is Clojure right for me?" thread. I'm breaking it into a separate thread here. Here's where we left off: On Fri, Dec 27, 2013 at 6:34 AM, Stuart Halloway wrote: > Yes, thanks Mark. It seems to me that you ar

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread john walker
I posted this in response to the original gist, but it probably wasn't seen. Does this demonstrate the behavior you want? https://gist.github.com/johnwalker/8142143 On Friday, December 27, 2013 1:08:49 PM UTC-5, puzzler wrote: > > I ended up accidentally injecting a completely different thread

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Cedric Greevey
On Fri, Dec 27, 2013 at 1:08 PM, Mark Engelberg wrote: > > Solution 2: > > (defn foo [shared-info x] ... body uses shared-info) > (defn bar [shared-info x] ... body uses shared-info) > > Call these functions via: > > (foo info 2) > (bar info 3) > In what way is this any worse than info.foo(2); in

Re: Is Clojure right for me?

2013-12-27 Thread Sean Corfield
On Fri, Dec 27, 2013 at 8:02 AM, Massimiliano Tomassoli wrote: > When I studied OOP at > University my professors taught me that OOP was extremely successful in > reducing the complexity of big systems. That's always been the claim about OOP but big systems have an inherent complexity and you can

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Softaddicts
We use a lot of configuration information in our product and I mean lot :) Immutable in regard to the application cycle. We chose to remove this from each name spaces and instead use a name space to act as an intermediate to acces it. It's not as pure as it should be (it's contextually outside o

Recommendations for a project with learning-friendly bugs and devs?

2013-12-27 Thread Jakub Holy
Hello, I'd like to sharpen my Clojure skill by contributing to an open source project and getting feedback on my patches from its developers. Can you recommend a project that would be suitable? Preferably something where there is plenty of beginner-friendly bugs and in the domain of web or devops.

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Gary Trakhman
I can think of a couple more alternatives to consider: ;; Turns out you don't need vars for everything. (let [state {:some :data}] (defn do-stuff [] (func-of state))) ;; Shifts some burden to the client code (defn do-stuff-fn [state] (fn [] (func-of state)) The issue as I see it is a complec

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Mark Engelberg
The thing I like about your record/protocol example version is that all the protocol function implementations can "see" the components of the record and use those names in the implementation without explicit destructuring. That adds significantly to the ease of working with multiple functions shari

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Mark Engelberg
On Fri, Dec 27, 2013 at 10:35 AM, Softaddicts wrote: > Passing this stuff around using one of the two methods you have shown > would have been cumbersome and unmaintainable. Most of the time > our configuration information comes from top level fns so the lower > layers remain even more insensitive

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Mark Engelberg
On Fri, Dec 27, 2013 at 10:27 AM, Cedric Greevey wrote: > On Fri, Dec 27, 2013 at 1:08 PM, Mark Engelberg > wrote: >> >> Solution 2: >> >> (defn foo [shared-info x] ... body uses shared-info) >> (defn bar [shared-info x] ... body uses shared-info) >> >> Call these functions via: >> >> (foo info

Re: Akka-like framework in Clojure ?

2013-12-27 Thread Bruno Kim Medeiros Cesar
I haven't dabbled yet on actor-based concurrency, can someone point out (a blog post about) a comparison between Akka actors, Clojure agents and other solutions? On Friday, December 27, 2013 6:54:16 AM UTC-2, Eric Le Goff wrote: > > > Hi, > > After a long background with imperative languages suc

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Mark Engelberg
On Fri, Dec 27, 2013 at 11:03 AM, Gary Trakhman wrote: > Why should functions share information? > Maybe I'm the odd one out, but every project I've done has at least a few bits of info shared by many functions. It might be something like BUFFERSIZE or NUM-THREADS or DATABASE_URL. Basically, th

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
That makes me think that maybe there's a need for more books about Clojure. There are many introductory books but nothing more advanced such as best practices, patterns, etc... That's maybe a problem for someone like me who wants to "do things right" from the start. Should I read books about Com

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread john walker
I investigated a few of these. Variable arity functions don't some to work, but destructuring and parameter number seem unaffected. https://gist.github.com/johnwalker/8151474 I suspect that what I wrote below is possible with multimethods. (defrecord foobarrecord foobarprotocol :declare

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Luc Prefontaine
We have a good basis with versioning. 99% of the time, workers are the ones accessing the configuration. They are at the top level. It happens that they do access configuration through the workers service name space. In fact through a single fn ... Passing a version number when pulling out a r

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread kovas boguta
On Fri, Dec 27, 2013 at 2:03 PM, Gary Trakhman wrote: > The issue as I see it is a complection of namespaces (DAG of bags of > functions) and individual object lifecycles. The grid size stuff impl is a This is a very fair point, and something people have worked on Check out https://github.com

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread guns
On Fri 27 Dec 2013 at 11:40:45AM -0800, Mark Engelberg wrote: > On Fri, Dec 27, 2013 at 11:03 AM, Gary Trakhman > wrote: > > > Why should functions share information? > > Maybe I'm the odd one out, but every project I've done has at least a few > bits of info shared by many functions. It might be

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Cedric Greevey
On Fri, Dec 27, 2013 at 2:32 PM, Mark Engelberg wrote: > On Fri, Dec 27, 2013 at 10:27 AM, Cedric Greevey wrote: > >> On Fri, Dec 27, 2013 at 1:08 PM, Mark Engelberg > > wrote: >>> >>> Solution 2: >>> >>> (defn foo [shared-info x] ... body uses shared-info) >>> (defn bar [shared-info x] ... body

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread john walker
This works (clever hack!), but you would have to reduplicate the keys in (defn bar [..]...), (defn baz [...] ...) etc. On Friday, December 27, 2013 3:05:24 PM UTC-5, Cedric Greevey wrote: > > On Fri, Dec 27, 2013 at 2:32 PM, Mark Engelberg > > > wrote: > >> On Fri, Dec 27, 2013 at 10:27 AM, Ced

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
On Friday, December 27, 2013 7:31:25 PM UTC+1, Sean Corfield wrote: > > I'm not sure why you are less trusting of their > real world experiences than what your professors told you about > (theoretical) OOP... > First, someone said that OOP doesn't alleviate the problems that it's supposed to s

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Cedric Greevey
On Fri, Dec 27, 2013 at 3:13 PM, john walker wrote: > This works (clever hack!), but you would have to reduplicate the keys in > (defn bar [..]...), (defn baz [...] ...) etc. > (defmacro defthingyfn [name arglist & body] `(defn name ~(vec (cons '{:keys [thingy mumble fiddly]} arglist)) ~@body))

Re: Is Clojure right for me?

2013-12-27 Thread Sean Corfield
On Fri, Dec 27, 2013 at 12:24 PM, Massimiliano Tomassoli wrote: > First, someone said that OOP doesn't alleviate the problems that it's > supposed to solve and this I don't believe. There is no silver bullet: OOP helps with some problems in some ways but it's not perfect. The folks who pioneered

Re: Is Clojure right for me?

2013-12-27 Thread Luc Prefontaine
I am kind of old school. To me these things come through practice... Which I understand maybe of little help to you in the immediate future :) When I was young we had many books that had little to do with the ones mostly available today. (Learn xxx in nnn days) Looks to me that this is the missi

Re: Is Clojure right for me?

2013-12-27 Thread Mark Engelberg
With a little searching, you can find several papers like this one that research the question of whether OO has lived up to the hype: http://scholarworks.gvsu.edu/cgi/viewcontent.cgi?article=1129&context=cistechlib Feel free to jump straight to the conclusion, i.e., "object-oriented technology has

Re: Is Clojure right for me?

2013-12-27 Thread john walker
Err, a lot of these questions are quite open in nature. I don't think anyone in software engineering has great answers - see "Everything is an Object" for Javaland and then some of the proposals in Doug Hoyte's Let Over Lambda (an excellent read if you're after Common Lisp books and recognize t

Re: Is Clojure right for me?

2013-12-27 Thread Mark Engelberg
Luc, I've just got to say, your tiny margin widths always make me think your message is some kind of haiku :) On Fri, Dec 27, 2013 at 1:08 PM, Luc Prefontaine < lprefonta...@softaddicts.ca> wrote: > I am kind of old school. > To me these things come through > practice... > > Which I understand m

Re: Is Clojure right for me?

2013-12-27 Thread Gary Trakhman
brain-dump TLDR: I like clojure's costs-to-benefits.. and it's successful because it's what the industry needs. I wouldn't say lisp family langs are the 'best' languages, but I would say its tradeoffs maximize the power of the individual, which interests me since I am one :-). Talking about tr

In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Kelker Ryan
In your opinion, what's the best, and what's the worst aspects of using Clojure? -- -- 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 Note that posts from new members are moderated - please

Re: Is Clojure right for me?

2013-12-27 Thread Patrick Kristiansen
Maybe it would be helpful to define what exactly you mean by OOP. Use this list: http://www.paulgraham.com/reesoo.html Clojure supports some of the constructs that people typically relate to OOP. Decomposing large systems: How do you decompose large systems with OOP? By using classes and object

Re: Is Clojure right for me?

2013-12-27 Thread Jeff Heon
Given your goals of evaluating the language quickly, not having a lot of free time to devote to it, and having to get productive fast in a web environment, I think a better avenue to explore would be Groovyalongside Spring Boot

Re: Is Clojure right for me?

2013-12-27 Thread Luc Prefontaine
Been writing these on my iPhone most of the day and if I do not cut lines myself, it looks pretty ugly on my side :) I am pretty bad at writing poetry, glad to see I could fake at it :) Luc P. > Luc, I've just got to say, your tiny margin widths always make me think > your message is some kind

Re: Clojure can't import some Java classes

2013-12-27 Thread Zach Oakes
Yeah I tried this with RoboVM, but there are so many classes that needed to be stubbed that it turned into an endless rabbit hole, so I gave up. It may be a good solution for those who just have one or two problematic classes, though. On Thursday, December 26, 2013 8:37:44 PM UTC-5, Colin Flemi

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread Timothy Baldridge
+1 for Stuart's component lib. I've been using it a lot in my day job and it works quite well. It also serves as a reminder not to throw global config values into vars. Building code that works well with the library makes it less natural to put random state values in globals. Timothy On Fri, De

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Daniel
Best: Language & Community Worst: Error Reporting On Friday, December 27, 2013 3:17:48 PM UTC-6, Kelker Ryan wrote: > > In your opinion, what's the best, and what's the worst aspects of using > Clojure? > -- -- You received this message because you are subscribed to the Google Groups "Clojure

Re: Akka-like framework in Clojure ?

2013-12-27 Thread Paulo Suzart
Hi, Am I wrong or Galaxy project (behind pulsar) is quite inactive? Does anybody know how promising are they? Cheers On 27 December 2013 17:32, Bruno Kim Medeiros Cesar wrote: > I haven't dabbled yet on actor-based concurrency, can someone point out (a > blog post about) a comparison between A

Re: Akka-like framework in Clojure ?

2013-12-27 Thread Alex Baranosky
You can just use Akka directly w/ Clojure's excellent Java interop. On Fri, Dec 27, 2013 at 3:48 PM, Paulo Suzart wrote: > Hi, > > Am I wrong or Galaxy project (behind pulsar) is quite inactive? Does > anybody know how promising are they? > > Cheers > > > On 27 December 2013 17:32, Bruno Kim Me

Re: Akka-like framework in Clojure ?

2013-12-27 Thread Sean Corfield
I got the impression - from talking to someone who tried to wrap Akka in Clojure - that Akka's API was pretty nasty to use from Clojure? Sean On Fri, Dec 27, 2013 at 3:54 PM, Alex Baranosky wrote: > You can just use Akka directly w/ Clojure's excellent Java interop. > > > On Fri, Dec 27, 2013 at

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread James Reeves
On 27 December 2013 18:08, Mark Engelberg wrote: > > On Fri, Dec 27, 2013 at 6:34 AM, Stuart Halloway < > stuart.hallo...@gmail.com> wrote: > >> Yes, thanks Mark. It seems to me that you are saying "namespaces make >> poor maps". Stipulated. So why not use records or maps? >> > > This is close,

Re: How do I serve clojure pages with nginx

2013-12-27 Thread Zeynel
Thank you, this is great, exactly what I was looking for. I had a few issues but I solved them and it is all set as you described, but I am unable to run it with $ start . I created /etc/init/nomilkfor.me.conf (this is the domain name) and this is what is in the file: description "ubuntu 13.10

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
On Friday, December 27, 2013 10:07:14 PM UTC+1, Sean Corfield wrote: > > On Fri, Dec 27, 2013 at 12:24 PM, Massimiliano Tomassoli > > So I was under the impression that you were criticizing something you > didn't > > fully understand. > > Perhaps you've been convinced otherwise now? I feel that

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
On Friday, December 27, 2013 10:12:06 PM UTC+1, john walker wrote: > > What are some flaws that you think Clojure has? : ) > I don't even know the language yet! :) -- -- You received this message because you are subscribed to the Google Groups "Clojure" group. To post to this group, send email

Re: Clojure can't import some Java classes

2013-12-27 Thread Aaron Cohen
I have the sneaking suspicion that this may be as simple as changing https://github.com/clojure/clojure/blob/master/src/jvm/clojure/lang/Compiler.java#L697 to: final static Method forNameMethod = Method.getMethod("Class *classForNameNonLoading*(String)"); and making "classForNameNonLoading" pu

Re: How do I serve clojure pages with nginx

2013-12-27 Thread James Reeves
Perhaps try nomilkforme.conf instead of nomilkfor.me.conf ? - James On 28 December 2013 00:27, Zeynel wrote: > Thank you, this is great, exactly what I was looking for. I had a few > issues but I solved them and it is all set as you described, but I am > unable to run it with $ start . > > I c

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
On Friday, December 27, 2013 10:47:35 PM UTC+1, Jeff Heon wrote: > > Given your goals of evaluating the language quickly, not having a lot of > free time to devote to it, and having to get productive fast in a web > environment, > I think a better avenue to explore would be > Groovy

Re: Is Clojure right for me?

2013-12-27 Thread Mars0i
On Friday, December 27, 2013 6:27:34 PM UTC-6, Massimiliano Tomassoli wrote: > > I must admit I don't like its syntax (or absence of it), but I hope to get >> used to it. >> > This is understandable. I think that the things that are most important for becoming comfortable with the syntax, other

Re: How do I serve clojure pages with nginx

2013-12-27 Thread Ahmet Zeynel
I just tried it but I got the same error. Do I need to add exec or script in the conf file? Thanks. On Fri, Dec 27, 2013 at 9:20 PM, James Reeves wrote: > Perhaps try nomilkforme.conf instead of nomilkfor.me.conf ? > > - James > > > On 28 December 2013 00:27, Zeynel wrote: > >> Thank you, this

Re: How do I serve clojure pages with nginx

2013-12-27 Thread James Reeves
The script looks fine... Are you executing "start nomilkforme" as root or with sudo? Do you have a "deploy" user and a "/deploy" directory? - James On 28 December 2013 01:33, Ahmet Zeynel wrote: > I just tried it but I got the same error. Do I need to add exec or script > in the conf file? Tha

Re: Is Clojure right for me?

2013-12-27 Thread Massimiliano Tomassoli
On Saturday, December 28, 2013 2:26:17 AM UTC+1, Mars0i wrote: > > On Friday, December 27, 2013 6:27:34 PM UTC-6, Massimiliano Tomassoli > wrote: >> >> I must admit I don't like its syntax (or absence of it), but I hope to >>> get used to it. >>> >> > This is understandable. I think that the th

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Guru Devanla
Seconded on Error reporting. I have been playing around with Clojure for sometime now and also completed almost 150 of the 4clojure problems. What still scars me in terms of incorporating Clojure as a language of choice in more complicated projects I work on in my other life, is the error reportin

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Guru Devanla
Ok, wanted to be clear that I do support the Best part of language so far has been the Language itself and community! On Fri, Dec 27, 2013 at 5:48 PM, Guru Devanla wrote: > Seconded on Error reporting. > > I have been playing around with Clojure for sometime now and also > completed almost 150

Re: How do I serve clojure pages with nginx

2013-12-27 Thread Ahmet Zeynel
I don't think I have a "deploy" user but I have a /deploy directory with the following content: z@ubuntu:/deploy$ ll total 8164 drwxr-xr-x 2 zz 4096 Dec 27 08:20 ./ drwxr-xr-x 24 root root4096 Dec 27 08:09 ../ -rw-r--r-- 1 zz8351715 Dec 27 08:20 my-webapp-0.1.0-standalone.j

Re: Is Clojure right for me?

2013-12-27 Thread Alexis Gallagher
Hi Massimiliano, Perhaps I'm a bit late to this thread but let me offer an opinion going in the opposite direction. Basically, if the web development you have in mind fits squarely within the use case addressed by RoR or Django or something like that, then I expect you will find one of those f

Re: How do I serve clojure pages with nginx

2013-12-27 Thread Alexis Gallagher
It's not free, but Kevin Lynagh sells a collection of nicely packaged and documented examples of basic dev ops setups. The package on server config illustrates exactly what you are asking for: deploying a Clojure web app behind nginx, with some monitoring, server-hardening, etc.. It's at: https

The SEO Holy Grail: shared client- and server-side rendering using Om/React.js

2013-12-27 Thread Brendan Younger
Hi all, With David Nolen's recent announcement of Om, he hinted that it might be possible to some day use the same templating/rendering logic on the server as on the client. I was inspired to see how possible this was and, after a few days of hacking on it, I'd like to share Omkara

Re: Clojure can't import some Java classes

2013-12-27 Thread Colin Fleming
Wow, that works! You just saved me an extraordinary amount of pain - thank you! I had to make one further small change, to invoke the method on RT instead of Class, but that was it. On 28 December 2013 14:16, Aaron Cohen wrote: > I have the sneaking suspicion that this may be as simple as chan

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Sean Corfield
Whilst the stacktraces can be pretty painful at times - esp. if you're dealing with lazy sequences - they do include filenames and line numbers, at least when you're outside the REPL. There are also a number of tools to clean up stack traces to show only Clojure-related entries and/or color-code th

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Alex Baranosky
I always hear people say that the errors are bad, but I just don't see it. The stacktraces say exactly what went wrong and at what line of the source. To me that's all I can hope for. I think there may have been some more obtuse errors that came up in older versions of Clojure that have since bee

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Lee Spector
On Dec 27, 2013, at 10:53 PM, Alex Baranosky wrote: > I always hear people say that the errors are bad, but I just don't see it. > The stacktraces say exactly what went wrong and at what line of the source. > To me that's all I can hope for. One can hope to see the values of locals, which for

Re: Akka-like framework in Clojure ?

2013-12-27 Thread kovas boguta
The bottom line is that the definitive clojure distributed computing solution is yet to be invented, but there are a number of things out there including the aforementioned. 1. clojure wrappers for Akka, for instance https://github.com/jasongustafson/akka-clojure (there are several others, of va

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Alex Baranosky
Lee, Sure, it'd be nice to have a functioning debugger, I'll give you that. On Fri, Dec 27, 2013 at 8:03 PM, Lee Spector wrote: > > On Dec 27, 2013, at 10:53 PM, Alex Baranosky wrote: > > I always hear people say that the errors are bad, but I just don't see > it. The stacktraces say exactly

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread guns
On Fri 27 Dec 2013 at 11:03:20PM -0500, Lee Spector wrote: > On Dec 27, 2013, at 10:53 PM, Alex Baranosky wrote: > > > I always hear people say that the errors are bad, but I just don't > > see it. The stacktraces say exactly what went wrong and at what line > > of the source. To me that's all I c

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Lee Spector
On Dec 27, 2013, at 11:18 PM, guns wrote: > > I personally use the following macro from my user.clj: > > (defmacro dump-locals [] > `(clojure.pprint/pprint > ~(into {} (map (fn [l] [`'~l l]) (reverse (keys &env)) > > It's not the automatic break-on-exception-and-start-local-repl of CL

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread guns
On Fri 27 Dec 2013 at 11:23:22PM -0500, Lee Spector wrote: > > On Dec 27, 2013, at 11:18 PM, guns wrote: > > > > I personally use the following macro from my user.clj: > > > > (defmacro dump-locals [] > > `(clojure.pprint/pprint > > ~(into {} (map (fn [l] [`'~l l]) (reverse (keys &env)) >

Re: Namespaces [was Re: Is Clojure right for me?]

2013-12-27 Thread John Chijioke
James Reeves has got it. It's same for me. All this boils down to really knowing the language. Knowing how to make music with the instruments provided. For me Clojure's namespaces has been one of the most wonderful things that has happened to me in programming. It has facilitated all kinds of e

Re: Clojure can't import some Java classes

2013-12-27 Thread Zach Oakes
Definitely exciting to hear that it works. Is this something you could propose as a patch on the Clojure JIRA? On Friday, December 27, 2013 9:52:04 PM UTC-5, Colin Fleming wrote: > > Wow, that works! You just saved me an extraordinary amount of pain - thank > you! > > I had to make one further s

Re: In your opinion, what's the best, and what's the worst aspects of using Clojure?

2013-12-27 Thread Colin Fleming
I think the error complaints are generally more about the errors when you have something wrong in your code. Things like parsing of ns forms has little to no error checking, and you can get some extremely obscure errors. For example if you (or some tool) places an :import clause ahead of your NS do

Re: Clojure can't import some Java classes

2013-12-27 Thread Colin Fleming
Absolutely, although with this fix execution doesn't work properly (for example, the tests fail because when you import a gen-class'ed class its namespace isn't loaded). However it would be good to be able to toggle it via a system property or something for compilation purposes. It's possible that