Best products from r/Clojure

We found 27 comments on r/Clojure discussing the most recommended products. We ran sentiment analysis on each of these comments to determine how redditors feel about different products. We found 24 products and ranked them based on the amount of positive reactions they received. Here are the top 20.

Top comments mentioning products on r/Clojure:

u/afmoreno · 3 pointsr/Clojure

The most amazing demo I've seen at a meetup was done with Overtone. Whether or not to pursue Clojure or Python is a matter of taste/inclination. I think it would be really hard a priori to determine it since it requires a fair amount of exposure to decide whether or not you are interested in computing as an intellectual exercise.

If you think you'll end up writing code a fair amount, then this is like any trade: invest in good tools to get professional results. In my opinion, Clojure is the superior tool (compared with Python).

Both Python and Clojure claim Lisp as an antecedent but Clojure has these "killer features":

  • macros: the ability to add new features to the language. One way to program in Lisp is to design a Domain Specific Language so you can interact with your problem using its language, not some arbitrary computer language.
  • literal syntax: think of this as a way to describe sets and other data structures that are core to programming. Here Python is great but Clojure is better!
  • very thoughtful design of its data structures so that you can move up and down a ladder of abstraction to pick, say, the right type of collection for your problem (e.g. a list vs. a vector)
  • functional programming is encouraged and supported with immutable data types. Not having immutable data types makes life really hard because one has to deal with values that change over time. If your domain is music, where time is of the essence (pardon the pun), I would think that immutability would be important to you.
  • Clojure runs on the browser (ClojureScript). This means that you can write all your code in one language (if you end up doing a lot of it, then this matters).

    Python is really nice but after having worked with it for years, I felt that I could do better. Things that pushed me away:

  • Writing DSLs is not the default. Sure, one can use parsers and create a grammar, but this is more like building a programming language instead of a DSL. (Sure, there is method overloading which one can take pretty far...)
  • Immutability: for my domain (processing data with a time dimension) it was very painful to keep track of values since the only efficient data structures were mutable. The core issue that I had debugging was that I had a hard time tracking when the data changed. Having immutable values provides a dead-simple solution to the problem of history.

    I wholeheartedly recommend reading SICP to anyone who ends up writing code in Lisp because it is a great way to expand one's mental model of what's possible in terms of capturing abstraction in code. And I think Scheme is a really nice language to learn. If you are interested, you might want to look at The Little Schemer. I have found Chez Scheme (now free) to be excellent.

    Good luck--feel free to write if you have any questions.

    Cheers! afm
u/ToasterImp · 3 pointsr/Clojure

I've never read Joy of Closure, but the book that really helped me was Programming Clojure by Stuart Halloway. That book helped me get up and running with the basics of Clojure pretty quickly.

DiomedesTydeus gives excellent advice on how to introduce Clojure into the workplace and I'd wholeheartedly recommend his approach. It's close to the path I took when introducing Clojure into my current job, and I was able to have a good deal of success using many of the techniques he mentions.

One thing I'll add that may be of use to you is this: When I introduced Clojure to my workplace I back doored it by creating a ton of useful utilities that could run via an executable jar or script. When people asked for changes or information on how to add a particular feature, I went into full evangelism mode walking them through the REPL, etc. explaining how simple it was to test their ideas before writing a line of code. Within weeks the Stash repositories for my utilities had a large number of pull requests from my peers with lots of useful updates. Not long after that I was asked to do a presentation to our architectural review board on web development in Clojure. Since then our management has bought into Clojure now that they see how it allows us to complete work faster and knowledge transfer amongst new team members is quicker since the code is easier to understand. Now we're using it for small projects and with every success the resistance to the language across the firm drops.

u/MR_ZORRR · 1 pointr/Clojure

Thanks, nice article!


I'd like to point out jonase/kibit for brevity concerns. Figuring out the brief form of a long expression is as much a matter of skill than a matter of taste in my opinion. For those of us that are lacking in any of those departments, automation brings a limited answer.


 


Also, since there's a dinoZORRR in the room (Strunk and White), allow me to recommend The Sense of Style by Steven Pinker, the best english style guide I've ever read.

u/gtani · 2 pointsr/Clojure

there's lots of good replies (this is a great subreddit!). A common reply is not to worry about it, start with pure clojure code written clojuristically (immutable bindings, lein/emacs, fully utilize the REPL) and worry about java when you need the interop or you're plowing through large datasets. (the Oreilly and Pragmatic and the 2 Manning books are great for that, especially first 2)

Also check on SO, where lots of people have opined about being new to clojure, jruby, scala, etc adn the Marx blog, one of my favs

http://stackoverflow.com/questions/4230746/does-being-a-competent-scala-programmer-require-you-to-be-a-competent-java-progra

http://stackoverflow.com/questions/4741626/what-parts-of-the-java-ecosystem-and-language-should-a-developer-learn-to-get-th

http://marxsoftware.blogspot.com/search/label/Java%20%28General%29

http://stackoverflow.com/questions/5721496/learning-java-so-i-can-get-at-clojure

http://stackoverflow.com/questions/11358929/what-should-a-scala-developer-know-about-java-and-or-the-jvm

------------

You do need to know about classpaths and the basic hotspot configuration options for heap, GC, inlining, (You'll often see -Xmx and Xms, Xss set in eclipse etc. Rich Hickey recommends increasing MaxInlineSize to 100 or more.

For Intellij's sake i only use Oracle JVM, but I wouldn't on windows unless they've removed the semi-malware that was bundled with it.

http://stackoverflow.com/questions/14382932/increase-jvm-max-heap-size-eclipse

Also Hunt and John's tuning book is excellent: http://www.amazon.com/dp/0137142528/

u/RodeoMonkey · 6 pointsr/Clojure

Yes, which is totally awesome BTW, and I think your book is a great place for people to start.

https://www.amazon.com/Web-Development-Clojure-Build-Bulletproof/dp/1680500821/

The question is, for a newbie interested in Clojure, how do we direct them to Luminus, or a similar set of beginner "blessed" libraries, as a definitive starting spot. To keep them from getting lost in the universe of alternative options. Basically every step of the process of getting started presents a beginner with options that they won't know how to answer until much later. Emacs or Cursive, Boot or Lein, Pedestal or Ring, Selmer or Enlive, Korma or Yesql, Om or Reagent.

What helped make Ruby and Rails easy to learn is those initial choices were pre-made. You were using Textmate, Rails (Rack, ActiveRecord, Prototype). Even though there were some bad choices, like Prototype as the default JS library, just by that choice being pre made it let you move forward into the learning. And by the time you built something, you knew enough to swap it out for JQuery, or whatever.

u/yogthos · 19 pointsr/Clojure

In practice lots of companies of all sizes are using Clojure for web development today. The success stories on the official site are a good place to start to see what it's being used for. I work in the enterprise and my team moved from Java to Clojure over past 6 years. We couldn't be happier with our decision.

What practical examples are you looking for specifically?

I published a Web Development with Clojure book that specifically focuses on building web applications using the language.

There aren't any frameworks because the community hasn't found them to be of value so far. However, that doesn't imply that there isn't a mature web platform available for Clojure. Luminus is widely used. It couples a template for generating the boilerplate for typical applications with documentation on how to accomplish common tasks. There are other alternatives as well such as Yada and Pedestal.

In terms of libraries and ecosystem, here are a few examples:

  • compojure-api is a fantastic library for writing services
  • HugSQL is a library I use for database access, but there are lots of others such as Honey SQL.
  • you can use any Java logging library, I personally use logback. However, there's Timbre which is a Clojure centric logger.
  • buddy is a popular authentication and authorization library

    Polymorphism is supported in the language via multimethods and protocols.

    Libraries such as component and integrant are used for inversion of control. Meanwhile, mount provides a novel and automated way to manage resource lifecycle.

    My experience working with OOP for over a decade is that it does not deliver on its promises. Large OOP codebases end up tangled and difficult to maintain due to shared mutable state. These systems are hard to reason about and they're hard to test. Any time you come back to an old project, it's hard to tell whether a change you make will be isolated or it will affect another part of the application via side effects.

    I found that code reuse was difficult to accomplish in practice, and also rare. With a language like Java, you end up writing most of the logic in methods, and those are only usable within the context of a particular class. When you need a similar method in a different class, you can't reuse your existing code directly. This leads to a mess of adapter and wrapper patterns often seen in OO codebases.
u/couch_seddit · 0 pointsr/Clojure

I love the book Head First Java http://www.amazon.com/Head-First-Java-Kathy-Sierra/dp/0596009208

That may be too thorough for you though. It's a great book.

u/mcvoid1 · 1 pointr/Clojure

> I've never taken any CS classes and so I am lacking in my understanding of the O(n*long(n)) stuff. Do you have any good resources so I can do a little research?

The definitive guide or big-O and algorithms is referred to by us CS types as "CLR", though looking up "Big-O Notation" on wikipedia will give you a quick intro. What O(n log n) means is that you calculation is working on every item in the list (n items) on the order of log n times. The smaller the function in the big-O, the more efficient it operates as you increase the input size, such as the length of the list.

u/dustingetz · 5 pointsr/Clojure

Good error messages and bulletproof tool experience will be a priority for teaching unless you wanna be the on-call guy. I've tutored 1:1 for kids and you want them to feel in control right away, making something real that they can show mom ("I made this HTML file with cats in it!") and stay motivated. Something like this <https://www.amazon.com/Learn-Program-Minecraft-Transform-Python/dp/1593276702/> where I can get them set up and then they can teleport their avatar around immediately (nb I haven't used this book before)

u/htedream · 2 pointsr/Clojure

most of the algorithms books are for any programming language as long as they are imperative.

as far as functional languages go, there are:

u/joinr · 1 pointr/Clojure

> travelling salesman is intractable

In Pursuit of the Traveling Salesman is pretty interesting historical and technical overview of advances here. With modern ILPs and cuts and other techniques, the notion of intractable today vs. 20 years ago is vastly different.

u/stefan_kurcubic · 2 pointsr/Clojure

i've been looking for comprehensive guide on clj concurrency

today i got https://www.amazon.com/Java-Concurrency-Practice-Brian-Goetz/dp/0321349601

thank you for this

u/gifsbegone · 1 pointr/Clojure

As a fellow noob, I'm about half-way through Clojure for the Brave and True and it's really thorough and easy-to-follow so far.

u/DrUngood · 6 pointsr/Clojure

Web Development in Clojure, written by the author of this library, is also very good.

u/ProfessionalSet0 · 1 pointr/Clojure

I want a thorough and up-to-date tutorial on the language. I want it to have exercises and to be more than just a syntax reference guide. Something like this textbook is for Haskell.

u/joequin · 3 pointsr/Clojure

If you don't mind spending money, spend it on a good book such as this. You can probably hack some decent web apps with just online tutorials and documentation though.

u/RedDeckWins · 4 pointsr/Clojure

I would highly recommend reading Purely Functional Data Structures.

Right now it only works with numbers. If you utilized compare you could make it more generalized.

u/sankyo · 1 pointr/Clojure

In short, unless you spend all of your time writing boring, vanilla business logic, you will spend a lot of time with your fact in this book "Java Concurrency in practice" by Brian Goetz, which is a good book, but at some point you may wonder just what the hell you are doing with your life and if programming with thread has to be so complicated.

Pretty sure Rich already did this and we can learn from his journey.

u/dig1 · 5 pointsr/Clojure
  1. I would do that. Even better, plan to audit every user interaction if possible so you can recreate what exactly he/she did in case of complain (that is one of the reasons why casinos has so many cameras on a single table - users do complain when they start to loose).

  2. I don't understand this. Can you give a sample of this approach?

  3. Maybe unrelated directly to your topic, but Hacking POS will be good introductory book. There are many details you can skip, but also you can find various approaches done in banking business and apply them to your case. Sorry, no code, mostly theory and practice.
u/DeusExCochina · 1 pointr/Clojure

Heh, I'm not about to! I don't even try to understand the other Purely Functional Data Structures - it's all black magic to me. But you're right - that doubly linked lists map so poorly onto immutable structures is no doubt a very strong reason we're not seeing them there.